-
-
Notifications
You must be signed in to change notification settings - Fork 20
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
Actual behavior (the bug)
I have a javalin server that has an API and an openapi specification, but no javalin-openapi annotations. (We actually use spec-first and generate the code with openapi-generator.tech which has a javalin6 generator as part of kotlin-server).
I serve the generated openapi.yaml under /openapi
and register config.registerPlugin(SwaggerPlugin())
The swagger UI doesn't load under /swagger
and says no API found.
Expected behavior
Swagger UI working under /swagger
To Reproduce
Set up project with just swagger plugin and a server openapi file.
Additional context
I found a workaround. The problematic code is
Line 56 in 7e1ec6d
val versions = OpenApiLoader() |
OpenApiLoader
is asked to provide all API versions.I added a resource file
openapi-plugin/.index
with just the word default
in it and then everything works.It would be nice if the SwaggerPlugin config could accept the versions of the API (and maybe revert back to
default
if the openapi plugin is not active) so that this works more easily.Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request
Type
Projects
Status
✅ Done