swagger-api/swagger-ui
GitHub で見るResponse Body not shown when Content-Type in the response header is not set
Open
#6,149 opened on 2020年6月16日
Hacktoberfestspecification: 3.xtype: bug
Repository metrics
- Stars
- (25,447 stars)
- PR merge metrics
- (平均マージ 20h 34m) (30d で 14 merged PRs)
説明
Q&A (please complete the following information)
- OS: macOS
- Browser: chrome
- Method of installation: dist
- Swagger-UI version: 3.26.2
- Swagger/OpenAPI version: OpenAPI 3.0
Describe the bug you're encountering
When the Content-Type response header is not set, swagger-ui does not show the Response Body. I am seeing this issue when using OpenAPI 3.0 with swagger-ui 3.26.2

When using Swagger 2.0 with swagger-ui 2.2.10, we do see Response Body even when the Content-Type response header is not set.

As you can see in the above picture, the Content-Type is set to null
So I am wondering if there is any way for swagger-ui(3.26.2) to show the Response Body even when the Content-Type response header is not set
Additional context or thoughts
I can confirm that if I pass in the Content-Type response header, the Response Body is seen like below
