Skip to content

Desired Server URLs #2750

@AndreKremer

Description

@AndreKremer

Hello everyone
I am using Spring Boot v3.2.8 with the plugin ‘springdoc-openapi-starter-webmvc-ui:2.6.0’ and I would like to list two server URL inside the dropdown bar in the Swagger UI
Thanks to the well-written https://springdoc.org/#swagger-ui-properties documentation I am very close to this request
Now I am facing the following problem; My application is Designed by Contract. However, for programmatic reasons, no servers are included within the corresponding yaml.
Using springdoc.swagger-ui.url=/openapi.yaml the Swagger UI is generated accordingly and works fine
For the provision of the server url within the dropdown bar I have tried different approaches, but all unsuccessful
With the help of the documentation point 13.49. it was possible to list the desired servers in the dropdown, but the desired content using springdoc.swagger-ui.url=/openapi.yaml is ignored or overwritten
In the documentation under point 13.24. I came across the CustomServerBaseUrlCustomize method, which, however, does not list the desired server urls.
Now I wanted to ask where I can manually list server urls or whether this is even possible in combination with the config springdoc.swagger-ui.url=/openapi.yaml?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions