trinsic_api 1.1.2 → 2.0.0.pre.alpha3
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/docs/AadhaarInput.md +20 -0
- data/docs/Address.md +3 -3
- data/docs/AttachmentAccessKeys.md +7 -5
- data/docs/BangladeshNationalIdInput.md +24 -0
- data/docs/BrazilCpfCheckInput.md +18 -0
- data/docs/BrazilDigitalCnhInput.md +24 -0
- data/docs/CreateAdvancedProviderSessionRequest.md +26 -0
- data/docs/CreateAdvancedProviderSessionResponse.md +22 -0
- data/docs/CreateHostedProviderSessionRequest.md +22 -0
- data/docs/CreateHostedProviderSessionResponse.md +20 -0
- data/docs/CreateWidgetSessionRequest.md +22 -0
- data/docs/{CreateSessionResponse.md → CreateWidgetSessionResponse.md} +5 -5
- data/docs/DocumentData.md +3 -3
- data/docs/DocumentScanAttachments.md +18 -0
- data/docs/{SessionState.md → DocumentType.md} +2 -2
- data/docs/HttpValidationProblemDetails.md +28 -0
- data/docs/IdentityData.md +4 -4
- data/docs/IndonesiaNikInput.md +22 -0
- data/docs/{FailureMessage.md → IntegrationCapability.md} +2 -5
- data/docs/IntegrationLaunchMethod.md +15 -0
- data/docs/IntegrationStep.md +22 -0
- data/docs/KenyaNidInput.md +28 -0
- data/docs/KnownAddress.md +32 -0
- data/docs/KnownIdentityData.md +18 -0
- data/docs/KnownPersonData.md +32 -0
- data/docs/MexicoCurpInput.md +18 -0
- data/docs/NetworkApi.md +37 -35
- data/docs/NigeriaNinInput.md +30 -0
- data/docs/PersonData.md +14 -12
- data/docs/PhilippineMatchInput.md +26 -0
- data/docs/PhilippineQRInput.md +20 -0
- data/docs/ProblemDetails.md +26 -0
- data/docs/ProviderAttachments.md +18 -0
- data/docs/ProviderInfo.md +3 -1
- data/docs/ProviderInformation.md +22 -0
- data/docs/ProviderInput.md +38 -0
- data/docs/RecommendRequest.md +26 -0
- data/docs/RecommendResponse.md +22 -0
- data/docs/RefreshStepContentRequest.md +18 -0
- data/docs/RefreshStepContentResponse.md +18 -0
- data/docs/ResultCollection.md +20 -0
- data/docs/ResultCollectionMethod.md +15 -0
- data/docs/Session.md +6 -8
- data/docs/{VerificationFailCode.md → SessionErrorCode.md} +2 -2
- data/docs/SessionsApi.md +236 -18
- data/docs/{SessionFailCode.md → Sex.md} +2 -2
- data/docs/SouthAfricaNidInput.md +24 -0
- data/docs/StepRefreshInfo.md +22 -0
- data/lib/trinsic_api/api/attachments_api.rb +1 -1
- data/lib/trinsic_api/api/network_api.rb +38 -37
- data/lib/trinsic_api/api/sessions_api.rb +217 -19
- data/lib/trinsic_api/api_client.rb +1 -1
- data/lib/trinsic_api/api_error.rb +1 -1
- data/lib/trinsic_api/configuration.rb +1 -1
- data/lib/trinsic_api/models/{validation_result.rb → aadhaar_input.rb} +21 -26
- data/lib/trinsic_api/models/address.rb +16 -10
- data/lib/trinsic_api/models/attachment_access_keys.rb +25 -10
- data/lib/trinsic_api/models/bangladesh_national_id_input.rb +249 -0
- data/lib/trinsic_api/models/brazil_cpf_check_input.rb +261 -0
- data/lib/trinsic_api/models/brazil_digital_cnh_input.rb +294 -0
- data/lib/trinsic_api/models/cancel_session_response.rb +1 -1
- data/lib/trinsic_api/models/create_advanced_provider_session_request.rb +312 -0
- data/lib/trinsic_api/models/create_advanced_provider_session_response.rb +256 -0
- data/lib/trinsic_api/models/create_hosted_provider_session_request.rb +288 -0
- data/lib/trinsic_api/models/create_hosted_provider_session_response.rb +233 -0
- data/lib/trinsic_api/models/create_widget_session_request.rb +240 -0
- data/lib/trinsic_api/models/{create_session_response.rb → create_widget_session_response.rb} +18 -17
- data/lib/trinsic_api/models/document_data.rb +32 -4
- data/lib/trinsic_api/models/{failure_message.rb → document_scan_attachments.rb} +12 -18
- data/lib/trinsic_api/models/{session_state.rb → document_type.rb} +9 -11
- data/lib/trinsic_api/models/get_attachment_request.rb +1 -1
- data/lib/trinsic_api/models/get_attachment_response.rb +1 -1
- data/lib/trinsic_api/models/get_session_response.rb +1 -1
- data/lib/trinsic_api/models/get_session_result_request.rb +1 -1
- data/lib/trinsic_api/models/get_session_result_response.rb +2 -1
- data/lib/trinsic_api/models/http_validation_problem_details.rb +273 -0
- data/lib/trinsic_api/models/identity_data.rb +5 -5
- data/lib/trinsic_api/models/{create_session_request.rb → indonesia_nik_input.rb} +105 -38
- data/lib/trinsic_api/models/integration_capability.rb +44 -0
- data/lib/trinsic_api/models/integration_launch_method.rb +42 -0
- data/lib/trinsic_api/models/integration_step.rb +275 -0
- data/lib/trinsic_api/models/kenya_nid_input.rb +397 -0
- data/lib/trinsic_api/models/known_address.rb +287 -0
- data/lib/trinsic_api/models/known_identity_data.rb +217 -0
- data/lib/trinsic_api/models/{disclosed_fields_request.rb → known_person_data.rb} +57 -77
- data/lib/trinsic_api/models/list_providers_response.rb +1 -1
- data/lib/trinsic_api/models/list_sessions_response.rb +1 -1
- data/lib/trinsic_api/models/mexico_curp_input.rb +250 -0
- data/lib/trinsic_api/models/nigeria_nin_input.rb +383 -0
- data/lib/trinsic_api/models/order_direction.rb +1 -1
- data/lib/trinsic_api/models/person_data.rb +50 -15
- data/lib/trinsic_api/models/philippine_match_input.rb +260 -0
- data/lib/trinsic_api/models/philippine_qr_input.rb +227 -0
- data/lib/trinsic_api/models/problem_details.rb +255 -0
- data/lib/trinsic_api/models/provider_attachments.rb +215 -0
- data/lib/trinsic_api/models/provider_info.rb +18 -5
- data/lib/trinsic_api/models/provider_information.rb +253 -0
- data/lib/trinsic_api/models/provider_input.rb +326 -0
- data/lib/trinsic_api/models/recommend_request.rb +266 -0
- data/lib/trinsic_api/models/recommend_response.rb +262 -0
- data/lib/trinsic_api/models/refresh_step_content_request.rb +216 -0
- data/lib/trinsic_api/models/{identity_lookup_response.rb → refresh_step_content_response.rb} +16 -16
- data/lib/trinsic_api/models/{verification.rb → result_collection.rb} +27 -20
- data/lib/trinsic_api/models/result_collection_method.rb +40 -0
- data/lib/trinsic_api/models/session.rb +32 -48
- data/lib/trinsic_api/models/session_error_code.rb +48 -0
- data/lib/trinsic_api/models/session_ordering.rb +1 -1
- data/lib/trinsic_api/models/sex.rb +42 -0
- data/lib/trinsic_api/models/{disclosed_fields.rb → south_africa_nid_input.rb} +107 -154
- data/lib/trinsic_api/models/step_refresh_info.rb +256 -0
- data/lib/trinsic_api/version.rb +2 -2
- data/lib/trinsic_api.rb +40 -12
- data/spec/api/attachments_api_spec.rb +1 -1
- data/spec/api/network_api_spec.rb +12 -12
- data/spec/api/sessions_api_spec.rb +44 -7
- data/spec/models/{verification_spec.rb → aadhaar_input_spec.rb} +9 -9
- data/spec/models/address_spec.rb +2 -2
- data/spec/models/attachment_access_keys_spec.rb +7 -1
- data/spec/models/bangladesh_national_id_input_spec.rb +54 -0
- data/spec/models/{identity_lookup_response_spec.rb → brazil_cpf_check_input_spec.rb} +8 -8
- data/spec/models/brazil_digital_cnh_input_spec.rb +54 -0
- data/spec/models/cancel_session_response_spec.rb +1 -1
- data/spec/models/create_advanced_provider_session_request_spec.rb +60 -0
- data/spec/models/create_advanced_provider_session_response_spec.rb +48 -0
- data/spec/models/create_hosted_provider_session_request_spec.rb +48 -0
- data/spec/models/create_hosted_provider_session_response_spec.rb +42 -0
- data/spec/models/create_widget_session_request_spec.rb +48 -0
- data/spec/models/{create_session_response_spec.rb → create_widget_session_response_spec.rb} +8 -8
- data/spec/models/document_data_spec.rb +1 -1
- data/spec/models/document_scan_attachments_spec.rb +36 -0
- data/spec/models/{session_state_spec.rb → document_type_spec.rb} +7 -7
- data/spec/models/get_attachment_request_spec.rb +1 -1
- data/spec/models/get_attachment_response_spec.rb +1 -1
- data/spec/models/get_session_response_spec.rb +1 -1
- data/spec/models/get_session_result_request_spec.rb +1 -1
- data/spec/models/get_session_result_response_spec.rb +1 -1
- data/spec/models/http_validation_problem_details_spec.rb +66 -0
- data/spec/models/identity_data_spec.rb +1 -1
- data/spec/models/indonesia_nik_input_spec.rb +48 -0
- data/spec/models/integration_capability_spec.rb +30 -0
- data/spec/models/integration_launch_method_spec.rb +30 -0
- data/spec/models/integration_step_spec.rb +48 -0
- data/spec/models/kenya_nid_input_spec.rb +66 -0
- data/spec/models/known_address_spec.rb +78 -0
- data/spec/models/known_identity_data_spec.rb +36 -0
- data/spec/models/{disclosed_fields_request_spec.rb → known_person_data_spec.rb} +13 -37
- data/spec/models/list_providers_response_spec.rb +1 -1
- data/spec/models/list_sessions_response_spec.rb +1 -1
- data/spec/models/{failure_message_spec.rb → mexico_curp_input_spec.rb} +8 -8
- data/spec/models/nigeria_nin_input_spec.rb +72 -0
- data/spec/models/order_direction_spec.rb +1 -1
- data/spec/models/person_data_spec.rb +8 -2
- data/spec/models/philippine_match_input_spec.rb +60 -0
- data/spec/models/philippine_qr_input_spec.rb +42 -0
- data/spec/models/problem_details_spec.rb +60 -0
- data/spec/models/provider_attachments_spec.rb +36 -0
- data/spec/models/provider_info_spec.rb +7 -1
- data/spec/models/provider_information_spec.rb +48 -0
- data/spec/models/{disclosed_fields_spec.rb → provider_input_spec.rb} +18 -24
- data/spec/models/recommend_request_spec.rb +60 -0
- data/spec/models/recommend_response_spec.rb +48 -0
- data/spec/models/refresh_step_content_request_spec.rb +36 -0
- data/spec/models/refresh_step_content_response_spec.rb +36 -0
- data/spec/models/result_collection_method_spec.rb +30 -0
- data/spec/models/{validation_result_spec.rb → result_collection_spec.rb} +9 -9
- data/spec/models/{verification_fail_code_spec.rb → session_error_code_spec.rb} +7 -7
- data/spec/models/session_ordering_spec.rb +1 -1
- data/spec/models/session_spec.rb +4 -10
- data/spec/models/{session_fail_code_spec.rb → sex_spec.rb} +7 -7
- data/spec/models/{create_session_request_spec.rb → south_africa_nid_input_spec.rb} +11 -11
- data/spec/models/step_refresh_info_spec.rb +48 -0
- data/spec/spec_helper.rb +1 -1
- data/trinsic_api.gemspec +1 -1
- metadata +173 -61
- data/docs/CreateSessionRequest.md +0 -24
- data/docs/DisclosedFields.md +0 -40
- data/docs/DisclosedFieldsRequest.md +0 -40
- data/docs/IdentityLookupResponse.md +0 -18
- data/docs/ValidationResult.md +0 -20
- data/docs/Verification.md +0 -20
- data/lib/trinsic_api/models/session_fail_code.rb +0 -45
- data/lib/trinsic_api/models/verification_fail_code.rb +0 -43
@@ -0,0 +1,217 @@
|
|
1
|
+
=begin
|
2
|
+
#Trinsic API
|
3
|
+
|
4
|
+
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v1
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.8.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module TrinsicApi
|
17
|
+
# Known identity data of an individual being verified. Provide this to Trinsic during Session creation to enable improved identity provider selection recommendations.
|
18
|
+
class KnownIdentityData
|
19
|
+
# Known identity data specific to the person being verified
|
20
|
+
attr_accessor :person
|
21
|
+
|
22
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
23
|
+
def self.attribute_map
|
24
|
+
{
|
25
|
+
:'person' => :'person'
|
26
|
+
}
|
27
|
+
end
|
28
|
+
|
29
|
+
# Returns all the JSON keys this model knows about
|
30
|
+
def self.acceptable_attributes
|
31
|
+
attribute_map.values
|
32
|
+
end
|
33
|
+
|
34
|
+
# Attribute type mapping.
|
35
|
+
def self.openapi_types
|
36
|
+
{
|
37
|
+
:'person' => :'KnownPersonData'
|
38
|
+
}
|
39
|
+
end
|
40
|
+
|
41
|
+
# List of attributes with nullable: true
|
42
|
+
def self.openapi_nullable
|
43
|
+
Set.new([
|
44
|
+
:'person'
|
45
|
+
])
|
46
|
+
end
|
47
|
+
|
48
|
+
# Initializes the object
|
49
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
50
|
+
def initialize(attributes = {})
|
51
|
+
if (!attributes.is_a?(Hash))
|
52
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::KnownIdentityData` initialize method"
|
53
|
+
end
|
54
|
+
|
55
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
56
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
57
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
58
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::KnownIdentityData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
59
|
+
end
|
60
|
+
h[k.to_sym] = v
|
61
|
+
}
|
62
|
+
|
63
|
+
if attributes.key?(:'person')
|
64
|
+
self.person = attributes[:'person']
|
65
|
+
end
|
66
|
+
end
|
67
|
+
|
68
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
69
|
+
# @return Array for valid properties with the reasons
|
70
|
+
def list_invalid_properties
|
71
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
72
|
+
invalid_properties = Array.new
|
73
|
+
invalid_properties
|
74
|
+
end
|
75
|
+
|
76
|
+
# Check to see if the all the properties in the model are valid
|
77
|
+
# @return true if the model is valid
|
78
|
+
def valid?
|
79
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
80
|
+
true
|
81
|
+
end
|
82
|
+
|
83
|
+
# Checks equality by comparing each attribute.
|
84
|
+
# @param [Object] Object to be compared
|
85
|
+
def ==(o)
|
86
|
+
return true if self.equal?(o)
|
87
|
+
self.class == o.class &&
|
88
|
+
person == o.person
|
89
|
+
end
|
90
|
+
|
91
|
+
# @see the `==` method
|
92
|
+
# @param [Object] Object to be compared
|
93
|
+
def eql?(o)
|
94
|
+
self == o
|
95
|
+
end
|
96
|
+
|
97
|
+
# Calculates hash code according to all attributes.
|
98
|
+
# @return [Integer] Hash code
|
99
|
+
def hash
|
100
|
+
[person].hash
|
101
|
+
end
|
102
|
+
|
103
|
+
# Builds the object from hash
|
104
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
105
|
+
# @return [Object] Returns the model itself
|
106
|
+
def self.build_from_hash(attributes)
|
107
|
+
return nil unless attributes.is_a?(Hash)
|
108
|
+
attributes = attributes.transform_keys(&:to_sym)
|
109
|
+
transformed_hash = {}
|
110
|
+
openapi_types.each_pair do |key, type|
|
111
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
112
|
+
transformed_hash["#{key}"] = nil
|
113
|
+
elsif type =~ /\AArray<(.*)>/i
|
114
|
+
# check to ensure the input is an array given that the attribute
|
115
|
+
# is documented as an array but the input is not
|
116
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
117
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
118
|
+
end
|
119
|
+
elsif !attributes[attribute_map[key]].nil?
|
120
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
121
|
+
end
|
122
|
+
end
|
123
|
+
new(transformed_hash)
|
124
|
+
end
|
125
|
+
|
126
|
+
# Deserializes the data based on type
|
127
|
+
# @param string type Data type
|
128
|
+
# @param string value Value to be deserialized
|
129
|
+
# @return [Object] Deserialized data
|
130
|
+
def self._deserialize(type, value)
|
131
|
+
case type.to_sym
|
132
|
+
when :Time
|
133
|
+
Time.parse(value)
|
134
|
+
when :Date
|
135
|
+
Date.parse(value)
|
136
|
+
when :String
|
137
|
+
value.to_s
|
138
|
+
when :Integer
|
139
|
+
value.to_i
|
140
|
+
when :Float
|
141
|
+
value.to_f
|
142
|
+
when :Boolean
|
143
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
144
|
+
true
|
145
|
+
else
|
146
|
+
false
|
147
|
+
end
|
148
|
+
when :Object
|
149
|
+
# generic object (usually a Hash), return directly
|
150
|
+
value
|
151
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
152
|
+
inner_type = Regexp.last_match[:inner_type]
|
153
|
+
value.map { |v| _deserialize(inner_type, v) }
|
154
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
155
|
+
k_type = Regexp.last_match[:k_type]
|
156
|
+
v_type = Regexp.last_match[:v_type]
|
157
|
+
{}.tap do |hash|
|
158
|
+
value.each do |k, v|
|
159
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
160
|
+
end
|
161
|
+
end
|
162
|
+
else # model
|
163
|
+
# models (e.g. Pet) or oneOf
|
164
|
+
klass = TrinsicApi.const_get(type)
|
165
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
166
|
+
end
|
167
|
+
end
|
168
|
+
|
169
|
+
# Returns the string representation of the object
|
170
|
+
# @return [String] String presentation of the object
|
171
|
+
def to_s
|
172
|
+
to_hash.to_s
|
173
|
+
end
|
174
|
+
|
175
|
+
# to_body is an alias to to_hash (backward compatibility)
|
176
|
+
# @return [Hash] Returns the object in the form of hash
|
177
|
+
def to_body
|
178
|
+
to_hash
|
179
|
+
end
|
180
|
+
|
181
|
+
# Returns the object in the form of hash
|
182
|
+
# @return [Hash] Returns the object in the form of hash
|
183
|
+
def to_hash
|
184
|
+
hash = {}
|
185
|
+
self.class.attribute_map.each_pair do |attr, param|
|
186
|
+
value = self.send(attr)
|
187
|
+
if value.nil?
|
188
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
189
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
190
|
+
end
|
191
|
+
|
192
|
+
hash[param] = _to_hash(value)
|
193
|
+
end
|
194
|
+
hash
|
195
|
+
end
|
196
|
+
|
197
|
+
# Outputs non-array value in the form of hash
|
198
|
+
# For object, use to_hash. Otherwise, just return the value
|
199
|
+
# @param [Object] value Any valid value
|
200
|
+
# @return [Hash] Returns the value in the form of hash
|
201
|
+
def _to_hash(value)
|
202
|
+
if value.is_a?(Array)
|
203
|
+
value.compact.map { |v| _to_hash(v) }
|
204
|
+
elsif value.is_a?(Hash)
|
205
|
+
{}.tap do |hash|
|
206
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
207
|
+
end
|
208
|
+
elsif value.respond_to? :to_hash
|
209
|
+
value.to_hash
|
210
|
+
else
|
211
|
+
value
|
212
|
+
end
|
213
|
+
end
|
214
|
+
|
215
|
+
end
|
216
|
+
|
217
|
+
end
|
@@ -1,5 +1,5 @@
|
|
1
1
|
=begin
|
2
|
-
#
|
2
|
+
#Trinsic API
|
3
3
|
|
4
4
|
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
5
|
|
@@ -14,46 +14,42 @@ require 'date'
|
|
14
14
|
require 'time'
|
15
15
|
|
16
16
|
module TrinsicApi
|
17
|
-
class
|
18
|
-
|
19
|
-
|
17
|
+
class KnownPersonData
|
18
|
+
# Given (first) name of the individual
|
20
19
|
attr_accessor :given_name
|
21
20
|
|
21
|
+
# Family (last) name of the individual
|
22
22
|
attr_accessor :family_name
|
23
23
|
|
24
|
-
|
25
|
-
|
26
|
-
attr_accessor :date_of_birth
|
27
|
-
|
28
|
-
attr_accessor :country
|
29
|
-
|
30
|
-
attr_accessor :issue_date
|
24
|
+
# Middle name of the individual
|
25
|
+
attr_accessor :middle_name
|
31
26
|
|
32
|
-
|
27
|
+
# Full name of the individual.
|
28
|
+
attr_accessor :full_name
|
33
29
|
|
34
|
-
|
30
|
+
# Suffix of the individual
|
31
|
+
attr_accessor :suffix
|
35
32
|
|
36
|
-
|
33
|
+
# The phone number (with preceding + character and country code) of the individual being verified
|
34
|
+
attr_accessor :phone_number
|
37
35
|
|
38
|
-
|
36
|
+
# The address of the individual being verified
|
37
|
+
attr_accessor :address
|
39
38
|
|
40
|
-
|
39
|
+
# Date of birth of the individual, in the format \"YYYY-MM-DD\"
|
40
|
+
attr_accessor :date_of_birth
|
41
41
|
|
42
42
|
# Attribute mapping from ruby-style variable name to JSON key.
|
43
43
|
def self.attribute_map
|
44
44
|
{
|
45
|
-
:'id_number' => :'idNumber',
|
46
45
|
:'given_name' => :'givenName',
|
47
46
|
:'family_name' => :'familyName',
|
47
|
+
:'middle_name' => :'middleName',
|
48
|
+
:'full_name' => :'fullName',
|
49
|
+
:'suffix' => :'suffix',
|
50
|
+
:'phone_number' => :'phoneNumber',
|
48
51
|
:'address' => :'address',
|
49
|
-
:'date_of_birth' => :'dateOfBirth'
|
50
|
-
:'country' => :'country',
|
51
|
-
:'issue_date' => :'issueDate',
|
52
|
-
:'expiration_date' => :'expirationDate',
|
53
|
-
:'document_front' => :'documentFront',
|
54
|
-
:'document_back' => :'documentBack',
|
55
|
-
:'document_portrait' => :'documentPortrait',
|
56
|
-
:'selfie' => :'selfie'
|
52
|
+
:'date_of_birth' => :'dateOfBirth'
|
57
53
|
}
|
58
54
|
end
|
59
55
|
|
@@ -65,24 +61,28 @@ module TrinsicApi
|
|
65
61
|
# Attribute type mapping.
|
66
62
|
def self.openapi_types
|
67
63
|
{
|
68
|
-
:'
|
69
|
-
:'
|
70
|
-
:'
|
71
|
-
:'
|
72
|
-
:'
|
73
|
-
:'
|
74
|
-
:'
|
75
|
-
:'
|
76
|
-
:'document_front' => :'Boolean',
|
77
|
-
:'document_back' => :'Boolean',
|
78
|
-
:'document_portrait' => :'Boolean',
|
79
|
-
:'selfie' => :'Boolean'
|
64
|
+
:'given_name' => :'String',
|
65
|
+
:'family_name' => :'String',
|
66
|
+
:'middle_name' => :'String',
|
67
|
+
:'full_name' => :'String',
|
68
|
+
:'suffix' => :'String',
|
69
|
+
:'phone_number' => :'String',
|
70
|
+
:'address' => :'KnownAddress',
|
71
|
+
:'date_of_birth' => :'String'
|
80
72
|
}
|
81
73
|
end
|
82
74
|
|
83
75
|
# List of attributes with nullable: true
|
84
76
|
def self.openapi_nullable
|
85
77
|
Set.new([
|
78
|
+
:'given_name',
|
79
|
+
:'family_name',
|
80
|
+
:'middle_name',
|
81
|
+
:'full_name',
|
82
|
+
:'suffix',
|
83
|
+
:'phone_number',
|
84
|
+
:'address',
|
85
|
+
:'date_of_birth'
|
86
86
|
])
|
87
87
|
end
|
88
88
|
|
@@ -90,21 +90,17 @@ module TrinsicApi
|
|
90
90
|
# @param [Hash] attributes Model attributes in the form of hash
|
91
91
|
def initialize(attributes = {})
|
92
92
|
if (!attributes.is_a?(Hash))
|
93
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::
|
93
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::KnownPersonData` initialize method"
|
94
94
|
end
|
95
95
|
|
96
96
|
# check to see if the attribute exists and convert string to symbol for hash key
|
97
97
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
98
98
|
if (!self.class.attribute_map.key?(k.to_sym))
|
99
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::
|
99
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::KnownPersonData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
100
100
|
end
|
101
101
|
h[k.to_sym] = v
|
102
102
|
}
|
103
103
|
|
104
|
-
if attributes.key?(:'id_number')
|
105
|
-
self.id_number = attributes[:'id_number']
|
106
|
-
end
|
107
|
-
|
108
104
|
if attributes.key?(:'given_name')
|
109
105
|
self.given_name = attributes[:'given_name']
|
110
106
|
end
|
@@ -113,40 +109,28 @@ module TrinsicApi
|
|
113
109
|
self.family_name = attributes[:'family_name']
|
114
110
|
end
|
115
111
|
|
116
|
-
if attributes.key?(:'
|
117
|
-
self.
|
118
|
-
end
|
119
|
-
|
120
|
-
if attributes.key?(:'date_of_birth')
|
121
|
-
self.date_of_birth = attributes[:'date_of_birth']
|
122
|
-
end
|
123
|
-
|
124
|
-
if attributes.key?(:'country')
|
125
|
-
self.country = attributes[:'country']
|
112
|
+
if attributes.key?(:'middle_name')
|
113
|
+
self.middle_name = attributes[:'middle_name']
|
126
114
|
end
|
127
115
|
|
128
|
-
if attributes.key?(:'
|
129
|
-
self.
|
116
|
+
if attributes.key?(:'full_name')
|
117
|
+
self.full_name = attributes[:'full_name']
|
130
118
|
end
|
131
119
|
|
132
|
-
if attributes.key?(:'
|
133
|
-
self.
|
120
|
+
if attributes.key?(:'suffix')
|
121
|
+
self.suffix = attributes[:'suffix']
|
134
122
|
end
|
135
123
|
|
136
|
-
if attributes.key?(:'
|
137
|
-
self.
|
124
|
+
if attributes.key?(:'phone_number')
|
125
|
+
self.phone_number = attributes[:'phone_number']
|
138
126
|
end
|
139
127
|
|
140
|
-
if attributes.key?(:'
|
141
|
-
self.
|
142
|
-
end
|
143
|
-
|
144
|
-
if attributes.key?(:'document_portrait')
|
145
|
-
self.document_portrait = attributes[:'document_portrait']
|
128
|
+
if attributes.key?(:'address')
|
129
|
+
self.address = attributes[:'address']
|
146
130
|
end
|
147
131
|
|
148
|
-
if attributes.key?(:'
|
149
|
-
self.
|
132
|
+
if attributes.key?(:'date_of_birth')
|
133
|
+
self.date_of_birth = attributes[:'date_of_birth']
|
150
134
|
end
|
151
135
|
end
|
152
136
|
|
@@ -170,18 +154,14 @@ module TrinsicApi
|
|
170
154
|
def ==(o)
|
171
155
|
return true if self.equal?(o)
|
172
156
|
self.class == o.class &&
|
173
|
-
id_number == o.id_number &&
|
174
157
|
given_name == o.given_name &&
|
175
158
|
family_name == o.family_name &&
|
159
|
+
middle_name == o.middle_name &&
|
160
|
+
full_name == o.full_name &&
|
161
|
+
suffix == o.suffix &&
|
162
|
+
phone_number == o.phone_number &&
|
176
163
|
address == o.address &&
|
177
|
-
date_of_birth == o.date_of_birth
|
178
|
-
country == o.country &&
|
179
|
-
issue_date == o.issue_date &&
|
180
|
-
expiration_date == o.expiration_date &&
|
181
|
-
document_front == o.document_front &&
|
182
|
-
document_back == o.document_back &&
|
183
|
-
document_portrait == o.document_portrait &&
|
184
|
-
selfie == o.selfie
|
164
|
+
date_of_birth == o.date_of_birth
|
185
165
|
end
|
186
166
|
|
187
167
|
# @see the `==` method
|
@@ -193,7 +173,7 @@ module TrinsicApi
|
|
193
173
|
# Calculates hash code according to all attributes.
|
194
174
|
# @return [Integer] Hash code
|
195
175
|
def hash
|
196
|
-
[
|
176
|
+
[given_name, family_name, middle_name, full_name, suffix, phone_number, address, date_of_birth].hash
|
197
177
|
end
|
198
178
|
|
199
179
|
# Builds the object from hash
|