passageidentity 0.7.1 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/openapi_client/api/users_api.rb +18 -18
- data/lib/openapi_client/models/create_magic_link_request.rb +21 -2
- data/lib/openapi_client/models/{create_user_request.rb → create_user_args.rb} +3 -3
- data/lib/openapi_client/models/magic_link.rb +1 -0
- data/lib/openapi_client/models/{theme_type.rb → magic_link_language.rb} +11 -7
- data/lib/openapi_client/models/{user_info.rb → passage_user.rb} +3 -3
- data/lib/openapi_client/models/{update_user_request.rb → update_user_args.rb} +3 -3
- data/lib/openapi_client/models/user_response.rb +1 -1
- data/lib/openapi_client.rb +4 -19
- data/lib/passageidentity/auth.rb +43 -156
- data/lib/passageidentity/client.rb +16 -96
- data/lib/passageidentity/user.rb +246 -0
- data/lib/passageidentity/version.rb +1 -1
- metadata +38 -36
- data/lib/models/update_magic_link_auth_method.rb +0 -276
- data/lib/models/update_otp_auth_method.rb +0 -276
- data/lib/models/update_passkeys_auth_method.rb +0 -216
- data/lib/openapi_client/api/apps_api.rb +0 -85
- data/lib/openapi_client/models/app_info.rb +0 -886
- data/lib/openapi_client/models/app_response.rb +0 -221
- data/lib/openapi_client/models/auth_methods.rb +0 -254
- data/lib/openapi_client/models/element_customization.rb +0 -457
- data/lib/openapi_client/models/font_family.rb +0 -58
- data/lib/openapi_client/models/layout_config.rb +0 -285
- data/lib/openapi_client/models/layouts.rb +0 -241
- data/lib/openapi_client/models/magic_link_auth_method.rb +0 -295
- data/lib/openapi_client/models/otp_auth_method.rb +0 -295
- data/lib/openapi_client/models/passkeys_auth_method.rb +0 -221
- data/lib/openapi_client/models/technologies.rb +0 -46
- data/lib/openapi_client/models/ttl_display_unit.rb +0 -42
- data/lib/openapi_client/models/user_metadata_field.rb +0 -323
- data/lib/openapi_client/models/user_metadata_field_type.rb +0 -44
- data/lib/passageidentity/user_api.rb +0 -218
@@ -1,886 +0,0 @@
|
|
1
|
-
=begin
|
2
|
-
#Passage Management API
|
3
|
-
|
4
|
-
#Passage's management API to manage your Passage apps and users.
|
5
|
-
|
6
|
-
The version of the OpenAPI document: 1
|
7
|
-
Contact: support@passage.id
|
8
|
-
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.11.0-SNAPSHOT
|
10
|
-
|
11
|
-
=end
|
12
|
-
|
13
|
-
require 'date'
|
14
|
-
require 'time'
|
15
|
-
|
16
|
-
module OpenapiClient
|
17
|
-
class AppInfo
|
18
|
-
attr_accessor :additional_auth_origins
|
19
|
-
|
20
|
-
# The valid URLs where users can be redirected after authentication.
|
21
|
-
attr_accessor :allowed_callback_urls
|
22
|
-
|
23
|
-
attr_accessor :allowed_identifier
|
24
|
-
|
25
|
-
# The valid URLs where users can be redirected after logging out.
|
26
|
-
attr_accessor :allowed_logout_urls
|
27
|
-
|
28
|
-
# A route within your application that redirects to the Authorization URL endpoint.
|
29
|
-
attr_accessor :application_login_uri
|
30
|
-
|
31
|
-
# Deprecated Property. Please refer to `auth_methods` to view settings for individual authentication methods.
|
32
|
-
attr_accessor :auth_fallback_method
|
33
|
-
|
34
|
-
# Deprecated Property. Please refer to `auth_methods` to view settings for individual authentication methods.
|
35
|
-
attr_accessor :auth_fallback_method_ttl
|
36
|
-
|
37
|
-
attr_accessor :auth_methods
|
38
|
-
|
39
|
-
attr_accessor :auth_origin
|
40
|
-
|
41
|
-
# Deprecated Property. Please use `hosted_theme` to set hosted page theming instead.
|
42
|
-
attr_accessor :auto_theme_enabled
|
43
|
-
|
44
|
-
attr_accessor :created_at
|
45
|
-
|
46
|
-
attr_accessor :default_language
|
47
|
-
|
48
|
-
attr_accessor :id
|
49
|
-
|
50
|
-
attr_accessor :layouts
|
51
|
-
|
52
|
-
attr_accessor :login_url
|
53
|
-
|
54
|
-
attr_accessor :light_logo_url
|
55
|
-
|
56
|
-
attr_accessor :dark_logo_url
|
57
|
-
|
58
|
-
attr_accessor :name
|
59
|
-
|
60
|
-
# whether or not the app's login page is hosted by Passage
|
61
|
-
attr_accessor :hosted
|
62
|
-
|
63
|
-
# the subdomain of the app's hosted login page
|
64
|
-
attr_accessor :hosted_subdomain
|
65
|
-
|
66
|
-
attr_accessor :hosted_theme
|
67
|
-
|
68
|
-
attr_accessor :id_token_lifetime
|
69
|
-
|
70
|
-
attr_accessor :passage_branding
|
71
|
-
|
72
|
-
attr_accessor :profile_management
|
73
|
-
|
74
|
-
attr_accessor :public_signup
|
75
|
-
|
76
|
-
attr_accessor :redirect_url
|
77
|
-
|
78
|
-
attr_accessor :refresh_absolute_lifetime
|
79
|
-
|
80
|
-
attr_accessor :refresh_enabled
|
81
|
-
|
82
|
-
attr_accessor :refresh_inactivity_lifetime
|
83
|
-
|
84
|
-
attr_accessor :require_email_verification
|
85
|
-
|
86
|
-
attr_accessor :require_identifier_verification
|
87
|
-
|
88
|
-
attr_accessor :required_identifier
|
89
|
-
|
90
|
-
attr_accessor :role
|
91
|
-
|
92
|
-
attr_accessor :rsa_public_key
|
93
|
-
|
94
|
-
# can only be retrieved by an app admin
|
95
|
-
attr_accessor :secret
|
96
|
-
|
97
|
-
attr_accessor :session_timeout_length
|
98
|
-
|
99
|
-
attr_accessor :type
|
100
|
-
|
101
|
-
attr_accessor :user_metadata_schema
|
102
|
-
|
103
|
-
attr_accessor :technologies
|
104
|
-
|
105
|
-
attr_accessor :element_customization
|
106
|
-
|
107
|
-
attr_accessor :element_customization_dark
|
108
|
-
|
109
|
-
class EnumAttributeValidator
|
110
|
-
attr_reader :datatype
|
111
|
-
attr_reader :allowable_values
|
112
|
-
|
113
|
-
def initialize(datatype, allowable_values)
|
114
|
-
@allowable_values = allowable_values.map do |value|
|
115
|
-
case datatype.to_s
|
116
|
-
when /Integer/i
|
117
|
-
value.to_i
|
118
|
-
when /Float/i
|
119
|
-
value.to_f
|
120
|
-
else
|
121
|
-
value
|
122
|
-
end
|
123
|
-
end
|
124
|
-
end
|
125
|
-
|
126
|
-
def valid?(value)
|
127
|
-
!value || allowable_values.include?(value)
|
128
|
-
end
|
129
|
-
end
|
130
|
-
|
131
|
-
# Attribute mapping from ruby-style variable name to JSON key.
|
132
|
-
def self.attribute_map
|
133
|
-
{
|
134
|
-
:'additional_auth_origins' => :'additional_auth_origins',
|
135
|
-
:'allowed_callback_urls' => :'allowed_callback_urls',
|
136
|
-
:'allowed_identifier' => :'allowed_identifier',
|
137
|
-
:'allowed_logout_urls' => :'allowed_logout_urls',
|
138
|
-
:'application_login_uri' => :'application_login_uri',
|
139
|
-
:'auth_fallback_method' => :'auth_fallback_method',
|
140
|
-
:'auth_fallback_method_ttl' => :'auth_fallback_method_ttl',
|
141
|
-
:'auth_methods' => :'auth_methods',
|
142
|
-
:'auth_origin' => :'auth_origin',
|
143
|
-
:'auto_theme_enabled' => :'auto_theme_enabled',
|
144
|
-
:'created_at' => :'created_at',
|
145
|
-
:'default_language' => :'default_language',
|
146
|
-
:'id' => :'id',
|
147
|
-
:'layouts' => :'layouts',
|
148
|
-
:'login_url' => :'login_url',
|
149
|
-
:'light_logo_url' => :'light_logo_url',
|
150
|
-
:'dark_logo_url' => :'dark_logo_url',
|
151
|
-
:'name' => :'name',
|
152
|
-
:'hosted' => :'hosted',
|
153
|
-
:'hosted_subdomain' => :'hosted_subdomain',
|
154
|
-
:'hosted_theme' => :'hosted_theme',
|
155
|
-
:'id_token_lifetime' => :'id_token_lifetime',
|
156
|
-
:'passage_branding' => :'passage_branding',
|
157
|
-
:'profile_management' => :'profile_management',
|
158
|
-
:'public_signup' => :'public_signup',
|
159
|
-
:'redirect_url' => :'redirect_url',
|
160
|
-
:'refresh_absolute_lifetime' => :'refresh_absolute_lifetime',
|
161
|
-
:'refresh_enabled' => :'refresh_enabled',
|
162
|
-
:'refresh_inactivity_lifetime' => :'refresh_inactivity_lifetime',
|
163
|
-
:'require_email_verification' => :'require_email_verification',
|
164
|
-
:'require_identifier_verification' => :'require_identifier_verification',
|
165
|
-
:'required_identifier' => :'required_identifier',
|
166
|
-
:'role' => :'role',
|
167
|
-
:'rsa_public_key' => :'rsa_public_key',
|
168
|
-
:'secret' => :'secret',
|
169
|
-
:'session_timeout_length' => :'session_timeout_length',
|
170
|
-
:'type' => :'type',
|
171
|
-
:'user_metadata_schema' => :'user_metadata_schema',
|
172
|
-
:'technologies' => :'technologies',
|
173
|
-
:'element_customization' => :'element_customization',
|
174
|
-
:'element_customization_dark' => :'element_customization_dark'
|
175
|
-
}
|
176
|
-
end
|
177
|
-
|
178
|
-
# Returns all the JSON keys this model knows about
|
179
|
-
def self.acceptable_attributes
|
180
|
-
attribute_map.values
|
181
|
-
end
|
182
|
-
|
183
|
-
# Attribute type mapping.
|
184
|
-
def self.openapi_types
|
185
|
-
{
|
186
|
-
:'additional_auth_origins' => :'Array<String>',
|
187
|
-
:'allowed_callback_urls' => :'Array<String>',
|
188
|
-
:'allowed_identifier' => :'String',
|
189
|
-
:'allowed_logout_urls' => :'Array<String>',
|
190
|
-
:'application_login_uri' => :'String',
|
191
|
-
:'auth_fallback_method' => :'String',
|
192
|
-
:'auth_fallback_method_ttl' => :'Integer',
|
193
|
-
:'auth_methods' => :'AuthMethods',
|
194
|
-
:'auth_origin' => :'String',
|
195
|
-
:'auto_theme_enabled' => :'Boolean',
|
196
|
-
:'created_at' => :'Time',
|
197
|
-
:'default_language' => :'String',
|
198
|
-
:'id' => :'String',
|
199
|
-
:'layouts' => :'Layouts',
|
200
|
-
:'login_url' => :'String',
|
201
|
-
:'light_logo_url' => :'String',
|
202
|
-
:'dark_logo_url' => :'String',
|
203
|
-
:'name' => :'String',
|
204
|
-
:'hosted' => :'Boolean',
|
205
|
-
:'hosted_subdomain' => :'String',
|
206
|
-
:'hosted_theme' => :'ThemeType',
|
207
|
-
:'id_token_lifetime' => :'Integer',
|
208
|
-
:'passage_branding' => :'Boolean',
|
209
|
-
:'profile_management' => :'Boolean',
|
210
|
-
:'public_signup' => :'Boolean',
|
211
|
-
:'redirect_url' => :'String',
|
212
|
-
:'refresh_absolute_lifetime' => :'Integer',
|
213
|
-
:'refresh_enabled' => :'Boolean',
|
214
|
-
:'refresh_inactivity_lifetime' => :'Integer',
|
215
|
-
:'require_email_verification' => :'Boolean',
|
216
|
-
:'require_identifier_verification' => :'Boolean',
|
217
|
-
:'required_identifier' => :'String',
|
218
|
-
:'role' => :'String',
|
219
|
-
:'rsa_public_key' => :'String',
|
220
|
-
:'secret' => :'String',
|
221
|
-
:'session_timeout_length' => :'Integer',
|
222
|
-
:'type' => :'String',
|
223
|
-
:'user_metadata_schema' => :'Array<UserMetadataField>',
|
224
|
-
:'technologies' => :'Array<Technologies>',
|
225
|
-
:'element_customization' => :'ElementCustomization',
|
226
|
-
:'element_customization_dark' => :'ElementCustomization'
|
227
|
-
}
|
228
|
-
end
|
229
|
-
|
230
|
-
# List of attributes with nullable: true
|
231
|
-
def self.openapi_nullable
|
232
|
-
Set.new([
|
233
|
-
])
|
234
|
-
end
|
235
|
-
|
236
|
-
# Initializes the object
|
237
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
238
|
-
def initialize(attributes = {})
|
239
|
-
if (!attributes.is_a?(Hash))
|
240
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `OpenapiClient::AppInfo` initialize method"
|
241
|
-
end
|
242
|
-
|
243
|
-
# check to see if the attribute exists and convert string to symbol for hash key
|
244
|
-
attributes = attributes.each_with_object({}) { |(k, v), h|
|
245
|
-
if (!self.class.attribute_map.key?(k.to_sym))
|
246
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `OpenapiClient::AppInfo`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
247
|
-
end
|
248
|
-
h[k.to_sym] = v
|
249
|
-
}
|
250
|
-
|
251
|
-
if attributes.key?(:'additional_auth_origins')
|
252
|
-
if (value = attributes[:'additional_auth_origins']).is_a?(Array)
|
253
|
-
self.additional_auth_origins = value
|
254
|
-
end
|
255
|
-
else
|
256
|
-
self.additional_auth_origins = nil
|
257
|
-
end
|
258
|
-
|
259
|
-
if attributes.key?(:'allowed_callback_urls')
|
260
|
-
if (value = attributes[:'allowed_callback_urls']).is_a?(Array)
|
261
|
-
self.allowed_callback_urls = value
|
262
|
-
end
|
263
|
-
else
|
264
|
-
self.allowed_callback_urls = nil
|
265
|
-
end
|
266
|
-
|
267
|
-
if attributes.key?(:'allowed_identifier')
|
268
|
-
self.allowed_identifier = attributes[:'allowed_identifier']
|
269
|
-
else
|
270
|
-
self.allowed_identifier = nil
|
271
|
-
end
|
272
|
-
|
273
|
-
if attributes.key?(:'allowed_logout_urls')
|
274
|
-
if (value = attributes[:'allowed_logout_urls']).is_a?(Array)
|
275
|
-
self.allowed_logout_urls = value
|
276
|
-
end
|
277
|
-
else
|
278
|
-
self.allowed_logout_urls = nil
|
279
|
-
end
|
280
|
-
|
281
|
-
if attributes.key?(:'application_login_uri')
|
282
|
-
self.application_login_uri = attributes[:'application_login_uri']
|
283
|
-
else
|
284
|
-
self.application_login_uri = nil
|
285
|
-
end
|
286
|
-
|
287
|
-
if attributes.key?(:'auth_fallback_method')
|
288
|
-
self.auth_fallback_method = attributes[:'auth_fallback_method']
|
289
|
-
else
|
290
|
-
self.auth_fallback_method = nil
|
291
|
-
end
|
292
|
-
|
293
|
-
if attributes.key?(:'auth_fallback_method_ttl')
|
294
|
-
self.auth_fallback_method_ttl = attributes[:'auth_fallback_method_ttl']
|
295
|
-
else
|
296
|
-
self.auth_fallback_method_ttl = nil
|
297
|
-
end
|
298
|
-
|
299
|
-
if attributes.key?(:'auth_methods')
|
300
|
-
self.auth_methods = attributes[:'auth_methods']
|
301
|
-
else
|
302
|
-
self.auth_methods = nil
|
303
|
-
end
|
304
|
-
|
305
|
-
if attributes.key?(:'auth_origin')
|
306
|
-
self.auth_origin = attributes[:'auth_origin']
|
307
|
-
else
|
308
|
-
self.auth_origin = nil
|
309
|
-
end
|
310
|
-
|
311
|
-
if attributes.key?(:'auto_theme_enabled')
|
312
|
-
self.auto_theme_enabled = attributes[:'auto_theme_enabled']
|
313
|
-
else
|
314
|
-
self.auto_theme_enabled = nil
|
315
|
-
end
|
316
|
-
|
317
|
-
if attributes.key?(:'created_at')
|
318
|
-
self.created_at = attributes[:'created_at']
|
319
|
-
else
|
320
|
-
self.created_at = nil
|
321
|
-
end
|
322
|
-
|
323
|
-
if attributes.key?(:'default_language')
|
324
|
-
self.default_language = attributes[:'default_language']
|
325
|
-
else
|
326
|
-
self.default_language = nil
|
327
|
-
end
|
328
|
-
|
329
|
-
if attributes.key?(:'id')
|
330
|
-
self.id = attributes[:'id']
|
331
|
-
else
|
332
|
-
self.id = nil
|
333
|
-
end
|
334
|
-
|
335
|
-
if attributes.key?(:'layouts')
|
336
|
-
self.layouts = attributes[:'layouts']
|
337
|
-
else
|
338
|
-
self.layouts = nil
|
339
|
-
end
|
340
|
-
|
341
|
-
if attributes.key?(:'login_url')
|
342
|
-
self.login_url = attributes[:'login_url']
|
343
|
-
else
|
344
|
-
self.login_url = nil
|
345
|
-
end
|
346
|
-
|
347
|
-
if attributes.key?(:'light_logo_url')
|
348
|
-
self.light_logo_url = attributes[:'light_logo_url']
|
349
|
-
end
|
350
|
-
|
351
|
-
if attributes.key?(:'dark_logo_url')
|
352
|
-
self.dark_logo_url = attributes[:'dark_logo_url']
|
353
|
-
end
|
354
|
-
|
355
|
-
if attributes.key?(:'name')
|
356
|
-
self.name = attributes[:'name']
|
357
|
-
else
|
358
|
-
self.name = nil
|
359
|
-
end
|
360
|
-
|
361
|
-
if attributes.key?(:'hosted')
|
362
|
-
self.hosted = attributes[:'hosted']
|
363
|
-
else
|
364
|
-
self.hosted = nil
|
365
|
-
end
|
366
|
-
|
367
|
-
if attributes.key?(:'hosted_subdomain')
|
368
|
-
self.hosted_subdomain = attributes[:'hosted_subdomain']
|
369
|
-
else
|
370
|
-
self.hosted_subdomain = nil
|
371
|
-
end
|
372
|
-
|
373
|
-
if attributes.key?(:'hosted_theme')
|
374
|
-
self.hosted_theme = attributes[:'hosted_theme']
|
375
|
-
else
|
376
|
-
self.hosted_theme = nil
|
377
|
-
end
|
378
|
-
|
379
|
-
if attributes.key?(:'id_token_lifetime')
|
380
|
-
self.id_token_lifetime = attributes[:'id_token_lifetime']
|
381
|
-
end
|
382
|
-
|
383
|
-
if attributes.key?(:'passage_branding')
|
384
|
-
self.passage_branding = attributes[:'passage_branding']
|
385
|
-
else
|
386
|
-
self.passage_branding = nil
|
387
|
-
end
|
388
|
-
|
389
|
-
if attributes.key?(:'profile_management')
|
390
|
-
self.profile_management = attributes[:'profile_management']
|
391
|
-
else
|
392
|
-
self.profile_management = nil
|
393
|
-
end
|
394
|
-
|
395
|
-
if attributes.key?(:'public_signup')
|
396
|
-
self.public_signup = attributes[:'public_signup']
|
397
|
-
else
|
398
|
-
self.public_signup = nil
|
399
|
-
end
|
400
|
-
|
401
|
-
if attributes.key?(:'redirect_url')
|
402
|
-
self.redirect_url = attributes[:'redirect_url']
|
403
|
-
else
|
404
|
-
self.redirect_url = nil
|
405
|
-
end
|
406
|
-
|
407
|
-
if attributes.key?(:'refresh_absolute_lifetime')
|
408
|
-
self.refresh_absolute_lifetime = attributes[:'refresh_absolute_lifetime']
|
409
|
-
else
|
410
|
-
self.refresh_absolute_lifetime = nil
|
411
|
-
end
|
412
|
-
|
413
|
-
if attributes.key?(:'refresh_enabled')
|
414
|
-
self.refresh_enabled = attributes[:'refresh_enabled']
|
415
|
-
else
|
416
|
-
self.refresh_enabled = nil
|
417
|
-
end
|
418
|
-
|
419
|
-
if attributes.key?(:'refresh_inactivity_lifetime')
|
420
|
-
self.refresh_inactivity_lifetime = attributes[:'refresh_inactivity_lifetime']
|
421
|
-
else
|
422
|
-
self.refresh_inactivity_lifetime = nil
|
423
|
-
end
|
424
|
-
|
425
|
-
if attributes.key?(:'require_email_verification')
|
426
|
-
self.require_email_verification = attributes[:'require_email_verification']
|
427
|
-
else
|
428
|
-
self.require_email_verification = nil
|
429
|
-
end
|
430
|
-
|
431
|
-
if attributes.key?(:'require_identifier_verification')
|
432
|
-
self.require_identifier_verification = attributes[:'require_identifier_verification']
|
433
|
-
else
|
434
|
-
self.require_identifier_verification = nil
|
435
|
-
end
|
436
|
-
|
437
|
-
if attributes.key?(:'required_identifier')
|
438
|
-
self.required_identifier = attributes[:'required_identifier']
|
439
|
-
else
|
440
|
-
self.required_identifier = nil
|
441
|
-
end
|
442
|
-
|
443
|
-
if attributes.key?(:'role')
|
444
|
-
self.role = attributes[:'role']
|
445
|
-
else
|
446
|
-
self.role = nil
|
447
|
-
end
|
448
|
-
|
449
|
-
if attributes.key?(:'rsa_public_key')
|
450
|
-
self.rsa_public_key = attributes[:'rsa_public_key']
|
451
|
-
else
|
452
|
-
self.rsa_public_key = nil
|
453
|
-
end
|
454
|
-
|
455
|
-
if attributes.key?(:'secret')
|
456
|
-
self.secret = attributes[:'secret']
|
457
|
-
end
|
458
|
-
|
459
|
-
if attributes.key?(:'session_timeout_length')
|
460
|
-
self.session_timeout_length = attributes[:'session_timeout_length']
|
461
|
-
else
|
462
|
-
self.session_timeout_length = nil
|
463
|
-
end
|
464
|
-
|
465
|
-
if attributes.key?(:'type')
|
466
|
-
self.type = attributes[:'type']
|
467
|
-
else
|
468
|
-
self.type = nil
|
469
|
-
end
|
470
|
-
|
471
|
-
if attributes.key?(:'user_metadata_schema')
|
472
|
-
if (value = attributes[:'user_metadata_schema']).is_a?(Array)
|
473
|
-
self.user_metadata_schema = value
|
474
|
-
end
|
475
|
-
else
|
476
|
-
self.user_metadata_schema = nil
|
477
|
-
end
|
478
|
-
|
479
|
-
if attributes.key?(:'technologies')
|
480
|
-
if (value = attributes[:'technologies']).is_a?(Array)
|
481
|
-
self.technologies = value
|
482
|
-
end
|
483
|
-
else
|
484
|
-
self.technologies = nil
|
485
|
-
end
|
486
|
-
|
487
|
-
if attributes.key?(:'element_customization')
|
488
|
-
self.element_customization = attributes[:'element_customization']
|
489
|
-
else
|
490
|
-
self.element_customization = nil
|
491
|
-
end
|
492
|
-
|
493
|
-
if attributes.key?(:'element_customization_dark')
|
494
|
-
self.element_customization_dark = attributes[:'element_customization_dark']
|
495
|
-
else
|
496
|
-
self.element_customization_dark = nil
|
497
|
-
end
|
498
|
-
end
|
499
|
-
|
500
|
-
# Show invalid properties with the reasons. Usually used together with valid?
|
501
|
-
# @return Array for valid properties with the reasons
|
502
|
-
def list_invalid_properties
|
503
|
-
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
504
|
-
invalid_properties = Array.new
|
505
|
-
if @additional_auth_origins.nil?
|
506
|
-
invalid_properties.push('invalid value for "additional_auth_origins", additional_auth_origins cannot be nil.')
|
507
|
-
end
|
508
|
-
|
509
|
-
if @allowed_callback_urls.nil?
|
510
|
-
invalid_properties.push('invalid value for "allowed_callback_urls", allowed_callback_urls cannot be nil.')
|
511
|
-
end
|
512
|
-
|
513
|
-
if @allowed_identifier.nil?
|
514
|
-
invalid_properties.push('invalid value for "allowed_identifier", allowed_identifier cannot be nil.')
|
515
|
-
end
|
516
|
-
|
517
|
-
if @allowed_logout_urls.nil?
|
518
|
-
invalid_properties.push('invalid value for "allowed_logout_urls", allowed_logout_urls cannot be nil.')
|
519
|
-
end
|
520
|
-
|
521
|
-
if @application_login_uri.nil?
|
522
|
-
invalid_properties.push('invalid value for "application_login_uri", application_login_uri cannot be nil.')
|
523
|
-
end
|
524
|
-
|
525
|
-
if @auth_fallback_method.nil?
|
526
|
-
invalid_properties.push('invalid value for "auth_fallback_method", auth_fallback_method cannot be nil.')
|
527
|
-
end
|
528
|
-
|
529
|
-
if @auth_fallback_method_ttl.nil?
|
530
|
-
invalid_properties.push('invalid value for "auth_fallback_method_ttl", auth_fallback_method_ttl cannot be nil.')
|
531
|
-
end
|
532
|
-
|
533
|
-
if @auth_methods.nil?
|
534
|
-
invalid_properties.push('invalid value for "auth_methods", auth_methods cannot be nil.')
|
535
|
-
end
|
536
|
-
|
537
|
-
if @auth_origin.nil?
|
538
|
-
invalid_properties.push('invalid value for "auth_origin", auth_origin cannot be nil.')
|
539
|
-
end
|
540
|
-
|
541
|
-
if @auto_theme_enabled.nil?
|
542
|
-
invalid_properties.push('invalid value for "auto_theme_enabled", auto_theme_enabled cannot be nil.')
|
543
|
-
end
|
544
|
-
|
545
|
-
if @created_at.nil?
|
546
|
-
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
547
|
-
end
|
548
|
-
|
549
|
-
if @default_language.nil?
|
550
|
-
invalid_properties.push('invalid value for "default_language", default_language cannot be nil.')
|
551
|
-
end
|
552
|
-
|
553
|
-
if @id.nil?
|
554
|
-
invalid_properties.push('invalid value for "id", id cannot be nil.')
|
555
|
-
end
|
556
|
-
|
557
|
-
if @layouts.nil?
|
558
|
-
invalid_properties.push('invalid value for "layouts", layouts cannot be nil.')
|
559
|
-
end
|
560
|
-
|
561
|
-
if @login_url.nil?
|
562
|
-
invalid_properties.push('invalid value for "login_url", login_url cannot be nil.')
|
563
|
-
end
|
564
|
-
|
565
|
-
if @name.nil?
|
566
|
-
invalid_properties.push('invalid value for "name", name cannot be nil.')
|
567
|
-
end
|
568
|
-
|
569
|
-
if @hosted.nil?
|
570
|
-
invalid_properties.push('invalid value for "hosted", hosted cannot be nil.')
|
571
|
-
end
|
572
|
-
|
573
|
-
if @hosted_subdomain.nil?
|
574
|
-
invalid_properties.push('invalid value for "hosted_subdomain", hosted_subdomain cannot be nil.')
|
575
|
-
end
|
576
|
-
|
577
|
-
if @hosted_theme.nil?
|
578
|
-
invalid_properties.push('invalid value for "hosted_theme", hosted_theme cannot be nil.')
|
579
|
-
end
|
580
|
-
|
581
|
-
if @passage_branding.nil?
|
582
|
-
invalid_properties.push('invalid value for "passage_branding", passage_branding cannot be nil.')
|
583
|
-
end
|
584
|
-
|
585
|
-
if @profile_management.nil?
|
586
|
-
invalid_properties.push('invalid value for "profile_management", profile_management cannot be nil.')
|
587
|
-
end
|
588
|
-
|
589
|
-
if @public_signup.nil?
|
590
|
-
invalid_properties.push('invalid value for "public_signup", public_signup cannot be nil.')
|
591
|
-
end
|
592
|
-
|
593
|
-
if @redirect_url.nil?
|
594
|
-
invalid_properties.push('invalid value for "redirect_url", redirect_url cannot be nil.')
|
595
|
-
end
|
596
|
-
|
597
|
-
if @refresh_absolute_lifetime.nil?
|
598
|
-
invalid_properties.push('invalid value for "refresh_absolute_lifetime", refresh_absolute_lifetime cannot be nil.')
|
599
|
-
end
|
600
|
-
|
601
|
-
if @refresh_enabled.nil?
|
602
|
-
invalid_properties.push('invalid value for "refresh_enabled", refresh_enabled cannot be nil.')
|
603
|
-
end
|
604
|
-
|
605
|
-
if @refresh_inactivity_lifetime.nil?
|
606
|
-
invalid_properties.push('invalid value for "refresh_inactivity_lifetime", refresh_inactivity_lifetime cannot be nil.')
|
607
|
-
end
|
608
|
-
|
609
|
-
if @require_email_verification.nil?
|
610
|
-
invalid_properties.push('invalid value for "require_email_verification", require_email_verification cannot be nil.')
|
611
|
-
end
|
612
|
-
|
613
|
-
if @require_identifier_verification.nil?
|
614
|
-
invalid_properties.push('invalid value for "require_identifier_verification", require_identifier_verification cannot be nil.')
|
615
|
-
end
|
616
|
-
|
617
|
-
if @required_identifier.nil?
|
618
|
-
invalid_properties.push('invalid value for "required_identifier", required_identifier cannot be nil.')
|
619
|
-
end
|
620
|
-
|
621
|
-
if @role.nil?
|
622
|
-
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
623
|
-
end
|
624
|
-
|
625
|
-
if @rsa_public_key.nil?
|
626
|
-
invalid_properties.push('invalid value for "rsa_public_key", rsa_public_key cannot be nil.')
|
627
|
-
end
|
628
|
-
|
629
|
-
if @session_timeout_length.nil?
|
630
|
-
invalid_properties.push('invalid value for "session_timeout_length", session_timeout_length cannot be nil.')
|
631
|
-
end
|
632
|
-
|
633
|
-
if @type.nil?
|
634
|
-
invalid_properties.push('invalid value for "type", type cannot be nil.')
|
635
|
-
end
|
636
|
-
|
637
|
-
if @user_metadata_schema.nil?
|
638
|
-
invalid_properties.push('invalid value for "user_metadata_schema", user_metadata_schema cannot be nil.')
|
639
|
-
end
|
640
|
-
|
641
|
-
if @technologies.nil?
|
642
|
-
invalid_properties.push('invalid value for "technologies", technologies cannot be nil.')
|
643
|
-
end
|
644
|
-
|
645
|
-
if @element_customization.nil?
|
646
|
-
invalid_properties.push('invalid value for "element_customization", element_customization cannot be nil.')
|
647
|
-
end
|
648
|
-
|
649
|
-
if @element_customization_dark.nil?
|
650
|
-
invalid_properties.push('invalid value for "element_customization_dark", element_customization_dark cannot be nil.')
|
651
|
-
end
|
652
|
-
|
653
|
-
invalid_properties
|
654
|
-
end
|
655
|
-
|
656
|
-
# Check to see if the all the properties in the model are valid
|
657
|
-
# @return true if the model is valid
|
658
|
-
def valid?
|
659
|
-
warn '[DEPRECATED] the `valid?` method is obsolete'
|
660
|
-
return false if @additional_auth_origins.nil?
|
661
|
-
return false if @allowed_callback_urls.nil?
|
662
|
-
return false if @allowed_identifier.nil?
|
663
|
-
return false if @allowed_logout_urls.nil?
|
664
|
-
return false if @application_login_uri.nil?
|
665
|
-
return false if @auth_fallback_method.nil?
|
666
|
-
return false if @auth_fallback_method_ttl.nil?
|
667
|
-
return false if @auth_methods.nil?
|
668
|
-
return false if @auth_origin.nil?
|
669
|
-
return false if @auto_theme_enabled.nil?
|
670
|
-
return false if @created_at.nil?
|
671
|
-
return false if @default_language.nil?
|
672
|
-
return false if @id.nil?
|
673
|
-
return false if @layouts.nil?
|
674
|
-
return false if @login_url.nil?
|
675
|
-
return false if @name.nil?
|
676
|
-
return false if @hosted.nil?
|
677
|
-
return false if @hosted_subdomain.nil?
|
678
|
-
return false if @hosted_theme.nil?
|
679
|
-
return false if @passage_branding.nil?
|
680
|
-
return false if @profile_management.nil?
|
681
|
-
return false if @public_signup.nil?
|
682
|
-
return false if @redirect_url.nil?
|
683
|
-
return false if @refresh_absolute_lifetime.nil?
|
684
|
-
return false if @refresh_enabled.nil?
|
685
|
-
return false if @refresh_inactivity_lifetime.nil?
|
686
|
-
return false if @require_email_verification.nil?
|
687
|
-
return false if @require_identifier_verification.nil?
|
688
|
-
return false if @required_identifier.nil?
|
689
|
-
return false if @role.nil?
|
690
|
-
return false if @rsa_public_key.nil?
|
691
|
-
return false if @session_timeout_length.nil?
|
692
|
-
return false if @type.nil?
|
693
|
-
type_validator = EnumAttributeValidator.new('String', ["complete", "flex"])
|
694
|
-
return false unless type_validator.valid?(@type)
|
695
|
-
return false if @user_metadata_schema.nil?
|
696
|
-
return false if @technologies.nil?
|
697
|
-
return false if @element_customization.nil?
|
698
|
-
return false if @element_customization_dark.nil?
|
699
|
-
true
|
700
|
-
end
|
701
|
-
|
702
|
-
# Custom attribute writer method checking allowed values (enum).
|
703
|
-
# @param [Object] type Object to be assigned
|
704
|
-
def type=(type)
|
705
|
-
validator = EnumAttributeValidator.new('String', ["complete", "flex"])
|
706
|
-
unless validator.valid?(type)
|
707
|
-
fail ArgumentError, "invalid value for \"type\", must be one of #{validator.allowable_values}."
|
708
|
-
end
|
709
|
-
@type = type
|
710
|
-
end
|
711
|
-
|
712
|
-
# Checks equality by comparing each attribute.
|
713
|
-
# @param [Object] Object to be compared
|
714
|
-
def ==(o)
|
715
|
-
return true if self.equal?(o)
|
716
|
-
self.class == o.class &&
|
717
|
-
additional_auth_origins == o.additional_auth_origins &&
|
718
|
-
allowed_callback_urls == o.allowed_callback_urls &&
|
719
|
-
allowed_identifier == o.allowed_identifier &&
|
720
|
-
allowed_logout_urls == o.allowed_logout_urls &&
|
721
|
-
application_login_uri == o.application_login_uri &&
|
722
|
-
auth_fallback_method == o.auth_fallback_method &&
|
723
|
-
auth_fallback_method_ttl == o.auth_fallback_method_ttl &&
|
724
|
-
auth_methods == o.auth_methods &&
|
725
|
-
auth_origin == o.auth_origin &&
|
726
|
-
auto_theme_enabled == o.auto_theme_enabled &&
|
727
|
-
created_at == o.created_at &&
|
728
|
-
default_language == o.default_language &&
|
729
|
-
id == o.id &&
|
730
|
-
layouts == o.layouts &&
|
731
|
-
login_url == o.login_url &&
|
732
|
-
light_logo_url == o.light_logo_url &&
|
733
|
-
dark_logo_url == o.dark_logo_url &&
|
734
|
-
name == o.name &&
|
735
|
-
hosted == o.hosted &&
|
736
|
-
hosted_subdomain == o.hosted_subdomain &&
|
737
|
-
hosted_theme == o.hosted_theme &&
|
738
|
-
id_token_lifetime == o.id_token_lifetime &&
|
739
|
-
passage_branding == o.passage_branding &&
|
740
|
-
profile_management == o.profile_management &&
|
741
|
-
public_signup == o.public_signup &&
|
742
|
-
redirect_url == o.redirect_url &&
|
743
|
-
refresh_absolute_lifetime == o.refresh_absolute_lifetime &&
|
744
|
-
refresh_enabled == o.refresh_enabled &&
|
745
|
-
refresh_inactivity_lifetime == o.refresh_inactivity_lifetime &&
|
746
|
-
require_email_verification == o.require_email_verification &&
|
747
|
-
require_identifier_verification == o.require_identifier_verification &&
|
748
|
-
required_identifier == o.required_identifier &&
|
749
|
-
role == o.role &&
|
750
|
-
rsa_public_key == o.rsa_public_key &&
|
751
|
-
secret == o.secret &&
|
752
|
-
session_timeout_length == o.session_timeout_length &&
|
753
|
-
type == o.type &&
|
754
|
-
user_metadata_schema == o.user_metadata_schema &&
|
755
|
-
technologies == o.technologies &&
|
756
|
-
element_customization == o.element_customization &&
|
757
|
-
element_customization_dark == o.element_customization_dark
|
758
|
-
end
|
759
|
-
|
760
|
-
# @see the `==` method
|
761
|
-
# @param [Object] Object to be compared
|
762
|
-
def eql?(o)
|
763
|
-
self == o
|
764
|
-
end
|
765
|
-
|
766
|
-
# Calculates hash code according to all attributes.
|
767
|
-
# @return [Integer] Hash code
|
768
|
-
def hash
|
769
|
-
[additional_auth_origins, allowed_callback_urls, allowed_identifier, allowed_logout_urls, application_login_uri, auth_fallback_method, auth_fallback_method_ttl, auth_methods, auth_origin, auto_theme_enabled, created_at, default_language, id, layouts, login_url, light_logo_url, dark_logo_url, name, hosted, hosted_subdomain, hosted_theme, id_token_lifetime, passage_branding, profile_management, public_signup, redirect_url, refresh_absolute_lifetime, refresh_enabled, refresh_inactivity_lifetime, require_email_verification, require_identifier_verification, required_identifier, role, rsa_public_key, secret, session_timeout_length, type, user_metadata_schema, technologies, element_customization, element_customization_dark].hash
|
770
|
-
end
|
771
|
-
|
772
|
-
# Builds the object from hash
|
773
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
774
|
-
# @return [Object] Returns the model itself
|
775
|
-
def self.build_from_hash(attributes)
|
776
|
-
return nil unless attributes.is_a?(Hash)
|
777
|
-
attributes = attributes.transform_keys(&:to_sym)
|
778
|
-
transformed_hash = {}
|
779
|
-
openapi_types.each_pair do |key, type|
|
780
|
-
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
781
|
-
transformed_hash["#{key}"] = nil
|
782
|
-
elsif type =~ /\AArray<(.*)>/i
|
783
|
-
# check to ensure the input is an array given that the attribute
|
784
|
-
# is documented as an array but the input is not
|
785
|
-
if attributes[attribute_map[key]].is_a?(Array)
|
786
|
-
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
787
|
-
end
|
788
|
-
elsif !attributes[attribute_map[key]].nil?
|
789
|
-
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
790
|
-
end
|
791
|
-
end
|
792
|
-
new(transformed_hash)
|
793
|
-
end
|
794
|
-
|
795
|
-
# Deserializes the data based on type
|
796
|
-
# @param string type Data type
|
797
|
-
# @param string value Value to be deserialized
|
798
|
-
# @return [Object] Deserialized data
|
799
|
-
def self._deserialize(type, value)
|
800
|
-
case type.to_sym
|
801
|
-
when :Time
|
802
|
-
Time.parse(value)
|
803
|
-
when :Date
|
804
|
-
Date.parse(value)
|
805
|
-
when :String
|
806
|
-
value.to_s
|
807
|
-
when :Integer
|
808
|
-
value.to_i
|
809
|
-
when :Float
|
810
|
-
value.to_f
|
811
|
-
when :Boolean
|
812
|
-
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
813
|
-
true
|
814
|
-
else
|
815
|
-
false
|
816
|
-
end
|
817
|
-
when :Object
|
818
|
-
# generic object (usually a Hash), return directly
|
819
|
-
value
|
820
|
-
when /\AArray<(?<inner_type>.+)>\z/
|
821
|
-
inner_type = Regexp.last_match[:inner_type]
|
822
|
-
value.map { |v| _deserialize(inner_type, v) }
|
823
|
-
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
824
|
-
k_type = Regexp.last_match[:k_type]
|
825
|
-
v_type = Regexp.last_match[:v_type]
|
826
|
-
{}.tap do |hash|
|
827
|
-
value.each do |k, v|
|
828
|
-
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
829
|
-
end
|
830
|
-
end
|
831
|
-
else # model
|
832
|
-
# models (e.g. Pet) or oneOf
|
833
|
-
klass = OpenapiClient.const_get(type)
|
834
|
-
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
835
|
-
end
|
836
|
-
end
|
837
|
-
|
838
|
-
# Returns the string representation of the object
|
839
|
-
# @return [String] String presentation of the object
|
840
|
-
def to_s
|
841
|
-
to_hash.to_s
|
842
|
-
end
|
843
|
-
|
844
|
-
# to_body is an alias to to_hash (backward compatibility)
|
845
|
-
# @return [Hash] Returns the object in the form of hash
|
846
|
-
def to_body
|
847
|
-
to_hash
|
848
|
-
end
|
849
|
-
|
850
|
-
# Returns the object in the form of hash
|
851
|
-
# @return [Hash] Returns the object in the form of hash
|
852
|
-
def to_hash
|
853
|
-
hash = {}
|
854
|
-
self.class.attribute_map.each_pair do |attr, param|
|
855
|
-
value = self.send(attr)
|
856
|
-
if value.nil?
|
857
|
-
is_nullable = self.class.openapi_nullable.include?(attr)
|
858
|
-
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
859
|
-
end
|
860
|
-
|
861
|
-
hash[param] = _to_hash(value)
|
862
|
-
end
|
863
|
-
hash
|
864
|
-
end
|
865
|
-
|
866
|
-
# Outputs non-array value in the form of hash
|
867
|
-
# For object, use to_hash. Otherwise, just return the value
|
868
|
-
# @param [Object] value Any valid value
|
869
|
-
# @return [Hash] Returns the value in the form of hash
|
870
|
-
def _to_hash(value)
|
871
|
-
if value.is_a?(Array)
|
872
|
-
value.compact.map { |v| _to_hash(v) }
|
873
|
-
elsif value.is_a?(Hash)
|
874
|
-
{}.tap do |hash|
|
875
|
-
value.each { |k, v| hash[k] = _to_hash(v) }
|
876
|
-
end
|
877
|
-
elsif value.respond_to? :to_hash
|
878
|
-
value.to_hash
|
879
|
-
else
|
880
|
-
value
|
881
|
-
end
|
882
|
-
end
|
883
|
-
|
884
|
-
end
|
885
|
-
|
886
|
-
end
|