Object in Query must be sent inline, not plain
Hello,
I have a query parameter in my Swagger doc, let's call it "tree". It is an object and can for example look like this:
tree={"apple":{"count":1}}
Whenever Swagger sends this query parameter to the server, it looks like this (encoded, of course - here, I put it decoded, for better readability)
https://myserver.de?tree={"apple":{"count":1}}
This does not work in my server. I need the object to be sent in this format:
https://myserver.de?tree[apple][count]=1
Is there any way to achieve this with Swagger?
My config is pretty basic, just:
"tree": {
"name": "tree",
"description": "a tree",
"in": "query",
"schema": {
"$ref": "#/components/schemas/theParent/properties/tree"
}
}
The schema itself is pretty complicated, but it is a plain object, defined with properties.
If there is a way to adjust the sending of parameters, I would be very grateful!
Thank you and best regards,
Dylan