ConfirmationResult interface Stay organized with collections Save and categorize content based on your preferences.
A result from a phone number sign-in, link, or reauthenticate call.
Signature:
exportinterfaceConfirmationResultProperties
| Property | Type | Description |
|---|---|---|
| verificationId | string | The phone number authentication operation's verification ID. |
Methods
| Method | Description |
|---|---|
| confirm(verificationCode) | Finishes a phone number sign-in, link, or reauthentication. |
ConfirmationResult.verificationId
The phone number authentication operation's verification ID.
This can be used along with the verification code to initialize aPhoneAuthCredential.
Signature:
readonlyverificationId:string;ConfirmationResult.confirm()
Finishes a phone number sign-in, link, or reauthentication.
Signature:
confirm(verificationCode:string):Promise<UserCredential>;Parameters
| Parameter | Type | Description |
|---|---|---|
| verificationCode | string | The code that was sent to the user's mobile device. |
Returns:
Promise<UserCredential>
Example
constconfirmationResult=awaitsignInWithPhoneNumber(auth,phoneNumber,applicationVerifier);// Obtain verificationCode from the user.constuserCredential=awaitconfirmationResult.confirm(verificationCode);Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-01-19 UTC.