swagger-ui
swagger-ui copied to clipboard
Body sample XML response
There is a problem with the XML Body Sample. The JSON snippet works well but when I choose the XML type format this doesn't change. It stays in the JSON format. Could you fix that please ?
Hello,
The swagger-ui version used inside this project search a content-type. So you could solve your problem, sending the good content-type into the response headers :
Example for python :
response = make_response(your-xml)
response.headers['Content-Type'] = 'application/xml'
Hope it help.
Regards,
Thierry