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

parameters with default values #707

Closed
orensolo opened this issue Dec 15, 2022 · 0 comments · Fixed by #708
Closed

parameters with default values #707

orensolo opened this issue Dec 15, 2022 · 0 comments · Fixed by #708

Comments

@orensolo
Copy link
Contributor

orensolo commented Dec 15, 2022

Hi,

I am using kinopenapi version 0.110.0,
If the schema contains parameters with a default value, and those parameters are missing in the request, then kinopenapi adds the
default values to the request after the validation.

This is not the desired behavior (in some cases) when the validation takes place on the client side.
This is because of the following reasons:

  1. The payload is unnecessarily larger.
  2. The server may respond differently if the default value exists.

So, the already existing SkipSettingDefaults option should be used for query parameters as well.
I will create a pull request to handle this issue.

Thanks,
Oren

@orensolo orensolo changed the title default parameters parameters with default values Dec 15, 2022
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

Successfully merging a pull request may close this issue.

1 participant