Auth

class Auth

Main entry point for authentication and authorization operations. This class provides functions to initialize and finalize login processes, handle device logins, and manage user credentials.

Functions

Link copied to clipboard
suspend fun finalizeDeviceLogin(deviceCode: String): AuthResult<Nothing>

Finalizes the device login flow. Polls until either a valid access token is received, or an unrecoverable error occurs.

Link copied to clipboard
suspend fun finalizeLogin(loginResponseUri: String): AuthResult<Nothing>

Initializes a device login flow, providing the necessary information for user verification.

Link copied to clipboard

Initializes a device login flow, providing the necessary information for user verification.

Link copied to clipboard
fun initializeLogin(redirectUri: String, loginConfig: LoginConfig?): Uri

Begins the login process by generating a URI to the login service.

Link copied to clipboard
suspend fun logout()
Link copied to clipboard
suspend fun setCredentials(credentials: Credentials, refreshToken: String? = null)