0

I have been developing a WebApi2 REST API with swagger docs (using swashbuckle) for a while now however in my local sandbox version I cannot get to the SwaggerUI, nor the swagger xml via a GET request. I have compared swagger setup between my code versions and there has not been any code changes in this area. I have uninstalled swashbuckle and IISExpress without any effect. I am running out of ideas and I would appreciate some advice on next steps to try and debug the swagger generation / or find out if there is any logging I can switch on the help diagnose further.

Apologies for posting such a general problem, but I am at a loss after looking at this for about 5 hours now.

Thanks

Mark

venerik
  • 5,766
  • 2
  • 33
  • 43
Mark Ruse
  • 387
  • 1
  • 4
  • 12
  • What is url of your SwaggerUI? What does happen when you navigate to that url? Do you get an error message? Did you inspect the HTTP messages using a tool like `Fiddler`? – venerik Mar 24 '16 at 18:49
  • 404 both for this and also going direct for the v1 doc - I will leave this open for a bit in case it helps collate info for others, but I ended up reverting and applying my changes again – Mark Ruse Mar 24 '16 at 20:08
  • Did you ever figure this out? – bsayegh Mar 31 '16 at 14:03
  • Unfortunately not - reverting to a working version and applying my changes was the only solution I could find. Do you have the same issue? – Mark Ruse Mar 31 '16 at 17:33

1 Answers1

0

I know it's an old question, but something similar happened to me and might happen to somebody else. The csproj has the "Build > XML doc file" config set. Swagger stopped generating the right docs because this option got unchecked, I might have disabled it accidentally. Checking it again and setting the value used in Swashbuckle config did the trick!

Luciano Santos
  • 201
  • 1
  • 2