-
-
Notifications
You must be signed in to change notification settings - Fork 504
Open
Open
Feature
Copy link
Labels
openapi_31OpenAPI 3.1 related issueOpenAPI 3.1 related issue
Description
Problem
I expect the pagination parameter to appear in the URL as &pagination[limit]=10&pagination[offset]=0.
However, the generated URL ends up as &pagination=[object+Object], because object-type query parameters are not supported.
There is no configuration option to override or customize URL generation, which makes it impossible to use objects for forming query parameters.
More details in the documentation - https://spec.openapis.org/oas/v3.1.0.html#style-examples
Is there a plan to add style support?
Scheme
"parameters": [
{
"name": "pagination",
"in": "query",
"required": true,
"style": "deepObject",
"explode": true,
"schema": {
"type": "object",
"title": "PaginationInDto",
"properties": {
"offset": {
"type": "integer"
},
"limit": {
"type": "integer"
}
},
"required": [
"offset",
"limit"
]
}
}
],Example of usage in code
const { data } = useGetCatalogRubric({
pagination: {
limit: 10,
offset: 0,
},
});andrew-samson, zagorodnyukwork and hrm1810884
Metadata
Metadata
Assignees
Labels
openapi_31OpenAPI 3.1 related issueOpenAPI 3.1 related issue