Skip to content

OpenAPI Spec contains validation errors #434

@obrhoff

Description

@obrhoff

The current OpenAPI specification is not valid and cannot be used in tools like Swagger Editor or code generators.

Steps to Reproduce
1. Open Swagger Editor.
2. Paste the contents of the OpenAPI spec file.
3. Observe the validation errors.

Observed Errors

Swagger Editor reports multiple structural issues:

Errors
Hide
 
Structural error at components.parameters.comment_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.follower_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.following_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.playlist_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.fake_playlist_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.repost_playlist_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.track_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.test_track_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.user_id
should have required property 'required' missingProperty: required
Jump to line 0
Structural error at components.parameters.user_id_to_follow
should have required property 'required' missingProperty: required
Jump to line 0

The Apple OpenAPI code generator for Swift also fails with similar issues:

- Additional file comments: <none>/Users/obrhoff/Downloads/new_music_app/soundcloud-open-api-schema.yaml: error: Inconsistency encountered when parsing `comment_id` in Document.components.parameters: positional path parameters must be explicitly set to required.
Error: /Users/obrhoff/Downloads/new_music_app/soundcloud-open-api-schema.yaml: error: Inconsistency encountered when parsing `comment_id` in Document.components.parameters: positional path parameters must be explicitly set to required.
[generate] ERROR task failed

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions