1

I am trying to add a reference to a global parameter in an operation in swagger doc in below manner, but couldn't figure out a way to do this in swashbuckle.

"paths": {
   "<path>": {
   "post": {
         "parameters": [{"$ref": "#/parameters/<globalparam>"}]
           }
     }
  }

I checked out NonBodyParameter() but it doesn't have ref field defined. Is it possible to achieve this via Swashbuckle.AspNetCore?

user1097128
  • 93
  • 11
  • This can be accomplished by post-processing using IDocumentFilter https://stackoverflow.com/questions/62782119/how-to-use-swashbuckle-to-generate-global-parameters-in-the-resulting-swagger-fi – Rune Jul 02 '21 at 08:14

0 Answers0