-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Support security OAuth2 scopes on operations #283
Comments
If this is something that is agreed-upon as a good feature, I'm willing to help with a PR to get this in. |
I have this working by showing any OAuth2 scopes beneath the responses for each operation (won't display if there are no oauth2 scopes for an operation): There are other UX possibilities of course, like adding the security info all in a tip (for example with a little padlock icon that shows the security scopes when hovering over, next to the operation description). I'll follow with a PR for what I've done if this looks like a good first step. Thanks! |
@jimmyjames I would love to see it be associated with the request vs. the response personally. |
Yeah @Schandlich I kind of agree. What about something like this, where there's a tooltip hint floated right of the operation (similar to Swagger UI): |
@jimmyjames I think the location is right. I would use a different icon though. Excited for this! |
@jimmyjames sorry for long reply! This looks awesome. Proceed with PR please! |
@RomanGotsiy will do, need to move it from proof-of-concept to PR-worthy (me no Angular so well 😄 ). I used a |
Start with |
+1 this feature will be awesome! I can help too |
+1 would really like this, |
+1 for sure! |
What is the status of this feature? Currently there is no way to see security at an operation leve. |
I think it's being worked on in version 2. |
as @theholiday mentioned this is being worked on in version 2. Here is the screenshot of the current implementation: If anyone has a better idea of how to visualize this, please share here! |
I just noticed it's a dup of #7. Let's track this there. |
Operations may define the required OAuth2 scope. For example, in the example PetStore spec, to
POST
to the/pet
endpoint to create a new Pet, it is required that the token have read and write permissions:You can see from the demo that the required auth scopes are not shown for the operation.
Is it on the near-term roadmap to support rendering the required auth scopes for an operation? We are loving ReDoc, but this is a pretty big deal as users need to know the required auth scope.
The text was updated successfully, but these errors were encountered: