com.kkbox.openapideveloper / com.kkbox.openapideveloper.auth / TokenFetcher
class TokenFetcher
The instance of this class fetches open api token.
| <init> | TokenFetcher(clientID: String, clientSecret: String, context: Context)creates a token fetcher. |
| clientID | val clientID: Stringthe client ID for accessing kkbox open api. |
| clientSecret | val clientSecret: Stringthe client secret for accessing kkbox open api. |
| context | val context: Contextthe context needed for creating http connection. |
| fetchAccessToken | fun fetchAccessToken(bodyParameters: Map<String, List<String>>): ResponseFuture<JsonObject>Fetches the access token. |
| fetchInfo | fun fetchInfo(accessToken: String): ResponseFuture<JsonObject>Fetches information about a access token. |
| refresh | fun refresh(refreshToken: String): ResponseFuture<JsonObject>Refresh token when the token expired. |