Open
Description
Q&A (please complete the following information)
- OS: Windows 10
- Browser: Firefox, Chrome, Edge
- Method of installation: npm
- Swagger-UI version: 3.11.0
- Swagger/OpenAPI version: Swagger 2.0
Content & configuration
I've reproduced this locally, but even easier to demonstrate, petstore has the same issue.
Example Swagger/OpenAPI definition:
https://generator.swagger.io/api/swagger.json
snippet from swagger.json
responses:
200:
description: "successful operation"
schema:
type: "array"
items:
$ref: "#/definitions/Pet"
Describe the bug you're encountering
In swagger ui, when you have a GET that has a response that is a list, and you selected content type of xml, the Example Value has an error "XML example cannot be generated".
To reproduce...
Steps to reproduce the behavior:
- Go to https://editor.swagger.io
- Expand /pet/findByStatus
- Make sure Response content type is application/xml
- Example Value for status code 200 has "XML example cannot be generated"
Expected behavior
I would expect to see the example xml for the response.