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

Rename exampleParametersResolution to responseParametersResolution #408

Open
steve-nay-sage opened this issue Sep 20, 2021 · 4 comments
Open
Labels
example-object feature New feature request, accepted for probable development importer

Comments

@steve-nay-sage
Copy link

For requests there is an option named requestParametersResolution that determines whether request bodies are created from schemas or examples. For responses, the equivalent parameter is named exampleParametersResolution. Shouldn't that name be responseSchemasResolution since it's about response schemas and not about example schemas? I thought maybe it was a mistake in the instructions, but I tried responseParametersResolution and got an error saying that it's invalid.

@khazamov
Copy link

+1

@khazamov
Copy link

I would go even further and ask why we have to choose? Ideally, if the example is available then Postman should use a provided example. If example is not available then it should fall back to the request parameter. Basically, instead of specifying request resolution and response resolution enums it should be "primary" and "fallback" resolution methods.

@umeshp7
Copy link
Member

umeshp7 commented Feb 14, 2022

@khazamov @steve-nay-sage Thanks for the feedback.

The example in the name indicates the Postman Example and not the response in the OAS spec. But I do understand the confusion.

@khazamov Also regarding the defaults: https://github.com/postmanlabs/openapi-to-postman/blob/develop/OPTIONS.md Here you can find that for exampleParametersResolution the default is in fact example. And if that is not found we fall back on the schema. We can also think of making the default for requestParametersResolution to example too, but that might affect existing users in postman app.

cc @VShingala

@VShingala VShingala added feature New feature request, accepted for probable development example-object labels Jan 13, 2023
@vedant-z
Copy link

@umeshp7 Is this issue open for contributing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
example-object feature New feature request, accepted for probable development importer
Projects
None yet
Development

No branches or pull requests

6 participants