-
Notifications
You must be signed in to change notification settings - Fork 9.1k
Are indexes in the query parameter array representable? #1501
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
Comments
@webron, I think you originally added collectionFormat and style so probably you have given this some thought |
Your last example parameters:
- in: query
name: map
schema:
type: object
properties:
x:
type: integer
y:
type: integer
style: deepObject
explode: true or parameters:
- in: query
name: map
schema:
type: object
additionalProperties:
type: integer
style: deepObject
explode: true Not sure about other examples though. |
.NET uses the However, when .NET has to pass an array of objects, it switches to the This issue is better documented here: domaindrivendev/Swashbuckle.AspNetCore#1832 |
I've just recently encountered this issue myself. Has anything new happened? |
This notation is also commonly used in PHP |
I have a question about the workaround: is it legit to name the parameter with brackets. E.g. for the author example it would be |
@OleksiiBulba the OpenAPI parameter name syntax allows it. Although the question of whether non-percent-encoded |
@handrews thanks for your prompt response! Actually, I've already tried it with P.S. For anyone who would find this comment: if your property is required, don't forget to add |
I understand how to represent in 2.0 and 3.0 these query parameters with OpenAPI:
But I can't understand if it is possible or not (so I imagine, not?) to represent this:
or this:
We use indexes so we can mix arrays and maps with the same notation, i.e. we would also have:
Is this even representable today? Any hack around it if not?
The text was updated successfully, but these errors were encountered: