Class HttpBearerAuth
java.lang.Object
de.xima.fc.api.rest.pub.client.form.auth.HttpBearerAuth
- All Implemented Interfaces:
Authentication
@Generated("de.xima.openapi.codegen.java_jaxrs.XimaJavaJaxrsGenerator")
public final class HttpBearerAuth
extends Object
implements Authentication
An authentication that uses a given bearer token for authentication.
-
Constructor Summary
ConstructorsConstructorDescriptionHttpBearerAuth(String scheme, String bearerToken) Creates a new authentication that uses the given bearer token for authentication. -
Method Summary
Modifier and TypeMethodDescriptionvoidapplyToParams(ApiCall<?> call) Apply authentication settings to header and query params.Gets the token, which together with the scheme, will be sent as the value of the Authorization header.withBearerToken(String bearerToken)
-
Constructor Details
-
HttpBearerAuth
Creates a new authentication that uses the given bearer token for authentication.- Parameters:
scheme- Optional scheme that gets prepended before the bearer token.bearerToken- The token, which together with the scheme, will be sent as the value of the Authorization header.
-
-
Method Details
-
bearerToken
Gets the token, which together with the scheme, will be sent as the value of the Authorization header.- Returns:
- The bearer token
-
applyToParams
Description copied from interface:AuthenticationApply authentication settings to header and query params.- Specified by:
applyToParamsin interfaceAuthentication- Parameters:
call- API call with all parameters that can be modified.
-
withBearerToken
- Parameters:
bearerToken- The bearer token sent together with the scheme in the Authorization header.- Returns:
- A new immutable instance with the new data.
-