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

Feature Request: Error on additional properties #1014

Open
leeleahulkcs opened this issue Nov 29, 2024 · 0 comments
Open

Feature Request: Error on additional properties #1014

leeleahulkcs opened this issue Nov 29, 2024 · 0 comments

Comments

@leeleahulkcs
Copy link

In the OpenAPI spec, for object types, I add additionalProperties: false.

With this project, using the removeAdditional for both validateRequests and validateResponses, I can have all additional properties removed.

I noticed and tested that unknown query parameters will cause an error to be returned instead of a silent removal.

A similar project https://github.com/kogosoftwarellc/open-api/tree/main/packages/openapi-response-validator, will return an error when an additional property is found.

I would like to request that this project add a configuration option to both validateRequests and validateResponses so that an additional property will cause an error to be returned instead of a silent removal. This is to match the current behavior of allowUnknownQueryParameters and the other similar project.

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

1 participant