FirebaseAuth class

The entry point of the Firebase Authentication SDK.


FirebaseAuth.fromApp(FirebaseApp app)
Provides an instance of this class corresponding to app.


app FirebaseApp
hashCode int
The hash code for this object. [...]
read-only, inherited
onAuthStateChanged Stream<FirebaseUser>
Receive FirebaseUser each time the user signIn or signOut
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited


confirmPasswordReset(String oobCode, String newPassword) Future<void>
Completes the password reset process, given a confirmation code and new password. [...]
createUserWithEmailAndPassword({String email, String password}) Future<AuthResult>
Tries to create a new user account with the given email address and password. [...]
currentUser() Future<FirebaseUser>
Returns the currently signed-in FirebaseUser or null if there is none.
fetchSignInMethodsForEmail({String email}) Future<List<String>>
Returns a list of sign-in methods that can be used to sign in a given user (identified by its main email address). [...]
Checks if link is an email sign-in link.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
sendPasswordResetEmail({String email}) Future<void>
Triggers the Firebase Authentication backend to send a password-reset email to the given email address, which must correspond to an existing user of your app. [...]
Sends a sign in with email link to provided email address.
setLanguageCode(String language) Future<void>
Sets the user-facing language code for auth operations that can be internationalized, such as sendEmailVerification. This language code should follow the conventions defined by the IETF in BCP47.
signInAnonymously() Future<AuthResult>
Asynchronously creates and becomes an anonymous user. [...]
signInWithCredential(AuthCredential credential) Future<AuthResult>
Asynchronously signs in to Firebase with the given 3rd-party credentials (e.g. a Facebook login Access Token, a Google ID Token/Access Token pair, etc.) and returns additional identity provider data. [...]
signInWithCustomToken({String token}) Future<AuthResult>
Tries to sign in a user with a given Custom Token token. [...]
Signs in using an email address and email sign-in link. [...]
signInWithEmailAndPassword({String email, String password}) Future<AuthResult>
Tries to sign in a user with the given email address and password. [...]
signOut() Future<void>
Signs out the current user and clears it from the disk cache. [...]
toString() String
Returns a string representation of this object.
verifyPhoneNumber({String phoneNumber, Duration timeout, int forceResendingToken, PhoneVerificationCompleted verificationCompleted, PhoneVerificationFailed verificationFailed, PhoneCodeSent codeSent, PhoneCodeAutoRetrievalTimeout codeAutoRetrievalTimeout}) Future<void>
Starts the phone number verification process for the given phone number. [...]


operator ==(dynamic other) bool
The equality operator. [...]

Static Properties

instance FirebaseAuth
Provides an instance of this class corresponding to the default app.