google-apis-identitytoolkit_v1 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,3769 @@
1
+ # Copyright 2020 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module IdentitytoolkitV1
24
+
25
+ # The parameters for Argon2 hashing algorithm.
26
+ class GoogleCloudIdentitytoolkitV1Argon2Parameters
27
+ include Google::Apis::Core::Hashable
28
+
29
+ # The additional associated data, if provided, is appended to the hash value to
30
+ # provide an additional layer of security. A base64-encoded string if specified
31
+ # via JSON.
32
+ # Corresponds to the JSON property `associatedData`
33
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
34
+ # @return [String]
35
+ attr_accessor :associated_data
36
+
37
+ # Required. The desired hash length in bytes. Minimum is 4 and maximum is 1024.
38
+ # Corresponds to the JSON property `hashLengthBytes`
39
+ # @return [Fixnum]
40
+ attr_accessor :hash_length_bytes
41
+
42
+ # Required. Must not be HASH_TYPE_UNSPECIFIED.
43
+ # Corresponds to the JSON property `hashType`
44
+ # @return [String]
45
+ attr_accessor :hash_type
46
+
47
+ # Required. The number of iterations to perform. Minimum is 1, maximum is 16.
48
+ # Corresponds to the JSON property `iterations`
49
+ # @return [Fixnum]
50
+ attr_accessor :iterations
51
+
52
+ # Required. The memory cost in kibibytes. Maximum is 32768.
53
+ # Corresponds to the JSON property `memoryCostKib`
54
+ # @return [Fixnum]
55
+ attr_accessor :memory_cost_kib
56
+
57
+ # Required. The degree of parallelism, also called threads or lanes. Minimum is
58
+ # 1, maximum is 16.
59
+ # Corresponds to the JSON property `parallelism`
60
+ # @return [Fixnum]
61
+ attr_accessor :parallelism
62
+
63
+ # The version of the Argon2 algorithm. This defaults to VERSION_13 if not
64
+ # specified.
65
+ # Corresponds to the JSON property `version`
66
+ # @return [String]
67
+ attr_accessor :version
68
+
69
+ def initialize(**args)
70
+ update!(**args)
71
+ end
72
+
73
+ # Update properties of this object
74
+ def update!(**args)
75
+ @associated_data = args[:associated_data] if args.key?(:associated_data)
76
+ @hash_length_bytes = args[:hash_length_bytes] if args.key?(:hash_length_bytes)
77
+ @hash_type = args[:hash_type] if args.key?(:hash_type)
78
+ @iterations = args[:iterations] if args.key?(:iterations)
79
+ @memory_cost_kib = args[:memory_cost_kib] if args.key?(:memory_cost_kib)
80
+ @parallelism = args[:parallelism] if args.key?(:parallelism)
81
+ @version = args[:version] if args.key?(:version)
82
+ end
83
+ end
84
+
85
+ # The information required to auto-retrieve an SMS.
86
+ class GoogleCloudIdentitytoolkitV1AutoRetrievalInfo
87
+ include Google::Apis::Core::Hashable
88
+
89
+ # The Android app's signature hash for Google Play Service's SMS Retriever API.
90
+ # Corresponds to the JSON property `appSignatureHash`
91
+ # @return [String]
92
+ attr_accessor :app_signature_hash
93
+
94
+ def initialize(**args)
95
+ update!(**args)
96
+ end
97
+
98
+ # Update properties of this object
99
+ def update!(**args)
100
+ @app_signature_hash = args[:app_signature_hash] if args.key?(:app_signature_hash)
101
+ end
102
+ end
103
+
104
+ # Request message for BatchDeleteAccounts.
105
+ class GoogleCloudIdentitytoolkitV1BatchDeleteAccountsRequest
106
+ include Google::Apis::Core::Hashable
107
+
108
+ # Whether to force deleting accounts that are not in disabled state. If false,
109
+ # only disabled accounts will be deleted, and accounts that are not disabled
110
+ # will be added to the `errors`.
111
+ # Corresponds to the JSON property `force`
112
+ # @return [Boolean]
113
+ attr_accessor :force
114
+ alias_method :force?, :force
115
+
116
+ # Required. List of user IDs to be deleted.
117
+ # Corresponds to the JSON property `localIds`
118
+ # @return [Array<String>]
119
+ attr_accessor :local_ids
120
+
121
+ # If the accounts belong to an Identity Platform tenant, the ID of the tenant.
122
+ # If the accounts belong to an default Identity Platform project, the field is
123
+ # not needed.
124
+ # Corresponds to the JSON property `tenantId`
125
+ # @return [String]
126
+ attr_accessor :tenant_id
127
+
128
+ def initialize(**args)
129
+ update!(**args)
130
+ end
131
+
132
+ # Update properties of this object
133
+ def update!(**args)
134
+ @force = args[:force] if args.key?(:force)
135
+ @local_ids = args[:local_ids] if args.key?(:local_ids)
136
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
137
+ end
138
+ end
139
+
140
+ # Response message to BatchDeleteAccounts.
141
+ class GoogleCloudIdentitytoolkitV1BatchDeleteAccountsResponse
142
+ include Google::Apis::Core::Hashable
143
+
144
+ # Detailed error info for accounts that cannot be deleted.
145
+ # Corresponds to the JSON property `errors`
146
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1BatchDeleteErrorInfo>]
147
+ attr_accessor :errors
148
+
149
+ def initialize(**args)
150
+ update!(**args)
151
+ end
152
+
153
+ # Update properties of this object
154
+ def update!(**args)
155
+ @errors = args[:errors] if args.key?(:errors)
156
+ end
157
+ end
158
+
159
+ # Error info for account failed to be deleted.
160
+ class GoogleCloudIdentitytoolkitV1BatchDeleteErrorInfo
161
+ include Google::Apis::Core::Hashable
162
+
163
+ # The index of the errored item in the original local_ids field.
164
+ # Corresponds to the JSON property `index`
165
+ # @return [Fixnum]
166
+ attr_accessor :index
167
+
168
+ # The corresponding user ID.
169
+ # Corresponds to the JSON property `localId`
170
+ # @return [String]
171
+ attr_accessor :local_id
172
+
173
+ # Detailed error message.
174
+ # Corresponds to the JSON property `message`
175
+ # @return [String]
176
+ attr_accessor :message
177
+
178
+ def initialize(**args)
179
+ update!(**args)
180
+ end
181
+
182
+ # Update properties of this object
183
+ def update!(**args)
184
+ @index = args[:index] if args.key?(:index)
185
+ @local_id = args[:local_id] if args.key?(:local_id)
186
+ @message = args[:message] if args.key?(:message)
187
+ end
188
+ end
189
+
190
+ # Request message for CreateAuthUri.
191
+ class GoogleCloudIdentitytoolkitV1CreateAuthUriRequest
192
+ include Google::Apis::Core::Hashable
193
+
194
+ #
195
+ # Corresponds to the JSON property `appId`
196
+ # @return [String]
197
+ attr_accessor :app_id
198
+
199
+ # Used for the Google provider. The type of the authentication flow to be used.
200
+ # If present, this should be `CODE_FLOW` to specify the authorization code flow.
201
+ # Otherwise, the default ID Token flow will be used.
202
+ # Corresponds to the JSON property `authFlowType`
203
+ # @return [String]
204
+ attr_accessor :auth_flow_type
205
+
206
+ # An opaque string used to maintain contextual information between the
207
+ # authentication request and the callback from the IdP.
208
+ # Corresponds to the JSON property `context`
209
+ # @return [String]
210
+ attr_accessor :context
211
+
212
+ # A valid URL for the IdP to redirect the user back to. The URL cannot contain
213
+ # fragments or the reserved `state` query parameter.
214
+ # Corresponds to the JSON property `continueUri`
215
+ # @return [String]
216
+ attr_accessor :continue_uri
217
+
218
+ # Additional customized query parameters to be added to the authorization URI.
219
+ # The following parameters are reserved and cannot be added: `client_id`, `
220
+ # response_type`, `scope`, `redirect_uri`, `state`. For the Microsoft provider,
221
+ # the Azure AD tenant to sign-in to can be specified in the `tenant` custom
222
+ # parameter.
223
+ # Corresponds to the JSON property `customParameter`
224
+ # @return [Hash<String,String>]
225
+ attr_accessor :custom_parameter
226
+
227
+ # Used for the Google provider. The G Suite hosted domain of the user in order
228
+ # to restrict sign-in to users at that domain.
229
+ # Corresponds to the JSON property `hostedDomain`
230
+ # @return [String]
231
+ attr_accessor :hosted_domain
232
+
233
+ # The email identifier of the user account to fetch associated providers for. At
234
+ # least one of the fields `identifier` and `provider_id` must be set. The length
235
+ # of the email address should be less than 256 characters and in the format of `
236
+ # name@domain.tld`. The email address should also match the [RFC 822](https://
237
+ # tools.ietf.org/html/rfc822) addr-spec production.
238
+ # Corresponds to the JSON property `identifier`
239
+ # @return [String]
240
+ attr_accessor :identifier
241
+
242
+ #
243
+ # Corresponds to the JSON property `oauthConsumerKey`
244
+ # @return [String]
245
+ attr_accessor :oauth_consumer_key
246
+
247
+ # Additional space-delimited OAuth 2.0 scopes specifying the scope of the
248
+ # authentication request with the IdP. Used for OAuth 2.0 IdPs. For the Google
249
+ # provider, the authorization code flow will be used if this field is set.
250
+ # Corresponds to the JSON property `oauthScope`
251
+ # @return [String]
252
+ attr_accessor :oauth_scope
253
+
254
+ #
255
+ # Corresponds to the JSON property `openidRealm`
256
+ # @return [String]
257
+ attr_accessor :openid_realm
258
+
259
+ #
260
+ # Corresponds to the JSON property `otaApp`
261
+ # @return [String]
262
+ attr_accessor :ota_app
263
+
264
+ # The provider ID of the IdP for the user to sign in with. This should be a
265
+ # provider ID enabled for sign-in, which is either from the list of [default
266
+ # supported IdPs](https://cloud.google.com/identity-platform/docs/reference/rest/
267
+ # v2/defaultSupportedIdps/list), or of the format `oidc.*` or `saml.*`. Some
268
+ # examples are `google.com`, `facebook.com`, `oidc.testapp`, and `saml.testapp`.
269
+ # At least one of the fields `identifier` and `provider_id` must be set.
270
+ # Corresponds to the JSON property `providerId`
271
+ # @return [String]
272
+ attr_accessor :provider_id
273
+
274
+ # A session ID that can be verified against in SignInWithIdp to prevent session
275
+ # fixation attacks. If absent, a random string will be generated and returned as
276
+ # the session ID.
277
+ # Corresponds to the JSON property `sessionId`
278
+ # @return [String]
279
+ attr_accessor :session_id
280
+
281
+ # The ID of the Identity Platform tenant to create an authorization URI or
282
+ # lookup an email identifier for. If not set, the operation will be performed in
283
+ # the default Identity Platform instance in the project.
284
+ # Corresponds to the JSON property `tenantId`
285
+ # @return [String]
286
+ attr_accessor :tenant_id
287
+
288
+ def initialize(**args)
289
+ update!(**args)
290
+ end
291
+
292
+ # Update properties of this object
293
+ def update!(**args)
294
+ @app_id = args[:app_id] if args.key?(:app_id)
295
+ @auth_flow_type = args[:auth_flow_type] if args.key?(:auth_flow_type)
296
+ @context = args[:context] if args.key?(:context)
297
+ @continue_uri = args[:continue_uri] if args.key?(:continue_uri)
298
+ @custom_parameter = args[:custom_parameter] if args.key?(:custom_parameter)
299
+ @hosted_domain = args[:hosted_domain] if args.key?(:hosted_domain)
300
+ @identifier = args[:identifier] if args.key?(:identifier)
301
+ @oauth_consumer_key = args[:oauth_consumer_key] if args.key?(:oauth_consumer_key)
302
+ @oauth_scope = args[:oauth_scope] if args.key?(:oauth_scope)
303
+ @openid_realm = args[:openid_realm] if args.key?(:openid_realm)
304
+ @ota_app = args[:ota_app] if args.key?(:ota_app)
305
+ @provider_id = args[:provider_id] if args.key?(:provider_id)
306
+ @session_id = args[:session_id] if args.key?(:session_id)
307
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
308
+ end
309
+ end
310
+
311
+ # Response message for CreateAuthUri.
312
+ class GoogleCloudIdentitytoolkitV1CreateAuthUriResponse
313
+ include Google::Apis::Core::Hashable
314
+
315
+ #
316
+ # Corresponds to the JSON property `allProviders`
317
+ # @return [Array<String>]
318
+ attr_accessor :all_providers
319
+
320
+ # The authorization URI for the requested provider. Present only when a provider
321
+ # ID is set in the request.
322
+ # Corresponds to the JSON property `authUri`
323
+ # @return [String]
324
+ attr_accessor :auth_uri
325
+
326
+ # Whether a CAPTCHA is needed because there have been too many failed login
327
+ # attempts by the user. Present only when a registered email identifier is set
328
+ # in the request.
329
+ # Corresponds to the JSON property `captchaRequired`
330
+ # @return [Boolean]
331
+ attr_accessor :captcha_required
332
+ alias_method :captcha_required?, :captcha_required
333
+
334
+ # Whether the user has previously signed in with the provider ID in the request.
335
+ # Present only when a registered email identifier is set in the request.
336
+ # Corresponds to the JSON property `forExistingProvider`
337
+ # @return [Boolean]
338
+ attr_accessor :for_existing_provider
339
+ alias_method :for_existing_provider?, :for_existing_provider
340
+
341
+ #
342
+ # Corresponds to the JSON property `kind`
343
+ # @return [String]
344
+ attr_accessor :kind
345
+
346
+ # The provider ID from the request, if provided.
347
+ # Corresponds to the JSON property `providerId`
348
+ # @return [String]
349
+ attr_accessor :provider_id
350
+
351
+ # Whether the email identifier represents an existing account. Present only when
352
+ # an email identifier is set in the request.
353
+ # Corresponds to the JSON property `registered`
354
+ # @return [Boolean]
355
+ attr_accessor :registered
356
+ alias_method :registered?, :registered
357
+
358
+ # The session ID from the request, or a random string generated by CreateAuthUri
359
+ # if absent. It is used to prevent session fixation attacks.
360
+ # Corresponds to the JSON property `sessionId`
361
+ # @return [String]
362
+ attr_accessor :session_id
363
+
364
+ # The list of sign-in methods that the user has previously used. Each element is
365
+ # one of `password`, `emailLink`, or the provider ID of an IdP. Present only
366
+ # when a registered email identifier is set in the request.
367
+ # Corresponds to the JSON property `signinMethods`
368
+ # @return [Array<String>]
369
+ attr_accessor :signin_methods
370
+
371
+ def initialize(**args)
372
+ update!(**args)
373
+ end
374
+
375
+ # Update properties of this object
376
+ def update!(**args)
377
+ @all_providers = args[:all_providers] if args.key?(:all_providers)
378
+ @auth_uri = args[:auth_uri] if args.key?(:auth_uri)
379
+ @captcha_required = args[:captcha_required] if args.key?(:captcha_required)
380
+ @for_existing_provider = args[:for_existing_provider] if args.key?(:for_existing_provider)
381
+ @kind = args[:kind] if args.key?(:kind)
382
+ @provider_id = args[:provider_id] if args.key?(:provider_id)
383
+ @registered = args[:registered] if args.key?(:registered)
384
+ @session_id = args[:session_id] if args.key?(:session_id)
385
+ @signin_methods = args[:signin_methods] if args.key?(:signin_methods)
386
+ end
387
+ end
388
+
389
+ # Request message for CreateSessionCookie.
390
+ class GoogleCloudIdentitytoolkitV1CreateSessionCookieRequest
391
+ include Google::Apis::Core::Hashable
392
+
393
+ # Required. A valid Identity Platform ID token.
394
+ # Corresponds to the JSON property `idToken`
395
+ # @return [String]
396
+ attr_accessor :id_token
397
+
398
+ # The tenant ID of the Identity Platform tenant the account belongs to.
399
+ # Corresponds to the JSON property `tenantId`
400
+ # @return [String]
401
+ attr_accessor :tenant_id
402
+
403
+ # The number of seconds until the session cookie expires. Specify a duration in
404
+ # seconds, between five minutes and fourteen days, inclusively.
405
+ # Corresponds to the JSON property `validDuration`
406
+ # @return [Fixnum]
407
+ attr_accessor :valid_duration
408
+
409
+ def initialize(**args)
410
+ update!(**args)
411
+ end
412
+
413
+ # Update properties of this object
414
+ def update!(**args)
415
+ @id_token = args[:id_token] if args.key?(:id_token)
416
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
417
+ @valid_duration = args[:valid_duration] if args.key?(:valid_duration)
418
+ end
419
+ end
420
+
421
+ # Response message for CreateSessionCookie.
422
+ class GoogleCloudIdentitytoolkitV1CreateSessionCookieResponse
423
+ include Google::Apis::Core::Hashable
424
+
425
+ # The session cookie that has been created from the Identity Platform ID token
426
+ # specified in the request. It is in the form of a JSON Web Token (JWT). Always
427
+ # present.
428
+ # Corresponds to the JSON property `sessionCookie`
429
+ # @return [String]
430
+ attr_accessor :session_cookie
431
+
432
+ def initialize(**args)
433
+ update!(**args)
434
+ end
435
+
436
+ # Update properties of this object
437
+ def update!(**args)
438
+ @session_cookie = args[:session_cookie] if args.key?(:session_cookie)
439
+ end
440
+ end
441
+
442
+ # Request message for DeleteAccount.
443
+ class GoogleCloudIdentitytoolkitV1DeleteAccountRequest
444
+ include Google::Apis::Core::Hashable
445
+
446
+ #
447
+ # Corresponds to the JSON property `delegatedProjectNumber`
448
+ # @return [Fixnum]
449
+ attr_accessor :delegated_project_number
450
+
451
+ # The Identity Platform ID token of the account to delete. Require to be
452
+ # specified for requests from end users that lack Google OAuth 2.0 credential.
453
+ # Authenticated requests bearing a Google OAuth2 credential with proper
454
+ # permissions may pass local_id to specify the account to delete alternatively.
455
+ # Corresponds to the JSON property `idToken`
456
+ # @return [String]
457
+ attr_accessor :id_token
458
+
459
+ # The ID of user account to delete. Specifying this field requires a Google
460
+ # OAuth 2.0 credential with proper [permissions](https://cloud.google.com/
461
+ # identity-platform/docs/access-control). Requests from users lacking the
462
+ # credential should pass an ID token instead.
463
+ # Corresponds to the JSON property `localId`
464
+ # @return [String]
465
+ attr_accessor :local_id
466
+
467
+ # The ID of the project which the account belongs to. Should only be specified
468
+ # in authenticated requests that specify local_id of an account.
469
+ # Corresponds to the JSON property `targetProjectId`
470
+ # @return [String]
471
+ attr_accessor :target_project_id
472
+
473
+ # The ID of the tenant that the account belongs to, if applicable. Only require
474
+ # to be specified for authenticated requests bearing a Google OAuth 2.0
475
+ # credential that specify local_id of an account that belongs to an Identity
476
+ # Platform tenant.
477
+ # Corresponds to the JSON property `tenantId`
478
+ # @return [String]
479
+ attr_accessor :tenant_id
480
+
481
+ def initialize(**args)
482
+ update!(**args)
483
+ end
484
+
485
+ # Update properties of this object
486
+ def update!(**args)
487
+ @delegated_project_number = args[:delegated_project_number] if args.key?(:delegated_project_number)
488
+ @id_token = args[:id_token] if args.key?(:id_token)
489
+ @local_id = args[:local_id] if args.key?(:local_id)
490
+ @target_project_id = args[:target_project_id] if args.key?(:target_project_id)
491
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
492
+ end
493
+ end
494
+
495
+ # Response message for DeleteAccount.
496
+ class GoogleCloudIdentitytoolkitV1DeleteAccountResponse
497
+ include Google::Apis::Core::Hashable
498
+
499
+ #
500
+ # Corresponds to the JSON property `kind`
501
+ # @return [String]
502
+ attr_accessor :kind
503
+
504
+ def initialize(**args)
505
+ update!(**args)
506
+ end
507
+
508
+ # Update properties of this object
509
+ def update!(**args)
510
+ @kind = args[:kind] if args.key?(:kind)
511
+ end
512
+ end
513
+
514
+ # Response message for DownloadAccount.
515
+ class GoogleCloudIdentitytoolkitV1DownloadAccountResponse
516
+ include Google::Apis::Core::Hashable
517
+
518
+ #
519
+ # Corresponds to the JSON property `kind`
520
+ # @return [String]
521
+ attr_accessor :kind
522
+
523
+ # If there are more accounts to be downloaded, a token that can be passed back
524
+ # to DownloadAccount to get more accounts. Otherwise, this is blank.
525
+ # Corresponds to the JSON property `nextPageToken`
526
+ # @return [String]
527
+ attr_accessor :next_page_token
528
+
529
+ # All accounts belonging to the project/tenant limited by max_results in the
530
+ # request.
531
+ # Corresponds to the JSON property `users`
532
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1UserInfo>]
533
+ attr_accessor :users
534
+
535
+ def initialize(**args)
536
+ update!(**args)
537
+ end
538
+
539
+ # Update properties of this object
540
+ def update!(**args)
541
+ @kind = args[:kind] if args.key?(:kind)
542
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
543
+ @users = args[:users] if args.key?(:users)
544
+ end
545
+ end
546
+
547
+ # Email template
548
+ class GoogleCloudIdentitytoolkitV1EmailTemplate
549
+ include Google::Apis::Core::Hashable
550
+
551
+ # Email body
552
+ # Corresponds to the JSON property `body`
553
+ # @return [String]
554
+ attr_accessor :body
555
+
556
+ # Whether the body or subject of the email is customized.
557
+ # Corresponds to the JSON property `customized`
558
+ # @return [Boolean]
559
+ attr_accessor :customized
560
+ alias_method :customized?, :customized
561
+
562
+ # Whether the template is disabled. If true, a default template will be used.
563
+ # Corresponds to the JSON property `disabled`
564
+ # @return [Boolean]
565
+ attr_accessor :disabled
566
+ alias_method :disabled?, :disabled
567
+
568
+ # Email body format
569
+ # Corresponds to the JSON property `format`
570
+ # @return [String]
571
+ attr_accessor :format
572
+
573
+ # From address of the email
574
+ # Corresponds to the JSON property `from`
575
+ # @return [String]
576
+ attr_accessor :from
577
+
578
+ # From display name
579
+ # Corresponds to the JSON property `fromDisplayName`
580
+ # @return [String]
581
+ attr_accessor :from_display_name
582
+
583
+ # Local part of From address
584
+ # Corresponds to the JSON property `fromLocalPart`
585
+ # @return [String]
586
+ attr_accessor :from_local_part
587
+
588
+ # Value is in III language code format (e.g. "zh-CN", "es"). Both '-' and '_'
589
+ # separators are accepted.
590
+ # Corresponds to the JSON property `locale`
591
+ # @return [String]
592
+ attr_accessor :locale
593
+
594
+ # Reply-to address
595
+ # Corresponds to the JSON property `replyTo`
596
+ # @return [String]
597
+ attr_accessor :reply_to
598
+
599
+ # Subject of the email
600
+ # Corresponds to the JSON property `subject`
601
+ # @return [String]
602
+ attr_accessor :subject
603
+
604
+ def initialize(**args)
605
+ update!(**args)
606
+ end
607
+
608
+ # Update properties of this object
609
+ def update!(**args)
610
+ @body = args[:body] if args.key?(:body)
611
+ @customized = args[:customized] if args.key?(:customized)
612
+ @disabled = args[:disabled] if args.key?(:disabled)
613
+ @format = args[:format] if args.key?(:format)
614
+ @from = args[:from] if args.key?(:from)
615
+ @from_display_name = args[:from_display_name] if args.key?(:from_display_name)
616
+ @from_local_part = args[:from_local_part] if args.key?(:from_local_part)
617
+ @locale = args[:locale] if args.key?(:locale)
618
+ @reply_to = args[:reply_to] if args.key?(:reply_to)
619
+ @subject = args[:subject] if args.key?(:subject)
620
+ end
621
+ end
622
+
623
+ # Error information explaining why an account cannot be uploaded. batch upload.
624
+ class GoogleCloudIdentitytoolkitV1ErrorInfo
625
+ include Google::Apis::Core::Hashable
626
+
627
+ # The index of the item, range is [0, request.size - 1]
628
+ # Corresponds to the JSON property `index`
629
+ # @return [Fixnum]
630
+ attr_accessor :index
631
+
632
+ # Detailed error message
633
+ # Corresponds to the JSON property `message`
634
+ # @return [String]
635
+ attr_accessor :message
636
+
637
+ def initialize(**args)
638
+ update!(**args)
639
+ end
640
+
641
+ # Update properties of this object
642
+ def update!(**args)
643
+ @index = args[:index] if args.key?(:index)
644
+ @message = args[:message] if args.key?(:message)
645
+ end
646
+ end
647
+
648
+ # Federated user identifier at an Identity Provider.
649
+ class GoogleCloudIdentitytoolkitV1FederatedUserIdentifier
650
+ include Google::Apis::Core::Hashable
651
+
652
+ # The ID of supported identity providers. This should be a provider ID enabled
653
+ # for sign-in, which is either from the list of [default supported IdPs](https://
654
+ # cloud.google.com/identity-platform/docs/reference/rest/v2/defaultSupportedIdps/
655
+ # list), or of the format `oidc.*` or `saml.*`. Some examples are `google.com`, `
656
+ # facebook.com`, `oidc.testapp`, and `saml.testapp`.
657
+ # Corresponds to the JSON property `providerId`
658
+ # @return [String]
659
+ attr_accessor :provider_id
660
+
661
+ # The user ID of the account at the third-party Identity Provider specified by `
662
+ # provider_id`.
663
+ # Corresponds to the JSON property `rawId`
664
+ # @return [String]
665
+ attr_accessor :raw_id
666
+
667
+ def initialize(**args)
668
+ update!(**args)
669
+ end
670
+
671
+ # Update properties of this object
672
+ def update!(**args)
673
+ @provider_id = args[:provider_id] if args.key?(:provider_id)
674
+ @raw_id = args[:raw_id] if args.key?(:raw_id)
675
+ end
676
+ end
677
+
678
+ # Request message for GetAccountInfo.
679
+ class GoogleCloudIdentitytoolkitV1GetAccountInfoRequest
680
+ include Google::Apis::Core::Hashable
681
+
682
+ #
683
+ # Corresponds to the JSON property `delegatedProjectNumber`
684
+ # @return [Fixnum]
685
+ attr_accessor :delegated_project_number
686
+
687
+ # The email address of one or more accounts to fetch. The length of email should
688
+ # be less than 256 characters and in the format of `name@domain.tld`. The email
689
+ # should also match the [RFC 822](https://tools.ietf.org/html/rfc822) addr-spec
690
+ # production. Should only be specified by authenticated requests from a
691
+ # developer.
692
+ # Corresponds to the JSON property `email`
693
+ # @return [Array<String>]
694
+ attr_accessor :email
695
+
696
+ # The federated user identifier of one or more accounts to fetch. Should only be
697
+ # specified by authenticated requests bearing a Google OAuth 2.0 credential with
698
+ # proper [permissions](https://cloud.google.com/identity-platform/docs/access-
699
+ # control).
700
+ # Corresponds to the JSON property `federatedUserId`
701
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1FederatedUserIdentifier>]
702
+ attr_accessor :federated_user_id
703
+
704
+ # The Identity Platform ID token of the account to fetch. Require to be
705
+ # specified for requests from end users.
706
+ # Corresponds to the JSON property `idToken`
707
+ # @return [String]
708
+ attr_accessor :id_token
709
+
710
+ # The initial email of one or more accounts to fetch. The length of email should
711
+ # be less than 256 characters and in the format of `name@domain.tld`. The email
712
+ # should also match the [RFC 822](https://tools.ietf.org/html/rfc822) addr-spec
713
+ # production. Should only be specified by authenticated requests from a
714
+ # developer.
715
+ # Corresponds to the JSON property `initialEmail`
716
+ # @return [Array<String>]
717
+ attr_accessor :initial_email
718
+
719
+ # The ID of one or more accounts to fetch. Should only be specified by
720
+ # authenticated requests bearing a Google OAuth 2.0 credential with proper [
721
+ # permissions](https://cloud.google.com/identity-platform/docs/access-control).
722
+ # Corresponds to the JSON property `localId`
723
+ # @return [Array<String>]
724
+ attr_accessor :local_id
725
+
726
+ # The phone number of one or more accounts to fetch. Should only be specified by
727
+ # authenticated requests from a developer and should be in E.164 format, for
728
+ # example, +15555555555.
729
+ # Corresponds to the JSON property `phoneNumber`
730
+ # @return [Array<String>]
731
+ attr_accessor :phone_number
732
+
733
+ # The ID of the Google Cloud project that the account or the Identity Platform
734
+ # tenant specified by `tenant_id` belongs to. Should only be specified by
735
+ # authenticated requests bearing a Google OAuth 2.0 credential with proper [
736
+ # permissions](https://cloud.google.com/identity-platform/docs/access-control).
737
+ # Corresponds to the JSON property `targetProjectId`
738
+ # @return [String]
739
+ attr_accessor :target_project_id
740
+
741
+ # The ID of the tenant that the account belongs to. Should only be specified by
742
+ # authenticated requests from a developer.
743
+ # Corresponds to the JSON property `tenantId`
744
+ # @return [String]
745
+ attr_accessor :tenant_id
746
+
747
+ def initialize(**args)
748
+ update!(**args)
749
+ end
750
+
751
+ # Update properties of this object
752
+ def update!(**args)
753
+ @delegated_project_number = args[:delegated_project_number] if args.key?(:delegated_project_number)
754
+ @email = args[:email] if args.key?(:email)
755
+ @federated_user_id = args[:federated_user_id] if args.key?(:federated_user_id)
756
+ @id_token = args[:id_token] if args.key?(:id_token)
757
+ @initial_email = args[:initial_email] if args.key?(:initial_email)
758
+ @local_id = args[:local_id] if args.key?(:local_id)
759
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
760
+ @target_project_id = args[:target_project_id] if args.key?(:target_project_id)
761
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
762
+ end
763
+ end
764
+
765
+ # Response message for GetAccountInfo.
766
+ class GoogleCloudIdentitytoolkitV1GetAccountInfoResponse
767
+ include Google::Apis::Core::Hashable
768
+
769
+ #
770
+ # Corresponds to the JSON property `kind`
771
+ # @return [String]
772
+ attr_accessor :kind
773
+
774
+ # The information of specific user account(s) matching the parameters in the
775
+ # request.
776
+ # Corresponds to the JSON property `users`
777
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1UserInfo>]
778
+ attr_accessor :users
779
+
780
+ def initialize(**args)
781
+ update!(**args)
782
+ end
783
+
784
+ # Update properties of this object
785
+ def update!(**args)
786
+ @kind = args[:kind] if args.key?(:kind)
787
+ @users = args[:users] if args.key?(:users)
788
+ end
789
+ end
790
+
791
+ # Request message for GetOobCode.
792
+ class GoogleCloudIdentitytoolkitV1GetOobCodeRequest
793
+ include Google::Apis::Core::Hashable
794
+
795
+ # If an associated android app can handle the OOB code, whether or not to
796
+ # install the android app on the device where the link is opened if the app is
797
+ # not already installed.
798
+ # Corresponds to the JSON property `androidInstallApp`
799
+ # @return [Boolean]
800
+ attr_accessor :android_install_app
801
+ alias_method :android_install_app?, :android_install_app
802
+
803
+ # If an associated android app can handle the OOB code, the minimum version of
804
+ # the app. If the version on the device is lower than this version then the user
805
+ # is taken to Google Play Store to upgrade the app.
806
+ # Corresponds to the JSON property `androidMinimumVersion`
807
+ # @return [String]
808
+ attr_accessor :android_minimum_version
809
+
810
+ # If an associated android app can handle the OOB code, the Android package name
811
+ # of the android app that will handle the callback when this OOB code is used.
812
+ # This will allow the correct app to open if it is already installed, or allow
813
+ # Google Play Store to open to the correct app if it is not yet installed.
814
+ # Corresponds to the JSON property `androidPackageName`
815
+ # @return [String]
816
+ attr_accessor :android_package_name
817
+
818
+ # When set to true, the OOB code link will be be sent as a Universal Link or an
819
+ # Android App Link and will be opened by the corresponding app if installed. If
820
+ # not set, or set to false, the OOB code will be sent to the web widget first
821
+ # and then on continue will redirect to the app if installed.
822
+ # Corresponds to the JSON property `canHandleCodeInApp`
823
+ # @return [Boolean]
824
+ attr_accessor :can_handle_code_in_app
825
+ alias_method :can_handle_code_in_app?, :can_handle_code_in_app
826
+
827
+ # For a PASSWORD_RESET request, a reCaptcha response is required when the system
828
+ # detects possible abuse activity. In those cases, this is the response from the
829
+ # reCaptcha challenge used to verify the caller.
830
+ # Corresponds to the JSON property `captchaResp`
831
+ # @return [String]
832
+ attr_accessor :captcha_resp
833
+
834
+ #
835
+ # Corresponds to the JSON property `challenge`
836
+ # @return [String]
837
+ attr_accessor :challenge
838
+
839
+ # The Url to continue after user clicks the link sent in email. This is the url
840
+ # that will allow the web widget to handle the OOB code.
841
+ # Corresponds to the JSON property `continueUrl`
842
+ # @return [String]
843
+ attr_accessor :continue_url
844
+
845
+ # In order to ensure that the url used can be easily opened up in iOS or android,
846
+ # we create a [Firebase Dynamic Link](https://firebase.google.com/docs/dynamic-
847
+ # links). Most Identity Platform projects will only have one Dynamic Link domain
848
+ # enabled, and can leave this field blank. This field contains a specified
849
+ # Dynamic Link domain for projects that have multiple enabled.
850
+ # Corresponds to the JSON property `dynamicLinkDomain`
851
+ # @return [String]
852
+ attr_accessor :dynamic_link_domain
853
+
854
+ # The account's email address to send the OOB code to, and generally the email
855
+ # address of the account that needs to be updated. Required for PASSWORD_RESET,
856
+ # EMAIL_SIGNIN, and VERIFY_EMAIL. Only required for VERIFY_AND_CHANGE_EMAIL
857
+ # requests when return_oob_link is set to true. In this case, it is the original
858
+ # email of the user.
859
+ # Corresponds to the JSON property `email`
860
+ # @return [String]
861
+ attr_accessor :email
862
+
863
+ # If an associated iOS app can handle the OOB code, the App Store id of this app.
864
+ # This will allow App Store to open to the correct app if the app is not yet
865
+ # installed.
866
+ # Corresponds to the JSON property `iOSAppStoreId`
867
+ # @return [String]
868
+ attr_accessor :i_os_app_store_id
869
+
870
+ # If an associated iOS app can handle the OOB code, the iOS bundle id of this
871
+ # app. This will allow the correct app to open if it is already installed.
872
+ # Corresponds to the JSON property `iOSBundleId`
873
+ # @return [String]
874
+ attr_accessor :i_os_bundle_id
875
+
876
+ # An ID token for the account. It is required for VERIFY_AND_CHANGE_EMAIL and
877
+ # VERIFY_EMAIL requests unless return_oob_link is set to true.
878
+ # Corresponds to the JSON property `idToken`
879
+ # @return [String]
880
+ attr_accessor :id_token
881
+
882
+ # The email address the account is being updated to. Required only for
883
+ # VERIFY_AND_CHANGE_EMAIL requests.
884
+ # Corresponds to the JSON property `newEmail`
885
+ # @return [String]
886
+ attr_accessor :new_email
887
+
888
+ # Required. The type of out-of-band (OOB) code to send. Depending on this value,
889
+ # other fields in this request will be required and/or have different meanings.
890
+ # There are 4 different OOB codes that can be sent: * PASSWORD_RESET *
891
+ # EMAIL_SIGNIN * VERIFY_EMAIL * VERIFY_AND_CHANGE_EMAIL
892
+ # Corresponds to the JSON property `requestType`
893
+ # @return [String]
894
+ attr_accessor :request_type
895
+
896
+ # Whether the confirmation link containing the OOB code should be returned in
897
+ # the response (no email is sent). Used when a developer wants to construct the
898
+ # email template and send it on their own. By default this is false; to specify
899
+ # this field, and to set it to true, it requires a Google OAuth 2.0 credential
900
+ # with proper [permissions](https://cloud.google.com/identity-platform/docs/
901
+ # access-control)
902
+ # Corresponds to the JSON property `returnOobLink`
903
+ # @return [Boolean]
904
+ attr_accessor :return_oob_link
905
+ alias_method :return_oob_link?, :return_oob_link
906
+
907
+ # The Project ID of the Identity Platform project which the account belongs to.
908
+ # To specify this field, it requires a Google OAuth 2.0 credential with proper [
909
+ # permissions](https://cloud.google.com/identity-platform/docs/access-control).
910
+ # Corresponds to the JSON property `targetProjectId`
911
+ # @return [String]
912
+ attr_accessor :target_project_id
913
+
914
+ # The tenant ID of the Identity Platform tenant the account belongs to.
915
+ # Corresponds to the JSON property `tenantId`
916
+ # @return [String]
917
+ attr_accessor :tenant_id
918
+
919
+ # The IP address of the caller. Required only for PASSWORD_RESET requests.
920
+ # Corresponds to the JSON property `userIp`
921
+ # @return [String]
922
+ attr_accessor :user_ip
923
+
924
+ def initialize(**args)
925
+ update!(**args)
926
+ end
927
+
928
+ # Update properties of this object
929
+ def update!(**args)
930
+ @android_install_app = args[:android_install_app] if args.key?(:android_install_app)
931
+ @android_minimum_version = args[:android_minimum_version] if args.key?(:android_minimum_version)
932
+ @android_package_name = args[:android_package_name] if args.key?(:android_package_name)
933
+ @can_handle_code_in_app = args[:can_handle_code_in_app] if args.key?(:can_handle_code_in_app)
934
+ @captcha_resp = args[:captcha_resp] if args.key?(:captcha_resp)
935
+ @challenge = args[:challenge] if args.key?(:challenge)
936
+ @continue_url = args[:continue_url] if args.key?(:continue_url)
937
+ @dynamic_link_domain = args[:dynamic_link_domain] if args.key?(:dynamic_link_domain)
938
+ @email = args[:email] if args.key?(:email)
939
+ @i_os_app_store_id = args[:i_os_app_store_id] if args.key?(:i_os_app_store_id)
940
+ @i_os_bundle_id = args[:i_os_bundle_id] if args.key?(:i_os_bundle_id)
941
+ @id_token = args[:id_token] if args.key?(:id_token)
942
+ @new_email = args[:new_email] if args.key?(:new_email)
943
+ @request_type = args[:request_type] if args.key?(:request_type)
944
+ @return_oob_link = args[:return_oob_link] if args.key?(:return_oob_link)
945
+ @target_project_id = args[:target_project_id] if args.key?(:target_project_id)
946
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
947
+ @user_ip = args[:user_ip] if args.key?(:user_ip)
948
+ end
949
+ end
950
+
951
+ # Response message for GetOobCode.
952
+ class GoogleCloudIdentitytoolkitV1GetOobCodeResponse
953
+ include Google::Apis::Core::Hashable
954
+
955
+ # If return_oob_link is false in the request, the email address the verification
956
+ # was sent to.
957
+ # Corresponds to the JSON property `email`
958
+ # @return [String]
959
+ attr_accessor :email
960
+
961
+ #
962
+ # Corresponds to the JSON property `kind`
963
+ # @return [String]
964
+ attr_accessor :kind
965
+
966
+ # If return_oob_link is true in the request, the OOB code to send.
967
+ # Corresponds to the JSON property `oobCode`
968
+ # @return [String]
969
+ attr_accessor :oob_code
970
+
971
+ # If return_oob_link is true in the request, the OOB link to be sent to the user.
972
+ # This returns the constructed link including [Firebase Dynamic Link](https://
973
+ # firebase.google.com/docs/dynamic-links) related parameters.
974
+ # Corresponds to the JSON property `oobLink`
975
+ # @return [String]
976
+ attr_accessor :oob_link
977
+
978
+ def initialize(**args)
979
+ update!(**args)
980
+ end
981
+
982
+ # Update properties of this object
983
+ def update!(**args)
984
+ @email = args[:email] if args.key?(:email)
985
+ @kind = args[:kind] if args.key?(:kind)
986
+ @oob_code = args[:oob_code] if args.key?(:oob_code)
987
+ @oob_link = args[:oob_link] if args.key?(:oob_link)
988
+ end
989
+ end
990
+
991
+ # Response message for GetProjectConfig.
992
+ class GoogleCloudIdentitytoolkitV1GetProjectConfigResponse
993
+ include Google::Apis::Core::Hashable
994
+
995
+ # Whether to allow password account sign up. This field is only returned for
996
+ # authenticated calls from a developer.
997
+ # Corresponds to the JSON property `allowPasswordUser`
998
+ # @return [Boolean]
999
+ attr_accessor :allow_password_user
1000
+ alias_method :allow_password_user?, :allow_password_user
1001
+
1002
+ # Google Cloud API key. This field is only returned for authenticated calls from
1003
+ # a developer.
1004
+ # Corresponds to the JSON property `apiKey`
1005
+ # @return [String]
1006
+ attr_accessor :api_key
1007
+
1008
+ # Authorized domains for widget redirect.
1009
+ # Corresponds to the JSON property `authorizedDomains`
1010
+ # @return [Array<String>]
1011
+ attr_accessor :authorized_domains
1012
+
1013
+ # Email template
1014
+ # Corresponds to the JSON property `changeEmailTemplate`
1015
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1EmailTemplate]
1016
+ attr_accessor :change_email_template
1017
+
1018
+ # The Firebase Dynamic Links domain used to construct links for redirects to
1019
+ # native apps.
1020
+ # Corresponds to the JSON property `dynamicLinksDomain`
1021
+ # @return [String]
1022
+ attr_accessor :dynamic_links_domain
1023
+
1024
+ # Whether anonymous user is enabled. This field is only returned for
1025
+ # authenticated calls from a developer.
1026
+ # Corresponds to the JSON property `enableAnonymousUser`
1027
+ # @return [Boolean]
1028
+ attr_accessor :enable_anonymous_user
1029
+ alias_method :enable_anonymous_user?, :enable_anonymous_user
1030
+
1031
+ # OAuth2 provider config. This field is only returned for authenticated calls
1032
+ # from a developer.
1033
+ # Corresponds to the JSON property `idpConfig`
1034
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1IdpConfig>]
1035
+ attr_accessor :idp_config
1036
+
1037
+ # Email template
1038
+ # Corresponds to the JSON property `legacyResetPasswordTemplate`
1039
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1EmailTemplate]
1040
+ attr_accessor :legacy_reset_password_template
1041
+
1042
+ # The project id of the retrieved configuration.
1043
+ # Corresponds to the JSON property `projectId`
1044
+ # @return [String]
1045
+ attr_accessor :project_id
1046
+
1047
+ # Email template
1048
+ # Corresponds to the JSON property `resetPasswordTemplate`
1049
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1EmailTemplate]
1050
+ attr_accessor :reset_password_template
1051
+
1052
+ # Email template
1053
+ # Corresponds to the JSON property `revertSecondFactorAdditionTemplate`
1054
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1EmailTemplate]
1055
+ attr_accessor :revert_second_factor_addition_template
1056
+
1057
+ # Whether to use email sending. This field is only returned for authenticated
1058
+ # calls from a developer.
1059
+ # Corresponds to the JSON property `useEmailSending`
1060
+ # @return [Boolean]
1061
+ attr_accessor :use_email_sending
1062
+ alias_method :use_email_sending?, :use_email_sending
1063
+
1064
+ # Email template
1065
+ # Corresponds to the JSON property `verifyEmailTemplate`
1066
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1EmailTemplate]
1067
+ attr_accessor :verify_email_template
1068
+
1069
+ def initialize(**args)
1070
+ update!(**args)
1071
+ end
1072
+
1073
+ # Update properties of this object
1074
+ def update!(**args)
1075
+ @allow_password_user = args[:allow_password_user] if args.key?(:allow_password_user)
1076
+ @api_key = args[:api_key] if args.key?(:api_key)
1077
+ @authorized_domains = args[:authorized_domains] if args.key?(:authorized_domains)
1078
+ @change_email_template = args[:change_email_template] if args.key?(:change_email_template)
1079
+ @dynamic_links_domain = args[:dynamic_links_domain] if args.key?(:dynamic_links_domain)
1080
+ @enable_anonymous_user = args[:enable_anonymous_user] if args.key?(:enable_anonymous_user)
1081
+ @idp_config = args[:idp_config] if args.key?(:idp_config)
1082
+ @legacy_reset_password_template = args[:legacy_reset_password_template] if args.key?(:legacy_reset_password_template)
1083
+ @project_id = args[:project_id] if args.key?(:project_id)
1084
+ @reset_password_template = args[:reset_password_template] if args.key?(:reset_password_template)
1085
+ @revert_second_factor_addition_template = args[:revert_second_factor_addition_template] if args.key?(:revert_second_factor_addition_template)
1086
+ @use_email_sending = args[:use_email_sending] if args.key?(:use_email_sending)
1087
+ @verify_email_template = args[:verify_email_template] if args.key?(:verify_email_template)
1088
+ end
1089
+ end
1090
+
1091
+ # Response message for GetRecaptchaParam.
1092
+ class GoogleCloudIdentitytoolkitV1GetRecaptchaParamResponse
1093
+ include Google::Apis::Core::Hashable
1094
+
1095
+ #
1096
+ # Corresponds to the JSON property `kind`
1097
+ # @return [String]
1098
+ attr_accessor :kind
1099
+
1100
+ # The reCAPTCHA v2 site key used to invoke the reCAPTCHA service. Always present.
1101
+ # Corresponds to the JSON property `recaptchaSiteKey`
1102
+ # @return [String]
1103
+ attr_accessor :recaptcha_site_key
1104
+
1105
+ #
1106
+ # Corresponds to the JSON property `recaptchaStoken`
1107
+ # @return [String]
1108
+ attr_accessor :recaptcha_stoken
1109
+
1110
+ def initialize(**args)
1111
+ update!(**args)
1112
+ end
1113
+
1114
+ # Update properties of this object
1115
+ def update!(**args)
1116
+ @kind = args[:kind] if args.key?(:kind)
1117
+ @recaptcha_site_key = args[:recaptcha_site_key] if args.key?(:recaptcha_site_key)
1118
+ @recaptcha_stoken = args[:recaptcha_stoken] if args.key?(:recaptcha_stoken)
1119
+ end
1120
+ end
1121
+
1122
+ # Response message for GetSessionCookiePublicKeys.
1123
+ class GoogleCloudIdentitytoolkitV1GetSessionCookiePublicKeysResponse
1124
+ include Google::Apis::Core::Hashable
1125
+
1126
+ # Public keys of the session cookie signer, formatted as [JSON Web Keys (JWK)](
1127
+ # https://tools.ietf.org/html/rfc7517).
1128
+ # Corresponds to the JSON property `keys`
1129
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1OpenIdConnectKey>]
1130
+ attr_accessor :keys
1131
+
1132
+ def initialize(**args)
1133
+ update!(**args)
1134
+ end
1135
+
1136
+ # Update properties of this object
1137
+ def update!(**args)
1138
+ @keys = args[:keys] if args.key?(:keys)
1139
+ end
1140
+ end
1141
+
1142
+ # Config of an identity provider.
1143
+ class GoogleCloudIdentitytoolkitV1IdpConfig
1144
+ include Google::Apis::Core::Hashable
1145
+
1146
+ # OAuth2 client ID.
1147
+ # Corresponds to the JSON property `clientId`
1148
+ # @return [String]
1149
+ attr_accessor :client_id
1150
+
1151
+ # True if allows the user to sign in with the provider.
1152
+ # Corresponds to the JSON property `enabled`
1153
+ # @return [Boolean]
1154
+ attr_accessor :enabled
1155
+ alias_method :enabled?, :enabled
1156
+
1157
+ # Percent of users who will be prompted/redirected federated login for this IdP
1158
+ # Corresponds to the JSON property `experimentPercent`
1159
+ # @return [Fixnum]
1160
+ attr_accessor :experiment_percent
1161
+
1162
+ # Name of the identity provider.
1163
+ # Corresponds to the JSON property `provider`
1164
+ # @return [String]
1165
+ attr_accessor :provider
1166
+
1167
+ # OAuth2 client secret.
1168
+ # Corresponds to the JSON property `secret`
1169
+ # @return [String]
1170
+ attr_accessor :secret
1171
+
1172
+ # Whitelisted client IDs for audience check.
1173
+ # Corresponds to the JSON property `whitelistedAudiences`
1174
+ # @return [Array<String>]
1175
+ attr_accessor :whitelisted_audiences
1176
+
1177
+ def initialize(**args)
1178
+ update!(**args)
1179
+ end
1180
+
1181
+ # Update properties of this object
1182
+ def update!(**args)
1183
+ @client_id = args[:client_id] if args.key?(:client_id)
1184
+ @enabled = args[:enabled] if args.key?(:enabled)
1185
+ @experiment_percent = args[:experiment_percent] if args.key?(:experiment_percent)
1186
+ @provider = args[:provider] if args.key?(:provider)
1187
+ @secret = args[:secret] if args.key?(:secret)
1188
+ @whitelisted_audiences = args[:whitelisted_audiences] if args.key?(:whitelisted_audiences)
1189
+ end
1190
+ end
1191
+
1192
+ # Request message for IssueSamlResponse.
1193
+ class GoogleCloudIdentitytoolkitV1IssueSamlResponseRequest
1194
+ include Google::Apis::Core::Hashable
1195
+
1196
+ # The Identity Platform ID token. It will be verified and then converted to a
1197
+ # new SAMLResponse.
1198
+ # Corresponds to the JSON property `idToken`
1199
+ # @return [String]
1200
+ attr_accessor :id_token
1201
+
1202
+ # Relying Party identifier, which is the audience of issued SAMLResponse.
1203
+ # Corresponds to the JSON property `rpId`
1204
+ # @return [String]
1205
+ attr_accessor :rp_id
1206
+
1207
+ # SAML app entity id specified in Google Admin Console for each app. If
1208
+ # developers want to redirect to a third-party app rather than a G Suite app,
1209
+ # they'll probably they need this. When it's used, we'll return a RelayState.
1210
+ # This includes a SAMLRequest, which can be used to trigger a SP-initiated SAML
1211
+ # flow to redirect to the real app.
1212
+ # Corresponds to the JSON property `samlAppEntityId`
1213
+ # @return [String]
1214
+ attr_accessor :saml_app_entity_id
1215
+
1216
+ def initialize(**args)
1217
+ update!(**args)
1218
+ end
1219
+
1220
+ # Update properties of this object
1221
+ def update!(**args)
1222
+ @id_token = args[:id_token] if args.key?(:id_token)
1223
+ @rp_id = args[:rp_id] if args.key?(:rp_id)
1224
+ @saml_app_entity_id = args[:saml_app_entity_id] if args.key?(:saml_app_entity_id)
1225
+ end
1226
+ end
1227
+
1228
+ # Response for IssueSamlResponse request.
1229
+ class GoogleCloudIdentitytoolkitV1IssueSamlResponseResponse
1230
+ include Google::Apis::Core::Hashable
1231
+
1232
+ # The ACS endpoint which consumes the returned SAMLResponse.
1233
+ # Corresponds to the JSON property `acsEndpoint`
1234
+ # @return [String]
1235
+ attr_accessor :acs_endpoint
1236
+
1237
+ # Email of the user.
1238
+ # Corresponds to the JSON property `email`
1239
+ # @return [String]
1240
+ attr_accessor :email
1241
+
1242
+ # First name of the user.
1243
+ # Corresponds to the JSON property `firstName`
1244
+ # @return [String]
1245
+ attr_accessor :first_name
1246
+
1247
+ # Whether the logged in user was created by this request.
1248
+ # Corresponds to the JSON property `isNewUser`
1249
+ # @return [Boolean]
1250
+ attr_accessor :is_new_user
1251
+ alias_method :is_new_user?, :is_new_user
1252
+
1253
+ # Last name of the user.
1254
+ # Corresponds to the JSON property `lastName`
1255
+ # @return [String]
1256
+ attr_accessor :last_name
1257
+
1258
+ # Generated RelayState.
1259
+ # Corresponds to the JSON property `relayState`
1260
+ # @return [String]
1261
+ attr_accessor :relay_state
1262
+
1263
+ # Signed SAMLResponse created for the Relying Party.
1264
+ # Corresponds to the JSON property `samlResponse`
1265
+ # @return [String]
1266
+ attr_accessor :saml_response
1267
+
1268
+ def initialize(**args)
1269
+ update!(**args)
1270
+ end
1271
+
1272
+ # Update properties of this object
1273
+ def update!(**args)
1274
+ @acs_endpoint = args[:acs_endpoint] if args.key?(:acs_endpoint)
1275
+ @email = args[:email] if args.key?(:email)
1276
+ @first_name = args[:first_name] if args.key?(:first_name)
1277
+ @is_new_user = args[:is_new_user] if args.key?(:is_new_user)
1278
+ @last_name = args[:last_name] if args.key?(:last_name)
1279
+ @relay_state = args[:relay_state] if args.key?(:relay_state)
1280
+ @saml_response = args[:saml_response] if args.key?(:saml_response)
1281
+ end
1282
+ end
1283
+
1284
+ # Information on which multi-factor authentication (MFA) providers are enabled
1285
+ # for an account.
1286
+ class GoogleCloudIdentitytoolkitV1MfaEnrollment
1287
+ include Google::Apis::Core::Hashable
1288
+
1289
+ # Display name for this mfa option e.g. "corp cell phone".
1290
+ # Corresponds to the JSON property `displayName`
1291
+ # @return [String]
1292
+ attr_accessor :display_name
1293
+
1294
+ # Timestamp when the account enrolled this second factor.
1295
+ # Corresponds to the JSON property `enrolledAt`
1296
+ # @return [String]
1297
+ attr_accessor :enrolled_at
1298
+
1299
+ # ID of this MFA option.
1300
+ # Corresponds to the JSON property `mfaEnrollmentId`
1301
+ # @return [String]
1302
+ attr_accessor :mfa_enrollment_id
1303
+
1304
+ # Normally this will show the phone number associated with this enrollment. In
1305
+ # some situations, such as after a first factor sign in, it will only show the
1306
+ # obfuscated version of the associated phone number.
1307
+ # Corresponds to the JSON property `phoneInfo`
1308
+ # @return [String]
1309
+ attr_accessor :phone_info
1310
+
1311
+ # Output only. Unobfuscated phone_info.
1312
+ # Corresponds to the JSON property `unobfuscatedPhoneInfo`
1313
+ # @return [String]
1314
+ attr_accessor :unobfuscated_phone_info
1315
+
1316
+ def initialize(**args)
1317
+ update!(**args)
1318
+ end
1319
+
1320
+ # Update properties of this object
1321
+ def update!(**args)
1322
+ @display_name = args[:display_name] if args.key?(:display_name)
1323
+ @enrolled_at = args[:enrolled_at] if args.key?(:enrolled_at)
1324
+ @mfa_enrollment_id = args[:mfa_enrollment_id] if args.key?(:mfa_enrollment_id)
1325
+ @phone_info = args[:phone_info] if args.key?(:phone_info)
1326
+ @unobfuscated_phone_info = args[:unobfuscated_phone_info] if args.key?(:unobfuscated_phone_info)
1327
+ end
1328
+ end
1329
+
1330
+ #
1331
+ class GoogleCloudIdentitytoolkitV1MfaFactor
1332
+ include Google::Apis::Core::Hashable
1333
+
1334
+ # Display name for this mfa option e.g. "corp cell phone".
1335
+ # Corresponds to the JSON property `displayName`
1336
+ # @return [String]
1337
+ attr_accessor :display_name
1338
+
1339
+ # Phone number to receive OTP for MFA.
1340
+ # Corresponds to the JSON property `phoneInfo`
1341
+ # @return [String]
1342
+ attr_accessor :phone_info
1343
+
1344
+ def initialize(**args)
1345
+ update!(**args)
1346
+ end
1347
+
1348
+ # Update properties of this object
1349
+ def update!(**args)
1350
+ @display_name = args[:display_name] if args.key?(:display_name)
1351
+ @phone_info = args[:phone_info] if args.key?(:phone_info)
1352
+ end
1353
+ end
1354
+
1355
+ # Multi-factor authentication related information.
1356
+ class GoogleCloudIdentitytoolkitV1MfaInfo
1357
+ include Google::Apis::Core::Hashable
1358
+
1359
+ # The second factors the user has enrolled.
1360
+ # Corresponds to the JSON property `enrollments`
1361
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaEnrollment>]
1362
+ attr_accessor :enrollments
1363
+
1364
+ def initialize(**args)
1365
+ update!(**args)
1366
+ end
1367
+
1368
+ # Update properties of this object
1369
+ def update!(**args)
1370
+ @enrollments = args[:enrollments] if args.key?(:enrollments)
1371
+ end
1372
+ end
1373
+
1374
+ # Represents a public key of the session cookie signer, formatted as a [JSON Web
1375
+ # Key (JWK)](https://tools.ietf.org/html/rfc7517).
1376
+ class GoogleCloudIdentitytoolkitV1OpenIdConnectKey
1377
+ include Google::Apis::Core::Hashable
1378
+
1379
+ # Signature algorithm.
1380
+ # Corresponds to the JSON property `alg`
1381
+ # @return [String]
1382
+ attr_accessor :alg
1383
+
1384
+ # Exponent for the RSA public key, it is represented as the base64url encoding
1385
+ # of the value's big endian representation.
1386
+ # Corresponds to the JSON property `e`
1387
+ # @return [String]
1388
+ attr_accessor :e
1389
+
1390
+ # Unique string to identify this key.
1391
+ # Corresponds to the JSON property `kid`
1392
+ # @return [String]
1393
+ attr_accessor :kid
1394
+
1395
+ # Key type.
1396
+ # Corresponds to the JSON property `kty`
1397
+ # @return [String]
1398
+ attr_accessor :kty
1399
+
1400
+ # Modulus for the RSA public key, it is represented as the base64url encoding of
1401
+ # the value's big endian representation.
1402
+ # Corresponds to the JSON property `n`
1403
+ # @return [String]
1404
+ attr_accessor :n
1405
+
1406
+ # Key use.
1407
+ # Corresponds to the JSON property `use`
1408
+ # @return [String]
1409
+ attr_accessor :use
1410
+
1411
+ def initialize(**args)
1412
+ update!(**args)
1413
+ end
1414
+
1415
+ # Update properties of this object
1416
+ def update!(**args)
1417
+ @alg = args[:alg] if args.key?(:alg)
1418
+ @e = args[:e] if args.key?(:e)
1419
+ @kid = args[:kid] if args.key?(:kid)
1420
+ @kty = args[:kty] if args.key?(:kty)
1421
+ @n = args[:n] if args.key?(:n)
1422
+ @use = args[:use] if args.key?(:use)
1423
+ end
1424
+ end
1425
+
1426
+ # Information about the user as provided by various Identity Providers.
1427
+ class GoogleCloudIdentitytoolkitV1ProviderUserInfo
1428
+ include Google::Apis::Core::Hashable
1429
+
1430
+ # The user's display name at the Identity Provider.
1431
+ # Corresponds to the JSON property `displayName`
1432
+ # @return [String]
1433
+ attr_accessor :display_name
1434
+
1435
+ # The user's email address at the Identity Provider.
1436
+ # Corresponds to the JSON property `email`
1437
+ # @return [String]
1438
+ attr_accessor :email
1439
+
1440
+ # The user's identifier at the Identity Provider.
1441
+ # Corresponds to the JSON property `federatedId`
1442
+ # @return [String]
1443
+ attr_accessor :federated_id
1444
+
1445
+ # The user's phone number at the Identity Provider.
1446
+ # Corresponds to the JSON property `phoneNumber`
1447
+ # @return [String]
1448
+ attr_accessor :phone_number
1449
+
1450
+ # The user's profile photo URL at the Identity Provider.
1451
+ # Corresponds to the JSON property `photoUrl`
1452
+ # @return [String]
1453
+ attr_accessor :photo_url
1454
+
1455
+ # The ID of the Identity Provider.
1456
+ # Corresponds to the JSON property `providerId`
1457
+ # @return [String]
1458
+ attr_accessor :provider_id
1459
+
1460
+ # The user's raw identifier directly returned from Identity Provider.
1461
+ # Corresponds to the JSON property `rawId`
1462
+ # @return [String]
1463
+ attr_accessor :raw_id
1464
+
1465
+ # The user's screen_name at Twitter or login name at GitHub.
1466
+ # Corresponds to the JSON property `screenName`
1467
+ # @return [String]
1468
+ attr_accessor :screen_name
1469
+
1470
+ def initialize(**args)
1471
+ update!(**args)
1472
+ end
1473
+
1474
+ # Update properties of this object
1475
+ def update!(**args)
1476
+ @display_name = args[:display_name] if args.key?(:display_name)
1477
+ @email = args[:email] if args.key?(:email)
1478
+ @federated_id = args[:federated_id] if args.key?(:federated_id)
1479
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
1480
+ @photo_url = args[:photo_url] if args.key?(:photo_url)
1481
+ @provider_id = args[:provider_id] if args.key?(:provider_id)
1482
+ @raw_id = args[:raw_id] if args.key?(:raw_id)
1483
+ @screen_name = args[:screen_name] if args.key?(:screen_name)
1484
+ end
1485
+ end
1486
+
1487
+ # Request message for QueryUserInfo.
1488
+ class GoogleCloudIdentitytoolkitV1QueryUserInfoRequest
1489
+ include Google::Apis::Core::Hashable
1490
+
1491
+ # Query conditions used to filter results. If more than one is passed, only the
1492
+ # first SqlExpression is evaluated.
1493
+ # Corresponds to the JSON property `expression`
1494
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1SqlExpression>]
1495
+ attr_accessor :expression
1496
+
1497
+ # The maximum number of accounts to return with an upper limit of __500__.
1498
+ # Defaults to _500_. Only valid when `return_user_info` is set to `true`.
1499
+ # Corresponds to the JSON property `limit`
1500
+ # @return [Fixnum]
1501
+ attr_accessor :limit
1502
+
1503
+ # The number of accounts to skip from the beginning of matching records. Only
1504
+ # valid when `return_user_info` is set to `true`.
1505
+ # Corresponds to the JSON property `offset`
1506
+ # @return [Fixnum]
1507
+ attr_accessor :offset
1508
+
1509
+ # The order for sorting query result. Defaults to __ascending__ order. Only
1510
+ # valid when `return_user_info` is set to `true`.
1511
+ # Corresponds to the JSON property `order`
1512
+ # @return [String]
1513
+ attr_accessor :order
1514
+
1515
+ # If `true`, this request will return the accounts matching the query. If `false`
1516
+ # , only the __count__ of accounts matching the query will be returned. Defaults
1517
+ # to `true`.
1518
+ # Corresponds to the JSON property `returnUserInfo`
1519
+ # @return [Boolean]
1520
+ attr_accessor :return_user_info
1521
+ alias_method :return_user_info?, :return_user_info
1522
+
1523
+ # The field to use for sorting user accounts. Defaults to `USER_ID`. Note: when `
1524
+ # phone_number` is specified in `expression`, the result ignores the sorting.
1525
+ # Only valid when `return_user_info` is set to `true`.
1526
+ # Corresponds to the JSON property `sortBy`
1527
+ # @return [String]
1528
+ attr_accessor :sort_by
1529
+
1530
+ # The ID of the tenant to which the result is scoped.
1531
+ # Corresponds to the JSON property `tenantId`
1532
+ # @return [String]
1533
+ attr_accessor :tenant_id
1534
+
1535
+ def initialize(**args)
1536
+ update!(**args)
1537
+ end
1538
+
1539
+ # Update properties of this object
1540
+ def update!(**args)
1541
+ @expression = args[:expression] if args.key?(:expression)
1542
+ @limit = args[:limit] if args.key?(:limit)
1543
+ @offset = args[:offset] if args.key?(:offset)
1544
+ @order = args[:order] if args.key?(:order)
1545
+ @return_user_info = args[:return_user_info] if args.key?(:return_user_info)
1546
+ @sort_by = args[:sort_by] if args.key?(:sort_by)
1547
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
1548
+ end
1549
+ end
1550
+
1551
+ # Response message for QueryUserInfo.
1552
+ class GoogleCloudIdentitytoolkitV1QueryUserInfoResponse
1553
+ include Google::Apis::Core::Hashable
1554
+
1555
+ # If `return_user_info` in the request is true, this is the number of returned
1556
+ # accounts in this message. Otherwise, this is the total number of accounts
1557
+ # matching the query.
1558
+ # Corresponds to the JSON property `recordsCount`
1559
+ # @return [Fixnum]
1560
+ attr_accessor :records_count
1561
+
1562
+ # If `return_user_info` in the request is true, this is the accounts matching
1563
+ # the query.
1564
+ # Corresponds to the JSON property `userInfo`
1565
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1UserInfo>]
1566
+ attr_accessor :user_info
1567
+
1568
+ def initialize(**args)
1569
+ update!(**args)
1570
+ end
1571
+
1572
+ # Update properties of this object
1573
+ def update!(**args)
1574
+ @records_count = args[:records_count] if args.key?(:records_count)
1575
+ @user_info = args[:user_info] if args.key?(:user_info)
1576
+ end
1577
+ end
1578
+
1579
+ # Request message for ResetPassword.
1580
+ class GoogleCloudIdentitytoolkitV1ResetPasswordRequest
1581
+ include Google::Apis::Core::Hashable
1582
+
1583
+ # The email of the account to be modified. Specify this and the old password in
1584
+ # order to change an account's password without using an out-of-band code.
1585
+ # Corresponds to the JSON property `email`
1586
+ # @return [String]
1587
+ attr_accessor :email
1588
+
1589
+ # The new password to be set for this account. Specifying this field will result
1590
+ # in a change to the account and consume the out-of-band code if one was
1591
+ # specified and it was of type PASSWORD_RESET.
1592
+ # Corresponds to the JSON property `newPassword`
1593
+ # @return [String]
1594
+ attr_accessor :new_password
1595
+
1596
+ # The current password of the account to be modified. Specify this and email to
1597
+ # change an account's password without using an out-of-band code.
1598
+ # Corresponds to the JSON property `oldPassword`
1599
+ # @return [String]
1600
+ attr_accessor :old_password
1601
+
1602
+ # An out-of-band (OOB) code generated by GetOobCode request. Specify only this
1603
+ # parameter (or only this parameter and a tenant ID) to get the out-of-band code'
1604
+ # s type in the response without mutating the account's state. Only a
1605
+ # PASSWORD_RESET out-of-band code can be consumed via this method.
1606
+ # Corresponds to the JSON property `oobCode`
1607
+ # @return [String]
1608
+ attr_accessor :oob_code
1609
+
1610
+ # The tenant ID of the Identity Platform tenant the account belongs to.
1611
+ # Corresponds to the JSON property `tenantId`
1612
+ # @return [String]
1613
+ attr_accessor :tenant_id
1614
+
1615
+ def initialize(**args)
1616
+ update!(**args)
1617
+ end
1618
+
1619
+ # Update properties of this object
1620
+ def update!(**args)
1621
+ @email = args[:email] if args.key?(:email)
1622
+ @new_password = args[:new_password] if args.key?(:new_password)
1623
+ @old_password = args[:old_password] if args.key?(:old_password)
1624
+ @oob_code = args[:oob_code] if args.key?(:oob_code)
1625
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
1626
+ end
1627
+ end
1628
+
1629
+ # Response message for ResetPassword.
1630
+ class GoogleCloudIdentitytoolkitV1ResetPasswordResponse
1631
+ include Google::Apis::Core::Hashable
1632
+
1633
+ # The email associated with the out-of-band code that was used.
1634
+ # Corresponds to the JSON property `email`
1635
+ # @return [String]
1636
+ attr_accessor :email
1637
+
1638
+ #
1639
+ # Corresponds to the JSON property `kind`
1640
+ # @return [String]
1641
+ attr_accessor :kind
1642
+
1643
+ # Information on which multi-factor authentication (MFA) providers are enabled
1644
+ # for an account.
1645
+ # Corresponds to the JSON property `mfaInfo`
1646
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaEnrollment]
1647
+ attr_accessor :mfa_info
1648
+
1649
+ #
1650
+ # Corresponds to the JSON property `newEmail`
1651
+ # @return [String]
1652
+ attr_accessor :new_email
1653
+
1654
+ #
1655
+ # Corresponds to the JSON property `requestType`
1656
+ # @return [String]
1657
+ attr_accessor :request_type
1658
+
1659
+ def initialize(**args)
1660
+ update!(**args)
1661
+ end
1662
+
1663
+ # Update properties of this object
1664
+ def update!(**args)
1665
+ @email = args[:email] if args.key?(:email)
1666
+ @kind = args[:kind] if args.key?(:kind)
1667
+ @mfa_info = args[:mfa_info] if args.key?(:mfa_info)
1668
+ @new_email = args[:new_email] if args.key?(:new_email)
1669
+ @request_type = args[:request_type] if args.key?(:request_type)
1670
+ end
1671
+ end
1672
+
1673
+ # Request message for SendVerificationCode. At least one of (`ios_receipt` and `
1674
+ # ios_secret`), `recaptcha_token`, or `safety_net_token` must be specified to
1675
+ # verify the verification code is being sent on behalf of a real app and not an
1676
+ # emulator.
1677
+ class GoogleCloudIdentitytoolkitV1SendVerificationCodeRequest
1678
+ include Google::Apis::Core::Hashable
1679
+
1680
+ # The information required to auto-retrieve an SMS.
1681
+ # Corresponds to the JSON property `autoRetrievalInfo`
1682
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1AutoRetrievalInfo]
1683
+ attr_accessor :auto_retrieval_info
1684
+
1685
+ # Receipt of successful iOS app token validation. At least one of (`ios_receipt`
1686
+ # and `ios_secret`), `recaptcha_token`, or `safety_net_token` must be specified
1687
+ # to verify the verification code is being sent on behalf of a real app and not
1688
+ # an emulator. This should come from the response of verifyIosClient. If present,
1689
+ # the caller should also provide the `ios_secret`, as well as a bundle ID in
1690
+ # the `x-ios-bundle-identifier` header, which must match the bundle ID from the
1691
+ # verifyIosClient request.
1692
+ # Corresponds to the JSON property `iosReceipt`
1693
+ # @return [String]
1694
+ attr_accessor :ios_receipt
1695
+
1696
+ # Secret delivered to iOS app as a push notification. Should be passed with an `
1697
+ # ios_receipt` as well as the `x-ios-bundle-identifier` header.
1698
+ # Corresponds to the JSON property `iosSecret`
1699
+ # @return [String]
1700
+ attr_accessor :ios_secret
1701
+
1702
+ # The phone number to send the verification code to in E.164 format.
1703
+ # Corresponds to the JSON property `phoneNumber`
1704
+ # @return [String]
1705
+ attr_accessor :phone_number
1706
+
1707
+ # Recaptcha token for app verification. At least one of (`ios_receipt` and `
1708
+ # ios_secret`), `recaptcha_token`, or `safety_net_token` must be specified to
1709
+ # verify the verification code is being sent on behalf of a real app and not an
1710
+ # emulator. The recaptcha should be generated by calling getRecaptchaParams and
1711
+ # the recaptcha token will be generated on user completion of the recaptcha
1712
+ # challenge.
1713
+ # Corresponds to the JSON property `recaptchaToken`
1714
+ # @return [String]
1715
+ attr_accessor :recaptcha_token
1716
+
1717
+ # Android only. Used to assert application identity in place of a recaptcha
1718
+ # token. At least one of (`ios_receipt` and `ios_secret`), `recaptcha_token`, or
1719
+ # `safety_net_token` must be specified to verify the verification code is being
1720
+ # sent on behalf of a real app and not an emulator. A SafetyNet Token can be
1721
+ # generated via the [SafetyNet Android Attestation API](https://developer.
1722
+ # android.com/training/safetynet/attestation.html), with the Base64 encoding of
1723
+ # the `phone_number` field as the nonce.
1724
+ # Corresponds to the JSON property `safetyNetToken`
1725
+ # @return [String]
1726
+ attr_accessor :safety_net_token
1727
+
1728
+ # Tenant ID of the Identity Platform tenant the user is signing in to.
1729
+ # Corresponds to the JSON property `tenantId`
1730
+ # @return [String]
1731
+ attr_accessor :tenant_id
1732
+
1733
+ def initialize(**args)
1734
+ update!(**args)
1735
+ end
1736
+
1737
+ # Update properties of this object
1738
+ def update!(**args)
1739
+ @auto_retrieval_info = args[:auto_retrieval_info] if args.key?(:auto_retrieval_info)
1740
+ @ios_receipt = args[:ios_receipt] if args.key?(:ios_receipt)
1741
+ @ios_secret = args[:ios_secret] if args.key?(:ios_secret)
1742
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
1743
+ @recaptcha_token = args[:recaptcha_token] if args.key?(:recaptcha_token)
1744
+ @safety_net_token = args[:safety_net_token] if args.key?(:safety_net_token)
1745
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
1746
+ end
1747
+ end
1748
+
1749
+ # Response message for SendVerificationCode.
1750
+ class GoogleCloudIdentitytoolkitV1SendVerificationCodeResponse
1751
+ include Google::Apis::Core::Hashable
1752
+
1753
+ # Encrypted session information. This can be used in signInWithPhoneNumber to
1754
+ # authenticate the phone number.
1755
+ # Corresponds to the JSON property `sessionInfo`
1756
+ # @return [String]
1757
+ attr_accessor :session_info
1758
+
1759
+ def initialize(**args)
1760
+ update!(**args)
1761
+ end
1762
+
1763
+ # Update properties of this object
1764
+ def update!(**args)
1765
+ @session_info = args[:session_info] if args.key?(:session_info)
1766
+ end
1767
+ end
1768
+
1769
+ # Request message for SetAccountInfo.
1770
+ class GoogleCloudIdentitytoolkitV1SetAccountInfoRequest
1771
+ include Google::Apis::Core::Hashable
1772
+
1773
+ #
1774
+ # Corresponds to the JSON property `captchaChallenge`
1775
+ # @return [String]
1776
+ attr_accessor :captcha_challenge
1777
+
1778
+ # The response from reCaptcha challenge. This is required when the system
1779
+ # detects possible abuse activities.
1780
+ # Corresponds to the JSON property `captchaResponse`
1781
+ # @return [String]
1782
+ attr_accessor :captcha_response
1783
+
1784
+ # The timestamp in milliseconds when the account was created.
1785
+ # Corresponds to the JSON property `createdAt`
1786
+ # @return [Fixnum]
1787
+ attr_accessor :created_at
1788
+
1789
+ # JSON formatted custom attributes to be stored in the Identity Platform ID
1790
+ # token. Specifying this field requires a Google OAuth 2.0 credential with
1791
+ # proper [permissions] (https://cloud.google.com/identity-platform/docs/access-
1792
+ # control).
1793
+ # Corresponds to the JSON property `customAttributes`
1794
+ # @return [String]
1795
+ attr_accessor :custom_attributes
1796
+
1797
+ #
1798
+ # Corresponds to the JSON property `delegatedProjectNumber`
1799
+ # @return [Fixnum]
1800
+ attr_accessor :delegated_project_number
1801
+
1802
+ # The account's attributes to be deleted.
1803
+ # Corresponds to the JSON property `deleteAttribute`
1804
+ # @return [Array<String>]
1805
+ attr_accessor :delete_attribute
1806
+
1807
+ # The Identity Providers to unlink from the user's account.
1808
+ # Corresponds to the JSON property `deleteProvider`
1809
+ # @return [Array<String>]
1810
+ attr_accessor :delete_provider
1811
+
1812
+ # If true, marks the account as disabled, meaning the user will no longer be
1813
+ # able to sign-in.
1814
+ # Corresponds to the JSON property `disableUser`
1815
+ # @return [Boolean]
1816
+ attr_accessor :disable_user
1817
+ alias_method :disable_user?, :disable_user
1818
+
1819
+ # The user's new display name to be updated in the account's attributes. The
1820
+ # length of the display name must be less than or equal to 256 characters.
1821
+ # Corresponds to the JSON property `displayName`
1822
+ # @return [String]
1823
+ attr_accessor :display_name
1824
+
1825
+ # The user's new email to be updated in the account's attributes. The length of
1826
+ # email should be less than 256 characters and in the format of `name@domain.tld`
1827
+ # . The email should also match the [RFC 822](https://tools.ietf.org/html/rfc822)
1828
+ # addr-spec production.
1829
+ # Corresponds to the JSON property `email`
1830
+ # @return [String]
1831
+ attr_accessor :email
1832
+
1833
+ # Whether the user's email has been verified. Specifying this field requires a
1834
+ # Google OAuth 2.0 credential with proper [permissions] (https://cloud.google.
1835
+ # com/identity-platform/docs/access-control).
1836
+ # Corresponds to the JSON property `emailVerified`
1837
+ # @return [Boolean]
1838
+ attr_accessor :email_verified
1839
+ alias_method :email_verified?, :email_verified
1840
+
1841
+ # A valid Identity Platform ID token. Required when attempting to change user-
1842
+ # related information.
1843
+ # Corresponds to the JSON property `idToken`
1844
+ # @return [String]
1845
+ attr_accessor :id_token
1846
+
1847
+ #
1848
+ # Corresponds to the JSON property `instanceId`
1849
+ # @return [String]
1850
+ attr_accessor :instance_id
1851
+
1852
+ # The timestamp in milliseconds when the account last logged in.
1853
+ # Corresponds to the JSON property `lastLoginAt`
1854
+ # @return [Fixnum]
1855
+ attr_accessor :last_login_at
1856
+
1857
+ # Information about the user as provided by various Identity Providers.
1858
+ # Corresponds to the JSON property `linkProviderUserInfo`
1859
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1ProviderUserInfo]
1860
+ attr_accessor :link_provider_user_info
1861
+
1862
+ # The ID of the user. Specifying this field requires a Google OAuth 2.0
1863
+ # credential with proper [permissions] (https://cloud.google.com/identity-
1864
+ # platform/docs/access-control). For requests from end-users, an ID token should
1865
+ # be passed instead.
1866
+ # Corresponds to the JSON property `localId`
1867
+ # @return [String]
1868
+ attr_accessor :local_id
1869
+
1870
+ # Multi-factor authentication related information.
1871
+ # Corresponds to the JSON property `mfa`
1872
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaInfo]
1873
+ attr_accessor :mfa
1874
+
1875
+ # The out-of-band code to be applied on the user's account. The following out-of-
1876
+ # band code types are supported: * VERIFY_EMAIL * RECOVER_EMAIL *
1877
+ # REVERT_SECOND_FACTOR_ADDITION * VERIFY_AND_CHANGE_EMAIL
1878
+ # Corresponds to the JSON property `oobCode`
1879
+ # @return [String]
1880
+ attr_accessor :oob_code
1881
+
1882
+ # The user's new password to be updated in the account's attributes. The
1883
+ # password must be at least 6 characters long.
1884
+ # Corresponds to the JSON property `password`
1885
+ # @return [String]
1886
+ attr_accessor :password
1887
+
1888
+ # The phone number to be updated in the account's attributes.
1889
+ # Corresponds to the JSON property `phoneNumber`
1890
+ # @return [String]
1891
+ attr_accessor :phone_number
1892
+
1893
+ # The user's new photo URL for the account's profile photo to be updated in the
1894
+ # account's attributes. The length of the URL must be less than or equal to 2048
1895
+ # characters.
1896
+ # Corresponds to the JSON property `photoUrl`
1897
+ # @return [String]
1898
+ attr_accessor :photo_url
1899
+
1900
+ # The Identity Providers that the account should be associated with.
1901
+ # Corresponds to the JSON property `provider`
1902
+ # @return [Array<String>]
1903
+ attr_accessor :provider
1904
+
1905
+ # Whether or not to return an ID and refresh token. Should always be true.
1906
+ # Corresponds to the JSON property `returnSecureToken`
1907
+ # @return [Boolean]
1908
+ attr_accessor :return_secure_token
1909
+ alias_method :return_secure_token?, :return_secure_token
1910
+
1911
+ # The project ID for the project that the account belongs to. Specifying this
1912
+ # field requires Google OAuth 2.0 credential with proper [permissions] (https://
1913
+ # cloud.google.com/identity-platform/docs/access-control). Requests from end
1914
+ # users should pass an Identity Platform ID token instead.
1915
+ # Corresponds to the JSON property `targetProjectId`
1916
+ # @return [String]
1917
+ attr_accessor :target_project_id
1918
+
1919
+ # The tenant ID of the Identity Platform tenant that the account belongs to.
1920
+ # Requests from end users should pass an Identity Platform ID token rather than
1921
+ # setting this field.
1922
+ # Corresponds to the JSON property `tenantId`
1923
+ # @return [String]
1924
+ attr_accessor :tenant_id
1925
+
1926
+ # Whether the account should be restricted to only using federated login.
1927
+ # Corresponds to the JSON property `upgradeToFederatedLogin`
1928
+ # @return [Boolean]
1929
+ attr_accessor :upgrade_to_federated_login
1930
+ alias_method :upgrade_to_federated_login?, :upgrade_to_federated_login
1931
+
1932
+ # Specifies the minimum timestamp in seconds for an Identity Platform ID token
1933
+ # to be considered valid.
1934
+ # Corresponds to the JSON property `validSince`
1935
+ # @return [Fixnum]
1936
+ attr_accessor :valid_since
1937
+
1938
+ def initialize(**args)
1939
+ update!(**args)
1940
+ end
1941
+
1942
+ # Update properties of this object
1943
+ def update!(**args)
1944
+ @captcha_challenge = args[:captcha_challenge] if args.key?(:captcha_challenge)
1945
+ @captcha_response = args[:captcha_response] if args.key?(:captcha_response)
1946
+ @created_at = args[:created_at] if args.key?(:created_at)
1947
+ @custom_attributes = args[:custom_attributes] if args.key?(:custom_attributes)
1948
+ @delegated_project_number = args[:delegated_project_number] if args.key?(:delegated_project_number)
1949
+ @delete_attribute = args[:delete_attribute] if args.key?(:delete_attribute)
1950
+ @delete_provider = args[:delete_provider] if args.key?(:delete_provider)
1951
+ @disable_user = args[:disable_user] if args.key?(:disable_user)
1952
+ @display_name = args[:display_name] if args.key?(:display_name)
1953
+ @email = args[:email] if args.key?(:email)
1954
+ @email_verified = args[:email_verified] if args.key?(:email_verified)
1955
+ @id_token = args[:id_token] if args.key?(:id_token)
1956
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
1957
+ @last_login_at = args[:last_login_at] if args.key?(:last_login_at)
1958
+ @link_provider_user_info = args[:link_provider_user_info] if args.key?(:link_provider_user_info)
1959
+ @local_id = args[:local_id] if args.key?(:local_id)
1960
+ @mfa = args[:mfa] if args.key?(:mfa)
1961
+ @oob_code = args[:oob_code] if args.key?(:oob_code)
1962
+ @password = args[:password] if args.key?(:password)
1963
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
1964
+ @photo_url = args[:photo_url] if args.key?(:photo_url)
1965
+ @provider = args[:provider] if args.key?(:provider)
1966
+ @return_secure_token = args[:return_secure_token] if args.key?(:return_secure_token)
1967
+ @target_project_id = args[:target_project_id] if args.key?(:target_project_id)
1968
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
1969
+ @upgrade_to_federated_login = args[:upgrade_to_federated_login] if args.key?(:upgrade_to_federated_login)
1970
+ @valid_since = args[:valid_since] if args.key?(:valid_since)
1971
+ end
1972
+ end
1973
+
1974
+ # Response message for SetAccountInfo
1975
+ class GoogleCloudIdentitytoolkitV1SetAccountInfoResponse
1976
+ include Google::Apis::Core::Hashable
1977
+
1978
+ # The account's display name.
1979
+ # Corresponds to the JSON property `displayName`
1980
+ # @return [String]
1981
+ attr_accessor :display_name
1982
+
1983
+ # The account's email address.
1984
+ # Corresponds to the JSON property `email`
1985
+ # @return [String]
1986
+ attr_accessor :email
1987
+
1988
+ # Whether the account's email has been verified.
1989
+ # Corresponds to the JSON property `emailVerified`
1990
+ # @return [Boolean]
1991
+ attr_accessor :email_verified
1992
+ alias_method :email_verified?, :email_verified
1993
+
1994
+ # The number of seconds until the Identity Platform ID token expires.
1995
+ # Corresponds to the JSON property `expiresIn`
1996
+ # @return [Fixnum]
1997
+ attr_accessor :expires_in
1998
+
1999
+ # An Identity Platform ID token for the account. This is used for legacy user
2000
+ # sign up.
2001
+ # Corresponds to the JSON property `idToken`
2002
+ # @return [String]
2003
+ attr_accessor :id_token
2004
+
2005
+ #
2006
+ # Corresponds to the JSON property `kind`
2007
+ # @return [String]
2008
+ attr_accessor :kind
2009
+
2010
+ # The ID of the authenticated user.
2011
+ # Corresponds to the JSON property `localId`
2012
+ # @return [String]
2013
+ attr_accessor :local_id
2014
+
2015
+ # The new email that has been set on the user's account attributes.
2016
+ # Corresponds to the JSON property `newEmail`
2017
+ # @return [String]
2018
+ attr_accessor :new_email
2019
+
2020
+ # Deprecated. No actual password hash is currently returned.
2021
+ # Corresponds to the JSON property `passwordHash`
2022
+ # @return [String]
2023
+ attr_accessor :password_hash
2024
+
2025
+ # The user's photo URL for the account's profile photo.
2026
+ # Corresponds to the JSON property `photoUrl`
2027
+ # @return [String]
2028
+ attr_accessor :photo_url
2029
+
2030
+ # The linked Identity Providers on the account.
2031
+ # Corresponds to the JSON property `providerUserInfo`
2032
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1ProviderUserInfo>]
2033
+ attr_accessor :provider_user_info
2034
+
2035
+ # A refresh token for the account. This is used for legacy user sign up.
2036
+ # Corresponds to the JSON property `refreshToken`
2037
+ # @return [String]
2038
+ attr_accessor :refresh_token
2039
+
2040
+ def initialize(**args)
2041
+ update!(**args)
2042
+ end
2043
+
2044
+ # Update properties of this object
2045
+ def update!(**args)
2046
+ @display_name = args[:display_name] if args.key?(:display_name)
2047
+ @email = args[:email] if args.key?(:email)
2048
+ @email_verified = args[:email_verified] if args.key?(:email_verified)
2049
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
2050
+ @id_token = args[:id_token] if args.key?(:id_token)
2051
+ @kind = args[:kind] if args.key?(:kind)
2052
+ @local_id = args[:local_id] if args.key?(:local_id)
2053
+ @new_email = args[:new_email] if args.key?(:new_email)
2054
+ @password_hash = args[:password_hash] if args.key?(:password_hash)
2055
+ @photo_url = args[:photo_url] if args.key?(:photo_url)
2056
+ @provider_user_info = args[:provider_user_info] if args.key?(:provider_user_info)
2057
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
2058
+ end
2059
+ end
2060
+
2061
+ # Request message for SignInWithCustomToken.
2062
+ class GoogleCloudIdentitytoolkitV1SignInWithCustomTokenRequest
2063
+ include Google::Apis::Core::Hashable
2064
+
2065
+ #
2066
+ # Corresponds to the JSON property `delegatedProjectNumber`
2067
+ # @return [Fixnum]
2068
+ attr_accessor :delegated_project_number
2069
+
2070
+ #
2071
+ # Corresponds to the JSON property `instanceId`
2072
+ # @return [String]
2073
+ attr_accessor :instance_id
2074
+
2075
+ # Should always be true.
2076
+ # Corresponds to the JSON property `returnSecureToken`
2077
+ # @return [Boolean]
2078
+ attr_accessor :return_secure_token
2079
+ alias_method :return_secure_token?, :return_secure_token
2080
+
2081
+ # The ID of the Identity Platform tenant the user is signing in to. If present,
2082
+ # the ID should match the tenant_id in the token.
2083
+ # Corresponds to the JSON property `tenantId`
2084
+ # @return [String]
2085
+ attr_accessor :tenant_id
2086
+
2087
+ # Required. The custom Auth token asserted by the developer. The token should be
2088
+ # a [JSON Web Token (JWT)](https://tools.ietf.org/html/rfc7519) that includes
2089
+ # the claims listed in the [API reference](https://cloud.google.com/identity-
2090
+ # platform/docs/reference/rest/client/) under the "Custom Token Claims" section.
2091
+ # Corresponds to the JSON property `token`
2092
+ # @return [String]
2093
+ attr_accessor :token
2094
+
2095
+ def initialize(**args)
2096
+ update!(**args)
2097
+ end
2098
+
2099
+ # Update properties of this object
2100
+ def update!(**args)
2101
+ @delegated_project_number = args[:delegated_project_number] if args.key?(:delegated_project_number)
2102
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
2103
+ @return_secure_token = args[:return_secure_token] if args.key?(:return_secure_token)
2104
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
2105
+ @token = args[:token] if args.key?(:token)
2106
+ end
2107
+ end
2108
+
2109
+ # Response message for SignInWithCustomToken.
2110
+ class GoogleCloudIdentitytoolkitV1SignInWithCustomTokenResponse
2111
+ include Google::Apis::Core::Hashable
2112
+
2113
+ # The number of seconds until the ID token expires.
2114
+ # Corresponds to the JSON property `expiresIn`
2115
+ # @return [Fixnum]
2116
+ attr_accessor :expires_in
2117
+
2118
+ # An Identity Platform ID token for the authenticated user.
2119
+ # Corresponds to the JSON property `idToken`
2120
+ # @return [String]
2121
+ attr_accessor :id_token
2122
+
2123
+ # Whether the authenticated user was created by this request.
2124
+ # Corresponds to the JSON property `isNewUser`
2125
+ # @return [Boolean]
2126
+ attr_accessor :is_new_user
2127
+ alias_method :is_new_user?, :is_new_user
2128
+
2129
+ #
2130
+ # Corresponds to the JSON property `kind`
2131
+ # @return [String]
2132
+ attr_accessor :kind
2133
+
2134
+ # An Identity Platform refresh token for the authenticated user.
2135
+ # Corresponds to the JSON property `refreshToken`
2136
+ # @return [String]
2137
+ attr_accessor :refresh_token
2138
+
2139
+ def initialize(**args)
2140
+ update!(**args)
2141
+ end
2142
+
2143
+ # Update properties of this object
2144
+ def update!(**args)
2145
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
2146
+ @id_token = args[:id_token] if args.key?(:id_token)
2147
+ @is_new_user = args[:is_new_user] if args.key?(:is_new_user)
2148
+ @kind = args[:kind] if args.key?(:kind)
2149
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
2150
+ end
2151
+ end
2152
+
2153
+ # Request message for SignInWithEmailLink
2154
+ class GoogleCloudIdentitytoolkitV1SignInWithEmailLinkRequest
2155
+ include Google::Apis::Core::Hashable
2156
+
2157
+ # Required. The email address the sign-in link was sent to. The length of email
2158
+ # should be less than 256 characters and in the format of `name@domain.tld`. The
2159
+ # email should also match the [RFC 822](https://tools.ietf.org/html/rfc822) addr-
2160
+ # spec production.
2161
+ # Corresponds to the JSON property `email`
2162
+ # @return [String]
2163
+ attr_accessor :email
2164
+
2165
+ # A valid ID token for an Identity Platform account. If passed, this request
2166
+ # will link the email address to the user represented by this ID token and
2167
+ # enable sign-in with email link on the account for the future.
2168
+ # Corresponds to the JSON property `idToken`
2169
+ # @return [String]
2170
+ attr_accessor :id_token
2171
+
2172
+ # Required. The out-of-band code from the email link.
2173
+ # Corresponds to the JSON property `oobCode`
2174
+ # @return [String]
2175
+ attr_accessor :oob_code
2176
+
2177
+ # The ID of the Identity Platform tenant the user is signing in to. If not set,
2178
+ # the user will sign in to the default Identity Platform project.
2179
+ # Corresponds to the JSON property `tenantId`
2180
+ # @return [String]
2181
+ attr_accessor :tenant_id
2182
+
2183
+ def initialize(**args)
2184
+ update!(**args)
2185
+ end
2186
+
2187
+ # Update properties of this object
2188
+ def update!(**args)
2189
+ @email = args[:email] if args.key?(:email)
2190
+ @id_token = args[:id_token] if args.key?(:id_token)
2191
+ @oob_code = args[:oob_code] if args.key?(:oob_code)
2192
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
2193
+ end
2194
+ end
2195
+
2196
+ # Response message for SignInWithEmailLink.
2197
+ class GoogleCloudIdentitytoolkitV1SignInWithEmailLinkResponse
2198
+ include Google::Apis::Core::Hashable
2199
+
2200
+ # The email the user signed in with. Always present in the response.
2201
+ # Corresponds to the JSON property `email`
2202
+ # @return [String]
2203
+ attr_accessor :email
2204
+
2205
+ # The number of seconds until the ID token expires.
2206
+ # Corresponds to the JSON property `expiresIn`
2207
+ # @return [Fixnum]
2208
+ attr_accessor :expires_in
2209
+
2210
+ # An Identity Platform ID token for the authenticated user.
2211
+ # Corresponds to the JSON property `idToken`
2212
+ # @return [String]
2213
+ attr_accessor :id_token
2214
+
2215
+ # Whether the authenticated user was created by this request.
2216
+ # Corresponds to the JSON property `isNewUser`
2217
+ # @return [Boolean]
2218
+ attr_accessor :is_new_user
2219
+ alias_method :is_new_user?, :is_new_user
2220
+
2221
+ #
2222
+ # Corresponds to the JSON property `kind`
2223
+ # @return [String]
2224
+ attr_accessor :kind
2225
+
2226
+ # The ID of the authenticated user. Always present in the response.
2227
+ # Corresponds to the JSON property `localId`
2228
+ # @return [String]
2229
+ attr_accessor :local_id
2230
+
2231
+ # Info on which multi-factor authentication providers are enabled. Present if
2232
+ # the user needs to complete the sign-in using multi-factor authentication.
2233
+ # Corresponds to the JSON property `mfaInfo`
2234
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaEnrollment>]
2235
+ attr_accessor :mfa_info
2236
+
2237
+ # An opaque string that functions as proof that the user has successfully passed
2238
+ # the first factor check.
2239
+ # Corresponds to the JSON property `mfaPendingCredential`
2240
+ # @return [String]
2241
+ attr_accessor :mfa_pending_credential
2242
+
2243
+ # Refresh token for the authenticated user.
2244
+ # Corresponds to the JSON property `refreshToken`
2245
+ # @return [String]
2246
+ attr_accessor :refresh_token
2247
+
2248
+ def initialize(**args)
2249
+ update!(**args)
2250
+ end
2251
+
2252
+ # Update properties of this object
2253
+ def update!(**args)
2254
+ @email = args[:email] if args.key?(:email)
2255
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
2256
+ @id_token = args[:id_token] if args.key?(:id_token)
2257
+ @is_new_user = args[:is_new_user] if args.key?(:is_new_user)
2258
+ @kind = args[:kind] if args.key?(:kind)
2259
+ @local_id = args[:local_id] if args.key?(:local_id)
2260
+ @mfa_info = args[:mfa_info] if args.key?(:mfa_info)
2261
+ @mfa_pending_credential = args[:mfa_pending_credential] if args.key?(:mfa_pending_credential)
2262
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
2263
+ end
2264
+ end
2265
+
2266
+ # Request message for SignInWithGameCenter
2267
+ class GoogleCloudIdentitytoolkitV1SignInWithGameCenterRequest
2268
+ include Google::Apis::Core::Hashable
2269
+
2270
+ # The user's Game Center display name.
2271
+ # Corresponds to the JSON property `displayName`
2272
+ # @return [String]
2273
+ attr_accessor :display_name
2274
+
2275
+ # A valid ID token for an Identity Platform account. If present, this request
2276
+ # will link the Game Center player ID to the account represented by this ID
2277
+ # token.
2278
+ # Corresponds to the JSON property `idToken`
2279
+ # @return [String]
2280
+ attr_accessor :id_token
2281
+
2282
+ # Required. The user's Game Center player ID.
2283
+ # Corresponds to the JSON property `playerId`
2284
+ # @return [String]
2285
+ attr_accessor :player_id
2286
+
2287
+ # Required. The URL to fetch the Apple public key in order to verify the given
2288
+ # signature is signed by Apple.
2289
+ # Corresponds to the JSON property `publicKeyUrl`
2290
+ # @return [String]
2291
+ attr_accessor :public_key_url
2292
+
2293
+ # Required. A random string used to generate the given signature.
2294
+ # Corresponds to the JSON property `salt`
2295
+ # @return [String]
2296
+ attr_accessor :salt
2297
+
2298
+ # Required. The verification signature data generated by Apple.
2299
+ # Corresponds to the JSON property `signature`
2300
+ # @return [String]
2301
+ attr_accessor :signature
2302
+
2303
+ # The ID of the Identity Platform tenant the user is signing in to.
2304
+ # Corresponds to the JSON property `tenantId`
2305
+ # @return [String]
2306
+ attr_accessor :tenant_id
2307
+
2308
+ # Required. The time when the signature was created by Apple, in milliseconds
2309
+ # since the epoch.
2310
+ # Corresponds to the JSON property `timestamp`
2311
+ # @return [Fixnum]
2312
+ attr_accessor :timestamp
2313
+
2314
+ def initialize(**args)
2315
+ update!(**args)
2316
+ end
2317
+
2318
+ # Update properties of this object
2319
+ def update!(**args)
2320
+ @display_name = args[:display_name] if args.key?(:display_name)
2321
+ @id_token = args[:id_token] if args.key?(:id_token)
2322
+ @player_id = args[:player_id] if args.key?(:player_id)
2323
+ @public_key_url = args[:public_key_url] if args.key?(:public_key_url)
2324
+ @salt = args[:salt] if args.key?(:salt)
2325
+ @signature = args[:signature] if args.key?(:signature)
2326
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
2327
+ @timestamp = args[:timestamp] if args.key?(:timestamp)
2328
+ end
2329
+ end
2330
+
2331
+ # Response message for SignInWithGameCenter
2332
+ class GoogleCloudIdentitytoolkitV1SignInWithGameCenterResponse
2333
+ include Google::Apis::Core::Hashable
2334
+
2335
+ # Display name of the authenticated user.
2336
+ # Corresponds to the JSON property `displayName`
2337
+ # @return [String]
2338
+ attr_accessor :display_name
2339
+
2340
+ # The number of seconds until the ID token expires.
2341
+ # Corresponds to the JSON property `expiresIn`
2342
+ # @return [Fixnum]
2343
+ attr_accessor :expires_in
2344
+
2345
+ # An Identity Platform ID token for the authenticated user.
2346
+ # Corresponds to the JSON property `idToken`
2347
+ # @return [String]
2348
+ attr_accessor :id_token
2349
+
2350
+ # Whether the logged in user was created by this request.
2351
+ # Corresponds to the JSON property `isNewUser`
2352
+ # @return [Boolean]
2353
+ attr_accessor :is_new_user
2354
+ alias_method :is_new_user?, :is_new_user
2355
+
2356
+ # The ID of the authenticated user. Always present in the response.
2357
+ # Corresponds to the JSON property `localId`
2358
+ # @return [String]
2359
+ attr_accessor :local_id
2360
+
2361
+ # The user's Game Center player ID.
2362
+ # Corresponds to the JSON property `playerId`
2363
+ # @return [String]
2364
+ attr_accessor :player_id
2365
+
2366
+ # An Identity Platform refresh token for the authenticated user.
2367
+ # Corresponds to the JSON property `refreshToken`
2368
+ # @return [String]
2369
+ attr_accessor :refresh_token
2370
+
2371
+ def initialize(**args)
2372
+ update!(**args)
2373
+ end
2374
+
2375
+ # Update properties of this object
2376
+ def update!(**args)
2377
+ @display_name = args[:display_name] if args.key?(:display_name)
2378
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
2379
+ @id_token = args[:id_token] if args.key?(:id_token)
2380
+ @is_new_user = args[:is_new_user] if args.key?(:is_new_user)
2381
+ @local_id = args[:local_id] if args.key?(:local_id)
2382
+ @player_id = args[:player_id] if args.key?(:player_id)
2383
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
2384
+ end
2385
+ end
2386
+
2387
+ # Request message for SignInWithIdp.
2388
+ class GoogleCloudIdentitytoolkitV1SignInWithIdpRequest
2389
+ include Google::Apis::Core::Hashable
2390
+
2391
+ #
2392
+ # Corresponds to the JSON property `autoCreate`
2393
+ # @return [Boolean]
2394
+ attr_accessor :auto_create
2395
+ alias_method :auto_create?, :auto_create
2396
+
2397
+ #
2398
+ # Corresponds to the JSON property `delegatedProjectNumber`
2399
+ # @return [Fixnum]
2400
+ attr_accessor :delegated_project_number
2401
+
2402
+ # A valid Identity Platform ID token. If passed, the user's account at the IdP
2403
+ # will be linked to the account represented by this ID token.
2404
+ # Corresponds to the JSON property `idToken`
2405
+ # @return [String]
2406
+ attr_accessor :id_token
2407
+
2408
+ #
2409
+ # Corresponds to the JSON property `pendingIdToken`
2410
+ # @return [String]
2411
+ attr_accessor :pending_id_token
2412
+
2413
+ # An opaque string from a previous SignInWithIdp response. If set, it can be
2414
+ # used to repeat the sign-in operation from the previous SignInWithIdp operation.
2415
+ # Corresponds to the JSON property `pendingToken`
2416
+ # @return [String]
2417
+ attr_accessor :pending_token
2418
+
2419
+ # If the user is signing in with an authorization response obtained via a
2420
+ # previous CreateAuthUri authorization request, this is the body of the HTTP
2421
+ # POST callback from the IdP, if present. Otherwise, if the user is signing in
2422
+ # with a manually provided IdP credential, this should be a URL-encoded form
2423
+ # that contains the credential (e.g. an ID token or access token for OAuth 2.0
2424
+ # IdPs) and the provider ID of the IdP that issued the credential. For example,
2425
+ # if the user is signing in to the Google provider using a Google ID token, this
2426
+ # should be set to `id_token=[GOOGLE_ID_TOKEN]&providerId=google.com`, where `[
2427
+ # GOOGLE_ID_TOKEN]` should be replaced with the Google ID token. If the user is
2428
+ # signing in to the Facebook provider using a Facebook authentication token,
2429
+ # this should be set to `id_token=[FACEBOOK_AUTHENTICATION_TOKEN]&providerId=
2430
+ # facebook.com&nonce= [NONCE]`, where `[FACEBOOK_AUTHENTICATION_TOKEN]` should
2431
+ # be replaced with the Facebook authentication token. Nonce is required for
2432
+ # validating the token. The request will fail if no nonce is provided. If the
2433
+ # user is signing in to the Facebook provider using a Facebook access token,
2434
+ # this should be set to `access_token=[FACEBOOK_ACCESS_TOKEN]&providerId=
2435
+ # facebook.com`, where `[FACEBOOK_ACCESS_TOKEN]` should be replaced with the
2436
+ # Facebook access token. If the user is signing in to the Twitter provider using
2437
+ # a Twitter OAuth 1.0 credential, this should be set to `access_token=[
2438
+ # TWITTER_ACCESS_TOKEN]&oauth_token_secret=[TWITTER_TOKEN_SECRET]&providerId=
2439
+ # twitter.com`, where `[TWITTER_ACCESS_TOKEN]` and `[TWITTER_TOKEN_SECRET]`
2440
+ # should be replaced with the Twitter OAuth access token and Twitter OAuth token
2441
+ # secret respectively.
2442
+ # Corresponds to the JSON property `postBody`
2443
+ # @return [String]
2444
+ attr_accessor :post_body
2445
+
2446
+ # Required. The URL to which the IdP redirects the user back. This can be set to
2447
+ # `http://localhost` if the user is signing in with a manually provided IdP
2448
+ # credential.
2449
+ # Corresponds to the JSON property `requestUri`
2450
+ # @return [String]
2451
+ attr_accessor :request_uri
2452
+
2453
+ # Whether or not to return OAuth credentials from the IdP on the following
2454
+ # errors: `FEDERATED_USER_ID_ALREADY_LINKED` and `EMAIL_EXISTS`.
2455
+ # Corresponds to the JSON property `returnIdpCredential`
2456
+ # @return [Boolean]
2457
+ attr_accessor :return_idp_credential
2458
+ alias_method :return_idp_credential?, :return_idp_credential
2459
+
2460
+ # Whether or not to return the OAuth refresh token from the IdP, if available.
2461
+ # Corresponds to the JSON property `returnRefreshToken`
2462
+ # @return [Boolean]
2463
+ attr_accessor :return_refresh_token
2464
+ alias_method :return_refresh_token?, :return_refresh_token
2465
+
2466
+ # Should always be true.
2467
+ # Corresponds to the JSON property `returnSecureToken`
2468
+ # @return [Boolean]
2469
+ attr_accessor :return_secure_token
2470
+ alias_method :return_secure_token?, :return_secure_token
2471
+
2472
+ # The session ID returned from a previous CreateAuthUri call. This field is
2473
+ # verified against that session ID to prevent session fixation attacks. Required
2474
+ # if the user is signing in with an authorization response from a previous
2475
+ # CreateAuthUri authorization request.
2476
+ # Corresponds to the JSON property `sessionId`
2477
+ # @return [String]
2478
+ attr_accessor :session_id
2479
+
2480
+ # The ID of the Identity Platform tenant the user is signing in to. If not set,
2481
+ # the user will sign in to the default Identity Platform project.
2482
+ # Corresponds to the JSON property `tenantId`
2483
+ # @return [String]
2484
+ attr_accessor :tenant_id
2485
+
2486
+ def initialize(**args)
2487
+ update!(**args)
2488
+ end
2489
+
2490
+ # Update properties of this object
2491
+ def update!(**args)
2492
+ @auto_create = args[:auto_create] if args.key?(:auto_create)
2493
+ @delegated_project_number = args[:delegated_project_number] if args.key?(:delegated_project_number)
2494
+ @id_token = args[:id_token] if args.key?(:id_token)
2495
+ @pending_id_token = args[:pending_id_token] if args.key?(:pending_id_token)
2496
+ @pending_token = args[:pending_token] if args.key?(:pending_token)
2497
+ @post_body = args[:post_body] if args.key?(:post_body)
2498
+ @request_uri = args[:request_uri] if args.key?(:request_uri)
2499
+ @return_idp_credential = args[:return_idp_credential] if args.key?(:return_idp_credential)
2500
+ @return_refresh_token = args[:return_refresh_token] if args.key?(:return_refresh_token)
2501
+ @return_secure_token = args[:return_secure_token] if args.key?(:return_secure_token)
2502
+ @session_id = args[:session_id] if args.key?(:session_id)
2503
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
2504
+ end
2505
+ end
2506
+
2507
+ # Response message for SignInWithIdp.
2508
+ class GoogleCloudIdentitytoolkitV1SignInWithIdpResponse
2509
+ include Google::Apis::Core::Hashable
2510
+
2511
+ # The opaque string set in CreateAuthUri that is used to maintain contextual
2512
+ # information between the authentication request and the callback from the IdP.
2513
+ # Corresponds to the JSON property `context`
2514
+ # @return [String]
2515
+ attr_accessor :context
2516
+
2517
+ # The date of birth for the user's account at the IdP.
2518
+ # Corresponds to the JSON property `dateOfBirth`
2519
+ # @return [String]
2520
+ attr_accessor :date_of_birth
2521
+
2522
+ # The display name for the user's account at the IdP.
2523
+ # Corresponds to the JSON property `displayName`
2524
+ # @return [String]
2525
+ attr_accessor :display_name
2526
+
2527
+ # The email address of the user's account at the IdP.
2528
+ # Corresponds to the JSON property `email`
2529
+ # @return [String]
2530
+ attr_accessor :email
2531
+
2532
+ # Whether or not there is an existing Identity Platform user account with the
2533
+ # same email address but linked to a different account at the same IdP. Only
2534
+ # present if the "One account per email address" setting is enabled and the
2535
+ # email address at the IdP is verified.
2536
+ # Corresponds to the JSON property `emailRecycled`
2537
+ # @return [Boolean]
2538
+ attr_accessor :email_recycled
2539
+ alias_method :email_recycled?, :email_recycled
2540
+
2541
+ # Whether the user account's email address is verified.
2542
+ # Corresponds to the JSON property `emailVerified`
2543
+ # @return [Boolean]
2544
+ attr_accessor :email_verified
2545
+ alias_method :email_verified?, :email_verified
2546
+
2547
+ # The error message returned if `return_idp_credential` is set to `true` and
2548
+ # either the `FEDERATED_USER_ID_ALREADY_LINKED` or `EMAIL_EXISTS` error is
2549
+ # encountered. This field's value is either `FEDERATED_USER_ID_ALREADY_LINKED`
2550
+ # or `EMAIL_EXISTS`.
2551
+ # Corresponds to the JSON property `errorMessage`
2552
+ # @return [String]
2553
+ attr_accessor :error_message
2554
+
2555
+ # The number of seconds until the Identity Platform ID token expires.
2556
+ # Corresponds to the JSON property `expiresIn`
2557
+ # @return [Fixnum]
2558
+ attr_accessor :expires_in
2559
+
2560
+ # The user's account ID at the IdP. Always present in the response.
2561
+ # Corresponds to the JSON property `federatedId`
2562
+ # @return [String]
2563
+ attr_accessor :federated_id
2564
+
2565
+ # The first name for the user's account at the IdP.
2566
+ # Corresponds to the JSON property `firstName`
2567
+ # @return [String]
2568
+ attr_accessor :first_name
2569
+
2570
+ # The full name for the user's account at the IdP.
2571
+ # Corresponds to the JSON property `fullName`
2572
+ # @return [String]
2573
+ attr_accessor :full_name
2574
+
2575
+ # An Identity Platform ID token for the authenticated user.
2576
+ # Corresponds to the JSON property `idToken`
2577
+ # @return [String]
2578
+ attr_accessor :id_token
2579
+
2580
+ #
2581
+ # Corresponds to the JSON property `inputEmail`
2582
+ # @return [String]
2583
+ attr_accessor :input_email
2584
+
2585
+ # Whether or not a new Identity Platform account was created for the
2586
+ # authenticated user.
2587
+ # Corresponds to the JSON property `isNewUser`
2588
+ # @return [Boolean]
2589
+ attr_accessor :is_new_user
2590
+ alias_method :is_new_user?, :is_new_user
2591
+
2592
+ #
2593
+ # Corresponds to the JSON property `kind`
2594
+ # @return [String]
2595
+ attr_accessor :kind
2596
+
2597
+ # The language preference for the user's account at the IdP.
2598
+ # Corresponds to the JSON property `language`
2599
+ # @return [String]
2600
+ attr_accessor :language
2601
+
2602
+ # The last name for the user's account at the IdP.
2603
+ # Corresponds to the JSON property `lastName`
2604
+ # @return [String]
2605
+ attr_accessor :last_name
2606
+
2607
+ # The ID of the authenticated Identity Platform user. Always present in the
2608
+ # response.
2609
+ # Corresponds to the JSON property `localId`
2610
+ # @return [String]
2611
+ attr_accessor :local_id
2612
+
2613
+ # Info on which multi-factor authentication providers are enabled for the
2614
+ # account. Present if the user needs to complete the sign-in using multi-factor
2615
+ # authentication.
2616
+ # Corresponds to the JSON property `mfaInfo`
2617
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaEnrollment>]
2618
+ attr_accessor :mfa_info
2619
+
2620
+ # An opaque string that functions as proof that the user has successfully passed
2621
+ # the first factor authentication.
2622
+ # Corresponds to the JSON property `mfaPendingCredential`
2623
+ # @return [String]
2624
+ attr_accessor :mfa_pending_credential
2625
+
2626
+ # Whether or not there is an existing Identity Platform user account with the
2627
+ # same email address as the current account signed in at the IdP, and the
2628
+ # account's email addresss is not verified at the IdP. The user will need to
2629
+ # sign in to the existing Identity Platform account and then link the current
2630
+ # credential from the IdP to it. Only present if the "One account per email
2631
+ # address" setting is enabled.
2632
+ # Corresponds to the JSON property `needConfirmation`
2633
+ # @return [Boolean]
2634
+ attr_accessor :need_confirmation
2635
+ alias_method :need_confirmation?, :need_confirmation
2636
+
2637
+ #
2638
+ # Corresponds to the JSON property `needEmail`
2639
+ # @return [Boolean]
2640
+ attr_accessor :need_email
2641
+ alias_method :need_email?, :need_email
2642
+
2643
+ # The nickname for the user's account at the IdP.
2644
+ # Corresponds to the JSON property `nickName`
2645
+ # @return [String]
2646
+ attr_accessor :nick_name
2647
+
2648
+ # The OAuth access token from the IdP, if available.
2649
+ # Corresponds to the JSON property `oauthAccessToken`
2650
+ # @return [String]
2651
+ attr_accessor :oauth_access_token
2652
+
2653
+ # The OAuth 2.0 authorization code, if available. Only present for the Google
2654
+ # provider.
2655
+ # Corresponds to the JSON property `oauthAuthorizationCode`
2656
+ # @return [String]
2657
+ attr_accessor :oauth_authorization_code
2658
+
2659
+ # The number of seconds until the OAuth access token from the IdP expires.
2660
+ # Corresponds to the JSON property `oauthExpireIn`
2661
+ # @return [Fixnum]
2662
+ attr_accessor :oauth_expire_in
2663
+
2664
+ # The OpenID Connect ID token from the IdP, if available.
2665
+ # Corresponds to the JSON property `oauthIdToken`
2666
+ # @return [String]
2667
+ attr_accessor :oauth_id_token
2668
+
2669
+ # The OAuth 2.0 refresh token from the IdP, if available and `
2670
+ # return_refresh_token` is set to `true`.
2671
+ # Corresponds to the JSON property `oauthRefreshToken`
2672
+ # @return [String]
2673
+ attr_accessor :oauth_refresh_token
2674
+
2675
+ # The OAuth 1.0 token secret from the IdP, if available. Only present for the
2676
+ # Twitter provider.
2677
+ # Corresponds to the JSON property `oauthTokenSecret`
2678
+ # @return [String]
2679
+ attr_accessor :oauth_token_secret
2680
+
2681
+ # The main (top-level) email address of the user's Identity Platform account, if
2682
+ # different from the email address at the IdP. Only present if the "One account
2683
+ # per email address" setting is enabled.
2684
+ # Corresponds to the JSON property `originalEmail`
2685
+ # @return [String]
2686
+ attr_accessor :original_email
2687
+
2688
+ # An opaque string that can be used as a credential from the IdP the user is
2689
+ # signing into. The pending token obtained here can be set in a future
2690
+ # SignInWithIdp request to sign the same user in with the IdP again.
2691
+ # Corresponds to the JSON property `pendingToken`
2692
+ # @return [String]
2693
+ attr_accessor :pending_token
2694
+
2695
+ # The URL of the user's profile picture at the IdP.
2696
+ # Corresponds to the JSON property `photoUrl`
2697
+ # @return [String]
2698
+ attr_accessor :photo_url
2699
+
2700
+ # The provider ID of the IdP that the user is signing in to. Always present in
2701
+ # the response.
2702
+ # Corresponds to the JSON property `providerId`
2703
+ # @return [String]
2704
+ attr_accessor :provider_id
2705
+
2706
+ # The stringified JSON response containing all the data corresponding to the
2707
+ # user's account at the IdP.
2708
+ # Corresponds to the JSON property `rawUserInfo`
2709
+ # @return [String]
2710
+ attr_accessor :raw_user_info
2711
+
2712
+ # An Identity Platform refresh token for the authenticated user.
2713
+ # Corresponds to the JSON property `refreshToken`
2714
+ # @return [String]
2715
+ attr_accessor :refresh_token
2716
+
2717
+ # The screen name for the user's account at the Twitter IdP or the login name
2718
+ # for the user's account at the GitHub IdP.
2719
+ # Corresponds to the JSON property `screenName`
2720
+ # @return [String]
2721
+ attr_accessor :screen_name
2722
+
2723
+ # The value of the `tenant_id` field in the request.
2724
+ # Corresponds to the JSON property `tenantId`
2725
+ # @return [String]
2726
+ attr_accessor :tenant_id
2727
+
2728
+ # The time zone for the user's account at the IdP.
2729
+ # Corresponds to the JSON property `timeZone`
2730
+ # @return [String]
2731
+ attr_accessor :time_zone
2732
+
2733
+ # A list of provider IDs that the user can sign in to in order to resolve a `
2734
+ # need_confirmation` error. Only present if `need_confirmation` is set to `true`.
2735
+ # Corresponds to the JSON property `verifiedProvider`
2736
+ # @return [Array<String>]
2737
+ attr_accessor :verified_provider
2738
+
2739
+ def initialize(**args)
2740
+ update!(**args)
2741
+ end
2742
+
2743
+ # Update properties of this object
2744
+ def update!(**args)
2745
+ @context = args[:context] if args.key?(:context)
2746
+ @date_of_birth = args[:date_of_birth] if args.key?(:date_of_birth)
2747
+ @display_name = args[:display_name] if args.key?(:display_name)
2748
+ @email = args[:email] if args.key?(:email)
2749
+ @email_recycled = args[:email_recycled] if args.key?(:email_recycled)
2750
+ @email_verified = args[:email_verified] if args.key?(:email_verified)
2751
+ @error_message = args[:error_message] if args.key?(:error_message)
2752
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
2753
+ @federated_id = args[:federated_id] if args.key?(:federated_id)
2754
+ @first_name = args[:first_name] if args.key?(:first_name)
2755
+ @full_name = args[:full_name] if args.key?(:full_name)
2756
+ @id_token = args[:id_token] if args.key?(:id_token)
2757
+ @input_email = args[:input_email] if args.key?(:input_email)
2758
+ @is_new_user = args[:is_new_user] if args.key?(:is_new_user)
2759
+ @kind = args[:kind] if args.key?(:kind)
2760
+ @language = args[:language] if args.key?(:language)
2761
+ @last_name = args[:last_name] if args.key?(:last_name)
2762
+ @local_id = args[:local_id] if args.key?(:local_id)
2763
+ @mfa_info = args[:mfa_info] if args.key?(:mfa_info)
2764
+ @mfa_pending_credential = args[:mfa_pending_credential] if args.key?(:mfa_pending_credential)
2765
+ @need_confirmation = args[:need_confirmation] if args.key?(:need_confirmation)
2766
+ @need_email = args[:need_email] if args.key?(:need_email)
2767
+ @nick_name = args[:nick_name] if args.key?(:nick_name)
2768
+ @oauth_access_token = args[:oauth_access_token] if args.key?(:oauth_access_token)
2769
+ @oauth_authorization_code = args[:oauth_authorization_code] if args.key?(:oauth_authorization_code)
2770
+ @oauth_expire_in = args[:oauth_expire_in] if args.key?(:oauth_expire_in)
2771
+ @oauth_id_token = args[:oauth_id_token] if args.key?(:oauth_id_token)
2772
+ @oauth_refresh_token = args[:oauth_refresh_token] if args.key?(:oauth_refresh_token)
2773
+ @oauth_token_secret = args[:oauth_token_secret] if args.key?(:oauth_token_secret)
2774
+ @original_email = args[:original_email] if args.key?(:original_email)
2775
+ @pending_token = args[:pending_token] if args.key?(:pending_token)
2776
+ @photo_url = args[:photo_url] if args.key?(:photo_url)
2777
+ @provider_id = args[:provider_id] if args.key?(:provider_id)
2778
+ @raw_user_info = args[:raw_user_info] if args.key?(:raw_user_info)
2779
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
2780
+ @screen_name = args[:screen_name] if args.key?(:screen_name)
2781
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
2782
+ @time_zone = args[:time_zone] if args.key?(:time_zone)
2783
+ @verified_provider = args[:verified_provider] if args.key?(:verified_provider)
2784
+ end
2785
+ end
2786
+
2787
+ # Request message for SignInWithPassword.
2788
+ class GoogleCloudIdentitytoolkitV1SignInWithPasswordRequest
2789
+ include Google::Apis::Core::Hashable
2790
+
2791
+ #
2792
+ # Corresponds to the JSON property `captchaChallenge`
2793
+ # @return [String]
2794
+ attr_accessor :captcha_challenge
2795
+
2796
+ # The reCAPTCHA token provided by the reCAPTCHA client-side integration.
2797
+ # reCAPTCHA Enterprise uses it for risk assessment. Required when reCAPTCHA
2798
+ # Enterprise is enabled.
2799
+ # Corresponds to the JSON property `captchaResponse`
2800
+ # @return [String]
2801
+ attr_accessor :captcha_response
2802
+
2803
+ #
2804
+ # Corresponds to the JSON property `delegatedProjectNumber`
2805
+ # @return [Fixnum]
2806
+ attr_accessor :delegated_project_number
2807
+
2808
+ # Required. The email the user is signing in with. The length of email should be
2809
+ # less than 256 characters and in the format of `name@domain.tld`. The email
2810
+ # should also match the [RFC 822](https://tools.ietf.org/html/rfc822) addr-spec
2811
+ # production.
2812
+ # Corresponds to the JSON property `email`
2813
+ # @return [String]
2814
+ attr_accessor :email
2815
+
2816
+ #
2817
+ # Corresponds to the JSON property `idToken`
2818
+ # @return [String]
2819
+ attr_accessor :id_token
2820
+
2821
+ #
2822
+ # Corresponds to the JSON property `instanceId`
2823
+ # @return [String]
2824
+ attr_accessor :instance_id
2825
+
2826
+ # Required. The password the user provides to sign in to the account.
2827
+ # Corresponds to the JSON property `password`
2828
+ # @return [String]
2829
+ attr_accessor :password
2830
+
2831
+ #
2832
+ # Corresponds to the JSON property `pendingIdToken`
2833
+ # @return [String]
2834
+ attr_accessor :pending_id_token
2835
+
2836
+ # Should always be true.
2837
+ # Corresponds to the JSON property `returnSecureToken`
2838
+ # @return [Boolean]
2839
+ attr_accessor :return_secure_token
2840
+ alias_method :return_secure_token?, :return_secure_token
2841
+
2842
+ # The ID of the Identity Platform tenant the user is signing in to. If not set,
2843
+ # the user will sign in to the default Identity Platform instance in the project.
2844
+ # Corresponds to the JSON property `tenantId`
2845
+ # @return [String]
2846
+ attr_accessor :tenant_id
2847
+
2848
+ def initialize(**args)
2849
+ update!(**args)
2850
+ end
2851
+
2852
+ # Update properties of this object
2853
+ def update!(**args)
2854
+ @captcha_challenge = args[:captcha_challenge] if args.key?(:captcha_challenge)
2855
+ @captcha_response = args[:captcha_response] if args.key?(:captcha_response)
2856
+ @delegated_project_number = args[:delegated_project_number] if args.key?(:delegated_project_number)
2857
+ @email = args[:email] if args.key?(:email)
2858
+ @id_token = args[:id_token] if args.key?(:id_token)
2859
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
2860
+ @password = args[:password] if args.key?(:password)
2861
+ @pending_id_token = args[:pending_id_token] if args.key?(:pending_id_token)
2862
+ @return_secure_token = args[:return_secure_token] if args.key?(:return_secure_token)
2863
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
2864
+ end
2865
+ end
2866
+
2867
+ # Response message for SignInWithPassword.
2868
+ class GoogleCloudIdentitytoolkitV1SignInWithPasswordResponse
2869
+ include Google::Apis::Core::Hashable
2870
+
2871
+ # The user's display name stored in the account's attributes.
2872
+ # Corresponds to the JSON property `displayName`
2873
+ # @return [String]
2874
+ attr_accessor :display_name
2875
+
2876
+ # The email of the authenticated user. Always present in the response.
2877
+ # Corresponds to the JSON property `email`
2878
+ # @return [String]
2879
+ attr_accessor :email
2880
+
2881
+ # The number of seconds until the Identity Platform ID token expires.
2882
+ # Corresponds to the JSON property `expiresIn`
2883
+ # @return [Fixnum]
2884
+ attr_accessor :expires_in
2885
+
2886
+ # An Identity Platform ID token for the authenticated user.
2887
+ # Corresponds to the JSON property `idToken`
2888
+ # @return [String]
2889
+ attr_accessor :id_token
2890
+
2891
+ #
2892
+ # Corresponds to the JSON property `kind`
2893
+ # @return [String]
2894
+ attr_accessor :kind
2895
+
2896
+ # The ID of the authenticated user. Always present in the response.
2897
+ # Corresponds to the JSON property `localId`
2898
+ # @return [String]
2899
+ attr_accessor :local_id
2900
+
2901
+ # Info on which multi-factor authentication providers are enabled for the
2902
+ # account. Present if the user needs to complete the sign-in using multi-factor
2903
+ # authentication.
2904
+ # Corresponds to the JSON property `mfaInfo`
2905
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaEnrollment>]
2906
+ attr_accessor :mfa_info
2907
+
2908
+ # An opaque string that functions as proof that the user has successfully passed
2909
+ # the first factor authentication.
2910
+ # Corresponds to the JSON property `mfaPendingCredential`
2911
+ # @return [String]
2912
+ attr_accessor :mfa_pending_credential
2913
+
2914
+ # The OAuth2 access token.
2915
+ # Corresponds to the JSON property `oauthAccessToken`
2916
+ # @return [String]
2917
+ attr_accessor :oauth_access_token
2918
+
2919
+ #
2920
+ # Corresponds to the JSON property `oauthAuthorizationCode`
2921
+ # @return [String]
2922
+ attr_accessor :oauth_authorization_code
2923
+
2924
+ # The access token expiration time in seconds.
2925
+ # Corresponds to the JSON property `oauthExpireIn`
2926
+ # @return [Fixnum]
2927
+ attr_accessor :oauth_expire_in
2928
+
2929
+ # The user's profile picture stored in the account's attributes.
2930
+ # Corresponds to the JSON property `profilePicture`
2931
+ # @return [String]
2932
+ attr_accessor :profile_picture
2933
+
2934
+ # An Identity Platform refresh token for the authenticated user.
2935
+ # Corresponds to the JSON property `refreshToken`
2936
+ # @return [String]
2937
+ attr_accessor :refresh_token
2938
+
2939
+ # Whether the email is for an existing account. Always true.
2940
+ # Corresponds to the JSON property `registered`
2941
+ # @return [Boolean]
2942
+ attr_accessor :registered
2943
+ alias_method :registered?, :registered
2944
+
2945
+ def initialize(**args)
2946
+ update!(**args)
2947
+ end
2948
+
2949
+ # Update properties of this object
2950
+ def update!(**args)
2951
+ @display_name = args[:display_name] if args.key?(:display_name)
2952
+ @email = args[:email] if args.key?(:email)
2953
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
2954
+ @id_token = args[:id_token] if args.key?(:id_token)
2955
+ @kind = args[:kind] if args.key?(:kind)
2956
+ @local_id = args[:local_id] if args.key?(:local_id)
2957
+ @mfa_info = args[:mfa_info] if args.key?(:mfa_info)
2958
+ @mfa_pending_credential = args[:mfa_pending_credential] if args.key?(:mfa_pending_credential)
2959
+ @oauth_access_token = args[:oauth_access_token] if args.key?(:oauth_access_token)
2960
+ @oauth_authorization_code = args[:oauth_authorization_code] if args.key?(:oauth_authorization_code)
2961
+ @oauth_expire_in = args[:oauth_expire_in] if args.key?(:oauth_expire_in)
2962
+ @profile_picture = args[:profile_picture] if args.key?(:profile_picture)
2963
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
2964
+ @registered = args[:registered] if args.key?(:registered)
2965
+ end
2966
+ end
2967
+
2968
+ # Request message for SignInWithPhoneNumber.
2969
+ class GoogleCloudIdentitytoolkitV1SignInWithPhoneNumberRequest
2970
+ include Google::Apis::Core::Hashable
2971
+
2972
+ # User-entered verification code from an SMS sent to the user's phone.
2973
+ # Corresponds to the JSON property `code`
2974
+ # @return [String]
2975
+ attr_accessor :code
2976
+
2977
+ # A valid ID token for an Identity Platform account. If passed, this request
2978
+ # will link the phone number to the user represented by this ID token if the
2979
+ # phone number is not in use, or will reauthenticate the user if the phone
2980
+ # number is already linked to the user.
2981
+ # Corresponds to the JSON property `idToken`
2982
+ # @return [String]
2983
+ attr_accessor :id_token
2984
+
2985
+ #
2986
+ # Corresponds to the JSON property `operation`
2987
+ # @return [String]
2988
+ attr_accessor :operation
2989
+
2990
+ # The user's phone number to sign in with. This is necessary in the case of uing
2991
+ # a temporary proof, in which case it must match the phone number that was
2992
+ # authenticated in the request that generated the temporary proof. This field is
2993
+ # ignored if a session info is passed.
2994
+ # Corresponds to the JSON property `phoneNumber`
2995
+ # @return [String]
2996
+ attr_accessor :phone_number
2997
+
2998
+ # Encrypted session information from the response of sendVerificationCode. In
2999
+ # the case of authenticating with an SMS code this must be specified, but in the
3000
+ # case of using a temporary proof it can be unspecified.
3001
+ # Corresponds to the JSON property `sessionInfo`
3002
+ # @return [String]
3003
+ attr_accessor :session_info
3004
+
3005
+ # A proof of the phone number verification, provided from a previous
3006
+ # signInWithPhoneNumber request. If this is passed, the caller must also pass in
3007
+ # the phone_number field the phone number that was verified in the previous
3008
+ # request.
3009
+ # Corresponds to the JSON property `temporaryProof`
3010
+ # @return [String]
3011
+ attr_accessor :temporary_proof
3012
+
3013
+ # The ID of the Identity Platform tenant the user is signing in to. If not set,
3014
+ # the user will sign in to the default Identity Platform project.
3015
+ # Corresponds to the JSON property `tenantId`
3016
+ # @return [String]
3017
+ attr_accessor :tenant_id
3018
+
3019
+ # Do not use.
3020
+ # Corresponds to the JSON property `verificationProof`
3021
+ # @return [String]
3022
+ attr_accessor :verification_proof
3023
+
3024
+ def initialize(**args)
3025
+ update!(**args)
3026
+ end
3027
+
3028
+ # Update properties of this object
3029
+ def update!(**args)
3030
+ @code = args[:code] if args.key?(:code)
3031
+ @id_token = args[:id_token] if args.key?(:id_token)
3032
+ @operation = args[:operation] if args.key?(:operation)
3033
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
3034
+ @session_info = args[:session_info] if args.key?(:session_info)
3035
+ @temporary_proof = args[:temporary_proof] if args.key?(:temporary_proof)
3036
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
3037
+ @verification_proof = args[:verification_proof] if args.key?(:verification_proof)
3038
+ end
3039
+ end
3040
+
3041
+ # Response message for SignInWithPhoneNumber.
3042
+ class GoogleCloudIdentitytoolkitV1SignInWithPhoneNumberResponse
3043
+ include Google::Apis::Core::Hashable
3044
+
3045
+ # The number of seconds until the ID token expires.
3046
+ # Corresponds to the JSON property `expiresIn`
3047
+ # @return [Fixnum]
3048
+ attr_accessor :expires_in
3049
+
3050
+ # Identity Platform ID token for the authenticated user.
3051
+ # Corresponds to the JSON property `idToken`
3052
+ # @return [String]
3053
+ attr_accessor :id_token
3054
+
3055
+ # Whether the authenticated user was created by this request.
3056
+ # Corresponds to the JSON property `isNewUser`
3057
+ # @return [Boolean]
3058
+ attr_accessor :is_new_user
3059
+ alias_method :is_new_user?, :is_new_user
3060
+
3061
+ # The id of the authenticated user. Present in the case of a successful
3062
+ # authentication. In the case when the phone could be verified but the account
3063
+ # operation could not be performed, a temporary proof will be returned instead.
3064
+ # Corresponds to the JSON property `localId`
3065
+ # @return [String]
3066
+ attr_accessor :local_id
3067
+
3068
+ # Phone number of the authenticated user. Always present in the response.
3069
+ # Corresponds to the JSON property `phoneNumber`
3070
+ # @return [String]
3071
+ attr_accessor :phone_number
3072
+
3073
+ # Refresh token for the authenticated user.
3074
+ # Corresponds to the JSON property `refreshToken`
3075
+ # @return [String]
3076
+ attr_accessor :refresh_token
3077
+
3078
+ # A proof of the phone number verification, provided if a phone authentication
3079
+ # is successful but the user operation fails. This happens when the request
3080
+ # tries to link a phone number to a user with an ID token or reauthenticate with
3081
+ # an ID token but the phone number is linked to a different user.
3082
+ # Corresponds to the JSON property `temporaryProof`
3083
+ # @return [String]
3084
+ attr_accessor :temporary_proof
3085
+
3086
+ # The number of seconds until the temporary proof expires.
3087
+ # Corresponds to the JSON property `temporaryProofExpiresIn`
3088
+ # @return [Fixnum]
3089
+ attr_accessor :temporary_proof_expires_in
3090
+
3091
+ # Do not use.
3092
+ # Corresponds to the JSON property `verificationProof`
3093
+ # @return [String]
3094
+ attr_accessor :verification_proof
3095
+
3096
+ # Do not use.
3097
+ # Corresponds to the JSON property `verificationProofExpiresIn`
3098
+ # @return [Fixnum]
3099
+ attr_accessor :verification_proof_expires_in
3100
+
3101
+ def initialize(**args)
3102
+ update!(**args)
3103
+ end
3104
+
3105
+ # Update properties of this object
3106
+ def update!(**args)
3107
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
3108
+ @id_token = args[:id_token] if args.key?(:id_token)
3109
+ @is_new_user = args[:is_new_user] if args.key?(:is_new_user)
3110
+ @local_id = args[:local_id] if args.key?(:local_id)
3111
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
3112
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
3113
+ @temporary_proof = args[:temporary_proof] if args.key?(:temporary_proof)
3114
+ @temporary_proof_expires_in = args[:temporary_proof_expires_in] if args.key?(:temporary_proof_expires_in)
3115
+ @verification_proof = args[:verification_proof] if args.key?(:verification_proof)
3116
+ @verification_proof_expires_in = args[:verification_proof_expires_in] if args.key?(:verification_proof_expires_in)
3117
+ end
3118
+ end
3119
+
3120
+ # Request message for SignUp.
3121
+ class GoogleCloudIdentitytoolkitV1SignUpRequest
3122
+ include Google::Apis::Core::Hashable
3123
+
3124
+ #
3125
+ # Corresponds to the JSON property `captchaChallenge`
3126
+ # @return [String]
3127
+ attr_accessor :captcha_challenge
3128
+
3129
+ # The reCAPTCHA token provided by the reCAPTCHA client-side integration.
3130
+ # reCAPTCHA Enterprise uses it for assessment. Required when reCAPTCHA
3131
+ # enterprise is enabled.
3132
+ # Corresponds to the JSON property `captchaResponse`
3133
+ # @return [String]
3134
+ attr_accessor :captcha_response
3135
+
3136
+ # Whether the user will be disabled upon creation. Disabled accounts are
3137
+ # inaccessible except for requests bearing a Google OAuth2 credential with
3138
+ # proper [permissions](https://cloud.google.com/identity-platform/docs/access-
3139
+ # control).
3140
+ # Corresponds to the JSON property `disabled`
3141
+ # @return [Boolean]
3142
+ attr_accessor :disabled
3143
+ alias_method :disabled?, :disabled
3144
+
3145
+ # The display name of the user to be created.
3146
+ # Corresponds to the JSON property `displayName`
3147
+ # @return [String]
3148
+ attr_accessor :display_name
3149
+
3150
+ # The email to assign to the created user. The length of the email should be
3151
+ # less than 256 characters and in the format of `name@domain.tld`. The email
3152
+ # should also match the [RFC 822](https://tools.ietf.org/html/rfc822) addr-spec
3153
+ # production. An anonymous user will be created if not provided.
3154
+ # Corresponds to the JSON property `email`
3155
+ # @return [String]
3156
+ attr_accessor :email
3157
+
3158
+ # Whether the user's email is verified. Specifying this field requires a Google
3159
+ # OAuth 2.0 credential with the proper [permissions](https://cloud.google.com/
3160
+ # identity-platform/docs/access-control).
3161
+ # Corresponds to the JSON property `emailVerified`
3162
+ # @return [Boolean]
3163
+ attr_accessor :email_verified
3164
+ alias_method :email_verified?, :email_verified
3165
+
3166
+ # A valid ID token for an Identity Platform user. If set, this request will link
3167
+ # the authentication credential to the user represented by this ID token. For a
3168
+ # non-admin request, both the `email` and `password` fields must be set. For an
3169
+ # admin request, `local_id` must not be set.
3170
+ # Corresponds to the JSON property `idToken`
3171
+ # @return [String]
3172
+ attr_accessor :id_token
3173
+
3174
+ #
3175
+ # Corresponds to the JSON property `instanceId`
3176
+ # @return [String]
3177
+ attr_accessor :instance_id
3178
+
3179
+ # The ID of the user to create. The ID must be unique within the project that
3180
+ # the user is being created under. Specifying this field requires a Google OAuth
3181
+ # 2.0 credential with the proper [permissions](https://cloud.google.com/identity-
3182
+ # platform/docs/access-control).
3183
+ # Corresponds to the JSON property `localId`
3184
+ # @return [String]
3185
+ attr_accessor :local_id
3186
+
3187
+ # The multi-factor authentication providers for the user to create.
3188
+ # Corresponds to the JSON property `mfaInfo`
3189
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaFactor>]
3190
+ attr_accessor :mfa_info
3191
+
3192
+ # The password to assign to the created user. The password must be be at least 6
3193
+ # characters long. If set, the `email` field must also be set.
3194
+ # Corresponds to the JSON property `password`
3195
+ # @return [String]
3196
+ attr_accessor :password
3197
+
3198
+ # The phone number of the user to create. Specifying this field requires a
3199
+ # Google OAuth 2.0 credential with the proper [permissions](https://cloud.google.
3200
+ # com/identity-platform/docs/access-control).
3201
+ # Corresponds to the JSON property `phoneNumber`
3202
+ # @return [String]
3203
+ attr_accessor :phone_number
3204
+
3205
+ # The profile photo url of the user to create.
3206
+ # Corresponds to the JSON property `photoUrl`
3207
+ # @return [String]
3208
+ attr_accessor :photo_url
3209
+
3210
+ # The project ID of the project which the user should belong to. Specifying this
3211
+ # field requires a Google OAuth 2.0 credential with the proper [permissions](
3212
+ # https://cloud.google.com/identity-platform/docs/access-control). If this is
3213
+ # not set, the target project is inferred from the scope associated to the
3214
+ # Bearer access token.
3215
+ # Corresponds to the JSON property `targetProjectId`
3216
+ # @return [String]
3217
+ attr_accessor :target_project_id
3218
+
3219
+ # The ID of the Identity Platform tenant to create a user under. If not set, the
3220
+ # user will be created under the default Identity Platform project.
3221
+ # Corresponds to the JSON property `tenantId`
3222
+ # @return [String]
3223
+ attr_accessor :tenant_id
3224
+
3225
+ def initialize(**args)
3226
+ update!(**args)
3227
+ end
3228
+
3229
+ # Update properties of this object
3230
+ def update!(**args)
3231
+ @captcha_challenge = args[:captcha_challenge] if args.key?(:captcha_challenge)
3232
+ @captcha_response = args[:captcha_response] if args.key?(:captcha_response)
3233
+ @disabled = args[:disabled] if args.key?(:disabled)
3234
+ @display_name = args[:display_name] if args.key?(:display_name)
3235
+ @email = args[:email] if args.key?(:email)
3236
+ @email_verified = args[:email_verified] if args.key?(:email_verified)
3237
+ @id_token = args[:id_token] if args.key?(:id_token)
3238
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
3239
+ @local_id = args[:local_id] if args.key?(:local_id)
3240
+ @mfa_info = args[:mfa_info] if args.key?(:mfa_info)
3241
+ @password = args[:password] if args.key?(:password)
3242
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
3243
+ @photo_url = args[:photo_url] if args.key?(:photo_url)
3244
+ @target_project_id = args[:target_project_id] if args.key?(:target_project_id)
3245
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
3246
+ end
3247
+ end
3248
+
3249
+ # Response message for SignUp.
3250
+ class GoogleCloudIdentitytoolkitV1SignUpResponse
3251
+ include Google::Apis::Core::Hashable
3252
+
3253
+ # The created user's display name.
3254
+ # Corresponds to the JSON property `displayName`
3255
+ # @return [String]
3256
+ attr_accessor :display_name
3257
+
3258
+ # The created user's email.
3259
+ # Corresponds to the JSON property `email`
3260
+ # @return [String]
3261
+ attr_accessor :email
3262
+
3263
+ # The number of seconds until the ID token expires.
3264
+ # Corresponds to the JSON property `expiresIn`
3265
+ # @return [Fixnum]
3266
+ attr_accessor :expires_in
3267
+
3268
+ # An Identity Platform ID token for the created user. This field is only set for
3269
+ # non-admin requests.
3270
+ # Corresponds to the JSON property `idToken`
3271
+ # @return [String]
3272
+ attr_accessor :id_token
3273
+
3274
+ #
3275
+ # Corresponds to the JSON property `kind`
3276
+ # @return [String]
3277
+ attr_accessor :kind
3278
+
3279
+ # The ID of the created user. Always present in the response.
3280
+ # Corresponds to the JSON property `localId`
3281
+ # @return [String]
3282
+ attr_accessor :local_id
3283
+
3284
+ # An Identity Platform refresh token for the created user. This field is only
3285
+ # set for non-admin requests.
3286
+ # Corresponds to the JSON property `refreshToken`
3287
+ # @return [String]
3288
+ attr_accessor :refresh_token
3289
+
3290
+ def initialize(**args)
3291
+ update!(**args)
3292
+ end
3293
+
3294
+ # Update properties of this object
3295
+ def update!(**args)
3296
+ @display_name = args[:display_name] if args.key?(:display_name)
3297
+ @email = args[:email] if args.key?(:email)
3298
+ @expires_in = args[:expires_in] if args.key?(:expires_in)
3299
+ @id_token = args[:id_token] if args.key?(:id_token)
3300
+ @kind = args[:kind] if args.key?(:kind)
3301
+ @local_id = args[:local_id] if args.key?(:local_id)
3302
+ @refresh_token = args[:refresh_token] if args.key?(:refresh_token)
3303
+ end
3304
+ end
3305
+
3306
+ # Query conditions used to filter results.
3307
+ class GoogleCloudIdentitytoolkitV1SqlExpression
3308
+ include Google::Apis::Core::Hashable
3309
+
3310
+ # A case insensitive string that the account's email should match. Only one of `
3311
+ # email`, `phone_number`, or `user_id` should be specified in a SqlExpression.
3312
+ # If more than one is specified, only the first (in that order) will be applied.
3313
+ # Corresponds to the JSON property `email`
3314
+ # @return [String]
3315
+ attr_accessor :email
3316
+
3317
+ # A string that the account's phone number should match. Only one of `email`, `
3318
+ # phone_number`, or `user_id` should be specified in a SqlExpression. If more
3319
+ # than one is specified, only the first (in that order) will be applied.
3320
+ # Corresponds to the JSON property `phoneNumber`
3321
+ # @return [String]
3322
+ attr_accessor :phone_number
3323
+
3324
+ # A string that the account's local ID should match. Only one of `email`, `
3325
+ # phone_number`, or `user_id` should be specified in a SqlExpression If more
3326
+ # than one is specified, only the first (in that order) will be applied.
3327
+ # Corresponds to the JSON property `userId`
3328
+ # @return [String]
3329
+ attr_accessor :user_id
3330
+
3331
+ def initialize(**args)
3332
+ update!(**args)
3333
+ end
3334
+
3335
+ # Update properties of this object
3336
+ def update!(**args)
3337
+ @email = args[:email] if args.key?(:email)
3338
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
3339
+ @user_id = args[:user_id] if args.key?(:user_id)
3340
+ end
3341
+ end
3342
+
3343
+ # Request message for UploadAccount.
3344
+ class GoogleCloudIdentitytoolkitV1UploadAccountRequest
3345
+ include Google::Apis::Core::Hashable
3346
+
3347
+ # Whether to overwrite an existing account in Identity Platform with a matching `
3348
+ # local_id` in the request. If true, the existing account will be overwritten.
3349
+ # If false, an error will be returned.
3350
+ # Corresponds to the JSON property `allowOverwrite`
3351
+ # @return [Boolean]
3352
+ attr_accessor :allow_overwrite
3353
+ alias_method :allow_overwrite?, :allow_overwrite
3354
+
3355
+ # The parameters for Argon2 hashing algorithm.
3356
+ # Corresponds to the JSON property `argon2Parameters`
3357
+ # @return [Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1Argon2Parameters]
3358
+ attr_accessor :argon2_parameters
3359
+
3360
+ # The block size parameter used by the STANDARD_SCRYPT hashing function. This
3361
+ # parameter, along with parallelization and cpu_mem_cost help tune the resources
3362
+ # needed to hash a password, and should be tuned as processor speeds and memory
3363
+ # technologies advance.
3364
+ # Corresponds to the JSON property `blockSize`
3365
+ # @return [Fixnum]
3366
+ attr_accessor :block_size
3367
+
3368
+ # The CPU memory cost parameter to be used by the STANDARD_SCRYPT hashing
3369
+ # function. This parameter, along with block_size and cpu_mem_cost help tune the
3370
+ # resources needed to hash a password, and should be tuned as processor speeds
3371
+ # and memory technologies advance.
3372
+ # Corresponds to the JSON property `cpuMemCost`
3373
+ # @return [Fixnum]
3374
+ attr_accessor :cpu_mem_cost
3375
+
3376
+ #
3377
+ # Corresponds to the JSON property `delegatedProjectNumber`
3378
+ # @return [Fixnum]
3379
+ attr_accessor :delegated_project_number
3380
+
3381
+ # The desired key length for the STANDARD_SCRYPT hashing function. Must be at
3382
+ # least 1.
3383
+ # Corresponds to the JSON property `dkLen`
3384
+ # @return [Fixnum]
3385
+ attr_accessor :dk_len
3386
+
3387
+ # Required. The hashing function used to hash the account passwords. Must be one
3388
+ # of the following: * HMAC_SHA256 * HMAC_SHA1 * HMAC_MD5 * SCRYPT * PBKDF_SHA1 *
3389
+ # MD5 * HMAC_SHA512 * SHA1 * BCRYPT * PBKDF2_SHA256 * SHA256 * SHA512 *
3390
+ # STANDARD_SCRYPT * ARGON2
3391
+ # Corresponds to the JSON property `hashAlgorithm`
3392
+ # @return [String]
3393
+ attr_accessor :hash_algorithm
3394
+
3395
+ # Memory cost for hash calculation. Only required when the hashing function is
3396
+ # SCRYPT.
3397
+ # Corresponds to the JSON property `memoryCost`
3398
+ # @return [Fixnum]
3399
+ attr_accessor :memory_cost
3400
+
3401
+ # The parallelization cost parameter to be used by the STANDARD_SCRYPT hashing
3402
+ # function. This parameter, along with block_size and cpu_mem_cost help tune the
3403
+ # resources needed to hash a password, and should be tuned as processor speeds
3404
+ # and memory technologies advance.
3405
+ # Corresponds to the JSON property `parallelization`
3406
+ # @return [Fixnum]
3407
+ attr_accessor :parallelization
3408
+
3409
+ # Password and salt order when verify password.
3410
+ # Corresponds to the JSON property `passwordHashOrder`
3411
+ # @return [String]
3412
+ attr_accessor :password_hash_order
3413
+
3414
+ # The number of rounds used for hash calculation. Only required for the
3415
+ # following hashing functions: * MD5 * SHA1 * SHA256 * SHA512 * PBKDF_SHA1 *
3416
+ # PBKDF2_SHA256 * SCRYPT
3417
+ # Corresponds to the JSON property `rounds`
3418
+ # @return [Fixnum]
3419
+ attr_accessor :rounds
3420
+
3421
+ # One or more bytes to be inserted between the salt and plain text password. For
3422
+ # stronger security, this should be a single non-printable character.
3423
+ # Corresponds to the JSON property `saltSeparator`
3424
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
3425
+ # @return [String]
3426
+ attr_accessor :salt_separator
3427
+
3428
+ # If true, the service will do the following list of checks before an account is
3429
+ # uploaded: * Duplicate emails * Duplicate federated IDs * Federated ID provider
3430
+ # validation If the duplication exists within the list of accounts to be
3431
+ # uploaded, it will prevent the entire list from being uploaded. If the email or
3432
+ # federated ID is a duplicate of a user already within the project/tenant, the
3433
+ # account will not be uploaded, but the rest of the accounts will be unaffected.
3434
+ # If false, these checks will be skipped.
3435
+ # Corresponds to the JSON property `sanityCheck`
3436
+ # @return [Boolean]
3437
+ attr_accessor :sanity_check
3438
+ alias_method :sanity_check?, :sanity_check
3439
+
3440
+ # The signer key used to hash the password. Required for the following hashing
3441
+ # functions: * SCRYPT, * HMAC_MD5, * HMAC_SHA1, * HMAC_SHA256, * HMAC_SHA512
3442
+ # Corresponds to the JSON property `signerKey`
3443
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
3444
+ # @return [String]
3445
+ attr_accessor :signer_key
3446
+
3447
+ # The ID of the Identity Platform tenant the account belongs to.
3448
+ # Corresponds to the JSON property `tenantId`
3449
+ # @return [String]
3450
+ attr_accessor :tenant_id
3451
+
3452
+ # A list of accounts to upload. `local_id` is required for each user; everything
3453
+ # else is optional.
3454
+ # Corresponds to the JSON property `users`
3455
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1UserInfo>]
3456
+ attr_accessor :users
3457
+
3458
+ def initialize(**args)
3459
+ update!(**args)
3460
+ end
3461
+
3462
+ # Update properties of this object
3463
+ def update!(**args)
3464
+ @allow_overwrite = args[:allow_overwrite] if args.key?(:allow_overwrite)
3465
+ @argon2_parameters = args[:argon2_parameters] if args.key?(:argon2_parameters)
3466
+ @block_size = args[:block_size] if args.key?(:block_size)
3467
+ @cpu_mem_cost = args[:cpu_mem_cost] if args.key?(:cpu_mem_cost)
3468
+ @delegated_project_number = args[:delegated_project_number] if args.key?(:delegated_project_number)
3469
+ @dk_len = args[:dk_len] if args.key?(:dk_len)
3470
+ @hash_algorithm = args[:hash_algorithm] if args.key?(:hash_algorithm)
3471
+ @memory_cost = args[:memory_cost] if args.key?(:memory_cost)
3472
+ @parallelization = args[:parallelization] if args.key?(:parallelization)
3473
+ @password_hash_order = args[:password_hash_order] if args.key?(:password_hash_order)
3474
+ @rounds = args[:rounds] if args.key?(:rounds)
3475
+ @salt_separator = args[:salt_separator] if args.key?(:salt_separator)
3476
+ @sanity_check = args[:sanity_check] if args.key?(:sanity_check)
3477
+ @signer_key = args[:signer_key] if args.key?(:signer_key)
3478
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
3479
+ @users = args[:users] if args.key?(:users)
3480
+ end
3481
+ end
3482
+
3483
+ # Response message for UploadAccount.
3484
+ class GoogleCloudIdentitytoolkitV1UploadAccountResponse
3485
+ include Google::Apis::Core::Hashable
3486
+
3487
+ # Detailed error info for accounts that cannot be uploaded.
3488
+ # Corresponds to the JSON property `error`
3489
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1ErrorInfo>]
3490
+ attr_accessor :error
3491
+
3492
+ #
3493
+ # Corresponds to the JSON property `kind`
3494
+ # @return [String]
3495
+ attr_accessor :kind
3496
+
3497
+ def initialize(**args)
3498
+ update!(**args)
3499
+ end
3500
+
3501
+ # Update properties of this object
3502
+ def update!(**args)
3503
+ @error = args[:error] if args.key?(:error)
3504
+ @kind = args[:kind] if args.key?(:kind)
3505
+ end
3506
+ end
3507
+
3508
+ # An Identity Platform account's information.
3509
+ class GoogleCloudIdentitytoolkitV1UserInfo
3510
+ include Google::Apis::Core::Hashable
3511
+
3512
+ # The time, in milliseconds from epoch, when the account was created.
3513
+ # Corresponds to the JSON property `createdAt`
3514
+ # @return [Fixnum]
3515
+ attr_accessor :created_at
3516
+
3517
+ # Custom claims to be added to any ID tokens minted for the account. Should be
3518
+ # at most 1,000 characters in length and in valid JSON format.
3519
+ # Corresponds to the JSON property `customAttributes`
3520
+ # @return [String]
3521
+ attr_accessor :custom_attributes
3522
+
3523
+ # Output only. Whether this account has been authenticated using
3524
+ # SignInWithCustomToken.
3525
+ # Corresponds to the JSON property `customAuth`
3526
+ # @return [Boolean]
3527
+ attr_accessor :custom_auth
3528
+ alias_method :custom_auth?, :custom_auth
3529
+
3530
+ # Output only. The date of birth set for the account. This account attribute is
3531
+ # not used by Identity Platform. It is available for informational purposes only.
3532
+ # Corresponds to the JSON property `dateOfBirth`
3533
+ # @return [String]
3534
+ attr_accessor :date_of_birth
3535
+
3536
+ # Whether the account is disabled. Disabled accounts are inaccessible except for
3537
+ # requests bearing a Google OAuth2 credential with proper permissions.
3538
+ # Corresponds to the JSON property `disabled`
3539
+ # @return [Boolean]
3540
+ attr_accessor :disabled
3541
+ alias_method :disabled?, :disabled
3542
+
3543
+ # The display name of the account. This account attribute is not used by
3544
+ # Identity Platform. It is available for informational purposes only.
3545
+ # Corresponds to the JSON property `displayName`
3546
+ # @return [String]
3547
+ attr_accessor :display_name
3548
+
3549
+ # The account's email address. The length of the email should be less than 256
3550
+ # characters and in the format of `name@domain.tld`. The email should also match
3551
+ # the [RFC 822](https://tools.ietf.org/html/rfc822) addr-spec.
3552
+ # Corresponds to the JSON property `email`
3553
+ # @return [String]
3554
+ attr_accessor :email
3555
+
3556
+ # Output only. Whether the account can authenticate with email link.
3557
+ # Corresponds to the JSON property `emailLinkSignin`
3558
+ # @return [Boolean]
3559
+ attr_accessor :email_link_signin
3560
+ alias_method :email_link_signin?, :email_link_signin
3561
+
3562
+ # Whether the account's email address has been verified.
3563
+ # Corresponds to the JSON property `emailVerified`
3564
+ # @return [Boolean]
3565
+ attr_accessor :email_verified
3566
+ alias_method :email_verified?, :email_verified
3567
+
3568
+ # The first email address associated with this account. The account's initial
3569
+ # email cannot be changed once set and is used to recover access to this account
3570
+ # if lost via the RECOVER_EMAIL flow in GetOobCode. Should match the [RFC 822](
3571
+ # https://tools.ietf.org/html/rfc822) addr-spec.
3572
+ # Corresponds to the JSON property `initialEmail`
3573
+ # @return [String]
3574
+ attr_accessor :initial_email
3575
+
3576
+ # Output only. The language preference of the account. This account attribute is
3577
+ # not used by Identity Platform. It is available for informational purposes only.
3578
+ # Corresponds to the JSON property `language`
3579
+ # @return [String]
3580
+ attr_accessor :language
3581
+
3582
+ # The last time, in milliseconds from epoch, this account was logged into.
3583
+ # Corresponds to the JSON property `lastLoginAt`
3584
+ # @return [Fixnum]
3585
+ attr_accessor :last_login_at
3586
+
3587
+ # Timestamp when an ID token was last minted for this account.
3588
+ # Corresponds to the JSON property `lastRefreshAt`
3589
+ # @return [String]
3590
+ attr_accessor :last_refresh_at
3591
+
3592
+ # Immutable. The unique ID of the account.
3593
+ # Corresponds to the JSON property `localId`
3594
+ # @return [String]
3595
+ attr_accessor :local_id
3596
+
3597
+ # Information on which multi-factor authentication providers are enabled for
3598
+ # this account.
3599
+ # Corresponds to the JSON property `mfaInfo`
3600
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1MfaEnrollment>]
3601
+ attr_accessor :mfa_info
3602
+
3603
+ # The account's hashed password. Only accessible by requests bearing a Google
3604
+ # OAuth2 credential with proper [permissions](https://cloud.google.com/identity-
3605
+ # platform/docs/access-control).
3606
+ # Corresponds to the JSON property `passwordHash`
3607
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
3608
+ # @return [String]
3609
+ attr_accessor :password_hash
3610
+
3611
+ # The timestamp, in milliseconds from the epoch of 1970-01-01T00:00:00Z, when
3612
+ # the account's password was last updated.
3613
+ # Corresponds to the JSON property `passwordUpdatedAt`
3614
+ # @return [Float]
3615
+ attr_accessor :password_updated_at
3616
+
3617
+ # The account's phone number.
3618
+ # Corresponds to the JSON property `phoneNumber`
3619
+ # @return [String]
3620
+ attr_accessor :phone_number
3621
+
3622
+ # The URL of the account's profile photo. This account attribute is not used by
3623
+ # Identity Platform. It is available for informational purposes only.
3624
+ # Corresponds to the JSON property `photoUrl`
3625
+ # @return [String]
3626
+ attr_accessor :photo_url
3627
+
3628
+ # Information about the user as provided by various Identity Providers.
3629
+ # Corresponds to the JSON property `providerUserInfo`
3630
+ # @return [Array<Google::Apis::IdentitytoolkitV1::GoogleCloudIdentitytoolkitV1ProviderUserInfo>]
3631
+ attr_accessor :provider_user_info
3632
+
3633
+ # Input only. Plain text password used to update a account's password. This
3634
+ # field is only ever used as input in a request. Identity Platform uses
3635
+ # cryptographically secure hashing when managing passwords and will never store
3636
+ # or transmit a user's password in plain text.
3637
+ # Corresponds to the JSON property `rawPassword`
3638
+ # @return [String]
3639
+ attr_accessor :raw_password
3640
+
3641
+ # The account's password salt. Only accessible by requests bearing a Google
3642
+ # OAuth2 credential with proper permissions.
3643
+ # Corresponds to the JSON property `salt`
3644
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
3645
+ # @return [String]
3646
+ attr_accessor :salt
3647
+
3648
+ # Output only. This account's screen name at Twitter or login name at GitHub.
3649
+ # Corresponds to the JSON property `screenName`
3650
+ # @return [String]
3651
+ attr_accessor :screen_name
3652
+
3653
+ # ID of the tenant this account belongs to. Only set if this account belongs to
3654
+ # a tenant.
3655
+ # Corresponds to the JSON property `tenantId`
3656
+ # @return [String]
3657
+ attr_accessor :tenant_id
3658
+
3659
+ # Output only. The time zone preference of the account. This account attribute
3660
+ # is not used by Identity Platform. It is available for informational purposes
3661
+ # only.
3662
+ # Corresponds to the JSON property `timeZone`
3663
+ # @return [String]
3664
+ attr_accessor :time_zone
3665
+
3666
+ # Oldest timestamp, in seconds since epoch, that an ID token should be
3667
+ # considered valid. All ID tokens issued before this time are considered invalid.
3668
+ # Corresponds to the JSON property `validSince`
3669
+ # @return [Fixnum]
3670
+ attr_accessor :valid_since
3671
+
3672
+ # The version of the account's password. Only accessible by requests bearing a
3673
+ # Google OAuth2 credential with proper permissions.
3674
+ # Corresponds to the JSON property `version`
3675
+ # @return [Fixnum]
3676
+ attr_accessor :version
3677
+
3678
+ def initialize(**args)
3679
+ update!(**args)
3680
+ end
3681
+
3682
+ # Update properties of this object
3683
+ def update!(**args)
3684
+ @created_at = args[:created_at] if args.key?(:created_at)
3685
+ @custom_attributes = args[:custom_attributes] if args.key?(:custom_attributes)
3686
+ @custom_auth = args[:custom_auth] if args.key?(:custom_auth)
3687
+ @date_of_birth = args[:date_of_birth] if args.key?(:date_of_birth)
3688
+ @disabled = args[:disabled] if args.key?(:disabled)
3689
+ @display_name = args[:display_name] if args.key?(:display_name)
3690
+ @email = args[:email] if args.key?(:email)
3691
+ @email_link_signin = args[:email_link_signin] if args.key?(:email_link_signin)
3692
+ @email_verified = args[:email_verified] if args.key?(:email_verified)
3693
+ @initial_email = args[:initial_email] if args.key?(:initial_email)
3694
+ @language = args[:language] if args.key?(:language)
3695
+ @last_login_at = args[:last_login_at] if args.key?(:last_login_at)
3696
+ @last_refresh_at = args[:last_refresh_at] if args.key?(:last_refresh_at)
3697
+ @local_id = args[:local_id] if args.key?(:local_id)
3698
+ @mfa_info = args[:mfa_info] if args.key?(:mfa_info)
3699
+ @password_hash = args[:password_hash] if args.key?(:password_hash)
3700
+ @password_updated_at = args[:password_updated_at] if args.key?(:password_updated_at)
3701
+ @phone_number = args[:phone_number] if args.key?(:phone_number)
3702
+ @photo_url = args[:photo_url] if args.key?(:photo_url)
3703
+ @provider_user_info = args[:provider_user_info] if args.key?(:provider_user_info)
3704
+ @raw_password = args[:raw_password] if args.key?(:raw_password)
3705
+ @salt = args[:salt] if args.key?(:salt)
3706
+ @screen_name = args[:screen_name] if args.key?(:screen_name)
3707
+ @tenant_id = args[:tenant_id] if args.key?(:tenant_id)
3708
+ @time_zone = args[:time_zone] if args.key?(:time_zone)
3709
+ @valid_since = args[:valid_since] if args.key?(:valid_since)
3710
+ @version = args[:version] if args.key?(:version)
3711
+ end
3712
+ end
3713
+
3714
+ # Request message for VerifyIosClient
3715
+ class GoogleCloudIdentitytoolkitV1VerifyIosClientRequest
3716
+ include Google::Apis::Core::Hashable
3717
+
3718
+ # A device token that the iOS client gets after registering to APNs (Apple Push
3719
+ # Notification service).
3720
+ # Corresponds to the JSON property `appToken`
3721
+ # @return [String]
3722
+ attr_accessor :app_token
3723
+
3724
+ # Whether the app token is in the iOS sandbox. If false, the app token is in the
3725
+ # production environment.
3726
+ # Corresponds to the JSON property `isSandbox`
3727
+ # @return [Boolean]
3728
+ attr_accessor :is_sandbox
3729
+ alias_method :is_sandbox?, :is_sandbox
3730
+
3731
+ def initialize(**args)
3732
+ update!(**args)
3733
+ end
3734
+
3735
+ # Update properties of this object
3736
+ def update!(**args)
3737
+ @app_token = args[:app_token] if args.key?(:app_token)
3738
+ @is_sandbox = args[:is_sandbox] if args.key?(:is_sandbox)
3739
+ end
3740
+ end
3741
+
3742
+ # Response message for VerifyIosClient.
3743
+ class GoogleCloudIdentitytoolkitV1VerifyIosClientResponse
3744
+ include Google::Apis::Core::Hashable
3745
+
3746
+ # Receipt of successful app token validation.
3747
+ # Corresponds to the JSON property `receipt`
3748
+ # @return [String]
3749
+ attr_accessor :receipt
3750
+
3751
+ # Suggested time that the client should wait in seconds for delivery of the push
3752
+ # notification.
3753
+ # Corresponds to the JSON property `suggestedTimeout`
3754
+ # @return [Fixnum]
3755
+ attr_accessor :suggested_timeout
3756
+
3757
+ def initialize(**args)
3758
+ update!(**args)
3759
+ end
3760
+
3761
+ # Update properties of this object
3762
+ def update!(**args)
3763
+ @receipt = args[:receipt] if args.key?(:receipt)
3764
+ @suggested_timeout = args[:suggested_timeout] if args.key?(:suggested_timeout)
3765
+ end
3766
+ end
3767
+ end
3768
+ end
3769
+ end