-
Notifications
You must be signed in to change notification settings - Fork 646
Add DELETE /api/v1/trusted_publishing/tokens
API endpoint
#11234
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
Conversation
Would you be willing to also add some regression tests? Specifically around cross-crate and user manipulation. This could probably apply to some of the other endpoints as well. Id feel better just covering any future errors. |
absolutely, but could you be slightly more specific on the exact scenarios you would like to see tested? :) |
1141dd8
to
a9cde09
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple of incredibly minor notes, but no blocking concerns. Great work! 👍
This makes it possible to construct `MockTokenUser` instances from an existing plaintext token or other random header value.
#11131 has been merged, so this PR is now muuuuch smaller and ready for review :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just left a nitpick question which is not blocking! This LGTM, thanks for the nice work 👍
This PR adds an endpoint to revoke a temporary access token from the Trusted Publishing flow.
The
DELETE /api/v1/trusted_publishing/tokens
endpoint expects the token to be handed over in theAuthorization
header as aBearer
token, similar to how it will be used in the publish endpoint.This PR is based upon (and currently includes the changes of) #11131, which implements the API endpoint to create a temporary access token (from a JWT).
Related:
PUT /api/v1/trusted_publishing/tokens
API endpoint #11131