public class TokenFetcher
extends java.lang.Object
Constructor and Description |
---|
TokenFetcher(java.lang.String oauthUrl,
java.lang.String clientId,
java.lang.String clientSecret,
java.lang.String grantType,
java.lang.String scope)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
AccessToken |
getToken()
Method that returns the OAuth credentials.
|
public TokenFetcher(java.lang.String oauthUrl, java.lang.String clientId, java.lang.String clientSecret, java.lang.String grantType, java.lang.String scope) throws GenieClientException
oauthUrl
- The url of the IDP from where to get the credentials.clientId
- The clientId to use to get the credentials.clientSecret
- The clientSecret to use to get the credentials.grantType
- The type of the grant.scope
- The scope of the credentials returned.GenieClientException
- If there is any problem.public AccessToken getToken() throws GenieClientException
GenieClientException
- If there is any problem.