Description
Request parameter object of GET request is shown as JSON on swagger-ui instead of individual parameters.
This issue has been mentioned a few times before:
- Add support for object as request parameter container #120
- Object request parameter issue #67
- Support beans as parameter in @GetMapping / components empty #12
These all have been closed as they are caused by an issue in swagger-ui project. However, that issue was opened 18 months ago and there is not much activity on that project so I don't expect it to be fixed anytime soon (if ever).
Would it be possible to generate parameters in the OpenAPI docs such a way that it can be correctly presented by swagger-ui?
I created a demo project with 2 endpoints:
https://github.com/martin-tarjanyi/openapi-ui-issue/blob/master/src/main/java/com/example/openapiuiissue/DemoController.java#L13-L23
As I understand semantically there is no difference between them. However, the generated API docs (and in consequence the UI) is quite different.
I'm rising this issue again because this is the only thing which prevents me from moving all my projects to springdoc. I also would be happy to contribute to solve this issue if possible.