implements Token
This class maintains the tokens and authenticates every request.
The Zoho CRM OAuth 2.0 reference provides information about the possible operations on OAuth 2.0.
Constructor | Description |
---|---|
OAuthToken(String clientID, String clientSecret, String token, TokenType type) | Creates an OAuthToken class instance with the specified parameters. |
OAuthToken(String clientID, String clientSecret, String token, TokenType type, String redirectURL) | Creates an OAuthToken class instance with the specified parameters. |
A String containing the OAuth client id.
A String containing the OAuth client secret.
A String containing the REFRESH/GRANT token.
An enum containing the given token type.
GRANT -> When Grant Token is given in the token.
REFRESH -> When Refresh Token is given in the token.
A String containing the OAuth redirect URL.
Return Type | Method | Description |
---|---|---|
String | getClientID() | The getter method to get OAuth ClientID. |
String | getClientSecret() | The getter method to get OAuth ClientSecret. |
String | getRedirectURL() | The getter method to get OAuth RedirectURL. |
String | getGrantToken() | The getter method to get OAuth GrantToken. |
String | getRefreshToken() | The getter method to get OAuth RefreshToken. |
void | setRefreshToken(String refreshToken) | The setter method to set OAuth RefreshToken. |
String | getAccessToken() | The getter method to get OAuth AccessToken. |
void | setAccessToken(String accessToken) | The setter method to set OAuth AccessToken. |
String | getExpiresIn() | The getter method to get OAuth ExpiresIn. |
void | setExpiresIn(String expiresIn) | The setter method to set OAuth ExpiresIn. |
Boolean | remove() | The method to remove the current token from the Store. |