class OAuthService : BaseNetworkService
OAuthService(environment: String, okHttpClient: OkHttpClient) |
fun refreshToken(clientId: String, clientSecret: String, refreshToken: String): Call<TokenResponse>
Prepares and commands a synchronous request to refresh an access token. |
|
fun tokenFromAuthCode(clientId: String, clientSecret: String, authCode: String, redirectUri: String, scopes: Array<String>?, codeVerifier: String? = null): Call<TokenResponse>
Requests a token by providing an authentication code |
|
fun tokenFromClientCredentials(clientId: String, clientSecret: String): Call<TokenResponse>
Requests client credentials that can be used to request client-authenticated requests. |
|
fun tokenFromPassword(clientId: String, clientSecret: String, username: String, password: String, vararg scopes: String): Call<TokenResponse>
Log in using identifier and password |
|
fun tokenFromPasswordless(clientId: String, clientSecret: String, identifier: String, code: String, passwordlessToken: String, vararg scopes: String): Call<TokenResponse>
Requests a token by providing an identifier and the auth code sent to it, plus the passwordless token received as a result of the request to have the auth code sent. |
open fun <T : Any!> createService(service: Class<T>): T
Creates a service to perform network interactions against. |