Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support text/plain response examples #270

Closed
aksyonov opened this issue May 22, 2017 · 4 comments
Closed

Support text/plain response examples #270

aksyonov opened this issue May 22, 2017 · 4 comments

Comments

@aksyonov
Copy link

aksyonov commented May 22, 2017

Thank you for very useful project.
I saw that xml response examples support was added in 1.16.0. Is it possible to also fallback to text/plain example if json or xml example is not present?

@RomanHotsiy
Copy link
Member

@aksyonov yes, sure.

Will try to add this for the next release

@RomanHotsiy
Copy link
Member

@aksyonov it took much time that I expected.
Won't add this in this release but I aim to have it in the next week release

@rishagit
Copy link

just wondering if there is any way to display response example using text/plain?

@rafgugi
Copy link

rafgugi commented Jan 25, 2025

Im still not be able to display plain text example

openapi: 3.0.0
info:
  title: Slot API
  version: 1.0.0
  description: API for checking the slot of the current meta.

paths:
  /health:
    get:
      summary: Health check endpoint
      description: Returns the health status of the service.
      operationId: healthCheck
      responses:
        '200':
          description: Service is healthy
          content:
            text/plain:
              schema:
                type: string
                example: "OK"
        '503':
          description: Service is unavailable
          content:
            text/plain:
              schema:
                type: string
                example: "Service Unavailable"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants