public interface TokenEndpoint
TokenEndpoint directly corresponds to the token endpoint as specified in
the OAuth2.0 Specification. See
OAuth2.0 Token Endpoint.| Modifier and Type | Method and Description |
|---|---|
Fresh<AccessTokenResponse> |
requestAutoRefreshingToken(AccessTokenRequest request)
POST to the token endpoint to get an always fresh HERE Access Token, for use with HERE Services.
|
Fresh<AccessTokenResponse> |
requestAutoRefreshingToken(Supplier<AccessTokenRequest> requestSupplier)
POST to the token endpoint to get an always fresh HERE Access Token, for use with HERE Services.
|
AccessTokenResponse |
requestToken(AccessTokenRequest request)
POST to the token endpoint to get a HERE Access Token, for use with HERE Services.
|
AccessTokenResponse requestToken(AccessTokenRequest request) throws AccessTokenException, RequestExecutionException, ResponseParsingException
request - the token requestAccessTokenException - if you had trouble authenticating your request to the authorization server,
or the authorization server rejected your requestRequestExecutionException - if trouble processing the requestResponseParsingException - if trouble parsing the responseFresh<AccessTokenResponse> requestAutoRefreshingToken(AccessTokenRequest request) throws AccessTokenException, RequestExecutionException, ResponseParsingException
Fresh, and is periodically and automatically
refreshed before it expires. The token can be used as an Authorization: Bearer token value.
See OAuth2.0,
and OAuth2.0 Bearer Token Usage
for details.request - the token requestFresh wrapped Access Token that can be used as Bearer token for HERE Service requests
the returned Fresh will always give an unexpired access token on a call to get()AccessTokenException - if you had trouble authenticating your request to the authorization server,
or the authorization server rejected your requestRequestExecutionException - if trouble processing the requestResponseParsingException - if trouble parsing the responseFresh<AccessTokenResponse> requestAutoRefreshingToken(Supplier<AccessTokenRequest> requestSupplier) throws AccessTokenException, RequestExecutionException, ResponseParsingException
Fresh, and is periodically and automatically
refreshed before it expires. The token can be used as an Authorization: Bearer token value.
See OAuth2.0,
and OAuth2.0 Bearer Token Usage
for details.requestSupplier - a Supplier of token requests, to be used for each attempt to get a fresh token.Fresh wrapped Access Token that can be used as Bearer token for HERE Service requests
the returned Fresh will always give an unexpired access token on a call to get()AccessTokenException - if you had trouble authenticating your request to the authorization server,
or the authorization server rejected your requestRequestExecutionException - if trouble processing the requestResponseParsingException - if trouble parsing the responseCopyright © 2020 HERE Europe B.V. All Rights Reserved.