1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028
|
<html><body>
<style>
body, h1, h2, h3, div, span, p, pre, a {
margin: 0;
padding: 0;
border: 0;
font-weight: inherit;
font-style: inherit;
font-size: 100%;
font-family: inherit;
vertical-align: baseline;
}
body {
font-size: 13px;
padding: 1em;
}
h1 {
font-size: 26px;
margin-bottom: 1em;
}
h2 {
font-size: 24px;
margin-bottom: 1em;
}
h3 {
font-size: 20px;
margin-bottom: 1em;
margin-top: 1em;
}
pre, code {
line-height: 1.5;
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
}
pre {
margin-top: 0.5em;
}
h1, h2, h3, p {
font-family: Arial, sans serif;
}
h1, h2, h3 {
border-bottom: solid #CCC 1px;
}
.toc_element {
margin-top: 0.5em;
}
.firstline {
margin-left: 2 em;
}
.method {
margin-top: 1em;
border: solid 1px #CCC;
padding: 1em;
background: #EEE;
}
.details {
font-weight: bold;
font-size: 14px;
}
</style>
<h1><a href="identitytoolkit_v3.html">Google Identity Toolkit API</a> . <a href="identitytoolkit_v3.relyingparty.html">relyingparty</a></h1>
<h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#close">close()</a></code></p>
<p class="firstline">Close httplib2 connections.</p>
<p class="toc_element">
<code><a href="#createAuthUri">createAuthUri(body=None)</a></code></p>
<p class="firstline">Creates the URI used by the IdP to authenticate the user.</p>
<p class="toc_element">
<code><a href="#deleteAccount">deleteAccount(body=None)</a></code></p>
<p class="firstline">Delete user account.</p>
<p class="toc_element">
<code><a href="#downloadAccount">downloadAccount(body=None)</a></code></p>
<p class="firstline">Batch download user accounts.</p>
<p class="toc_element">
<code><a href="#downloadAccount_next">downloadAccount_next()</a></code></p>
<p class="firstline">Retrieves the next page of results.</p>
<p class="toc_element">
<code><a href="#emailLinkSignin">emailLinkSignin(body=None)</a></code></p>
<p class="firstline">Reset password for a user.</p>
<p class="toc_element">
<code><a href="#getAccountInfo">getAccountInfo(body=None)</a></code></p>
<p class="firstline">Returns the account info.</p>
<p class="toc_element">
<code><a href="#getOobConfirmationCode">getOobConfirmationCode(body=None)</a></code></p>
<p class="firstline">Get a code for user action confirmation.</p>
<p class="toc_element">
<code><a href="#getProjectConfig">getProjectConfig(delegatedProjectNumber=None, projectNumber=None)</a></code></p>
<p class="firstline">Get project configuration.</p>
<p class="toc_element">
<code><a href="#getPublicKeys">getPublicKeys()</a></code></p>
<p class="firstline">Get token signing public key.</p>
<p class="toc_element">
<code><a href="#getRecaptchaParam">getRecaptchaParam()</a></code></p>
<p class="firstline">Get recaptcha secure param.</p>
<p class="toc_element">
<code><a href="#resetPassword">resetPassword(body=None)</a></code></p>
<p class="firstline">Reset password for a user.</p>
<p class="toc_element">
<code><a href="#sendVerificationCode">sendVerificationCode(body=None)</a></code></p>
<p class="firstline">Send SMS verification code.</p>
<p class="toc_element">
<code><a href="#setAccountInfo">setAccountInfo(body=None)</a></code></p>
<p class="firstline">Set account info for a user.</p>
<p class="toc_element">
<code><a href="#setProjectConfig">setProjectConfig(body=None)</a></code></p>
<p class="firstline">Set project configuration.</p>
<p class="toc_element">
<code><a href="#signOutUser">signOutUser(body=None)</a></code></p>
<p class="firstline">Sign out user.</p>
<p class="toc_element">
<code><a href="#signupNewUser">signupNewUser(body=None)</a></code></p>
<p class="firstline">Signup new user.</p>
<p class="toc_element">
<code><a href="#uploadAccount">uploadAccount(body=None)</a></code></p>
<p class="firstline">Batch upload existing user accounts.</p>
<p class="toc_element">
<code><a href="#verifyAssertion">verifyAssertion(body=None)</a></code></p>
<p class="firstline">Verifies the assertion returned by the IdP.</p>
<p class="toc_element">
<code><a href="#verifyCustomToken">verifyCustomToken(body=None)</a></code></p>
<p class="firstline">Verifies the developer asserted ID token.</p>
<p class="toc_element">
<code><a href="#verifyPassword">verifyPassword(body=None)</a></code></p>
<p class="firstline">Verifies the user entered password.</p>
<p class="toc_element">
<code><a href="#verifyPhoneNumber">verifyPhoneNumber(body=None)</a></code></p>
<p class="firstline">Verifies ownership of a phone number and creates/updates the user account accordingly.</p>
<h3>Method Details</h3>
<div class="method">
<code class="details" id="close">close()</code>
<pre>Close httplib2 connections.</pre>
</div>
<div class="method">
<code class="details" id="createAuthUri">createAuthUri(body=None)</code>
<pre>Creates the URI used by the IdP to authenticate the user.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to get the IDP authentication URL.
"appId": "A String", # The app ID of the mobile app, base64(CERT_SHA1):PACKAGE_NAME for Android, BUNDLE_ID for iOS.
"authFlowType": "A String", # Explicitly specify the auth flow type. Currently only support "CODE_FLOW" type. The field is only used for Google provider.
"clientId": "A String", # The relying party OAuth client ID.
"context": "A String", # The opaque value used by the client to maintain context info between the authentication request and the IDP callback.
"continueUri": "A String", # The URI to which the IDP redirects the user after the federated login flow.
"customParameter": { # The query parameter that client can customize by themselves in auth url. The following parameters are reserved for server so that they cannot be customized by clients: client_id, response_type, scope, redirect_uri, state, oauth_token.
"a_key": "A String", # The customized query parameter.
},
"hostedDomain": "A String", # The hosted domain to restrict sign-in to accounts at that domain for Google Apps hosted accounts.
"identifier": "A String", # The email or federated ID of the user.
"oauthConsumerKey": "A String", # The developer's consumer key for OpenId OAuth Extension
"oauthScope": "A String", # Additional oauth scopes, beyond the basid user profile, that the user would be prompted to grant
"openidRealm": "A String", # Optional realm for OpenID protocol. The sub string "scheme://domain:port" of the param "continueUri" is used if this is not set.
"otaApp": "A String", # The native app package for OTA installation.
"providerId": "A String", # The IdP ID. For white listed IdPs it's a short domain name e.g. google.com, aol.com, live.net and yahoo.com. For other OpenID IdPs it's the OP identifier.
"sessionId": "A String", # The session_id passed by client.
"tenantId": "A String", # For multi-tenant use cases, in order to construct sign-in URL with the correct IDP parameters, Firebear needs to know which Tenant to retrieve IDP configs from.
"tenantProjectNumber": "A String", # Tenant project number to be used for idp discovery.
}
Returns:
An object of the form:
{ # Response of creating the IDP authentication URL.
"allProviders": [ # all providers the user has once used to do federated login
"A String",
],
"authUri": "A String", # The URI used by the IDP to authenticate the user.
"captchaRequired": True or False, # True if captcha is required.
"forExistingProvider": True or False, # True if the authUri is for user's existing provider.
"kind": "identitytoolkit#CreateAuthUriResponse", # The fixed string identitytoolkit#CreateAuthUriResponse".
"providerId": "A String", # The provider ID of the auth URI.
"registered": True or False, # Whether the user is registered if the identifier is an email.
"sessionId": "A String", # Session ID which should be passed in the following verifyAssertion request.
"signinMethods": [ # All sign-in methods this user has used.
"A String",
],
}</pre>
</div>
<div class="method">
<code class="details" id="deleteAccount">deleteAccount(body=None)</code>
<pre>Delete user account.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to delete account.
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"idToken": "A String", # The GITKit token or STS id token of the authenticated user.
"localId": "A String", # The local ID of the user.
}
Returns:
An object of the form:
{ # Respone of deleting account.
"kind": "identitytoolkit#DeleteAccountResponse", # The fixed string "identitytoolkit#DeleteAccountResponse".
}</pre>
</div>
<div class="method">
<code class="details" id="downloadAccount">downloadAccount(body=None)</code>
<pre>Batch download user accounts.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to download user account in batch.
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"maxResults": 42, # The max number of results to return in the response.
"nextPageToken": "A String", # The token for the next page. This should be taken from the previous response.
"targetProjectId": "A String", # Specify which project (field value is actually project id) to operate. Only used when provided credential.
}
Returns:
An object of the form:
{ # Response of downloading accounts in batch.
"kind": "identitytoolkit#DownloadAccountResponse", # The fixed string "identitytoolkit#DownloadAccountResponse".
"nextPageToken": "A String", # The next page token. To be used in a subsequent request to return the next page of results.
"users": [ # The user accounts data.
{ # Template for an individual account info.
"createdAt": "A String", # User creation timestamp.
"customAttributes": "A String", # The custom attributes to be set in the user's id token.
"customAuth": True or False, # Whether the user is authenticated by the developer.
"disabled": True or False, # Whether the user is disabled.
"displayName": "A String", # The name of the user.
"email": "A String", # The email of the user.
"emailVerified": True or False, # Whether the email has been verified.
"lastLoginAt": "A String", # last login timestamp.
"localId": "A String", # The local ID of the user.
"passwordHash": "A String", # The user's hashed password.
"passwordUpdatedAt": 3.14, # The timestamp when the password was last updated.
"phoneNumber": "A String", # User's phone number.
"photoUrl": "A String", # The URL of the user profile photo.
"providerUserInfo": [ # The IDP of the user.
{
"displayName": "A String", # The user's display name at the IDP.
"email": "A String", # User's email at IDP.
"federatedId": "A String", # User's identifier at IDP.
"phoneNumber": "A String", # User's phone number.
"photoUrl": "A String", # The user's photo url at the IDP.
"providerId": "A String", # The IdP ID. For white listed IdPs it's a short domain name, e.g., google.com, aol.com, live.net and yahoo.com. For other OpenID IdPs it's the OP identifier.
"rawId": "A String", # User's raw identifier directly returned from IDP.
"screenName": "A String", # User's screen name at Twitter or login name at Github.
},
],
"rawPassword": "A String", # The user's plain text password.
"salt": "A String", # The user's password salt.
"screenName": "A String", # User's screen name at Twitter or login name at Github.
"validSince": "A String", # Timestamp in seconds for valid login token.
"version": 42, # Version of the user's password.
},
],
}</pre>
</div>
<div class="method">
<code class="details" id="downloadAccount_next">downloadAccount_next()</code>
<pre>Retrieves the next page of results.
Args:
previous_request: The request for the previous page. (required)
previous_response: The response from the request for the previous page. (required)
Returns:
A request object that you can call 'execute()' on to request the next
page. Returns None if there are no more items in the collection.
</pre>
</div>
<div class="method">
<code class="details" id="emailLinkSignin">emailLinkSignin(body=None)</code>
<pre>Reset password for a user.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to sign in with email.
"email": "A String", # The email address of the user.
"idToken": "A String", # Token for linking flow.
"oobCode": "A String", # The confirmation code.
}
Returns:
An object of the form:
{ # Response of email signIn.
"email": "A String", # The user's email.
"expiresIn": "A String", # Expiration time of STS id token in seconds.
"idToken": "A String", # The STS id token to login the newly signed in user.
"isNewUser": True or False, # Whether the user is new.
"kind": "identitytoolkit#EmailLinkSigninResponse", # The fixed string "identitytoolkit#EmailLinkSigninResponse".
"localId": "A String", # The RP local ID of the user.
"refreshToken": "A String", # The refresh token for the signed in user.
}</pre>
</div>
<div class="method">
<code class="details" id="getAccountInfo">getAccountInfo(body=None)</code>
<pre>Returns the account info.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to get the account information.
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"email": [ # The list of emails of the users to inquiry.
"A String",
],
"idToken": "A String", # The GITKit token of the authenticated user.
"localId": [ # The list of local ID's of the users to inquiry.
"A String",
],
"phoneNumber": [ # Privileged caller can query users by specified phone number.
"A String",
],
}
Returns:
An object of the form:
{ # Response of getting account information.
"kind": "identitytoolkit#GetAccountInfoResponse", # The fixed string "identitytoolkit#GetAccountInfoResponse".
"users": [ # The info of the users.
{ # Template for an individual account info.
"createdAt": "A String", # User creation timestamp.
"customAttributes": "A String", # The custom attributes to be set in the user's id token.
"customAuth": True or False, # Whether the user is authenticated by the developer.
"disabled": True or False, # Whether the user is disabled.
"displayName": "A String", # The name of the user.
"email": "A String", # The email of the user.
"emailVerified": True or False, # Whether the email has been verified.
"lastLoginAt": "A String", # last login timestamp.
"localId": "A String", # The local ID of the user.
"passwordHash": "A String", # The user's hashed password.
"passwordUpdatedAt": 3.14, # The timestamp when the password was last updated.
"phoneNumber": "A String", # User's phone number.
"photoUrl": "A String", # The URL of the user profile photo.
"providerUserInfo": [ # The IDP of the user.
{
"displayName": "A String", # The user's display name at the IDP.
"email": "A String", # User's email at IDP.
"federatedId": "A String", # User's identifier at IDP.
"phoneNumber": "A String", # User's phone number.
"photoUrl": "A String", # The user's photo url at the IDP.
"providerId": "A String", # The IdP ID. For white listed IdPs it's a short domain name, e.g., google.com, aol.com, live.net and yahoo.com. For other OpenID IdPs it's the OP identifier.
"rawId": "A String", # User's raw identifier directly returned from IDP.
"screenName": "A String", # User's screen name at Twitter or login name at Github.
},
],
"rawPassword": "A String", # The user's plain text password.
"salt": "A String", # The user's password salt.
"screenName": "A String", # User's screen name at Twitter or login name at Github.
"validSince": "A String", # Timestamp in seconds for valid login token.
"version": 42, # Version of the user's password.
},
],
}</pre>
</div>
<div class="method">
<code class="details" id="getOobConfirmationCode">getOobConfirmationCode(body=None)</code>
<pre>Get a code for user action confirmation.
Args:
body: object, The request body.
The object takes the form of:
{ # Request of getting a code for user confirmation (reset password, change email etc.)
"androidInstallApp": True or False, # whether or not to install the android app on the device where the link is opened
"androidMinimumVersion": "A String", # minimum version of the app. if the version on the device is lower than this version then the user is taken to the play store to upgrade the app
"androidPackageName": "A String", # android package name of the android app to handle the action code
"canHandleCodeInApp": True or False, # whether or not the app can handle the oob code without first going to web
"captchaResp": "A String", # The recaptcha response from the user.
"challenge": "A String", # The recaptcha challenge presented to the user.
"continueUrl": "A String", # The url to continue to the Gitkit app
"email": "A String", # The email of the user.
"iOSAppStoreId": "A String", # iOS app store id to download the app if it's not already installed
"iOSBundleId": "A String", # the iOS bundle id of iOS app to handle the action code
"idToken": "A String", # The user's Gitkit login token for email change.
"kind": "identitytoolkit#relyingparty", # The fixed string "identitytoolkit#relyingparty".
"newEmail": "A String", # The new email if the code is for email change.
"requestType": "A String", # The request type.
"userIp": "A String", # The IP address of the user.
}
Returns:
An object of the form:
{ # Response of getting a code for user confirmation (reset password, change email etc.).
"email": "A String", # The email address that the email is sent to.
"kind": "identitytoolkit#GetOobConfirmationCodeResponse", # The fixed string "identitytoolkit#GetOobConfirmationCodeResponse".
"oobCode": "A String", # The code to be send to the user.
}</pre>
</div>
<div class="method">
<code class="details" id="getProjectConfig">getProjectConfig(delegatedProjectNumber=None, projectNumber=None)</code>
<pre>Get project configuration.
Args:
delegatedProjectNumber: string, Delegated GCP project number of the request.
projectNumber: string, GCP project number of the request.
Returns:
An object of the form:
{ # Response of getting the project configuration.
"allowPasswordUser": True or False, # Whether to allow password user sign in or sign up.
"apiKey": "A String", # Browser API key, needed when making http request to Apiary.
"authorizedDomains": [ # Authorized domains.
"A String",
],
"changeEmailTemplate": { # Template for an email template. # Change email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
"dynamicLinksDomain": "A String",
"enableAnonymousUser": True or False, # Whether anonymous user is enabled.
"idpConfig": [ # OAuth2 provider configuration.
{ # Template for a single idp configuration.
"clientId": "A String", # OAuth2 client ID.
"enabled": True or False, # Whether this IDP is enabled.
"experimentPercent": 42, # Percent of users who will be prompted/redirected federated login for this IDP.
"provider": "A String", # OAuth2 provider.
"secret": "A String", # OAuth2 client secret.
"whitelistedAudiences": [ # Whitelisted client IDs for audience check.
"A String",
],
},
],
"legacyResetPasswordTemplate": { # Template for an email template. # Legacy reset password email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
"projectId": "A String", # Project ID of the relying party.
"resetPasswordTemplate": { # Template for an email template. # Reset password email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
"useEmailSending": True or False, # Whether to use email sending provided by Firebear.
"verifyEmailTemplate": { # Template for an email template. # Verify email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
}</pre>
</div>
<div class="method">
<code class="details" id="getPublicKeys">getPublicKeys()</code>
<pre>Get token signing public key.
Args:
Returns:
An object of the form:
{ # Respone of getting public keys.
"a_key": "A String",
}</pre>
</div>
<div class="method">
<code class="details" id="getRecaptchaParam">getRecaptchaParam()</code>
<pre>Get recaptcha secure param.
Args:
Returns:
An object of the form:
{ # Response of getting recaptcha param.
"kind": "identitytoolkit#GetRecaptchaParamResponse", # The fixed string "identitytoolkit#GetRecaptchaParamResponse".
"recaptchaSiteKey": "A String", # Site key registered at recaptcha.
"recaptchaStoken": "A String", # The stoken field for the recaptcha widget, used to request captcha challenge.
}</pre>
</div>
<div class="method">
<code class="details" id="resetPassword">resetPassword(body=None)</code>
<pre>Reset password for a user.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to reset the password.
"email": "A String", # The email address of the user.
"newPassword": "A String", # The new password inputted by the user.
"oldPassword": "A String", # The old password inputted by the user.
"oobCode": "A String", # The confirmation code.
}
Returns:
An object of the form:
{ # Response of resetting the password.
"email": "A String", # The user's email. If the out-of-band code is for email recovery, the user's original email.
"kind": "identitytoolkit#ResetPasswordResponse", # The fixed string "identitytoolkit#ResetPasswordResponse".
"newEmail": "A String", # If the out-of-band code is for email recovery, the user's new email.
"requestType": "A String", # The request type.
}</pre>
</div>
<div class="method">
<code class="details" id="sendVerificationCode">sendVerificationCode(body=None)</code>
<pre>Send SMS verification code.
Args:
body: object, The request body.
The object takes the form of:
{ # Request for Identitytoolkit-SendVerificationCode
"iosReceipt": "A String", # Receipt of successful app token validation with APNS.
"iosSecret": "A String", # Secret delivered to iOS app via APNS.
"phoneNumber": "A String", # The phone number to send the verification code to in E.164 format.
"recaptchaToken": "A String", # Recaptcha solution.
}
Returns:
An object of the form:
{ # Response for Identitytoolkit-SendVerificationCode
"sessionInfo": "A String", # Encrypted session information
}</pre>
</div>
<div class="method">
<code class="details" id="setAccountInfo">setAccountInfo(body=None)</code>
<pre>Set account info for a user.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to set the account information.
"captchaChallenge": "A String", # The captcha challenge.
"captchaResponse": "A String", # Response to the captcha.
"createdAt": "A String", # The timestamp when the account is created.
"customAttributes": "A String", # The custom attributes to be set in the user's id token.
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"deleteAttribute": [ # The attributes users request to delete.
"A String",
],
"deleteProvider": [ # The IDPs the user request to delete.
"A String",
],
"disableUser": True or False, # Whether to disable the user.
"displayName": "A String", # The name of the user.
"email": "A String", # The email of the user.
"emailVerified": True or False, # Mark the email as verified or not.
"idToken": "A String", # The GITKit token of the authenticated user.
"instanceId": "A String", # Instance id token of the app.
"lastLoginAt": "A String", # Last login timestamp.
"localId": "A String", # The local ID of the user.
"oobCode": "A String", # The out-of-band code of the change email request.
"password": "A String", # The new password of the user.
"phoneNumber": "A String", # Privileged caller can update user with specified phone number.
"photoUrl": "A String", # The photo url of the user.
"provider": [ # The associated IDPs of the user.
"A String",
],
"returnSecureToken": True or False, # Whether return sts id token and refresh token instead of gitkit token.
"upgradeToFederatedLogin": True or False, # Mark the user to upgrade to federated login.
"validSince": "A String", # Timestamp in seconds for valid login token.
}
Returns:
An object of the form:
{ # Respone of setting the account information.
"displayName": "A String", # The name of the user.
"email": "A String", # The email of the user.
"emailVerified": True or False, # If email has been verified.
"expiresIn": "A String", # If idToken is STS id token, then this field will be expiration time of STS id token in seconds.
"idToken": "A String", # The Gitkit id token to login the newly sign up user.
"kind": "identitytoolkit#SetAccountInfoResponse", # The fixed string "identitytoolkit#SetAccountInfoResponse".
"localId": "A String", # The local ID of the user.
"newEmail": "A String", # The new email the user attempts to change to.
"passwordHash": "A String", # The user's hashed password.
"photoUrl": "A String", # The photo url of the user.
"providerUserInfo": [ # The user's profiles at the associated IdPs.
{
"displayName": "A String", # The user's display name at the IDP.
"federatedId": "A String", # User's identifier at IDP.
"photoUrl": "A String", # The user's photo url at the IDP.
"providerId": "A String", # The IdP ID. For whitelisted IdPs it's a short domain name, e.g., google.com, aol.com, live.net and yahoo.com. For other OpenID IdPs it's the OP identifier.
},
],
"refreshToken": "A String", # If idToken is STS id token, then this field will be refresh token.
}</pre>
</div>
<div class="method">
<code class="details" id="setProjectConfig">setProjectConfig(body=None)</code>
<pre>Set project configuration.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to set the project configuration.
"allowPasswordUser": True or False, # Whether to allow password user sign in or sign up.
"apiKey": "A String", # Browser API key, needed when making http request to Apiary.
"authorizedDomains": [ # Authorized domains for widget redirect.
"A String",
],
"changeEmailTemplate": { # Template for an email template. # Change email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"enableAnonymousUser": True or False, # Whether to enable anonymous user.
"idpConfig": [ # Oauth2 provider configuration.
{ # Template for a single idp configuration.
"clientId": "A String", # OAuth2 client ID.
"enabled": True or False, # Whether this IDP is enabled.
"experimentPercent": 42, # Percent of users who will be prompted/redirected federated login for this IDP.
"provider": "A String", # OAuth2 provider.
"secret": "A String", # OAuth2 client secret.
"whitelistedAudiences": [ # Whitelisted client IDs for audience check.
"A String",
],
},
],
"legacyResetPasswordTemplate": { # Template for an email template. # Legacy reset password email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
"resetPasswordTemplate": { # Template for an email template. # Reset password email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
"useEmailSending": True or False, # Whether to use email sending provided by Firebear.
"verifyEmailTemplate": { # Template for an email template. # Verify email template.
"body": "A String", # Email body.
"format": "A String", # Email body format.
"from": "A String", # From address of the email.
"fromDisplayName": "A String", # From display name.
"replyTo": "A String", # Reply-to address.
"subject": "A String", # Subject of the email.
},
}
Returns:
An object of the form:
{ # Response of setting the project configuration.
"projectId": "A String", # Project ID of the relying party.
}</pre>
</div>
<div class="method">
<code class="details" id="signOutUser">signOutUser(body=None)</code>
<pre>Sign out user.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to sign out user.
"instanceId": "A String", # Instance id token of the app.
"localId": "A String", # The local ID of the user.
}
Returns:
An object of the form:
{ # Response of signing out user.
"localId": "A String", # The local ID of the user.
}</pre>
</div>
<div class="method">
<code class="details" id="signupNewUser">signupNewUser(body=None)</code>
<pre>Signup new user.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to signup new user, create anonymous user or anonymous user reauth.
"captchaChallenge": "A String", # The captcha challenge.
"captchaResponse": "A String", # Response to the captcha.
"disabled": True or False, # Whether to disable the user. Only can be used by service account.
"displayName": "A String", # The name of the user.
"email": "A String", # The email of the user.
"emailVerified": True or False, # Mark the email as verified or not. Only can be used by service account.
"idToken": "A String", # The GITKit token of the authenticated user.
"instanceId": "A String", # Instance id token of the app.
"localId": "A String", # Privileged caller can create user with specified user id.
"password": "A String", # The new password of the user.
"phoneNumber": "A String", # Privileged caller can create user with specified phone number.
"photoUrl": "A String", # The photo url of the user.
"tenantId": "A String", # For multi-tenant use cases, in order to construct sign-in URL with the correct IDP parameters, Firebear needs to know which Tenant to retrieve IDP configs from.
"tenantProjectNumber": "A String", # Tenant project number to be used for idp discovery.
}
Returns:
An object of the form:
{ # Response of signing up new user, creating anonymous user or anonymous user reauth.
"displayName": "A String", # The name of the user.
"email": "A String", # The email of the user.
"expiresIn": "A String", # If idToken is STS id token, then this field will be expiration time of STS id token in seconds.
"idToken": "A String", # The Gitkit id token to login the newly sign up user.
"kind": "identitytoolkit#SignupNewUserResponse", # The fixed string "identitytoolkit#SignupNewUserResponse".
"localId": "A String", # The RP local ID of the user.
"refreshToken": "A String", # If idToken is STS id token, then this field will be refresh token.
}</pre>
</div>
<div class="method">
<code class="details" id="uploadAccount">uploadAccount(body=None)</code>
<pre>Batch upload existing user accounts.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to upload user account in batch.
"allowOverwrite": True or False, # Whether allow overwrite existing account when user local_id exists.
"blockSize": 42,
"cpuMemCost": 42, # The following 4 fields are for standard scrypt algorithm.
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"dkLen": 42,
"hashAlgorithm": "A String", # The password hash algorithm.
"memoryCost": 42, # Memory cost for hash calculation. Used by scrypt similar algorithms.
"parallelization": 42,
"rounds": 42, # Rounds for hash calculation. Used by scrypt and similar algorithms.
"saltSeparator": "A String", # The salt separator.
"sanityCheck": True or False, # If true, backend will do sanity check(including duplicate email and federated id) when uploading account.
"signerKey": "A String", # The key for to hash the password.
"targetProjectId": "A String", # Specify which project (field value is actually project id) to operate. Only used when provided credential.
"users": [ # The account info to be stored.
{ # Template for an individual account info.
"createdAt": "A String", # User creation timestamp.
"customAttributes": "A String", # The custom attributes to be set in the user's id token.
"customAuth": True or False, # Whether the user is authenticated by the developer.
"disabled": True or False, # Whether the user is disabled.
"displayName": "A String", # The name of the user.
"email": "A String", # The email of the user.
"emailVerified": True or False, # Whether the email has been verified.
"lastLoginAt": "A String", # last login timestamp.
"localId": "A String", # The local ID of the user.
"passwordHash": "A String", # The user's hashed password.
"passwordUpdatedAt": 3.14, # The timestamp when the password was last updated.
"phoneNumber": "A String", # User's phone number.
"photoUrl": "A String", # The URL of the user profile photo.
"providerUserInfo": [ # The IDP of the user.
{
"displayName": "A String", # The user's display name at the IDP.
"email": "A String", # User's email at IDP.
"federatedId": "A String", # User's identifier at IDP.
"phoneNumber": "A String", # User's phone number.
"photoUrl": "A String", # The user's photo url at the IDP.
"providerId": "A String", # The IdP ID. For white listed IdPs it's a short domain name, e.g., google.com, aol.com, live.net and yahoo.com. For other OpenID IdPs it's the OP identifier.
"rawId": "A String", # User's raw identifier directly returned from IDP.
"screenName": "A String", # User's screen name at Twitter or login name at Github.
},
],
"rawPassword": "A String", # The user's plain text password.
"salt": "A String", # The user's password salt.
"screenName": "A String", # User's screen name at Twitter or login name at Github.
"validSince": "A String", # Timestamp in seconds for valid login token.
"version": 42, # Version of the user's password.
},
],
}
Returns:
An object of the form:
{ # Respone of uploading accounts in batch.
"error": [ # The error encountered while processing the account info.
{
"index": 42, # The index of the malformed account, starting from 0.
"message": "A String", # Detailed error message for the account info.
},
],
"kind": "identitytoolkit#UploadAccountResponse", # The fixed string "identitytoolkit#UploadAccountResponse".
}</pre>
</div>
<div class="method">
<code class="details" id="verifyAssertion">verifyAssertion(body=None)</code>
<pre>Verifies the assertion returned by the IdP.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to verify the IDP assertion.
"autoCreate": True or False, # When it's true, automatically creates a new account if the user doesn't exist. When it's false, allows existing user to sign in normally and throws exception if the user doesn't exist.
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"idToken": "A String", # The GITKit token of the authenticated user.
"instanceId": "A String", # Instance id token of the app.
"pendingIdToken": "A String", # The GITKit token for the non-trusted IDP pending to be confirmed by the user.
"postBody": "A String", # The post body if the request is a HTTP POST.
"requestUri": "A String", # The URI to which the IDP redirects the user back. It may contain federated login result params added by the IDP.
"returnIdpCredential": True or False, # Whether return 200 and IDP credential rather than throw exception when federated id is already linked.
"returnRefreshToken": True or False, # Whether to return refresh tokens.
"returnSecureToken": True or False, # Whether return sts id token and refresh token instead of gitkit token.
"sessionId": "A String", # Session ID, which should match the one in previous createAuthUri request.
"tenantId": "A String", # For multi-tenant use cases, in order to construct sign-in URL with the correct IDP parameters, Firebear needs to know which Tenant to retrieve IDP configs from.
"tenantProjectNumber": "A String", # Tenant project number to be used for idp discovery.
}
Returns:
An object of the form:
{ # Response of verifying the IDP assertion.
"action": "A String", # The action code.
"appInstallationUrl": "A String", # URL for OTA app installation.
"appScheme": "A String", # The custom scheme used by mobile app.
"context": "A String", # The opaque value used by the client to maintain context info between the authentication request and the IDP callback.
"dateOfBirth": "A String", # The birth date of the IdP account.
"displayName": "A String", # The display name of the user.
"email": "A String", # The email returned by the IdP. NOTE: The federated login user may not own the email.
"emailRecycled": True or False, # It's true if the email is recycled.
"emailVerified": True or False, # The value is true if the IDP is also the email provider. It means the user owns the email.
"errorMessage": "A String", # Client error code.
"expiresIn": "A String", # If idToken is STS id token, then this field will be expiration time of STS id token in seconds.
"federatedId": "A String", # The unique ID identifies the IdP account.
"firstName": "A String", # The first name of the user.
"fullName": "A String", # The full name of the user.
"idToken": "A String", # The ID token.
"inputEmail": "A String", # It's the identifier param in the createAuthUri request if the identifier is an email. It can be used to check whether the user input email is different from the asserted email.
"isNewUser": True or False, # True if it's a new user sign-in, false if it's a returning user.
"kind": "identitytoolkit#VerifyAssertionResponse", # The fixed string "identitytoolkit#VerifyAssertionResponse".
"language": "A String", # The language preference of the user.
"lastName": "A String", # The last name of the user.
"localId": "A String", # The RP local ID if it's already been mapped to the IdP account identified by the federated ID.
"needConfirmation": True or False, # Whether the assertion is from a non-trusted IDP and need account linking confirmation.
"needEmail": True or False, # Whether need client to supply email to complete the federated login flow.
"nickName": "A String", # The nick name of the user.
"oauthAccessToken": "A String", # The OAuth2 access token.
"oauthAuthorizationCode": "A String", # The OAuth2 authorization code.
"oauthExpireIn": 42, # The lifetime in seconds of the OAuth2 access token.
"oauthIdToken": "A String", # The OIDC id token.
"oauthRequestToken": "A String", # The user approved request token for the OpenID OAuth extension.
"oauthScope": "A String", # The scope for the OpenID OAuth extension.
"oauthTokenSecret": "A String", # The OAuth1 access token secret.
"originalEmail": "A String", # The original email stored in the mapping storage. It's returned when the federated ID is associated to a different email.
"photoUrl": "A String", # The URI of the public accessible profiel picture.
"providerId": "A String", # The IdP ID. For white listed IdPs it's a short domain name e.g. google.com, aol.com, live.net and yahoo.com. If the "providerId" param is set to OpenID OP identifer other than the whilte listed IdPs the OP identifier is returned. If the "identifier" param is federated ID in the createAuthUri request. The domain part of the federated ID is returned.
"rawUserInfo": "A String", # Raw IDP-returned user info.
"refreshToken": "A String", # If idToken is STS id token, then this field will be refresh token.
"screenName": "A String", # The screen_name of a Twitter user or the login name at Github.
"timeZone": "A String", # The timezone of the user.
"verifiedProvider": [ # When action is 'map', contains the idps which can be used for confirmation.
"A String",
],
}</pre>
</div>
<div class="method">
<code class="details" id="verifyCustomToken">verifyCustomToken(body=None)</code>
<pre>Verifies the developer asserted ID token.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to verify a custom token
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"instanceId": "A String", # Instance id token of the app.
"returnSecureToken": True or False, # Whether return sts id token and refresh token instead of gitkit token.
"token": "A String", # The custom token to verify
}
Returns:
An object of the form:
{ # Response from verifying a custom token
"expiresIn": "A String", # If idToken is STS id token, then this field will be expiration time of STS id token in seconds.
"idToken": "A String", # The GITKit token for authenticated user.
"isNewUser": True or False, # True if it's a new user sign-in, false if it's a returning user.
"kind": "identitytoolkit#VerifyCustomTokenResponse", # The fixed string "identitytoolkit#VerifyCustomTokenResponse".
"refreshToken": "A String", # If idToken is STS id token, then this field will be refresh token.
}</pre>
</div>
<div class="method">
<code class="details" id="verifyPassword">verifyPassword(body=None)</code>
<pre>Verifies the user entered password.
Args:
body: object, The request body.
The object takes the form of:
{ # Request to verify the password.
"captchaChallenge": "A String", # The captcha challenge.
"captchaResponse": "A String", # Response to the captcha.
"delegatedProjectNumber": "A String", # GCP project number of the requesting delegated app. Currently only intended for Firebase V1 migration.
"email": "A String", # The email of the user.
"idToken": "A String", # The GITKit token of the authenticated user.
"instanceId": "A String", # Instance id token of the app.
"password": "A String", # The password inputed by the user.
"pendingIdToken": "A String", # The GITKit token for the non-trusted IDP, which is to be confirmed by the user.
"returnSecureToken": True or False, # Whether return sts id token and refresh token instead of gitkit token.
"tenantId": "A String", # For multi-tenant use cases, in order to construct sign-in URL with the correct IDP parameters, Firebear needs to know which Tenant to retrieve IDP configs from.
"tenantProjectNumber": "A String", # Tenant project number to be used for idp discovery.
}
Returns:
An object of the form:
{ # Request of verifying the password.
"displayName": "A String", # The name of the user.
"email": "A String", # The email returned by the IdP. NOTE: The federated login user may not own the email.
"expiresIn": "A String", # If idToken is STS id token, then this field will be expiration time of STS id token in seconds.
"idToken": "A String", # The GITKit token for authenticated user.
"kind": "identitytoolkit#VerifyPasswordResponse", # The fixed string "identitytoolkit#VerifyPasswordResponse".
"localId": "A String", # The RP local ID if it's already been mapped to the IdP account identified by the federated ID.
"oauthAccessToken": "A String", # The OAuth2 access token.
"oauthAuthorizationCode": "A String", # The OAuth2 authorization code.
"oauthExpireIn": 42, # The lifetime in seconds of the OAuth2 access token.
"photoUrl": "A String", # The URI of the user's photo at IdP
"refreshToken": "A String", # If idToken is STS id token, then this field will be refresh token.
"registered": True or False, # Whether the email is registered.
}</pre>
</div>
<div class="method">
<code class="details" id="verifyPhoneNumber">verifyPhoneNumber(body=None)</code>
<pre>Verifies ownership of a phone number and creates/updates the user account accordingly.
Args:
body: object, The request body.
The object takes the form of:
{ # Request for Identitytoolkit-VerifyPhoneNumber
"code": "A String",
"idToken": "A String",
"operation": "A String",
"phoneNumber": "A String",
"sessionInfo": "A String", # The session info previously returned by IdentityToolkit-SendVerificationCode.
"temporaryProof": "A String",
"verificationProof": "A String",
}
Returns:
An object of the form:
{ # Response for Identitytoolkit-VerifyPhoneNumber
"expiresIn": "A String",
"idToken": "A String",
"isNewUser": True or False,
"localId": "A String",
"phoneNumber": "A String",
"refreshToken": "A String",
"temporaryProof": "A String",
"temporaryProofExpiresIn": "A String",
"verificationProof": "A String",
"verificationProofExpiresIn": "A String",
}</pre>
</div>
</body></html>
|