Swashbuckle.WebApi
Swashbuckle.WebApi copied to clipboard
Swagger UI does not show properly when custom message handler is used in web api 2
I am implementing a generic response for my web api 2 project. I implemented a delegatingHandler that create a response with my custom response type.
class WrappingHandler : DelegatingHandler{
...
}
Registered it in WebApiConfig before routes like
config.MessageHandlers.Add(new WrappingHandler());
I have swashbuckle 5.6.0 installed when I comment above line swagger UI shows up. However, with above code UI does not show any API controllers. Only this show up:
{"StatusCode":200,"ErrorMessage":null,"response":null}
There is no error in console and UI works fine otherwise.
I have same issue. Can anyone help please?
Same