| 1 |
<html><body> |
| 2 |
<style> |
| 3 |
|
| 4 |
body, h1, h2, h3, div, span, p, pre, a { |
| 5 |
margin: 0; |
| 6 |
padding: 0; |
| 7 |
border: 0; |
| 8 |
font-weight: inherit; |
| 9 |
font-style: inherit; |
| 10 |
font-size: 100%; |
| 11 |
font-family: inherit; |
| 12 |
vertical-align: baseline; |
| 13 |
} |
| 14 |
|
| 15 |
body { |
| 16 |
font-size: 13px; |
| 17 |
padding: 1em; |
| 18 |
} |
| 19 |
|
| 20 |
h1 { |
| 21 |
font-size: 26px; |
| 22 |
margin-bottom: 1em; |
| 23 |
} |
| 24 |
|
| 25 |
h2 { |
| 26 |
font-size: 24px; |
| 27 |
margin-bottom: 1em; |
| 28 |
} |
| 29 |
|
| 30 |
h3 { |
| 31 |
font-size: 20px; |
| 32 |
margin-bottom: 1em; |
| 33 |
margin-top: 1em; |
| 34 |
} |
| 35 |
|
| 36 |
pre, code { |
| 37 |
line-height: 1.5; |
| 38 |
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; |
| 39 |
} |
| 40 |
|
| 41 |
pre { |
| 42 |
margin-top: 0.5em; |
| 43 |
} |
| 44 |
|
| 45 |
h1, h2, h3, p { |
| 46 |
font-family: Arial, sans serif; |
| 47 |
} |
| 48 |
|
| 49 |
h1, h2, h3 { |
| 50 |
border-bottom: solid #CCC 1px; |
| 51 |
} |
| 52 |
|
| 53 |
.toc_element { |
| 54 |
margin-top: 0.5em; |
| 55 |
} |
| 56 |
|
| 57 |
.firstline { |
| 58 |
margin-left: 2 em; |
| 59 |
} |
| 60 |
|
| 61 |
.method { |
| 62 |
margin-top: 1em; |
| 63 |
border: solid 1px #CCC; |
| 64 |
padding: 1em; |
| 65 |
background: #EEE; |
| 66 |
} |
| 67 |
|
| 68 |
.details { |
| 69 |
font-weight: bold; |
| 70 |
font-size: 14px; |
| 71 |
} |
| 72 |
|
| 73 |
</style> |
| 74 |
|
| 75 |
<h1><a href="identitytoolkit_v2.html">Identity Toolkit API</a> . <a href="identitytoolkit_v2.accounts.html">accounts</a> . <a href="identitytoolkit_v2.accounts.mfaEnrollment.html">mfaEnrollment</a></h1> |
| 76 |
<h2>Instance Methods</h2> |
| 77 |
<p class="toc_element"> |
| 78 |
<code><a href="#close">close()</a></code></p> |
| 79 |
<p class="firstline">Close httplib2 connections.</p> |
| 80 |
<p class="toc_element"> |
| 81 |
<code><a href="#finalize">finalize(body=None, x__xgafv=None)</a></code></p> |
| 82 |
<p class="firstline">Finishes enrolling a second factor for the user.</p> |
| 83 |
<p class="toc_element"> |
| 84 |
<code><a href="#start">start(body=None, x__xgafv=None)</a></code></p> |
| 85 |
<p class="firstline">Step one of the MFA enrollment process. In SMS case, this sends an SMS verification code to the user.</p> |
| 86 |
<p class="toc_element"> |
| 87 |
<code><a href="#withdraw">withdraw(body=None, x__xgafv=None)</a></code></p> |
| 88 |
<p class="firstline">Revokes one second factor from the enrolled second factors for an account.</p> |
| 89 |
<h3>Method Details</h3> |
| 90 |
<div class="method"> |
| 91 |
<code class="details" id="close">close()</code> |
| 92 |
<pre>Close httplib2 connections.</pre> |
| 93 |
</div> |
| 94 |
|
| 95 |
<div class="method"> |
| 96 |
<code class="details" id="finalize">finalize(body=None, x__xgafv=None)</code> |
| 97 |
<pre>Finishes enrolling a second factor for the user. |
| 98 |
|
| 99 |
Args: |
| 100 |
body: object, The request body. |
| 101 |
The object takes the form of: |
| 102 |
|
| 103 |
{ # Finishes enrolling a second factor for the user. |
| 104 |
"displayName": "A String", # Display name which is entered by users to distinguish between different second factors with same type or different type. |
| 105 |
"idToken": "A String", # Required. ID token. |
| 106 |
"phoneVerificationInfo": { # Phone Verification info for a FinalizeMfa request. # Verification info to authorize sending an SMS for phone verification. |
| 107 |
"androidVerificationProof": "A String", # Android only. Uses for "instant" phone number verification though GmsCore. |
| 108 |
"code": "A String", # User-entered verification code. |
| 109 |
"phoneNumber": "A String", # Required if Android verification proof is presented. |
| 110 |
"sessionInfo": "A String", # An opaque string that represents the enrollment session. |
| 111 |
}, |
| 112 |
"tenantId": "A String", # The ID of the Identity Platform tenant that the user enrolling MFA belongs to. If not set, the user belongs to the default Identity Platform project. |
| 113 |
"totpVerificationInfo": { # Mfa request info specific to TOTP auth for FinalizeMfa. # Verification information for TOTP. |
| 114 |
"sessionInfo": "A String", # An opaque string that represents the enrollment session. |
| 115 |
"verificationCode": "A String", # User-entered verification code. |
| 116 |
}, |
| 117 |
} |
| 118 |
|
| 119 |
x__xgafv: string, V1 error format. |
| 120 |
Allowed values |
| 121 |
1 - v1 error format |
| 122 |
2 - v2 error format |
| 123 |
|
| 124 |
Returns: |
| 125 |
An object of the form: |
| 126 |
|
| 127 |
{ # FinalizeMfaEnrollment response. |
| 128 |
"idToken": "A String", # ID token updated to reflect MFA enrollment. |
| 129 |
"phoneAuthInfo": { # Phone Verification info for a FinalizeMfa response. # Auxiliary auth info specific to phone auth. |
| 130 |
"androidVerificationProof": "A String", # Android only. Long-lived replacement for valid code tied to android device. |
| 131 |
"androidVerificationProofExpireTime": "A String", # Android only. Expiration time of verification proof in seconds. |
| 132 |
"phoneNumber": "A String", # For Android verification proof. |
| 133 |
}, |
| 134 |
"refreshToken": "A String", # Refresh token updated to reflect MFA enrollment. |
| 135 |
"totpAuthInfo": { # Mfa response info specific to TOTP auth for FinalizeMfa. # Auxiliary auth info specific to TOTP auth. |
| 136 |
}, |
| 137 |
}</pre> |
| 138 |
</div> |
| 139 |
|
| 140 |
<div class="method"> |
| 141 |
<code class="details" id="start">start(body=None, x__xgafv=None)</code> |
| 142 |
<pre>Step one of the MFA enrollment process. In SMS case, this sends an SMS verification code to the user. |
| 143 |
|
| 144 |
Args: |
| 145 |
body: object, The request body. |
| 146 |
The object takes the form of: |
| 147 |
|
| 148 |
{ # Sends MFA enrollment verification SMS for a user. |
| 149 |
"idToken": "A String", # Required. User's ID token. |
| 150 |
"phoneEnrollmentInfo": { # App Verification info for a StartMfa request. # Verification info to authorize sending an SMS for phone verification. |
| 151 |
"autoRetrievalInfo": { # The information required to auto-retrieve an SMS. # Android only. Used by Google Play Services to identify the app for auto-retrieval. |
| 152 |
"appSignatureHash": "A String", # The Android app's signature hash for Google Play Service's SMS Retriever API. |
| 153 |
}, |
| 154 |
"captchaResponse": "A String", # The reCAPTCHA Enterprise token provided by the reCAPTCHA client-side integration. Required when reCAPTCHA enterprise is enabled. |
| 155 |
"clientType": "A String", # The client type, web, android or ios. Required when reCAPTCHA Enterprise is enabled. |
| 156 |
"iosReceipt": "A String", # iOS only. Receipt of successful app token validation with APNS. |
| 157 |
"iosSecret": "A String", # iOS only. Secret delivered to iOS app via APNS. |
| 158 |
"phoneNumber": "A String", # Required for enrollment. Phone number to be enrolled as MFA. |
| 159 |
"playIntegrityToken": "A String", # Android only. Used to assert application identity in place of a recaptcha token (or safety net token). A Play Integrity Token can be generated via the [PlayIntegrity API] (https://developer.android.com/google/play/integrity) with applying SHA256 to the `phone_number` field as the nonce. |
| 160 |
"recaptchaToken": "A String", # Web only. Recaptcha solution. |
| 161 |
"recaptchaVersion": "A String", # The reCAPTCHA version of the reCAPTCHA token in the captcha_response. Required when reCAPTCHA Enterprise is enabled. |
| 162 |
"safetyNetToken": "A String", # Android only. Used to assert application identity in place of a recaptcha token. A SafetyNet Token can be generated via the [SafetyNet Android Attestation API](https://developer.android.com/training/safetynet/attestation.html), with the Base64 encoding of the `phone_number` field as the nonce. |
| 163 |
}, |
| 164 |
"tenantId": "A String", # The ID of the Identity Platform tenant that the user enrolling MFA belongs to. If not set, the user belongs to the default Identity Platform project. |
| 165 |
"totpEnrollmentInfo": { # Mfa request info specific to TOTP auth for StartMfa. # Sign-in info specific to TOTP auth. |
| 166 |
}, |
| 167 |
} |
| 168 |
|
| 169 |
x__xgafv: string, V1 error format. |
| 170 |
Allowed values |
| 171 |
1 - v1 error format |
| 172 |
2 - v2 error format |
| 173 |
|
| 174 |
Returns: |
| 175 |
An object of the form: |
| 176 |
|
| 177 |
{ # StartMfaEnrollment response. |
| 178 |
"phoneSessionInfo": { # Phone Verification info for a StartMfa response. # Verification info to authorize sending an SMS for phone verification. |
| 179 |
"sessionInfo": "A String", # An opaque string that represents the enrollment session. |
| 180 |
}, |
| 181 |
"totpSessionInfo": { # Mfa response info specific to TOTP auth for StartMfa. # Enrollment response info specific to TOTP auth. |
| 182 |
"finalizeEnrollmentTime": "A String", # The time by which the enrollment must finish. |
| 183 |
"hashingAlgorithm": "A String", # The hashing algorithm used to generate the verification code. |
| 184 |
"periodSec": 42, # Duration in seconds at which the verification code will change. |
| 185 |
"sessionInfo": "A String", # An encoded string that represents the enrollment session. |
| 186 |
"sharedSecretKey": "A String", # A base 32 encoded string that represents the shared TOTP secret. The base 32 encoding is the one specified by [RFC4648#section-6](https://datatracker.ietf.org/doc/html/rfc4648#section-6). (This is the same as the base 32 encoding from [RFC3548#section-5](https://datatracker.ietf.org/doc/html/rfc3548#section-5).) |
| 187 |
"verificationCodeLength": 42, # The length of the verification code that needs to be generated. |
| 188 |
}, |
| 189 |
}</pre> |
| 190 |
</div> |
| 191 |
|
| 192 |
<div class="method"> |
| 193 |
<code class="details" id="withdraw">withdraw(body=None, x__xgafv=None)</code> |
| 194 |
<pre>Revokes one second factor from the enrolled second factors for an account. |
| 195 |
|
| 196 |
Args: |
| 197 |
body: object, The request body. |
| 198 |
The object takes the form of: |
| 199 |
|
| 200 |
{ # Withdraws MFA. |
| 201 |
"idToken": "A String", # Required. User's ID token. |
| 202 |
"mfaEnrollmentId": "A String", # Required. MFA enrollment id from a current MFA enrollment. |
| 203 |
"tenantId": "A String", # The ID of the Identity Platform tenant that the user unenrolling MFA belongs to. If not set, the user belongs to the default Identity Platform project. |
| 204 |
} |
| 205 |
|
| 206 |
x__xgafv: string, V1 error format. |
| 207 |
Allowed values |
| 208 |
1 - v1 error format |
| 209 |
2 - v2 error format |
| 210 |
|
| 211 |
Returns: |
| 212 |
An object of the form: |
| 213 |
|
| 214 |
{ # Withdraws MultiFactorAuth response. |
| 215 |
"idToken": "A String", # ID token updated to reflect removal of the second factor. |
| 216 |
"refreshToken": "A String", # Refresh token updated to reflect removal of the second factor. |
| 217 |
}</pre> |
| 218 |
</div> |
| 219 |
|
| 220 |
</body></html> |