swagger-editor icon indicating copy to clipboard operation
swagger-editor copied to clipboard

Swagger editor allows to define object with required attributes and no definition

Open kejmyn opened this issue 8 months ago • 0 comments

Q&A (please complete the following information)

  • OS: macOS
  • Browser: Firefox
  • Version: 120.0.1
  • Swagger-Editor version: latest: https://editor.swagger.io/
  • Swagger/OpenAPI version: 3.0.1

Content & configuration

Using the online demo at editor.swagger.io.

Example Swagger/OpenAPI definition:

 schema:
            type: object
            required:
              - param1
              - param2
            properties:
              param1:
                type: string

Describe the bug you're encountering

The editor does not detect such definition as an error, there is no checking if attributes defined as required are defined in "properties".

kejmyn avatar Dec 18 '23 15:12 kejmyn