AuthRepository

interface AuthRepository

Provider-agnostic authentication repository. Bridge this to Firebase Auth, Supabase Auth, or any other auth backend.

Properties

Link copied to clipboard
abstract val currentUser: AuthUser?
Link copied to clipboard
abstract val isAnonymous: Boolean
Link copied to clipboard
abstract val isAuthenticated: Boolean

Functions

Link copied to clipboard
abstract fun authStateFlow(): Flow<AuthUser?>
Link copied to clipboard
abstract suspend fun createAccountWithEmailAndPassword(email: String, password: String): Result<AuthUser>
Link copied to clipboard
abstract suspend fun deleteAccount(): Result<Unit>
Link copied to clipboard
abstract suspend fun sendPasswordResetEmail(email: String): Result<Unit>
Link copied to clipboard
abstract suspend fun sendSignInLinkToEmail(email: String, continueUrl: String): Result<Unit>
Link copied to clipboard
abstract suspend fun signInAnonymously(): Result<AuthUser>
Link copied to clipboard
abstract suspend fun signInWithApple(activity: Activity): Result<AuthUser>
Link copied to clipboard
abstract suspend fun signInWithEmailAndPassword(email: String, password: String): Result<AuthUser>
Link copied to clipboard
abstract suspend fun signInWithGoogle(idToken: String): Result<AuthUser>
Link copied to clipboard
abstract fun signOut()