Is there a way to describe two different response types in OpenAPI 3.0?
问题 What I'd like to do is specify that sometimes the response to an API call might be a PDF document, and sometimes it will be JSON. I'd like to do this in OpenAPI 3.0 format. In the case of a PDF, the response would look like this: responses: '200': description: An invoice in PDF format. content: application/pdf: schema: type: string format: binary And in the case of a JSON response, this would describe the response: responses: '200': description: A JSON object containing user name and avatar