public final class HttpApiKeyAuthConverter extends java.lang.Object implements SecuritySchemeConverter<HttpApiKeyAuthTrait>
This is compatible with Amazon API Gateway API key authorization.
Constructor and Description |
---|
HttpApiKeyAuthConverter() |
Modifier and Type | Method and Description |
---|---|
SecurityScheme |
createSecurityScheme(Context<? extends Trait> context,
HttpApiKeyAuthTrait trait)
Creates an OpenAPI security scheme.
|
java.util.Set<java.lang.String> |
getAuthRequestHeaders(Context<? extends Trait> context,
HttpApiKeyAuthTrait trait)
Gets the names of the headers set on HTTP requests used by this
authentication scheme.
|
java.lang.Class<HttpApiKeyAuthTrait> |
getAuthSchemeType()
Get the U that matches this converter.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createSecurityRequirements, getAuthResponseHeaders, getAuthSchemeId, getOpenApiAuthSchemeName, usesHttpCredentials
public java.lang.Class<HttpApiKeyAuthTrait> getAuthSchemeType()
SecuritySchemeConverter
getAuthSchemeType
in interface SecuritySchemeConverter<HttpApiKeyAuthTrait>
public SecurityScheme createSecurityScheme(Context<? extends Trait> context, HttpApiKeyAuthTrait trait)
SecuritySchemeConverter
createSecurityScheme
in interface SecuritySchemeConverter<HttpApiKeyAuthTrait>
context
- Conversion context.trait
- Authentication trait to convert.public java.util.Set<java.lang.String> getAuthRequestHeaders(Context<? extends Trait> context, HttpApiKeyAuthTrait trait)
SecuritySchemeConverter
This is useful when integrating with things like CORS.
getAuthRequestHeaders
in interface SecuritySchemeConverter<HttpApiKeyAuthTrait>
context
- Context for the conversion.trait
- The auth trait that is being used.