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

Parameter explode: true does not work #573

Open
hamir-suspect opened this issue Nov 17, 2023 · 1 comment
Open

Parameter explode: true does not work #573

hamir-suspect opened this issue Nov 17, 2023 · 1 comment

Comments

@hamir-suspect
Copy link
Contributor

hamir-suspect commented Nov 17, 2023

As per openapi if the explode: true and style: form the parameters should be serialized as follows:

URI template: /users{?id*}
Object id = {"role": "admin", "firstName": "Alex"} ---> /users?role=admin&firstName=Alex

With current implamentation of OpenApiSpex.CastParameters it is only possible to use query param as a deepObject and that looks like: /users?id[role]=admin&id[firstName]=Alex.
The explode: true does nothing in this case.
The CastParameters module when creating a schema for a location (path, query,...) it is always using the top name of the object and not exploding the parameter properties.

@hamir-suspect
Copy link
Contributor Author

WDYT @moxley @mbuhot

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