onfido 3.0.0 → 3.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a9653d3538d5e5bb57827c1e1219904664065fb717c2a8bffb4adbf021d64ca7
4
- data.tar.gz: c1d007e144f6516a305b84936f6b60c0f723af9407df2c8c2144016793540179
3
+ metadata.gz: e49647b89683e1a972dd4aa7fc52fe3b83a2ef5b91015b703f2f1825163aefdf
4
+ data.tar.gz: c2c0fc5cfef81086c92b90765ab0156b4d401bde312566350edfe8dd52d90a87
5
5
  SHA512:
6
- metadata.gz: 85351c613a670ca1b2c437d7bbbfd206f864b37fec99171ec731b4c23c82168b4919e9fc18e0155eeb9e3ee1abdb4b9eb9bea6e3a79346323d4aa029b48ee630
7
- data.tar.gz: a2db36ed27b85c56bf775e20f8c264dc894848e6bafc99a968ac78b0c4942578e98826e4f7d8ab683bd52f0ffa404feefdc15dc96470482d08b522a29371e366
6
+ metadata.gz: 7ad579443fe7bb71ea26ebf39c622959f386bbae04a6450fb5d6617026e68a691c67a6ddb9928f97a4610161c246ac596a8ca8b226df907836a1ab6293e058b5
7
+ data.tar.gz: 667e52f85d7afb8d775c66db9ccfb6f121feb80510628784863ce576321f66cc19014f850397696598ad116d04171db1f465baf218cb99801a3ddf9cdfcff329
data/README.md CHANGED
@@ -6,15 +6,15 @@ Documentation can be found at <https://documentation.onfido.com>.
6
6
 
7
7
  This version uses Onfido API v3.6. Refer to our [API versioning guide](https://developers.onfido.com/guide/api-versioning-policy#client-libraries) for details of which client library versions use which versions of the API.
8
8
 
9
- [![Gem Version](https://badge.fury.io/rb/onfido.svg)](http://badge.fury.io/rb/onfido)
10
- [![Build Status](https://travis-ci.org/onfido/onfido-ruby.svg?branch=master)](https://travis-ci.org/onfido/onfido-ruby)
9
+ [![Gem Version](https://badge.fury.io/rb/onfido.svg)](https://badge.fury.io/rb/onfido)
10
+ ![Build Status](https://github.com/onfido/onfido-ruby/actions/workflows/ruby.yml/badge.svg)
11
11
 
12
12
  ## Installation & Usage
13
13
 
14
14
  ### Installation
15
15
 
16
16
  ```ruby
17
- gem onfido, '~> 3.0.0'
17
+ gem onfido, '~> 3.1.0'
18
18
  ```
19
19
 
20
20
  Configure with your API token, region and optional timeout (default value is 30):
@@ -34,7 +34,7 @@ module Onfido
34
34
  # @option config [Configuration] Configuration for initializing the object, default to Configuration.default
35
35
  def initialize(config = Configuration.default)
36
36
  @config = config
37
- @user_agent = "onfido-ruby/3.0.0"
37
+ @user_agent = "onfido-ruby/3.1.0"
38
38
  @default_headers = {
39
39
  'Content-Type' => 'application/json',
40
40
  'User-Agent' => @user_agent
@@ -19,6 +19,8 @@ module Onfido
19
19
 
20
20
  attr_accessor :date_of_expiry
21
21
 
22
+ attr_accessor :personal_number
23
+
22
24
  attr_accessor :document_numbers
23
25
 
24
26
  attr_accessor :document_type
@@ -57,8 +59,38 @@ module Onfido
57
59
 
58
60
  attr_accessor :issuing_authority
59
61
 
62
+ attr_accessor :remarks
63
+
64
+ attr_accessor :civil_state
65
+
66
+ attr_accessor :expatriation
67
+
68
+ attr_accessor :father_name
69
+
70
+ attr_accessor :mother_name
71
+
72
+ attr_accessor :religion
73
+
74
+ attr_accessor :type_of_permit
75
+
76
+ attr_accessor :version_number
77
+
78
+ attr_accessor :document_subtype
79
+
80
+ attr_accessor :profession
81
+
82
+ attr_accessor :security_document_number
83
+
84
+ attr_accessor :tax_number
85
+
86
+ attr_accessor :nist_identity_evidence_strength
87
+
88
+ attr_accessor :has_issuance_confirmation
89
+
60
90
  attr_accessor :real_id_compliance
61
91
 
92
+ attr_accessor :security_tier
93
+
62
94
  attr_accessor :address_lines
63
95
 
64
96
  attr_accessor :barcode
@@ -71,11 +103,34 @@ module Onfido
71
103
 
72
104
  attr_accessor :extracted_data
73
105
 
106
+ class EnumAttributeValidator
107
+ attr_reader :datatype
108
+ attr_reader :allowable_values
109
+
110
+ def initialize(datatype, allowable_values)
111
+ @allowable_values = allowable_values.map do |value|
112
+ case datatype.to_s
113
+ when /Integer/i
114
+ value.to_i
115
+ when /Float/i
116
+ value.to_f
117
+ else
118
+ value
119
+ end
120
+ end
121
+ end
122
+
123
+ def valid?(value)
124
+ !value || allowable_values.include?(value)
125
+ end
126
+ end
127
+
74
128
  # Attribute mapping from ruby-style variable name to JSON key.
75
129
  def self.attribute_map
76
130
  {
77
131
  :'date_of_birth' => :'date_of_birth',
78
132
  :'date_of_expiry' => :'date_of_expiry',
133
+ :'personal_number' => :'personal_number',
79
134
  :'document_numbers' => :'document_numbers',
80
135
  :'document_type' => :'document_type',
81
136
  :'first_name' => :'first_name',
@@ -95,7 +150,22 @@ module Onfido
95
150
  :'widow_name' => :'widow_name',
96
151
  :'alias_name' => :'alias_name',
97
152
  :'issuing_authority' => :'issuing_authority',
153
+ :'remarks' => :'remarks',
154
+ :'civil_state' => :'civil_state',
155
+ :'expatriation' => :'expatriation',
156
+ :'father_name' => :'father_name',
157
+ :'mother_name' => :'mother_name',
158
+ :'religion' => :'religion',
159
+ :'type_of_permit' => :'type_of_permit',
160
+ :'version_number' => :'version_number',
161
+ :'document_subtype' => :'document_subtype',
162
+ :'profession' => :'profession',
163
+ :'security_document_number' => :'security_document_number',
164
+ :'tax_number' => :'tax_number',
165
+ :'nist_identity_evidence_strength' => :'nist_identity_evidence_strength',
166
+ :'has_issuance_confirmation' => :'has_issuance_confirmation',
98
167
  :'real_id_compliance' => :'real_id_compliance',
168
+ :'security_tier' => :'security_tier',
99
169
  :'address_lines' => :'address_lines',
100
170
  :'barcode' => :'barcode',
101
171
  :'nfc' => :'nfc',
@@ -115,6 +185,7 @@ module Onfido
115
185
  {
116
186
  :'date_of_birth' => :'Date',
117
187
  :'date_of_expiry' => :'Date',
188
+ :'personal_number' => :'String',
118
189
  :'document_numbers' => :'Array<DocumentPropertiesDocumentNumbersInner>',
119
190
  :'document_type' => :'String',
120
191
  :'first_name' => :'String',
@@ -134,7 +205,22 @@ module Onfido
134
205
  :'widow_name' => :'String',
135
206
  :'alias_name' => :'String',
136
207
  :'issuing_authority' => :'String',
208
+ :'remarks' => :'String',
209
+ :'civil_state' => :'String',
210
+ :'expatriation' => :'String',
211
+ :'father_name' => :'String',
212
+ :'mother_name' => :'String',
213
+ :'religion' => :'String',
214
+ :'type_of_permit' => :'String',
215
+ :'version_number' => :'String',
216
+ :'document_subtype' => :'String',
217
+ :'profession' => :'String',
218
+ :'security_document_number' => :'String',
219
+ :'tax_number' => :'String',
220
+ :'nist_identity_evidence_strength' => :'String',
221
+ :'has_issuance_confirmation' => :'String',
137
222
  :'real_id_compliance' => :'Boolean',
223
+ :'security_tier' => :'String',
138
224
  :'address_lines' => :'DocumentPropertiesAddressLines',
139
225
  :'barcode' => :'Array<DocumentPropertiesBarcodeInner>',
140
226
  :'nfc' => :'DocumentPropertiesNfc',
@@ -173,6 +259,10 @@ module Onfido
173
259
  self.date_of_expiry = attributes[:'date_of_expiry']
174
260
  end
175
261
 
262
+ if attributes.key?(:'personal_number')
263
+ self.personal_number = attributes[:'personal_number']
264
+ end
265
+
176
266
  if attributes.key?(:'document_numbers')
177
267
  if (value = attributes[:'document_numbers']).is_a?(Array)
178
268
  self.document_numbers = value
@@ -251,10 +341,70 @@ module Onfido
251
341
  self.issuing_authority = attributes[:'issuing_authority']
252
342
  end
253
343
 
344
+ if attributes.key?(:'remarks')
345
+ self.remarks = attributes[:'remarks']
346
+ end
347
+
348
+ if attributes.key?(:'civil_state')
349
+ self.civil_state = attributes[:'civil_state']
350
+ end
351
+
352
+ if attributes.key?(:'expatriation')
353
+ self.expatriation = attributes[:'expatriation']
354
+ end
355
+
356
+ if attributes.key?(:'father_name')
357
+ self.father_name = attributes[:'father_name']
358
+ end
359
+
360
+ if attributes.key?(:'mother_name')
361
+ self.mother_name = attributes[:'mother_name']
362
+ end
363
+
364
+ if attributes.key?(:'religion')
365
+ self.religion = attributes[:'religion']
366
+ end
367
+
368
+ if attributes.key?(:'type_of_permit')
369
+ self.type_of_permit = attributes[:'type_of_permit']
370
+ end
371
+
372
+ if attributes.key?(:'version_number')
373
+ self.version_number = attributes[:'version_number']
374
+ end
375
+
376
+ if attributes.key?(:'document_subtype')
377
+ self.document_subtype = attributes[:'document_subtype']
378
+ end
379
+
380
+ if attributes.key?(:'profession')
381
+ self.profession = attributes[:'profession']
382
+ end
383
+
384
+ if attributes.key?(:'security_document_number')
385
+ self.security_document_number = attributes[:'security_document_number']
386
+ end
387
+
388
+ if attributes.key?(:'tax_number')
389
+ self.tax_number = attributes[:'tax_number']
390
+ end
391
+
392
+ if attributes.key?(:'nist_identity_evidence_strength')
393
+ self.nist_identity_evidence_strength = attributes[:'nist_identity_evidence_strength']
394
+ end
395
+
396
+ if attributes.key?(:'has_issuance_confirmation')
397
+ self.has_issuance_confirmation = attributes[:'has_issuance_confirmation']
398
+ end
399
+
254
400
  if attributes.key?(:'real_id_compliance')
255
401
  self.real_id_compliance = attributes[:'real_id_compliance']
256
402
  end
257
403
 
404
+ if attributes.key?(:'security_tier')
405
+ self.security_tier = attributes[:'security_tier']
406
+ end
407
+
258
408
  if attributes.key?(:'address_lines')
259
409
  self.address_lines = attributes[:'address_lines']
260
410
  end
@@ -294,9 +444,45 @@ module Onfido
294
444
  # @return true if the model is valid
295
445
  def valid?
296
446
  warn '[DEPRECATED] the `valid?` method is obsolete'
447
+ nist_identity_evidence_strength_validator = EnumAttributeValidator.new('String', ["superior", "strong", "fair", "weak", "unacceptable", "unspecified_identity_evidence_strength", "unknown_default_open_api"])
448
+ return false unless nist_identity_evidence_strength_validator.valid?(@nist_identity_evidence_strength)
449
+ has_issuance_confirmation_validator = EnumAttributeValidator.new('String', ["true", "false", "unspecified", "unknown_default_open_api"])
450
+ return false unless has_issuance_confirmation_validator.valid?(@has_issuance_confirmation)
451
+ security_tier_validator = EnumAttributeValidator.new('String', ["tier_1", "tier_2", "tier_3", "tier_4", "tier_5", "unspecified_security_tier", "unknown_default_open_api"])
452
+ return false unless security_tier_validator.valid?(@security_tier)
297
453
  true
298
454
  end
299
455
 
456
+ # Custom attribute writer method checking allowed values (enum).
457
+ # @param [Object] nist_identity_evidence_strength Object to be assigned
458
+ def nist_identity_evidence_strength=(nist_identity_evidence_strength)
459
+ validator = EnumAttributeValidator.new('String', ["superior", "strong", "fair", "weak", "unacceptable", "unspecified_identity_evidence_strength", "unknown_default_open_api"])
460
+ unless validator.valid?(nist_identity_evidence_strength)
461
+ fail ArgumentError, "invalid value for \"nist_identity_evidence_strength\", must be one of #{validator.allowable_values}."
462
+ end
463
+ @nist_identity_evidence_strength = nist_identity_evidence_strength
464
+ end
465
+
466
+ # Custom attribute writer method checking allowed values (enum).
467
+ # @param [Object] has_issuance_confirmation Object to be assigned
468
+ def has_issuance_confirmation=(has_issuance_confirmation)
469
+ validator = EnumAttributeValidator.new('String', ["true", "false", "unspecified", "unknown_default_open_api"])
470
+ unless validator.valid?(has_issuance_confirmation)
471
+ fail ArgumentError, "invalid value for \"has_issuance_confirmation\", must be one of #{validator.allowable_values}."
472
+ end
473
+ @has_issuance_confirmation = has_issuance_confirmation
474
+ end
475
+
476
+ # Custom attribute writer method checking allowed values (enum).
477
+ # @param [Object] security_tier Object to be assigned
478
+ def security_tier=(security_tier)
479
+ validator = EnumAttributeValidator.new('String', ["tier_1", "tier_2", "tier_3", "tier_4", "tier_5", "unspecified_security_tier", "unknown_default_open_api"])
480
+ unless validator.valid?(security_tier)
481
+ fail ArgumentError, "invalid value for \"security_tier\", must be one of #{validator.allowable_values}."
482
+ end
483
+ @security_tier = security_tier
484
+ end
485
+
300
486
  # Checks equality by comparing each attribute.
301
487
  # @param [Object] Object to be compared
302
488
  def ==(o)
@@ -304,6 +490,7 @@ module Onfido
304
490
  self.class == o.class &&
305
491
  date_of_birth == o.date_of_birth &&
306
492
  date_of_expiry == o.date_of_expiry &&
493
+ personal_number == o.personal_number &&
307
494
  document_numbers == o.document_numbers &&
308
495
  document_type == o.document_type &&
309
496
  first_name == o.first_name &&
@@ -323,7 +510,22 @@ module Onfido
323
510
  widow_name == o.widow_name &&
324
511
  alias_name == o.alias_name &&
325
512
  issuing_authority == o.issuing_authority &&
513
+ remarks == o.remarks &&
514
+ civil_state == o.civil_state &&
515
+ expatriation == o.expatriation &&
516
+ father_name == o.father_name &&
517
+ mother_name == o.mother_name &&
518
+ religion == o.religion &&
519
+ type_of_permit == o.type_of_permit &&
520
+ version_number == o.version_number &&
521
+ document_subtype == o.document_subtype &&
522
+ profession == o.profession &&
523
+ security_document_number == o.security_document_number &&
524
+ tax_number == o.tax_number &&
525
+ nist_identity_evidence_strength == o.nist_identity_evidence_strength &&
526
+ has_issuance_confirmation == o.has_issuance_confirmation &&
326
527
  real_id_compliance == o.real_id_compliance &&
528
+ security_tier == o.security_tier &&
327
529
  address_lines == o.address_lines &&
328
530
  barcode == o.barcode &&
329
531
  nfc == o.nfc &&
@@ -341,7 +543,7 @@ module Onfido
341
543
  # Calculates hash code according to all attributes.
342
544
  # @return [Integer] Hash code
343
545
  def hash
344
- [date_of_birth, date_of_expiry, document_numbers, document_type, first_name, gender, issuing_country, last_name, nationality, issuing_state, issuing_date, categorisation, mrz_line1, mrz_line2, mrz_line3, address, place_of_birth, spouse_name, widow_name, alias_name, issuing_authority, real_id_compliance, address_lines, barcode, nfc, driving_licence_information, document_classification, extracted_data].hash
546
+ [date_of_birth, date_of_expiry, personal_number, document_numbers, document_type, first_name, gender, issuing_country, last_name, nationality, issuing_state, issuing_date, categorisation, mrz_line1, mrz_line2, mrz_line3, address, place_of_birth, spouse_name, widow_name, alias_name, issuing_authority, remarks, civil_state, expatriation, father_name, mother_name, religion, type_of_permit, version_number, document_subtype, profession, security_document_number, tax_number, nist_identity_evidence_strength, has_issuance_confirmation, real_id_compliance, security_tier, address_lines, barcode, nfc, driving_licence_information, document_classification, extracted_data].hash
345
547
  end
346
548
 
347
549
  # Builds the object from hash
@@ -19,6 +19,8 @@ module Onfido
19
19
 
20
20
  attr_accessor :date_of_expiry
21
21
 
22
+ attr_accessor :personal_number
23
+
22
24
  attr_accessor :document_numbers
23
25
 
24
26
  attr_accessor :document_type
@@ -57,8 +59,38 @@ module Onfido
57
59
 
58
60
  attr_accessor :issuing_authority
59
61
 
62
+ attr_accessor :remarks
63
+
64
+ attr_accessor :civil_state
65
+
66
+ attr_accessor :expatriation
67
+
68
+ attr_accessor :father_name
69
+
70
+ attr_accessor :mother_name
71
+
72
+ attr_accessor :religion
73
+
74
+ attr_accessor :type_of_permit
75
+
76
+ attr_accessor :version_number
77
+
78
+ attr_accessor :document_subtype
79
+
80
+ attr_accessor :profession
81
+
82
+ attr_accessor :security_document_number
83
+
84
+ attr_accessor :tax_number
85
+
86
+ attr_accessor :nist_identity_evidence_strength
87
+
88
+ attr_accessor :has_issuance_confirmation
89
+
60
90
  attr_accessor :real_id_compliance
61
91
 
92
+ attr_accessor :security_tier
93
+
62
94
  attr_accessor :address_lines
63
95
 
64
96
  attr_accessor :barcode
@@ -88,11 +120,34 @@ module Onfido
88
120
 
89
121
  attr_accessor :passenger_vehicle
90
122
 
123
+ class EnumAttributeValidator
124
+ attr_reader :datatype
125
+ attr_reader :allowable_values
126
+
127
+ def initialize(datatype, allowable_values)
128
+ @allowable_values = allowable_values.map do |value|
129
+ case datatype.to_s
130
+ when /Integer/i
131
+ value.to_i
132
+ when /Float/i
133
+ value.to_f
134
+ else
135
+ value
136
+ end
137
+ end
138
+ end
139
+
140
+ def valid?(value)
141
+ !value || allowable_values.include?(value)
142
+ end
143
+ end
144
+
91
145
  # Attribute mapping from ruby-style variable name to JSON key.
92
146
  def self.attribute_map
93
147
  {
94
148
  :'date_of_birth' => :'date_of_birth',
95
149
  :'date_of_expiry' => :'date_of_expiry',
150
+ :'personal_number' => :'personal_number',
96
151
  :'document_numbers' => :'document_numbers',
97
152
  :'document_type' => :'document_type',
98
153
  :'first_name' => :'first_name',
@@ -112,7 +167,22 @@ module Onfido
112
167
  :'widow_name' => :'widow_name',
113
168
  :'alias_name' => :'alias_name',
114
169
  :'issuing_authority' => :'issuing_authority',
170
+ :'remarks' => :'remarks',
171
+ :'civil_state' => :'civil_state',
172
+ :'expatriation' => :'expatriation',
173
+ :'father_name' => :'father_name',
174
+ :'mother_name' => :'mother_name',
175
+ :'religion' => :'religion',
176
+ :'type_of_permit' => :'type_of_permit',
177
+ :'version_number' => :'version_number',
178
+ :'document_subtype' => :'document_subtype',
179
+ :'profession' => :'profession',
180
+ :'security_document_number' => :'security_document_number',
181
+ :'tax_number' => :'tax_number',
182
+ :'nist_identity_evidence_strength' => :'nist_identity_evidence_strength',
183
+ :'has_issuance_confirmation' => :'has_issuance_confirmation',
115
184
  :'real_id_compliance' => :'real_id_compliance',
185
+ :'security_tier' => :'security_tier',
116
186
  :'address_lines' => :'address_lines',
117
187
  :'barcode' => :'barcode',
118
188
  :'nfc' => :'nfc',
@@ -138,6 +208,7 @@ module Onfido
138
208
  {
139
209
  :'date_of_birth' => :'Date',
140
210
  :'date_of_expiry' => :'Date',
211
+ :'personal_number' => :'String',
141
212
  :'document_numbers' => :'Array<DocumentPropertiesDocumentNumbersInner>',
142
213
  :'document_type' => :'String',
143
214
  :'first_name' => :'String',
@@ -157,7 +228,22 @@ module Onfido
157
228
  :'widow_name' => :'String',
158
229
  :'alias_name' => :'String',
159
230
  :'issuing_authority' => :'String',
231
+ :'remarks' => :'String',
232
+ :'civil_state' => :'String',
233
+ :'expatriation' => :'String',
234
+ :'father_name' => :'String',
235
+ :'mother_name' => :'String',
236
+ :'religion' => :'String',
237
+ :'type_of_permit' => :'String',
238
+ :'version_number' => :'String',
239
+ :'document_subtype' => :'String',
240
+ :'profession' => :'String',
241
+ :'security_document_number' => :'String',
242
+ :'tax_number' => :'String',
243
+ :'nist_identity_evidence_strength' => :'String',
244
+ :'has_issuance_confirmation' => :'String',
160
245
  :'real_id_compliance' => :'Boolean',
246
+ :'security_tier' => :'String',
161
247
  :'address_lines' => :'DocumentPropertiesAddressLines',
162
248
  :'barcode' => :'Array<DocumentPropertiesBarcodeInner>',
163
249
  :'nfc' => :'DocumentPropertiesNfc',
@@ -209,6 +295,10 @@ module Onfido
209
295
  self.date_of_expiry = attributes[:'date_of_expiry']
210
296
  end
211
297
 
298
+ if attributes.key?(:'personal_number')
299
+ self.personal_number = attributes[:'personal_number']
300
+ end
301
+
212
302
  if attributes.key?(:'document_numbers')
213
303
  if (value = attributes[:'document_numbers']).is_a?(Array)
214
304
  self.document_numbers = value
@@ -287,10 +377,70 @@ module Onfido
287
377
  self.issuing_authority = attributes[:'issuing_authority']
288
378
  end
289
379
 
380
+ if attributes.key?(:'remarks')
381
+ self.remarks = attributes[:'remarks']
382
+ end
383
+
384
+ if attributes.key?(:'civil_state')
385
+ self.civil_state = attributes[:'civil_state']
386
+ end
387
+
388
+ if attributes.key?(:'expatriation')
389
+ self.expatriation = attributes[:'expatriation']
390
+ end
391
+
392
+ if attributes.key?(:'father_name')
393
+ self.father_name = attributes[:'father_name']
394
+ end
395
+
396
+ if attributes.key?(:'mother_name')
397
+ self.mother_name = attributes[:'mother_name']
398
+ end
399
+
400
+ if attributes.key?(:'religion')
401
+ self.religion = attributes[:'religion']
402
+ end
403
+
404
+ if attributes.key?(:'type_of_permit')
405
+ self.type_of_permit = attributes[:'type_of_permit']
406
+ end
407
+
408
+ if attributes.key?(:'version_number')
409
+ self.version_number = attributes[:'version_number']
410
+ end
411
+
412
+ if attributes.key?(:'document_subtype')
413
+ self.document_subtype = attributes[:'document_subtype']
414
+ end
415
+
416
+ if attributes.key?(:'profession')
417
+ self.profession = attributes[:'profession']
418
+ end
419
+
420
+ if attributes.key?(:'security_document_number')
421
+ self.security_document_number = attributes[:'security_document_number']
422
+ end
423
+
424
+ if attributes.key?(:'tax_number')
425
+ self.tax_number = attributes[:'tax_number']
426
+ end
427
+
428
+ if attributes.key?(:'nist_identity_evidence_strength')
429
+ self.nist_identity_evidence_strength = attributes[:'nist_identity_evidence_strength']
430
+ end
431
+
432
+ if attributes.key?(:'has_issuance_confirmation')
433
+ self.has_issuance_confirmation = attributes[:'has_issuance_confirmation']
434
+ end
435
+
290
436
  if attributes.key?(:'real_id_compliance')
291
437
  self.real_id_compliance = attributes[:'real_id_compliance']
292
438
  end
293
439
 
440
+ if attributes.key?(:'security_tier')
441
+ self.security_tier = attributes[:'security_tier']
442
+ end
443
+
294
444
  if attributes.key?(:'address_lines')
295
445
  self.address_lines = attributes[:'address_lines']
296
446
  end
@@ -356,9 +506,45 @@ module Onfido
356
506
  # @return true if the model is valid
357
507
  def valid?
358
508
  warn '[DEPRECATED] the `valid?` method is obsolete'
509
+ nist_identity_evidence_strength_validator = EnumAttributeValidator.new('String', ["superior", "strong", "fair", "weak", "unacceptable", "unspecified_identity_evidence_strength", "unknown_default_open_api"])
510
+ return false unless nist_identity_evidence_strength_validator.valid?(@nist_identity_evidence_strength)
511
+ has_issuance_confirmation_validator = EnumAttributeValidator.new('String', ["true", "false", "unspecified", "unknown_default_open_api"])
512
+ return false unless has_issuance_confirmation_validator.valid?(@has_issuance_confirmation)
513
+ security_tier_validator = EnumAttributeValidator.new('String', ["tier_1", "tier_2", "tier_3", "tier_4", "tier_5", "unspecified_security_tier", "unknown_default_open_api"])
514
+ return false unless security_tier_validator.valid?(@security_tier)
359
515
  true
360
516
  end
361
517
 
518
+ # Custom attribute writer method checking allowed values (enum).
519
+ # @param [Object] nist_identity_evidence_strength Object to be assigned
520
+ def nist_identity_evidence_strength=(nist_identity_evidence_strength)
521
+ validator = EnumAttributeValidator.new('String', ["superior", "strong", "fair", "weak", "unacceptable", "unspecified_identity_evidence_strength", "unknown_default_open_api"])
522
+ unless validator.valid?(nist_identity_evidence_strength)
523
+ fail ArgumentError, "invalid value for \"nist_identity_evidence_strength\", must be one of #{validator.allowable_values}."
524
+ end
525
+ @nist_identity_evidence_strength = nist_identity_evidence_strength
526
+ end
527
+
528
+ # Custom attribute writer method checking allowed values (enum).
529
+ # @param [Object] has_issuance_confirmation Object to be assigned
530
+ def has_issuance_confirmation=(has_issuance_confirmation)
531
+ validator = EnumAttributeValidator.new('String', ["true", "false", "unspecified", "unknown_default_open_api"])
532
+ unless validator.valid?(has_issuance_confirmation)
533
+ fail ArgumentError, "invalid value for \"has_issuance_confirmation\", must be one of #{validator.allowable_values}."
534
+ end
535
+ @has_issuance_confirmation = has_issuance_confirmation
536
+ end
537
+
538
+ # Custom attribute writer method checking allowed values (enum).
539
+ # @param [Object] security_tier Object to be assigned
540
+ def security_tier=(security_tier)
541
+ validator = EnumAttributeValidator.new('String', ["tier_1", "tier_2", "tier_3", "tier_4", "tier_5", "unspecified_security_tier", "unknown_default_open_api"])
542
+ unless validator.valid?(security_tier)
543
+ fail ArgumentError, "invalid value for \"security_tier\", must be one of #{validator.allowable_values}."
544
+ end
545
+ @security_tier = security_tier
546
+ end
547
+
362
548
  # Checks equality by comparing each attribute.
363
549
  # @param [Object] Object to be compared
364
550
  def ==(o)
@@ -366,6 +552,7 @@ module Onfido
366
552
  self.class == o.class &&
367
553
  date_of_birth == o.date_of_birth &&
368
554
  date_of_expiry == o.date_of_expiry &&
555
+ personal_number == o.personal_number &&
369
556
  document_numbers == o.document_numbers &&
370
557
  document_type == o.document_type &&
371
558
  first_name == o.first_name &&
@@ -385,7 +572,22 @@ module Onfido
385
572
  widow_name == o.widow_name &&
386
573
  alias_name == o.alias_name &&
387
574
  issuing_authority == o.issuing_authority &&
575
+ remarks == o.remarks &&
576
+ civil_state == o.civil_state &&
577
+ expatriation == o.expatriation &&
578
+ father_name == o.father_name &&
579
+ mother_name == o.mother_name &&
580
+ religion == o.religion &&
581
+ type_of_permit == o.type_of_permit &&
582
+ version_number == o.version_number &&
583
+ document_subtype == o.document_subtype &&
584
+ profession == o.profession &&
585
+ security_document_number == o.security_document_number &&
586
+ tax_number == o.tax_number &&
587
+ nist_identity_evidence_strength == o.nist_identity_evidence_strength &&
588
+ has_issuance_confirmation == o.has_issuance_confirmation &&
388
589
  real_id_compliance == o.real_id_compliance &&
590
+ security_tier == o.security_tier &&
389
591
  address_lines == o.address_lines &&
390
592
  barcode == o.barcode &&
391
593
  nfc == o.nfc &&
@@ -409,7 +611,7 @@ module Onfido
409
611
  # Calculates hash code according to all attributes.
410
612
  # @return [Integer] Hash code
411
613
  def hash
412
- [date_of_birth, date_of_expiry, document_numbers, document_type, first_name, gender, issuing_country, last_name, nationality, issuing_state, issuing_date, categorisation, mrz_line1, mrz_line2, mrz_line3, address, place_of_birth, spouse_name, widow_name, alias_name, issuing_authority, real_id_compliance, address_lines, barcode, nfc, driving_licence_information, document_classification, extracted_data, drivers_licence, restricted_licence, raw_licence_category, raw_vehicle_classes, vehicle_class_details, passenger_vehicle].hash
614
+ [date_of_birth, date_of_expiry, personal_number, document_numbers, document_type, first_name, gender, issuing_country, last_name, nationality, issuing_state, issuing_date, categorisation, mrz_line1, mrz_line2, mrz_line3, address, place_of_birth, spouse_name, widow_name, alias_name, issuing_authority, remarks, civil_state, expatriation, father_name, mother_name, religion, type_of_permit, version_number, document_subtype, profession, security_document_number, tax_number, nist_identity_evidence_strength, has_issuance_confirmation, real_id_compliance, security_tier, address_lines, barcode, nfc, driving_licence_information, document_classification, extracted_data, drivers_licence, restricted_licence, raw_licence_category, raw_vehicle_classes, vehicle_class_details, passenger_vehicle].hash
413
615
  end
414
616
 
415
617
  # Builds the object from hash
@@ -11,5 +11,5 @@ Generator version: 7.6.0
11
11
  =end
12
12
 
13
13
  module Onfido
14
- VERSION = '3.0.0'
14
+ VERSION = '3.1.0'
15
15
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: onfido
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0
4
+ version: 3.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-06-24 00:00:00.000000000 Z
11
+ date: 2024-07-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday