Closed
Description
Hi, not sure if this is a bug or if I'm doing something wrong:
I have a spring boot application with this annotation
@SpringBootApplication(scanBasePackages = "packages")
@OpenAPIDefinition(
info = @Info(
...
),
servers = {
},
security = {@SecurityRequirement(name = "basicAuth"), @SecurityRequirement(name = "bearerToken")}
)
@SecuritySchemes({
@SecurityScheme(
name = "basicAuth",
type = SecuritySchemeType.HTTP,
scheme = "basic"
),
@SecurityScheme(
name = "bearerToken",
type = SecuritySchemeType.HTTP,
scheme = "bearer",
bearerFormat = "JWT"
)
})
public class ExampleApplication {
I've also tried not using @SecuritySchemes
and just putting the two @SecurityScheme
, both result in the yaml having no securitySchemes
in component
.
If I only have 1 top level @SecurityScheme
, then it works.
How can I add multiple security schemes?
Thanks
Metadata
Metadata
Assignees
Labels
No labels