Hey,
Have a set of API already finished api controllers in our main project, I was asked to use Swagger to generate the description of the API, by going to (website).com/swagger/docs/v1 ect. Then put it through the swagger online tool to generate a c# rest client which seemed to work fine. I've just added a simple console application to that project it generated and want to write some examples of consuming those rest api methods.
My questions are pretty much:
How do I go about doing the above?
Is there a best way?
How do I authenticate these requests? On swagger ui, you just put the bearer - 'apikey' in, not sure how to do similar in the console application.
But yeah, never worked with web api before or swagger so any help greatly appreciated.
Thanks!