SwaggerUI specify default values #2868
-
Is there any way to provide default values for swaggerUI so when you use the endopint, it has some default data so you just can call the endpoint with all filled defaults? Something like this: Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
That is not implemented yet. For now, a solution is to manually customize the OpenAPI output and add the "parameters": {
...
"rowFilter.your_table.column": {
"name": "column",
"required": false,
"format": "text",
"in": "query",
"type": "string",
"example": "eq.Value"
},
...
} We're not doing big changes to the OpenAPI output before #1698 is completed. I'll open an issue to keep track of this in the meantime. |
Beta Was this translation helpful? Give feedback.
-
I don't really understand how to override parts of the standard swagger resultset, the example in the docs states how to fully replace the response with a static json following openapi. Maybe I will wait until #1698 is complete. Thanks! |
Beta Was this translation helpful? Give feedback.
That is not implemented yet. For now, a solution is to manually customize the OpenAPI output and add the
"example"
key to each"parameter"
, e.g:We're not doing big changes to the OpenAPI output before #1698 is completed. I'll open an issue to keep track of this in the meantime.