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

Request body rendering for application/jose content-type #622

Closed
Wachiwi opened this issue Dec 8, 2021 · 1 comment
Closed

Request body rendering for application/jose content-type #622

Wachiwi opened this issue Dec 8, 2021 · 1 comment

Comments

@Wachiwi
Copy link
Contributor

Wachiwi commented Dec 8, 2021

When having a different content type than application/json or application/xml the rendering of the schema is slightly confusing. E.g. we use application/jose at some points of our spec and it doesn't get rendered at all (see image below)

image

When using something like that I would expect it to render at least : string as it does it with text/plain since application/jose is represented as a base64 string.

Below you can find an attached example.

Example spec
openapi: 3.0.0
info:
  version: 4.2.0
  title: Whatsoever
  description: nah
paths:
  /ep:
    post:
      summary: POST stuff
      requestBody:
        required: true
        content:
          application/jose:
            schema:
              title: Title
              description: This is a description
              type: string
            examples:
              E1:
                value: ajasdjasdsad
          text/plain:
            schema:
              title: Title
              description: This is a description
              type: string
            examples:
              E1:
                value: ajasdjasdsad

      responses:
        '200':
          description: OK
          content:
            application/jose:
              schema:
                title: Anlage
                description: Verschlüsselte Anlage im Format JSON Web Encryption (JWE) laut RFC7516
                type: string
                pattern: '^[a-zA-Z0-9-_=.]+$'
@mrin9
Copy link
Collaborator

mrin9 commented Feb 21, 2022

thanks for reporting, will work on it soon

@mrin9 mrin9 closed this as completed in 179f5e8 Feb 23, 2022
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

2 participants