@Bean
		public OpenAPI openApi() {
			return new OpenAPI()
					.components(new Components()

							//HTTP Basic, see: https://swagger.io/docs/specification/authentication/basic-authentication/
							.addSecuritySchemes("basicScheme", new SecurityScheme()
									.type(SecurityScheme.Type.HTTP)
									.scheme("basic")
							)

							//API Key, see: https://swagger.io/docs/specification/authentication/api-keys/
							.addSecuritySchemes("apiKeyScheme", new SecurityScheme()
									.type(SecurityScheme.Type.APIKEY)
									.in(SecurityScheme.In.HEADER)
									.name("X-API-KEY")
							)

							//OAuth 2.0, see: https://swagger.io/docs/specification/authentication/oauth2/
							.addSecuritySchemes("oAuthScheme", new SecurityScheme()
									.type(SecurityScheme.Type.OAUTH2)
									.description("This API uses OAuth 2 with the implicit grant flow. [More info](https://api.example.com/docs/auth)")
									.flows(new OAuthFlows()
											.implicit(new OAuthFlow()
													.authorizationUrl("https://api.example.com/oauth2/authorize")
													.scopes(new Scopes()
															.addString("read_pets", "read your pets")
															.addString("write_pets", "modify pets in your account")
													)
											)
									)
							)
					)
					.addSecurityItem(new SecurityRequirement()
							.addList("basicScheme")
					)
					.addSecurityItem(new SecurityRequirement()
							.addList("apiKeyScheme")
					)
					.addSecurityItem(new SecurityRequirement()
							.addList("oAuthScheme")
					)
					;
		}
Given: Bean configuration with security scheme OAuth2
When: Get api-docs
Then: Return security definitions with OAuth
springdoc-openapi-starter-webmvc-api/src/test/java/test/org/springdoc/api/v30/app5/sample/OpenAPIResourceBeanConfigurationComponentsSecuritySchemesTest.java