-
Notifications
You must be signed in to change notification settings - Fork 9.1k
Description
I would like to be able to specify to each path some labels and make them visible in the UI. A usecase for this is to mark the paths for specific user roles from your API. Let me give you an example.
Let's say you want to group the paths by controller eg of tags to group them:
- pet
- store
Each having a lot of operations on them eg:
- pet/update
- pet/remove
- store/update
- store/filter
- store/clear
- etc...
I want to group them by controller(all pet and all store), that can be done with tags. But I also want to label some of those. for example I want to mark those operations that can be done by a specific user role .
For example only admins can call store/clear
and receive a valid response, the rest of the users(normal users) can only call the other APIs. This way you can specify in the docs for what type of user are those paths, and this is only a use case, but I'm sure this can be used for other use cases.
I would like a way to add these labels and display them as in this image:
Can this be done? I tried to find something that already exists but couldn't find anything.
Here's someone from stackoverflow who asked something similar 3 years ago(I used their image): https://stackoverflow.com/questions/65422963/does-swashbuckle-support-a-way-to-represent-custom-operation-tags-as-badges-in-t