cancel
Showing results for 
Search instead for 
Did you mean: 

Does Swagger create routes or controllers while executing documentation for Rest Api (C#)

Highlighted
New Contributor

Does Swagger create routes or controllers while executing documentation for Rest Api (C#)

Hello everybody,
I am trying to set rights (according to my own database repository) to my C# Rest Api Swagger documentation.
In other words, I would like to decide who can display the Swagger documentation for my Rest Api.
I would like to know how does Swagger works.
Does it create controllers, routes when executing which I can catch by code to check the rights before displaying ?
What are the objects I can interact with ?
I would like to read the current routes to check in my database who can display documentation for this route.
Thank you very much in advance.
Eric.

2 REPLIES 2
Highlighted
Moderator

Re: Does Swagger create routes or controllers while executing documentation for Rest Api (C#)

Hi Eric,

 

Since you use C# you're most likely using Swashbuckle. Swashbuckle is not one our projects and we don't know the specifics of how it works. Your best bet is to go through the Swashbuckle documentaiton, and if you don't find answers to your questions, file a ticket with them for further support.


Helen Kosova
SmartBear Technical Writer
________________________

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
Highlighted
New Contributor

Re: Does Swagger create routes or controllers while executing documentation for Rest Api (C#)

Thank you for your answer Helen,

I will post my question in the Swashbuckle tag.

Eric.

New Here?
Join us and watch the welcome video: