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

Potential issues with open api schema #299

Open
paul-rinaldi opened this issue Dec 18, 2024 · 1 comment
Open

Potential issues with open api schema #299

paul-rinaldi opened this issue Dec 18, 2024 · 1 comment

Comments

@paul-rinaldi
Copy link

The yaml schema seems to have a number of issues...

Structural error at info
should have required property 'version'
missingProperty: version
At line 2

Semantic error at paths./member/congress/{congress}.get.operationId
Operations must have unique operationIds.
At line 3325

Semantic error at paths./member/{stateCode}
Equivalent paths are not allowed.
At line 3362

Semantic error at paths./committee/{congress}
Equivalent paths are not allowed.
At line 3872

Semantic error at paths./committee/{chamber}/{committeeCode}
Equivalent paths are not allowed.
At line 4169

Easily view these errors by pasting the open api specification in https://editor.swagger.io/

@paul-rinaldi
Copy link
Author

paul-rinaldi commented Dec 18, 2024

Perhaps,

  • the /congress endpoint should have an operationId of operationId: "congress_members_list" since it doesn't list congresses.
  • version: "3.0" should be added to the info property
    These two eliminate two of the issues swagger raises.

Looks to me like

  • /member/{statecode} and /member/{bioguideId} clash and that is causing Semantic error at paths./member/{stateCode} Equivalent paths are not allowed.
  • /committee/{congress}/* and /committee/{chamber}/* clash and that is causing Semantic error at paths./committee/{congress} Equivalent paths are not allowed.
  • I do not see why /committee/{chamber}/{committeeCode is flagged though.

These affect multiple paths and I'm not sure the effort required since I do not engage in this domain often.

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