Ask a Question

C# Class for Swagger.json

New Contributor

C# Class for Swagger.json

I need to parse a swagger.json file to dynamically find out what paths are available and what parameters for instance a POST requires. I do not know the content of it beforehand. Currently I am using the Newtonsoft JSON library to deserialize the swagger.json into a C# object. However, the parsing is kind of cumbersome. It would be so much easier if there was a known class that I can deserialize to. I understand that items like "parameters" will vary from case to case. Anyhow, is there a way to accomplish this? If not, what is the best way to parse a swagger.json file.

SmartBear Alumni (Retired)

Hi Hala,

Are you familiar with Swager Parser? it looks like this tool is what you need.

Tanya Yatskovskaya
SmartBear Community and Education Manager

Showing results for 
Search instead for 
Did you mean: