You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs-devsite/auth.md
+26-12Lines changed: 26 additions & 12 deletions
Original file line number
Diff line number
Diff line change
@@ -57,7 +57,7 @@ Firebase Authentication
57
57
|[getIdToken(user, forceRefresh)](./auth.md#getidtoken)| Returns a JSON Web Token (JWT) used to identify the user to a Firebase service. |
58
58
|[getIdTokenResult(user, forceRefresh)](./auth.md#getidtokenresult)| Returns a deserialized JSON Web Token (JWT) used to identify the user to a Firebase service. |
59
59
|[linkWithCredential(user, credential)](./auth.md#linkwithcredential)| Links the user account with the given credentials. |
60
-
|[linkWithPhoneNumber(user, phoneNumber, appVerifier)](./auth.md#linkwithphonenumber)| Links the user account with the given phone number.<!---->This method is not available in Node.js.|
60
+
|[linkWithPhoneNumber(user, phoneNumber, appVerifier)](./auth.md#linkwithphonenumber)| Links the user account with the given phone number. |
61
61
|[linkWithPopup(user, provider, resolver)](./auth.md#linkwithpopup)| Links the authenticated provider to the user account using a pop-up based OAuth flow. |
62
62
|[linkWithRedirect(user, provider, resolver)](./auth.md#linkwithredirect)| Links the [OAuthProvider](./auth.oauthprovider.md#oauthprovider_class) to the user account using a full-page redirect flow. |
63
63
|[multiFactor(user)](./auth.md#multifactor)| The [MultiFactorUser](./auth.multifactoruser.md#multifactoruser_interface) corresponding to the user. |
@@ -92,7 +92,7 @@ Firebase Authentication
92
92
|[PhoneAuthCredential](./auth.phoneauthcredential.md#phoneauthcredential_class)| Represents the credentials returned by [PhoneAuthProvider](./auth.phoneauthprovider.md#phoneauthprovider_class)<!---->. |
93
93
|[PhoneAuthProvider](./auth.phoneauthprovider.md#phoneauthprovider_class)| Provider for generating an [PhoneAuthCredential](./auth.phoneauthcredential.md#phoneauthcredential_class)<!---->. |
94
94
|[PhoneMultiFactorGenerator](./auth.phonemultifactorgenerator.md#phonemultifactorgenerator_class)| Provider for generating a [PhoneMultiFactorAssertion](./auth.phonemultifactorassertion.md#phonemultifactorassertion_interface)<!---->. |
95
-
|[RecaptchaVerifier](./auth.recaptchaverifier.md#recaptchaverifier_class)| An [reCAPTCHA](https://www.google.com/recaptcha/)<!---->-based application verifier.<code>RecaptchaVerifier</code> is not available in Node.js.|
95
+
|[RecaptchaVerifier](./auth.recaptchaverifier.md#recaptchaverifier_class)| An [reCAPTCHA](https://www.google.com/recaptcha/)<!---->-based application verifier. |
96
96
|[SAMLAuthProvider](./auth.samlauthprovider.md#samlauthprovider_class)| An [AuthProvider](./auth.authprovider.md#authprovider_interface) for SAML. |
97
97
|[TotpMultiFactorGenerator](./auth.totpmultifactorgenerator.md#totpmultifactorgenerator_class)| Provider for generating a [TotpMultiFactorAssertion](./auth.totpmultifactorassertion.md#totpmultifactorassertion_interface)<!---->. |
98
98
|[TotpSecret](./auth.totpsecret.md#totpsecret_class)| Provider for generating a [TotpMultiFactorAssertion](./auth.totpmultifactorassertion.md#totpmultifactorassertion_interface)<!---->.<!---->Stores the shared secret key and other parameters to generate time-based OTPs. Implements methods to retrieve the shared secret key and generate a QR code URL. |
@@ -147,7 +147,7 @@ Firebase Authentication
147
147
|[ActionCodeOperation](./auth.md#actioncodeoperation)| An enumeration of the possible email action types. |
148
148
|[AuthErrorCodes](./auth.md#autherrorcodes)| A map of potential <code>Auth</code> error codes, for easier comparison with errors thrown by the SDK. |
149
149
|[browserLocalPersistence](./auth.md#browserlocalpersistence)| An implementation of [Persistence](./auth.persistence.md#persistence_interface) of type <code>LOCAL</code> using <code>localStorage</code> for the underlying storage. |
150
-
|[browserPopupRedirectResolver](./auth.md#browserpopupredirectresolver)| An implementation of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface) suitable for browser based applications.<!---->This method is not available in Node.js.|
150
+
|[browserPopupRedirectResolver](./auth.md#browserpopupredirectresolver)| An implementation of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface) suitable for browser based applications. |
151
151
|[browserSessionPersistence](./auth.md#browsersessionpersistence)| An implementation of [Persistence](./auth.persistence.md#persistence_interface) of <code>SESSION</code> using <code>sessionStorage</code> for the underlying storage. |
152
152
|[cordovaPopupRedirectResolver](./auth.md#cordovapopupredirectresolver)| An implementation of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface) suitable for Cordova based applications. |
153
153
|[debugErrorMap](./auth.md#debugerrormap)| A verbose error map with detailed descriptions for most error codes.<!---->See discussion at [AuthErrorMap](./auth.autherrormap.md#autherrormap_interface)|
@@ -442,6 +442,8 @@ Returns a [UserCredential](./auth.usercredential.md#usercredential_interface) fr
442
442
443
443
If sign-in succeeded, returns the signed in user. If sign-in was unsuccessful, fails with an error. If no redirect operation was called, returns `null`<!---->.
| auth |[Auth](./auth.auth.md#auth_interface)| The [Auth](./auth.auth.md#auth_interface) instance. |
456
-
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->.<!---->This method is not available in Node.js.|
458
+
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->. |
457
459
458
460
<b>Returns:</b>
459
461
@@ -878,6 +880,8 @@ This method sends a code via SMS to the given phone number, and returns a [Confi
878
880
879
881
For abuse prevention, this method also requires a [ApplicationVerifier](./auth.applicationverifier.md#applicationverifier_interface)<!---->. This SDK includes a reCAPTCHA-based implementation, [RecaptchaVerifier](./auth.recaptchaverifier.md#recaptchaverifier_class)<!---->. This function can work on other platforms that do not support the [RecaptchaVerifier](./auth.recaptchaverifier.md#recaptchaverifier_class) (like React Native), but you need to use a third-party [ApplicationVerifier](./auth.applicationverifier.md#applicationverifier_interface) implementation.
Authenticates a Firebase client using a popup-based OAuth authentication flow.
915
918
916
919
If succeeds, returns the signed in user along with the provider's credential. If sign in was unsuccessful, returns an error object containing additional information about the error.
| auth |[Auth](./auth.auth.md#auth_interface)| The [Auth](./auth.auth.md#auth_interface) instance. |
929
934
| provider |[AuthProvider](./auth.authprovider.md#authprovider_interface)| The provider to authenticate. The provider has to be an [OAuthProvider](./auth.oauthprovider.md#oauthprovider_class)<!---->. Non-OAuth providers like [EmailAuthProvider](./auth.emailauthprovider.md#emailauthprovider_class) will throw an error. |
930
-
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->.<!---->This method is not available in Node.js.|
935
+
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->. |
931
936
932
937
<b>Returns:</b>
933
938
@@ -955,6 +960,8 @@ Authenticates a Firebase client using a full-page redirect flow.
955
960
956
961
To handle the results and errors for this operation, refer to [getRedirectResult()](./auth.md#getredirectresult)<!---->. Follow the [best practices](https://firebase.google.com/docs/auth/web/redirect-best-practices) when using [signInWithRedirect()](./auth.md#signinwithredirect)<!---->.
957
962
963
+
This method is not available in Node.js.
964
+
958
965
<b>Signature:</b>
959
966
960
967
```typescript
@@ -967,7 +974,7 @@ export declare function signInWithRedirect(auth: Auth, provider: AuthProvider, r
967
974
| --- | --- | --- |
968
975
| auth |[Auth](./auth.auth.md#auth_interface)| The [Auth](./auth.auth.md#auth_interface) instance. |
969
976
| provider |[AuthProvider](./auth.authprovider.md#authprovider_interface)| The provider to authenticate. The provider has to be an [OAuthProvider](./auth.oauthprovider.md#oauthprovider_class)<!---->. Non-OAuth providers like [EmailAuthProvider](./auth.emailauthprovider.md#emailauthprovider_class) will throw an error. |
970
-
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->.<!---->This method is not available in Node.js.|
977
+
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->. |
971
978
972
979
<b>Returns:</b>
973
980
@@ -1232,6 +1239,8 @@ Links the authenticated provider to the user account using a pop-up based OAuth
1232
1239
1233
1240
If the linking is successful, the returned result will contain the user and the provider's credential.
1234
1241
1242
+
This method is not available in Node.js.
1243
+
1235
1244
<b>Signature:</b>
1236
1245
1237
1246
```typescript
@@ -1261,14 +1270,15 @@ const provider = new FacebookAuthProvider();
1261
1270
awaitlinkWithPopup(result.user, provider);
1262
1271
1263
1272
```
1264
-
This method is not available in Node.js.
1265
1273
1266
1274
## linkWithRedirect()
1267
1275
1268
1276
Links the [OAuthProvider](./auth.oauthprovider.md#oauthprovider_class) to the user account using a full-page redirect flow.
1269
1277
1270
1278
To handle the results and errors for this operation, refer to [getRedirectResult()](./auth.md#getredirectresult)<!---->. Follow the [best practices](https://firebase.google.com/docs/auth/web/redirect-best-practices) when using [linkWithRedirect()](./auth.md#linkwithredirect)<!---->.
1271
1279
1280
+
This method is not available in Node.js.
1281
+
1272
1282
<b>Signature:</b>
1273
1283
1274
1284
```typescript
@@ -1281,7 +1291,7 @@ export declare function linkWithRedirect(user: User, provider: AuthProvider, res
1281
1291
| --- | --- | --- |
1282
1292
| user |[User](./auth.user.md#user_interface)| The user. |
1283
1293
| provider |[AuthProvider](./auth.authprovider.md#authprovider_interface)| The provider to authenticate. The provider has to be an [OAuthProvider](./auth.oauthprovider.md#oauthprovider_class)<!---->. Non-OAuth providers like [EmailAuthProvider](./auth.emailauthprovider.md#emailauthprovider_class) will throw an error. |
1284
-
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->.<!---->This method is not available in Node.js.|
1294
+
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->. |
1285
1295
1286
1296
<b>Returns:</b>
1287
1297
@@ -1380,6 +1390,8 @@ Reauthenticates the current user with the specified [OAuthProvider](./auth.oauth
1380
1390
1381
1391
If the reauthentication is successful, the returned result will contain the user and the provider's credential.
1382
1392
1393
+
This method is not available in Node.js.
1394
+
1383
1395
<b>Signature:</b>
1384
1396
1385
1397
```typescript
@@ -1409,14 +1421,15 @@ const result = await signInWithPopup(auth, provider);
Reauthenticates the current user with the specified [OAuthProvider](./auth.oauthprovider.md#oauthprovider_class) using a full-page redirect flow.
1417
1428
1418
1429
To handle the results and errors for this operation, refer to [getRedirectResult()](./auth.md#getredirectresult)<!---->. Follow the [best practices](https://firebase.google.com/docs/auth/web/redirect-best-practices) when using [reauthenticateWithRedirect()](./auth.md#reauthenticatewithredirect)<!---->.
| user |[User](./auth.user.md#user_interface)| The user. |
1431
1444
| provider |[AuthProvider](./auth.authprovider.md#authprovider_interface)| The provider to authenticate. The provider has to be an [OAuthProvider](./auth.oauthprovider.md#oauthprovider_class)<!---->. Non-OAuth providers like [EmailAuthProvider](./auth.emailauthprovider.md#emailauthprovider_class) will throw an error. |
1432
-
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->.<!---->This method is not available in Node.js.|
1445
+
| resolver |[PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)| An instance of [PopupRedirectResolver](./auth.popupredirectresolver.md#popupredirectresolver_interface)<!---->, optional if already supplied to [initializeAuth()](./auth.md#initializeauth) or provided by [getAuth()](./auth.md#getauth)<!---->. |
|[@firebase/analytics](./analytics.md#analytics_package)| The Firebase Analytics Web SDK.<!---->The Firebase Analytics Web SDK currently does not work in Node.js. |
18
+
|[@firebase/analytics](./analytics.md#analytics_package)| The Firebase Analytics Web SDK. This SDK currently does not work in Node.js. |
|[@firebase/app-check](./app-check.md#app-check_package)| The Firebase App Check Web SDK.<!---->Firebase App Check does not work in Node.js using <code>ReCaptchaV3Provider</code> or <code>ReCaptchaEnterpriseProvider</code>, but can be used in Node.js if you use <code>CustomProvider</code> and write your own attestation method.|
20
+
|[@firebase/app-check](./app-check.md#app-check_package)| The Firebase App Check Web SDK. |
|[@firebase/functions](./functions.md#functions_package)| Cloud Functions for Firebase |
25
-
|[@firebase/installations](./installations.md#installations_package)| The Firebase Installations Web SDK.<!---->The Firebase Installations Web SDK currently does not work in Node.js. |
26
-
|[@firebase/messaging](./messaging.md#messaging_package)| The Firebase Cloud Messaging Web SDK.<!---->The Firebase Cloud Messaging Web SDK currently does not work in Node.js. |
27
-
|[@firebase/performance](./performance.md#performance_package)| The Firebase Performance Monitoring Web SDK.<!---->The Firebase Performance Monitoring Web SDK currently does not work in Node.js. |
28
-
|[@firebase/remote-config](./remote-config.md#remote-config_package)| The Firebase Remote Config Web SDK.<!---->The Firebase Remote Config Web SDK currently does not work in Node.js. |
25
+
|[@firebase/installations](./installations.md#installations_package)| The Firebase Installations Web SDK. This SDK currently does not work in Node.js. |
26
+
|[@firebase/messaging](./messaging.md#messaging_package)| The Firebase Cloud Messaging Web SDK. This SDK currently does not work in Node.js. |
27
+
|[@firebase/performance](./performance.md#performance_package)| The Firebase Performance Monitoring Web SDK. This SDK currently does not work in Node.js. |
28
+
|[@firebase/remote-config](./remote-config.md#remote-config_package)| The Firebase Remote Config Web SDK. This SDK currently does not work in Node.js. |
29
29
|[@firebase/storage](./storage.md#storage_package)| Cloud Storage for Firebase |
0 commit comments