Class ApiKeyAuth
- java.lang.Object
-
- de.xima.fc.api.rest.pub.client.user_portal.auth.ApiKeyAuth
-
- All Implemented Interfaces:
Authentication
@Generated("de.xima.openapi.codegen.java_jaxrs.XimaJavaJaxrsGenerator") public final class ApiKeyAuth extends Object implements AuthenticationAn authentication that uses a given API key for authentication.
-
-
Constructor Summary
Constructors Constructor Description ApiKeyAuth(String location, String paramName, String apiKey, String apiKeyPrefix)A new authentication that uses the given API key for authentication.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringapiKey()StringapiKeyPrefix()voidapplyToParams(ApiCall<?> call)Apply authentication settings to header and query params.Stringlocation()StringparamName()ApiKeyAuthwithApiKey(String apiKey)ApiKeyAuthwithApiKeyPrefix(String apiKeyPrefix)
-
-
-
Constructor Detail
-
ApiKeyAuth
public ApiKeyAuth(String location, String paramName, String apiKey, String apiKeyPrefix)
A new authentication that uses the given API key for authentication.- Parameters:
location- How to send the token, one ofquery,header, orcookie.paramName- The name of the query, header, or cookie parameter with the API key.apiKey- API key to send.apiKeyPrefix- Prefix of the API key to send.
-
-
Method Detail
-
location
public String location()
- Returns:
- location How to send the token, one of
query,header, orcookie.
-
paramName
public String paramName()
- Returns:
- paramName The name of the query, header, or cookie parameter with the API key.
-
apiKey
public String apiKey()
- Returns:
- apiKey API key to send.
-
apiKeyPrefix
public String apiKeyPrefix()
- Returns:
- apiKey Prefix of the API key to send.
-
withApiKey
public ApiKeyAuth withApiKey(String apiKey)
- Parameters:
apiKey- The API key to use for authentication.- Returns:
- A new immutable instance with the new data.
-
withApiKeyPrefix
public ApiKeyAuth withApiKeyPrefix(String apiKeyPrefix)
- Parameters:
apiKeyPrefix- The prefix for the API key to use for authentication.- Returns:
- A new immutable instance with the new data.
-
applyToParams
public void applyToParams(ApiCall<?> call)
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.
-
-