public class ClientCredentialsTokenFlow extends Object
XsuaaTokenFlows and then create the flow request
using a builder pattern.| Modifier and Type | Method and Description |
|---|---|
ClientCredentialsTokenFlow |
attributes(Map<String,String> additionalAuthorizationAttributes)
Adds additional authorization attributes to the request.
|
ClientCredentialsTokenFlow |
disableCache(boolean disableCache)
Can be used to disable the cache for the flow.
|
OAuth2TokenResponse |
execute()
Executes the token flow and returns a JWT token from XSUAA.
|
ClientCredentialsTokenFlow |
scopes(String... scopes)
Sets the scope attribute for the token request.
|
ClientCredentialsTokenFlow |
subdomain(String subdomain)
Sets the subdomain (tenant) the token is requested for.
|
ClientCredentialsTokenFlow |
zoneId(String zoneId)
Sets the zone Id of the tenant
|
public ClientCredentialsTokenFlow attributes(Map<String,String> additionalAuthorizationAttributes)
'az_attr' claim of the returned token.additionalAuthorizationAttributes - - the additional attributes.public ClientCredentialsTokenFlow subdomain(String subdomain)
subdomain - - the subdomain.public ClientCredentialsTokenFlow zoneId(String zoneId)
zoneId - - the zoneId.public ClientCredentialsTokenFlow scopes(@Nonnull String... scopes)
scopes - - one or many scopes as string.public ClientCredentialsTokenFlow disableCache(boolean disableCache)
disableCache - - disables cache when set to true.public OAuth2TokenResponse execute() throws IllegalArgumentException, TokenFlowException
IllegalArgumentException - - in case not all mandatory fields of the token flow request have
been set.TokenFlowException - - in case of an error during the flow, or when the token cannot
be refreshed.Copyright © 2023. All rights reserved.