Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify behavior of list operations when no results found #26819

Merged
merged 3 commits into from May 14, 2024

Conversation

marcboudreau
Copy link
Contributor

This PR adds an explanation that when a LIST operation is issued and there are no results to return, the response is an HTTP 404 response. For example, when no UI headers are configured:

$ curl -v -H "X-Vault-Token: $VAULT_TOKEN" -X LIST "$VAULT_ADDR/v1/sys/config/ui/headers"
*   Trying [::1]:8200...
* Connected to localhost (::1) port 8200
> LIST /v1/sys/config/ui/headers HTTP/1.1
> Host: localhost:8200
> User-Agent: curl/8.4.0
> Accept: */*
> X-Vault-Token: ********
>
< HTTP/1.1 404 Not Found
< Cache-Control: no-store
< Content-Type: application/json
< Strict-Transport-Security: max-age=31536000; includeSubDomains
< Date: Fri, 03 May 2024 17:51:46 GMT
< Content-Length: 14
<
{"errors":[]}

@marcboudreau marcboudreau requested a review from a team as a code owner May 3, 2024 18:05
@github-actions github-actions bot added the hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed label May 3, 2024
Copy link

github-actions bot commented May 3, 2024

CI Results:
All Go tests succeeded! ✅

Copy link

github-actions bot commented May 3, 2024

Build Results:
All builds succeeded! ✅

website/content/api-docs/index.mdx Outdated Show resolved Hide resolved
Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>
@marcboudreau marcboudreau merged commit aaf59a7 into main May 14, 2024
32 checks passed
@marcboudreau marcboudreau deleted the marcboudreau/clarify-list-behavior branch May 14, 2024 17:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed pr/no-changelog pr/no-milestone
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants