You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to preview the documentation for an OpenAPI Document complying to the version 3.1.0 of the spec with empty paths, an error is shown.
Can you please check this? Thanks in advance.
How to reproduce
The OpenAPI Document I'm trying to render:
openapi: 3.1.0info:
title: Book Shelf APIdescription: An API to keep track of Booksversion: "0.1"contact:
name: API Designerlicense:
url: https://opensource.org/licenses/MITname: MITservers:
- url: http://api.bookshelf.compaths: {}
Expected Behavior
The API metadata is rendered.
Actual Behavior
This error is show:
Something went wrong...
Cannot read properties of undefined (reading 'type')
Stack trace
(...)
More context
According to the spec, a document with an empty paths is a valid one:
Thank you @pedrodovale for notifying!
Additional context: to reproduce the case I had to put a change to the definition (otherwise only blank screen is shown).
When trying to preview the documentation for an OpenAPI Document complying to the version 3.1.0 of the spec with empty paths, an error is shown.
Can you please check this? Thanks in advance.
How to reproduce
The OpenAPI Document I'm trying to render:
Expected Behavior
The API metadata is rendered.
Actual Behavior
This error is show:
More context
According to the spec, a document with an empty paths is a valid one:
(source: https://spec.openapis.org/oas/v3.1.0#paths-object)
Leaving the paths empty can be useful for API Designers that want to describe only the contact information or the API Security requirements.
The Redoc Interactive Demo seems to handle this correctly, rendering the API metadata.
The text was updated successfully, but these errors were encountered: