@@ -30,7 +30,7 @@ class Client:
30
30
31
31
def __init__ (self , app , tenant_id = None ):
32
32
if not app .project_id :
33
- raise ValueError ("""Project ID is required to access the auth service.
33
+ raise ValueError ("""A project ID is required to access the auth service.
34
34
1. Use a service account credential, or
35
35
2. set the project ID explicitly via Firebase App options, or
36
36
3. set the project ID via the GOOGLE_CLOUD_PROJECT environment variable.""" )
@@ -73,7 +73,7 @@ def create_custom_token(self, uid, developer_claims=None):
73
73
def verify_id_token (self , id_token , check_revoked = False ):
74
74
"""Verifies the signature and data for the provided JWT.
75
75
76
- Accepts a signed token string, verifies that it is current, and issued
76
+ Accepts a signed token string, verifies that it is current, was issued
77
77
to this project, and that it was correctly signed by Google.
78
78
79
79
Args:
@@ -113,7 +113,7 @@ def verify_id_token(self, id_token, check_revoked=False):
113
113
def revoke_refresh_tokens (self , uid ):
114
114
"""Revokes all refresh tokens for an existing user.
115
115
116
- revoke_refresh_tokens updates the user's tokens_valid_after_timestamp to the current UTC
116
+ This method updates the user's `` tokens_valid_after_timestamp`` to the current UTC
117
117
in seconds since the epoch. It is important that the server on which this is called has its
118
118
clock set correctly and synchronized.
119
119
@@ -138,7 +138,7 @@ def get_user(self, uid):
138
138
uid: A user ID string.
139
139
140
140
Returns:
141
- UserRecord: A UserRecord instance.
141
+ UserRecord: A user record instance.
142
142
143
143
Raises:
144
144
ValueError: If the user ID is None, empty or malformed.
@@ -155,7 +155,7 @@ def get_user_by_email(self, email):
155
155
email: A user email address string.
156
156
157
157
Returns:
158
- UserRecord: A UserRecord instance.
158
+ UserRecord: A user record instance.
159
159
160
160
Raises:
161
161
ValueError: If the email is None, empty or malformed.
@@ -172,10 +172,10 @@ def get_user_by_phone_number(self, phone_number):
172
172
phone_number: A phone number string.
173
173
174
174
Returns:
175
- UserRecord: A UserRecord instance.
175
+ UserRecord: A user record instance.
176
176
177
177
Raises:
178
- ValueError: If the phone number is None, empty or malformed.
178
+ ValueError: If the phone number is `` None`` , empty or malformed.
179
179
UserNotFoundError: If no user exists by the specified phone number.
180
180
FirebaseError: If an error occurs while retrieving the user.
181
181
"""
@@ -187,7 +187,7 @@ def list_users(self, page_token=None, max_results=_user_mgt.MAX_LIST_USERS_RESUL
187
187
188
188
The ``page_token`` argument governs the starting point of the page. The ``max_results``
189
189
argument governs the maximum number of user accounts that may be included in the returned
190
- page. This function never returns None. If there are no user accounts in the Firebase
190
+ page. This function never returns `` None`` . If there are no user accounts in the Firebase
191
191
project, this returns an empty page.
192
192
193
193
Args:
@@ -198,7 +198,7 @@ def list_users(self, page_token=None, max_results=_user_mgt.MAX_LIST_USERS_RESUL
198
198
allowed.
199
199
200
200
Returns:
201
- ListUsersPage: A ListUsersPage instance .
201
+ ListUsersPage: A page of user accounts .
202
202
203
203
Raises:
204
204
ValueError: If max_results or page_token are invalid.
@@ -310,7 +310,7 @@ def import_users(self, users, hash_alg=None):
310
310
"""Imports the specified list of users into Firebase Auth.
311
311
312
312
At most 1000 users can be imported at a time. This operation is optimized for bulk imports
313
- and will ignore checks on identifier uniqueness which could result in duplications. The
313
+ and ignores checks on identifier uniqueness, which could result in duplications. The
314
314
``hash_alg`` parameter must be specified when importing users with passwords. Refer to the
315
315
``UserImportHash`` class for supported hash algorithms.
316
316
@@ -391,13 +391,13 @@ def generate_sign_in_with_email_link(self, email, action_code_settings):
391
391
'EMAIL_SIGNIN' , email , action_code_settings = action_code_settings )
392
392
393
393
def get_oidc_provider_config (self , provider_id ):
394
- """Returns the OIDCProviderConfig with the given ID.
394
+ """Returns the `` OIDCProviderConfig`` with the given ID.
395
395
396
396
Args:
397
397
provider_id: Provider ID string.
398
398
399
399
Returns:
400
- SAMLProviderConfig: An OIDCProviderConfig instance.
400
+ SAMLProviderConfig: An OIDC provider config instance.
401
401
402
402
Raises:
403
403
ValueError: If the provider ID is invalid, empty or does not have ``oidc.`` prefix.
@@ -423,7 +423,7 @@ def create_oidc_provider_config(
423
423
(optional). A user cannot sign in using a disabled provider.
424
424
425
425
Returns:
426
- OIDCProviderConfig: The newly created OIDCProviderConfig instance.
426
+ OIDCProviderConfig: The newly created OIDC provider config instance.
427
427
428
428
Raises:
429
429
ValueError: If any of the specified input parameters are invalid.
@@ -447,7 +447,7 @@ def update_oidc_provider_config(
447
447
(optional).
448
448
449
449
Returns:
450
- OIDCProviderConfig: The updated OIDCProviderConfig instance.
450
+ OIDCProviderConfig: The updated OIDC provider config instance.
451
451
452
452
Raises:
453
453
ValueError: If any of the specified input parameters are invalid.
@@ -458,7 +458,7 @@ def update_oidc_provider_config(
458
458
enabled = enabled )
459
459
460
460
def delete_oidc_provider_config (self , provider_id ):
461
- """Deletes the OIDCProviderConfig with the given ID.
461
+ """Deletes the `` OIDCProviderConfig`` with the given ID.
462
462
463
463
Args:
464
464
provider_id: Provider ID string.
@@ -476,7 +476,7 @@ def list_oidc_provider_configs(
476
476
477
477
The ``page_token`` argument governs the starting point of the page. The ``max_results``
478
478
argument governs the maximum number of configs that may be included in the returned
479
- page. This function never returns None. If there are no OIDC configs in the Firebase
479
+ page. This function never returns `` None`` . If there are no OIDC configs in the Firebase
480
480
project, this returns an empty page.
481
481
482
482
Args:
@@ -487,22 +487,22 @@ def list_oidc_provider_configs(
487
487
allowed.
488
488
489
489
Returns:
490
- ListProviderConfigsPage: A ListProviderConfigsPage instance .
490
+ ListProviderConfigsPage: A page of OIDC provider config instances .
491
491
492
492
Raises:
493
- ValueError: If max_results or page_token are invalid.
493
+ ValueError: If `` max_results`` or `` page_token`` are invalid.
494
494
FirebaseError: If an error occurs while retrieving the OIDC provider configs.
495
495
"""
496
496
return self ._provider_manager .list_oidc_provider_configs (page_token , max_results )
497
497
498
498
def get_saml_provider_config (self , provider_id ):
499
- """Returns the SAMLProviderConfig with the given ID.
499
+ """Returns the `` SAMLProviderConfig`` with the given ID.
500
500
501
501
Args:
502
502
provider_id: Provider ID string.
503
503
504
504
Returns:
505
- SAMLProviderConfig: A SAMLProviderConfig instance.
505
+ SAMLProviderConfig: A SAML provider config instance.
506
506
507
507
Raises:
508
508
ValueError: If the provider ID is invalid, empty or does not have ``saml.`` prefix.
@@ -540,7 +540,7 @@ def create_saml_provider_config(
540
540
(optional). A user cannot sign in using a disabled provider.
541
541
542
542
Returns:
543
- SAMLProviderConfig: The newly created SAMLProviderConfig instance.
543
+ SAMLProviderConfig: The newly created SAML provider config instance.
544
544
545
545
Raises:
546
546
ValueError: If any of the specified input parameters are invalid.
@@ -564,13 +564,13 @@ def update_saml_provider_config(
564
564
provider (optional).
565
565
rp_entity_id: The SAML relying party entity ID (optional).
566
566
callback_url: Callback URL string (optional).
567
- display_name: The user-friendly display name to the current configuration (optional).
567
+ display_name: The user-friendly display name of the current configuration (optional).
568
568
Pass ``auth.DELETE_ATTRIBUTE`` to delete the current display name.
569
569
enabled: A boolean indicating whether the provider configuration is enabled or disabled
570
570
(optional).
571
571
572
572
Returns:
573
- SAMLProviderConfig: The updated SAMLProviderConfig instance.
573
+ SAMLProviderConfig: The updated SAML provider config instance.
574
574
575
575
Raises:
576
576
ValueError: If any of the specified input parameters are invalid.
@@ -582,7 +582,7 @@ def update_saml_provider_config(
582
582
callback_url = callback_url , display_name = display_name , enabled = enabled )
583
583
584
584
def delete_saml_provider_config (self , provider_id ):
585
- """Deletes the SAMLProviderConfig with the given ID.
585
+ """Deletes the `` SAMLProviderConfig`` with the given ID.
586
586
587
587
Args:
588
588
provider_id: Provider ID string.
@@ -600,7 +600,7 @@ def list_saml_provider_configs(
600
600
601
601
The ``page_token`` argument governs the starting point of the page. The ``max_results``
602
602
argument governs the maximum number of configs that may be included in the returned
603
- page. This function never returns None. If there are no SAML configs in the Firebase
603
+ page. This function never returns `` None`` . If there are no SAML configs in the Firebase
604
604
project, this returns an empty page.
605
605
606
606
Args:
@@ -611,10 +611,10 @@ def list_saml_provider_configs(
611
611
allowed.
612
612
613
613
Returns:
614
- ListProviderConfigsPage: A ListProviderConfigsPage instance .
614
+ ListProviderConfigsPage: A page of SAML provider config instances .
615
615
616
616
Raises:
617
- ValueError: If max_results or page_token are invalid.
617
+ ValueError: If `` max_results`` or `` page_token`` are invalid.
618
618
FirebaseError: If an error occurs while retrieving the SAML provider configs.
619
619
"""
620
620
return self ._provider_manager .list_saml_provider_configs (page_token , max_results )
0 commit comments