mservicetech / openapi-schema-validation

Apache License 2.0
17 stars 11 forks source link

Reject content types that are not listed #55

Open david0 opened 3 months ago

david0 commented 3 months ago

Shouldn't be unspecified content types rejected by this library?

For example with this OpenAPI

      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Pet'

requests using the Content-Type application/xml should be rejected. Even application/merge-patch+json should be rejected I think.