trinsic_api 1.2.0 → 2.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.
Files changed (212) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/docs/AadhaarInput.md +20 -0
  4. data/docs/Address.md +3 -3
  5. data/docs/AttachmentAccessKeys.md +7 -5
  6. data/docs/AttachmentsApi.md +1 -1
  7. data/docs/BangladeshNationalIdInput.md +24 -0
  8. data/docs/BrazilCpfCheckInput.md +18 -0
  9. data/docs/BrazilDigitalCnhInput.md +24 -0
  10. data/docs/CreateAdvancedProviderSessionRequest.md +26 -0
  11. data/docs/CreateAdvancedProviderSessionResponse.md +22 -0
  12. data/docs/CreateHostedProviderSessionRequest.md +22 -0
  13. data/docs/CreateHostedProviderSessionResponse.md +22 -0
  14. data/docs/CreateWidgetSessionRequest.md +22 -0
  15. data/docs/CreateWidgetSessionResponse.md +22 -0
  16. data/docs/DocumentData.md +3 -3
  17. data/docs/DocumentScanAttachments.md +18 -0
  18. data/docs/{SessionState.md → DocumentType.md} +2 -2
  19. data/docs/HttpValidationProblemDetails.md +28 -0
  20. data/docs/IdentityData.md +6 -4
  21. data/docs/IdinInput.md +18 -0
  22. data/docs/IndonesiaNikInput.md +22 -0
  23. data/docs/{FailureMessage.md → IntegrationCapability.md} +2 -5
  24. data/docs/IntegrationLaunchMethod.md +15 -0
  25. data/docs/IntegrationStep.md +22 -0
  26. data/docs/KenyaNidInput.md +28 -0
  27. data/docs/{SessionFailCode.md → Language.md} +2 -2
  28. data/docs/ListProviderContractsResponse.md +18 -0
  29. data/docs/MexicoCurpInput.md +18 -0
  30. data/docs/MobileIdInput.md +22 -0
  31. data/docs/NetworkApi.md +22 -25
  32. data/docs/NigeriaNinInput.md +30 -0
  33. data/docs/PersonData.md +14 -12
  34. data/docs/PhilippineMatchInput.md +26 -0
  35. data/docs/PhilippineQRInput.md +20 -0
  36. data/docs/ProblemDetails.md +26 -0
  37. data/docs/ProviderAttachments.md +18 -0
  38. data/docs/ProviderContract.md +46 -0
  39. data/docs/ProviderInformation.md +3 -3
  40. data/docs/ProviderInput.md +50 -0
  41. data/docs/RecommendRequest.md +2 -6
  42. data/docs/RecommendationInfo.md +24 -0
  43. data/docs/RefreshStepContentRequest.md +18 -0
  44. data/docs/RefreshStepContentResponse.md +18 -0
  45. data/docs/ResultCollection.md +20 -0
  46. data/docs/ResultCollectionMethod.md +15 -0
  47. data/docs/Session.md +6 -8
  48. data/docs/{VerificationFailCode.md → SessionErrorCode.md} +2 -2
  49. data/docs/SessionsApi.md +237 -19
  50. data/docs/Sex.md +15 -0
  51. data/docs/SmartIdInput.md +18 -0
  52. data/docs/SouthAfricaNidInput.md +24 -0
  53. data/docs/SpidInput.md +18 -0
  54. data/docs/StepRefreshInfo.md +22 -0
  55. data/docs/SubProviderMetadata.md +24 -0
  56. data/docs/TrinsicTestDatabaseLookupInput.md +24 -0
  57. data/docs/TrinsicTestSubProvidersInput.md +18 -0
  58. data/lib/trinsic_api/api/attachments_api.rb +3 -3
  59. data/lib/trinsic_api/api/network_api.rb +19 -25
  60. data/lib/trinsic_api/api/sessions_api.rb +219 -21
  61. data/lib/trinsic_api/api_client.rb +1 -1
  62. data/lib/trinsic_api/api_error.rb +1 -1
  63. data/lib/trinsic_api/configuration.rb +1 -1
  64. data/lib/trinsic_api/models/aadhaar_input.rb +227 -0
  65. data/lib/trinsic_api/models/address.rb +16 -10
  66. data/lib/trinsic_api/models/attachment_access_keys.rb +25 -10
  67. data/lib/trinsic_api/models/bangladesh_national_id_input.rb +249 -0
  68. data/lib/trinsic_api/models/brazil_cpf_check_input.rb +261 -0
  69. data/lib/trinsic_api/models/brazil_digital_cnh_input.rb +294 -0
  70. data/lib/trinsic_api/models/cancel_session_response.rb +1 -1
  71. data/lib/trinsic_api/models/create_advanced_provider_session_request.rb +312 -0
  72. data/lib/trinsic_api/models/create_advanced_provider_session_response.rb +256 -0
  73. data/lib/trinsic_api/models/create_hosted_provider_session_request.rb +288 -0
  74. data/lib/trinsic_api/models/create_hosted_provider_session_response.rb +256 -0
  75. data/lib/trinsic_api/models/create_widget_session_request.rb +240 -0
  76. data/lib/trinsic_api/models/create_widget_session_response.rb +256 -0
  77. data/lib/trinsic_api/models/document_data.rb +32 -4
  78. data/lib/trinsic_api/models/{failure_message.rb → document_scan_attachments.rb} +12 -18
  79. data/lib/trinsic_api/models/{session_state.rb → document_type.rb} +9 -11
  80. data/lib/trinsic_api/models/get_attachment_request.rb +1 -1
  81. data/lib/trinsic_api/models/get_attachment_response.rb +1 -1
  82. data/lib/trinsic_api/models/get_session_response.rb +1 -1
  83. data/lib/trinsic_api/models/get_session_result_request.rb +1 -1
  84. data/lib/trinsic_api/models/get_session_result_response.rb +2 -1
  85. data/lib/trinsic_api/models/{known_address.rb → http_validation_problem_details.rb} +55 -51
  86. data/lib/trinsic_api/models/identity_data.rb +16 -6
  87. data/lib/trinsic_api/models/{known_identity_data.rb → idin_input.rb} +13 -13
  88. data/lib/trinsic_api/models/{disclosed_fields_request.rb → indonesia_nik_input.rb} +94 -93
  89. data/lib/trinsic_api/models/integration_capability.rb +44 -0
  90. data/lib/trinsic_api/models/integration_launch_method.rb +42 -0
  91. data/lib/trinsic_api/models/integration_step.rb +275 -0
  92. data/lib/trinsic_api/models/kenya_nid_input.rb +397 -0
  93. data/lib/trinsic_api/models/language.rb +42 -0
  94. data/lib/trinsic_api/models/{validation_result.rb → list_provider_contracts_response.rb} +17 -25
  95. data/lib/trinsic_api/models/list_providers_response.rb +1 -1
  96. data/lib/trinsic_api/models/list_sessions_response.rb +1 -1
  97. data/lib/trinsic_api/models/{create_session_response.rb → mexico_curp_input.rb} +44 -26
  98. data/lib/trinsic_api/models/mobile_id_input.rb +260 -0
  99. data/lib/trinsic_api/models/nigeria_nin_input.rb +383 -0
  100. data/lib/trinsic_api/models/order_direction.rb +1 -1
  101. data/lib/trinsic_api/models/person_data.rb +50 -15
  102. data/lib/trinsic_api/models/{known_person_data.rb → philippine_match_input.rb} +28 -33
  103. data/lib/trinsic_api/models/philippine_qr_input.rb +227 -0
  104. data/lib/trinsic_api/models/{verification.rb → problem_details.rb} +49 -42
  105. data/lib/trinsic_api/models/provider_attachments.rb +215 -0
  106. data/lib/trinsic_api/models/provider_contract.rb +482 -0
  107. data/lib/trinsic_api/models/provider_info.rb +1 -1
  108. data/lib/trinsic_api/models/provider_information.rb +1 -1
  109. data/lib/trinsic_api/models/provider_input.rb +392 -0
  110. data/lib/trinsic_api/models/recommend_request.rb +10 -40
  111. data/lib/trinsic_api/models/recommend_response.rb +1 -1
  112. data/lib/trinsic_api/models/recommendation_info.rb +256 -0
  113. data/lib/trinsic_api/models/refresh_step_content_request.rb +216 -0
  114. data/lib/trinsic_api/models/{identity_lookup_response.rb → refresh_step_content_response.rb} +16 -16
  115. data/lib/trinsic_api/models/result_collection.rb +261 -0
  116. data/lib/trinsic_api/models/result_collection_method.rb +40 -0
  117. data/lib/trinsic_api/models/session.rb +32 -48
  118. data/lib/trinsic_api/models/session_error_code.rb +48 -0
  119. data/lib/trinsic_api/models/session_ordering.rb +1 -1
  120. data/lib/trinsic_api/models/sex.rb +42 -0
  121. data/lib/trinsic_api/models/smart_id_input.rb +216 -0
  122. data/lib/trinsic_api/models/{disclosed_fields.rb → south_africa_nid_input.rb} +107 -154
  123. data/lib/trinsic_api/models/spid_input.rb +216 -0
  124. data/lib/trinsic_api/models/step_refresh_info.rb +256 -0
  125. data/lib/trinsic_api/models/sub_provider_metadata.rb +274 -0
  126. data/lib/trinsic_api/models/trinsic_test_database_lookup_input.rb +249 -0
  127. data/lib/trinsic_api/models/trinsic_test_sub_providers_input.rb +216 -0
  128. data/lib/trinsic_api/version.rb +2 -2
  129. data/lib/trinsic_api.rb +45 -15
  130. data/spec/api/attachments_api_spec.rb +2 -2
  131. data/spec/api/network_api_spec.rb +8 -9
  132. data/spec/api/sessions_api_spec.rb +45 -8
  133. data/spec/models/{verification_spec.rb → aadhaar_input_spec.rb} +9 -9
  134. data/spec/models/address_spec.rb +2 -2
  135. data/spec/models/attachment_access_keys_spec.rb +7 -1
  136. data/spec/models/bangladesh_national_id_input_spec.rb +54 -0
  137. data/spec/models/{identity_lookup_response_spec.rb → brazil_cpf_check_input_spec.rb} +8 -8
  138. data/spec/models/brazil_digital_cnh_input_spec.rb +54 -0
  139. data/spec/models/cancel_session_response_spec.rb +1 -1
  140. data/spec/models/create_advanced_provider_session_request_spec.rb +60 -0
  141. data/spec/models/create_advanced_provider_session_response_spec.rb +48 -0
  142. data/spec/models/create_hosted_provider_session_request_spec.rb +48 -0
  143. data/spec/models/create_hosted_provider_session_response_spec.rb +48 -0
  144. data/spec/models/create_widget_session_request_spec.rb +48 -0
  145. data/spec/models/create_widget_session_response_spec.rb +48 -0
  146. data/spec/models/document_data_spec.rb +1 -1
  147. data/spec/models/document_scan_attachments_spec.rb +36 -0
  148. data/spec/models/{session_state_spec.rb → document_type_spec.rb} +7 -7
  149. data/spec/models/get_attachment_request_spec.rb +1 -1
  150. data/spec/models/get_attachment_response_spec.rb +1 -1
  151. data/spec/models/get_session_response_spec.rb +1 -1
  152. data/spec/models/get_session_result_request_spec.rb +1 -1
  153. data/spec/models/get_session_result_response_spec.rb +1 -1
  154. data/spec/models/http_validation_problem_details_spec.rb +66 -0
  155. data/spec/models/identity_data_spec.rb +7 -1
  156. data/spec/models/{failure_message_spec.rb → idin_input_spec.rb} +8 -8
  157. data/spec/models/indonesia_nik_input_spec.rb +48 -0
  158. data/spec/models/integration_capability_spec.rb +30 -0
  159. data/spec/models/integration_launch_method_spec.rb +30 -0
  160. data/spec/models/integration_step_spec.rb +48 -0
  161. data/spec/models/{known_person_data_spec.rb → kenya_nid_input_spec.rb} +13 -13
  162. data/spec/models/{session_fail_code_spec.rb → language_spec.rb} +7 -7
  163. data/spec/models/list_provider_contracts_response_spec.rb +36 -0
  164. data/spec/models/list_providers_response_spec.rb +1 -1
  165. data/spec/models/list_sessions_response_spec.rb +1 -1
  166. data/spec/models/{known_identity_data_spec.rb → mexico_curp_input_spec.rb} +8 -8
  167. data/spec/models/mobile_id_input_spec.rb +48 -0
  168. data/spec/models/{known_address_spec.rb → nigeria_nin_input_spec.rb} +14 -14
  169. data/spec/models/order_direction_spec.rb +1 -1
  170. data/spec/models/person_data_spec.rb +8 -2
  171. data/spec/models/{create_session_request_spec.rb → philippine_match_input_spec.rb} +12 -12
  172. data/spec/models/{create_session_response_spec.rb → philippine_qr_input_spec.rb} +9 -9
  173. data/spec/models/problem_details_spec.rb +60 -0
  174. data/spec/models/provider_attachments_spec.rb +36 -0
  175. data/spec/models/{disclosed_fields_request_spec.rb → provider_contract_spec.rb} +37 -19
  176. data/spec/models/provider_info_spec.rb +1 -1
  177. data/spec/models/provider_information_spec.rb +1 -1
  178. data/spec/models/{disclosed_fields_spec.rb → provider_input_spec.rb} +49 -19
  179. data/spec/models/recommend_request_spec.rb +2 -14
  180. data/spec/models/recommend_response_spec.rb +1 -1
  181. data/spec/models/recommendation_info_spec.rb +54 -0
  182. data/spec/models/refresh_step_content_request_spec.rb +36 -0
  183. data/spec/models/refresh_step_content_response_spec.rb +36 -0
  184. data/spec/models/result_collection_method_spec.rb +30 -0
  185. data/spec/models/{validation_result_spec.rb → result_collection_spec.rb} +9 -9
  186. data/spec/models/{verification_fail_code_spec.rb → session_error_code_spec.rb} +7 -7
  187. data/spec/models/session_ordering_spec.rb +1 -1
  188. data/spec/models/session_spec.rb +4 -10
  189. data/spec/models/sex_spec.rb +30 -0
  190. data/spec/models/smart_id_input_spec.rb +36 -0
  191. data/spec/models/south_africa_nid_input_spec.rb +54 -0
  192. data/spec/models/spid_input_spec.rb +36 -0
  193. data/spec/models/step_refresh_info_spec.rb +48 -0
  194. data/spec/models/sub_provider_metadata_spec.rb +54 -0
  195. data/spec/models/trinsic_test_database_lookup_input_spec.rb +54 -0
  196. data/spec/models/trinsic_test_sub_providers_input_spec.rb +36 -0
  197. data/spec/spec_helper.rb +1 -1
  198. data/trinsic_api.gemspec +1 -1
  199. metadata +195 -75
  200. data/docs/CreateSessionRequest.md +0 -26
  201. data/docs/CreateSessionResponse.md +0 -20
  202. data/docs/DisclosedFields.md +0 -40
  203. data/docs/DisclosedFieldsRequest.md +0 -40
  204. data/docs/IdentityLookupResponse.md +0 -18
  205. data/docs/KnownAddress.md +0 -30
  206. data/docs/KnownIdentityData.md +0 -18
  207. data/docs/KnownPersonData.md +0 -28
  208. data/docs/ValidationResult.md +0 -20
  209. data/docs/Verification.md +0 -20
  210. data/lib/trinsic_api/models/create_session_request.rb +0 -257
  211. data/lib/trinsic_api/models/session_fail_code.rb +0 -45
  212. data/lib/trinsic_api/models/verification_fail_code.rb +0 -44
@@ -0,0 +1,256 @@
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
+ class CreateWidgetSessionResponse
18
+ # The ID of the newly-created Acceptance Session
19
+ attr_accessor :session_id
20
+
21
+ # The URL that should be used to invoke the Acceptance Session on your user's device. You can use our frontend SDKs to launch the user into the Acceptance Session, or you can redirect the user's browser to this URL. This URL is sensitive and as such can only be obtained once. If you need to obtain it again, you will need to create a new Acceptance Session.
22
+ attr_accessor :launch_url
23
+
24
+ # The `resultsAccessKey` for the Acceptance Session. This is an encrypted payload which contains the decryption key necessary to access the Session's Data Vault. Save this securely in your systems; it must be passed back with any API call which requires access to the Session's Data Vault. Trinsic cannot access a Session's Data Vault without this key.
25
+ attr_accessor :results_access_key
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ def self.attribute_map
29
+ {
30
+ :'session_id' => :'sessionId',
31
+ :'launch_url' => :'launchUrl',
32
+ :'results_access_key' => :'resultsAccessKey'
33
+ }
34
+ end
35
+
36
+ # Returns all the JSON keys this model knows about
37
+ def self.acceptable_attributes
38
+ attribute_map.values
39
+ end
40
+
41
+ # Attribute type mapping.
42
+ def self.openapi_types
43
+ {
44
+ :'session_id' => :'String',
45
+ :'launch_url' => :'String',
46
+ :'results_access_key' => :'String'
47
+ }
48
+ end
49
+
50
+ # List of attributes with nullable: true
51
+ def self.openapi_nullable
52
+ Set.new([
53
+ ])
54
+ end
55
+
56
+ # Initializes the object
57
+ # @param [Hash] attributes Model attributes in the form of hash
58
+ def initialize(attributes = {})
59
+ if (!attributes.is_a?(Hash))
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::CreateWidgetSessionResponse` initialize method"
61
+ end
62
+
63
+ # check to see if the attribute exists and convert string to symbol for hash key
64
+ attributes = attributes.each_with_object({}) { |(k, v), h|
65
+ if (!self.class.attribute_map.key?(k.to_sym))
66
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::CreateWidgetSessionResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
67
+ end
68
+ h[k.to_sym] = v
69
+ }
70
+
71
+ if attributes.key?(:'session_id')
72
+ self.session_id = attributes[:'session_id']
73
+ else
74
+ self.session_id = nil
75
+ end
76
+
77
+ if attributes.key?(:'launch_url')
78
+ self.launch_url = attributes[:'launch_url']
79
+ else
80
+ self.launch_url = nil
81
+ end
82
+
83
+ if attributes.key?(:'results_access_key')
84
+ self.results_access_key = attributes[:'results_access_key']
85
+ else
86
+ self.results_access_key = nil
87
+ end
88
+ end
89
+
90
+ # Show invalid properties with the reasons. Usually used together with valid?
91
+ # @return Array for valid properties with the reasons
92
+ def list_invalid_properties
93
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
94
+ invalid_properties = Array.new
95
+ if @session_id.nil?
96
+ invalid_properties.push('invalid value for "session_id", session_id cannot be nil.')
97
+ end
98
+
99
+ if @launch_url.nil?
100
+ invalid_properties.push('invalid value for "launch_url", launch_url cannot be nil.')
101
+ end
102
+
103
+ if @results_access_key.nil?
104
+ invalid_properties.push('invalid value for "results_access_key", results_access_key cannot be nil.')
105
+ end
106
+
107
+ invalid_properties
108
+ end
109
+
110
+ # Check to see if the all the properties in the model are valid
111
+ # @return true if the model is valid
112
+ def valid?
113
+ warn '[DEPRECATED] the `valid?` method is obsolete'
114
+ return false if @session_id.nil?
115
+ return false if @launch_url.nil?
116
+ return false if @results_access_key.nil?
117
+ true
118
+ end
119
+
120
+ # Checks equality by comparing each attribute.
121
+ # @param [Object] Object to be compared
122
+ def ==(o)
123
+ return true if self.equal?(o)
124
+ self.class == o.class &&
125
+ session_id == o.session_id &&
126
+ launch_url == o.launch_url &&
127
+ results_access_key == o.results_access_key
128
+ end
129
+
130
+ # @see the `==` method
131
+ # @param [Object] Object to be compared
132
+ def eql?(o)
133
+ self == o
134
+ end
135
+
136
+ # Calculates hash code according to all attributes.
137
+ # @return [Integer] Hash code
138
+ def hash
139
+ [session_id, launch_url, results_access_key].hash
140
+ end
141
+
142
+ # Builds the object from hash
143
+ # @param [Hash] attributes Model attributes in the form of hash
144
+ # @return [Object] Returns the model itself
145
+ def self.build_from_hash(attributes)
146
+ return nil unless attributes.is_a?(Hash)
147
+ attributes = attributes.transform_keys(&:to_sym)
148
+ transformed_hash = {}
149
+ openapi_types.each_pair do |key, type|
150
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
151
+ transformed_hash["#{key}"] = nil
152
+ elsif type =~ /\AArray<(.*)>/i
153
+ # check to ensure the input is an array given that the attribute
154
+ # is documented as an array but the input is not
155
+ if attributes[attribute_map[key]].is_a?(Array)
156
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
157
+ end
158
+ elsif !attributes[attribute_map[key]].nil?
159
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
160
+ end
161
+ end
162
+ new(transformed_hash)
163
+ end
164
+
165
+ # Deserializes the data based on type
166
+ # @param string type Data type
167
+ # @param string value Value to be deserialized
168
+ # @return [Object] Deserialized data
169
+ def self._deserialize(type, value)
170
+ case type.to_sym
171
+ when :Time
172
+ Time.parse(value)
173
+ when :Date
174
+ Date.parse(value)
175
+ when :String
176
+ value.to_s
177
+ when :Integer
178
+ value.to_i
179
+ when :Float
180
+ value.to_f
181
+ when :Boolean
182
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
183
+ true
184
+ else
185
+ false
186
+ end
187
+ when :Object
188
+ # generic object (usually a Hash), return directly
189
+ value
190
+ when /\AArray<(?<inner_type>.+)>\z/
191
+ inner_type = Regexp.last_match[:inner_type]
192
+ value.map { |v| _deserialize(inner_type, v) }
193
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
194
+ k_type = Regexp.last_match[:k_type]
195
+ v_type = Regexp.last_match[:v_type]
196
+ {}.tap do |hash|
197
+ value.each do |k, v|
198
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
199
+ end
200
+ end
201
+ else # model
202
+ # models (e.g. Pet) or oneOf
203
+ klass = TrinsicApi.const_get(type)
204
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
205
+ end
206
+ end
207
+
208
+ # Returns the string representation of the object
209
+ # @return [String] String presentation of the object
210
+ def to_s
211
+ to_hash.to_s
212
+ end
213
+
214
+ # to_body is an alias to to_hash (backward compatibility)
215
+ # @return [Hash] Returns the object in the form of hash
216
+ def to_body
217
+ to_hash
218
+ end
219
+
220
+ # Returns the object in the form of hash
221
+ # @return [Hash] Returns the object in the form of hash
222
+ def to_hash
223
+ hash = {}
224
+ self.class.attribute_map.each_pair do |attr, param|
225
+ value = self.send(attr)
226
+ if value.nil?
227
+ is_nullable = self.class.openapi_nullable.include?(attr)
228
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
229
+ end
230
+
231
+ hash[param] = _to_hash(value)
232
+ end
233
+ hash
234
+ end
235
+
236
+ # Outputs non-array value in the form of hash
237
+ # For object, use to_hash. Otherwise, just return the value
238
+ # @param [Object] value Any valid value
239
+ # @return [Hash] Returns the value in the form of hash
240
+ def _to_hash(value)
241
+ if value.is_a?(Array)
242
+ value.compact.map { |v| _to_hash(v) }
243
+ elsif value.is_a?(Hash)
244
+ {}.tap do |hash|
245
+ value.each { |k, v| hash[k] = _to_hash(v) }
246
+ end
247
+ elsif value.respond_to? :to_hash
248
+ value.to_hash
249
+ else
250
+ value
251
+ end
252
+ end
253
+
254
+ end
255
+
256
+ end
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -27,6 +27,28 @@ module TrinsicApi
27
27
 
28
28
  attr_accessor :issuing_authority
29
29
 
30
+ class EnumAttributeValidator
31
+ attr_reader :datatype
32
+ attr_reader :allowable_values
33
+
34
+ def initialize(datatype, allowable_values)
35
+ @allowable_values = allowable_values.map do |value|
36
+ case datatype.to_s
37
+ when /Integer/i
38
+ value.to_i
39
+ when /Float/i
40
+ value.to_f
41
+ else
42
+ value
43
+ end
44
+ end
45
+ end
46
+
47
+ def valid?(value)
48
+ !value || allowable_values.include?(value)
49
+ end
50
+ end
51
+
30
52
  # Attribute mapping from ruby-style variable name to JSON key.
31
53
  def self.attribute_map
32
54
  {
@@ -47,10 +69,10 @@ module TrinsicApi
47
69
  # Attribute type mapping.
48
70
  def self.openapi_types
49
71
  {
50
- :'type' => :'String',
72
+ :'type' => :'DocumentType',
51
73
  :'number' => :'String',
52
- :'issue_date' => :'String',
53
- :'expiration_date' => :'String',
74
+ :'issue_date' => :'Date',
75
+ :'expiration_date' => :'Date',
54
76
  :'issuing_country' => :'String',
55
77
  :'issuing_authority' => :'String'
56
78
  }
@@ -59,6 +81,12 @@ module TrinsicApi
59
81
  # List of attributes with nullable: true
60
82
  def self.openapi_nullable
61
83
  Set.new([
84
+ :'type',
85
+ :'number',
86
+ :'issue_date',
87
+ :'expiration_date',
88
+ :'issuing_country',
89
+ :'issuing_authority'
62
90
  ])
63
91
  end
64
92
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -14,13 +14,13 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module TrinsicApi
17
- class FailureMessage
18
- attr_accessor :message
17
+ class DocumentScanAttachments
18
+ attr_accessor :report
19
19
 
20
20
  # Attribute mapping from ruby-style variable name to JSON key.
21
21
  def self.attribute_map
22
22
  {
23
- :'message' => :'message'
23
+ :'report' => :'report'
24
24
  }
25
25
  end
26
26
 
@@ -32,13 +32,14 @@ module TrinsicApi
32
32
  # Attribute type mapping.
33
33
  def self.openapi_types
34
34
  {
35
- :'message' => :'String'
35
+ :'report' => :'String'
36
36
  }
37
37
  end
38
38
 
39
39
  # List of attributes with nullable: true
40
40
  def self.openapi_nullable
41
41
  Set.new([
42
+ :'report'
42
43
  ])
43
44
  end
44
45
 
@@ -46,21 +47,19 @@ module TrinsicApi
46
47
  # @param [Hash] attributes Model attributes in the form of hash
47
48
  def initialize(attributes = {})
48
49
  if (!attributes.is_a?(Hash))
49
- fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::FailureMessage` initialize method"
50
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::DocumentScanAttachments` initialize method"
50
51
  end
51
52
 
52
53
  # check to see if the attribute exists and convert string to symbol for hash key
53
54
  attributes = attributes.each_with_object({}) { |(k, v), h|
54
55
  if (!self.class.attribute_map.key?(k.to_sym))
55
- fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::FailureMessage`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::DocumentScanAttachments`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
57
  end
57
58
  h[k.to_sym] = v
58
59
  }
59
60
 
60
- if attributes.key?(:'message')
61
- self.message = attributes[:'message']
62
- else
63
- self.message = nil
61
+ if attributes.key?(:'report')
62
+ self.report = attributes[:'report']
64
63
  end
65
64
  end
66
65
 
@@ -69,10 +68,6 @@ module TrinsicApi
69
68
  def list_invalid_properties
70
69
  warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
71
70
  invalid_properties = Array.new
72
- if @message.nil?
73
- invalid_properties.push('invalid value for "message", message cannot be nil.')
74
- end
75
-
76
71
  invalid_properties
77
72
  end
78
73
 
@@ -80,7 +75,6 @@ module TrinsicApi
80
75
  # @return true if the model is valid
81
76
  def valid?
82
77
  warn '[DEPRECATED] the `valid?` method is obsolete'
83
- return false if @message.nil?
84
78
  true
85
79
  end
86
80
 
@@ -89,7 +83,7 @@ module TrinsicApi
89
83
  def ==(o)
90
84
  return true if self.equal?(o)
91
85
  self.class == o.class &&
92
- message == o.message
86
+ report == o.report
93
87
  end
94
88
 
95
89
  # @see the `==` method
@@ -101,7 +95,7 @@ module TrinsicApi
101
95
  # Calculates hash code according to all attributes.
102
96
  # @return [Integer] Hash code
103
97
  def hash
104
- [message].hash
98
+ [report].hash
105
99
  end
106
100
 
107
101
  # Builds the object from hash
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -14,16 +14,14 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module TrinsicApi
17
- class SessionState
18
- IDV_CREATED = "IdvCreated".freeze
19
- IDV_INITIATED = "IdvInitiated".freeze
20
- IDV_AUTHENTICATING = "IdvAuthenticating".freeze
21
- IDV_IN_PROGRESS = "IdvInProgress".freeze
22
- IDV_SUCCESS = "IdvSuccess".freeze
23
- IDV_FAILED = "IdvFailed".freeze
17
+ class DocumentType
18
+ PASSPORT = "Passport".freeze
19
+ DRIVERS_LICENSE = "DriversLicense".freeze
20
+ NATIONAL_ID = "NationalId".freeze
21
+ ID_CARD = "IdCard".freeze
24
22
 
25
23
  def self.all_vars
26
- @all_vars ||= [IDV_CREATED, IDV_INITIATED, IDV_AUTHENTICATING, IDV_IN_PROGRESS, IDV_SUCCESS, IDV_FAILED].freeze
24
+ @all_vars ||= [PASSPORT, DRIVERS_LICENSE, NATIONAL_ID, ID_CARD].freeze
27
25
  end
28
26
 
29
27
  # Builds the enum from string
@@ -37,8 +35,8 @@ module TrinsicApi
37
35
  # @param [String] The enum value in the form of the string
38
36
  # @return [String] The enum value
39
37
  def build_from_hash(value)
40
- return value if SessionState.all_vars.include?(value)
41
- raise "Invalid ENUM value #{value} for class #SessionState"
38
+ return value if DocumentType.all_vars.include?(value)
39
+ raise "Invalid ENUM value #{value} for class #DocumentType"
42
40
  end
43
41
  end
44
42
  end
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -43,6 +43,7 @@ module TrinsicApi
43
43
  # List of attributes with nullable: true
44
44
  def self.openapi_nullable
45
45
  Set.new([
46
+ :'identity_data'
46
47
  ])
47
48
  end
48
49
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Connect API
2
+ #Trinsic API
3
3
 
4
4
  #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
5
 
@@ -14,32 +14,28 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module TrinsicApi
17
- # Address information for an individual
18
- class KnownAddress
19
- attr_accessor :line1
17
+ class HttpValidationProblemDetails
18
+ attr_accessor :type
20
19
 
21
- attr_accessor :line2
20
+ attr_accessor :title
22
21
 
23
- attr_accessor :line3
22
+ attr_accessor :status
24
23
 
25
- attr_accessor :city
24
+ attr_accessor :detail
26
25
 
27
- attr_accessor :state
26
+ attr_accessor :instance
28
27
 
29
- attr_accessor :postal_code
30
-
31
- attr_accessor :country
28
+ attr_accessor :errors
32
29
 
33
30
  # Attribute mapping from ruby-style variable name to JSON key.
34
31
  def self.attribute_map
35
32
  {
36
- :'line1' => :'line1',
37
- :'line2' => :'line2',
38
- :'line3' => :'line3',
39
- :'city' => :'city',
40
- :'state' => :'state',
41
- :'postal_code' => :'postalCode',
42
- :'country' => :'country'
33
+ :'type' => :'type',
34
+ :'title' => :'title',
35
+ :'status' => :'status',
36
+ :'detail' => :'detail',
37
+ :'instance' => :'instance',
38
+ :'errors' => :'errors'
43
39
  }
44
40
  end
45
41
 
@@ -51,63 +47,72 @@ module TrinsicApi
51
47
  # Attribute type mapping.
52
48
  def self.openapi_types
53
49
  {
54
- :'line1' => :'String',
55
- :'line2' => :'String',
56
- :'line3' => :'String',
57
- :'city' => :'String',
58
- :'state' => :'String',
59
- :'postal_code' => :'String',
60
- :'country' => :'String'
50
+ :'type' => :'String',
51
+ :'title' => :'String',
52
+ :'status' => :'Integer',
53
+ :'detail' => :'String',
54
+ :'instance' => :'String',
55
+ :'errors' => :'Hash<String, Array<String>>'
61
56
  }
62
57
  end
63
58
 
64
59
  # List of attributes with nullable: true
65
60
  def self.openapi_nullable
66
61
  Set.new([
62
+ :'type',
63
+ :'title',
64
+ :'status',
65
+ :'detail',
66
+ :'instance',
67
67
  ])
68
68
  end
69
69
 
70
+ # List of class defined in allOf (OpenAPI v3)
71
+ def self.openapi_all_of
72
+ [
73
+ :'ProblemDetails'
74
+ ]
75
+ end
76
+
70
77
  # Initializes the object
71
78
  # @param [Hash] attributes Model attributes in the form of hash
72
79
  def initialize(attributes = {})
73
80
  if (!attributes.is_a?(Hash))
74
- fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::KnownAddress` initialize method"
81
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::HttpValidationProblemDetails` initialize method"
75
82
  end
76
83
 
77
84
  # check to see if the attribute exists and convert string to symbol for hash key
78
85
  attributes = attributes.each_with_object({}) { |(k, v), h|
79
86
  if (!self.class.attribute_map.key?(k.to_sym))
80
- fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::KnownAddress`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
87
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::HttpValidationProblemDetails`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
81
88
  end
82
89
  h[k.to_sym] = v
83
90
  }
84
91
 
85
- if attributes.key?(:'line1')
86
- self.line1 = attributes[:'line1']
92
+ if attributes.key?(:'type')
93
+ self.type = attributes[:'type']
87
94
  end
88
95
 
89
- if attributes.key?(:'line2')
90
- self.line2 = attributes[:'line2']
96
+ if attributes.key?(:'title')
97
+ self.title = attributes[:'title']
91
98
  end
92
99
 
93
- if attributes.key?(:'line3')
94
- self.line3 = attributes[:'line3']
100
+ if attributes.key?(:'status')
101
+ self.status = attributes[:'status']
95
102
  end
96
103
 
97
- if attributes.key?(:'city')
98
- self.city = attributes[:'city']
104
+ if attributes.key?(:'detail')
105
+ self.detail = attributes[:'detail']
99
106
  end
100
107
 
101
- if attributes.key?(:'state')
102
- self.state = attributes[:'state']
108
+ if attributes.key?(:'instance')
109
+ self.instance = attributes[:'instance']
103
110
  end
104
111
 
105
- if attributes.key?(:'postal_code')
106
- self.postal_code = attributes[:'postal_code']
107
- end
108
-
109
- if attributes.key?(:'country')
110
- self.country = attributes[:'country']
112
+ if attributes.key?(:'errors')
113
+ if (value = attributes[:'errors']).is_a?(Hash)
114
+ self.errors = value
115
+ end
111
116
  end
112
117
  end
113
118
 
@@ -131,13 +136,12 @@ module TrinsicApi
131
136
  def ==(o)
132
137
  return true if self.equal?(o)
133
138
  self.class == o.class &&
134
- line1 == o.line1 &&
135
- line2 == o.line2 &&
136
- line3 == o.line3 &&
137
- city == o.city &&
138
- state == o.state &&
139
- postal_code == o.postal_code &&
140
- country == o.country
139
+ type == o.type &&
140
+ title == o.title &&
141
+ status == o.status &&
142
+ detail == o.detail &&
143
+ instance == o.instance &&
144
+ errors == o.errors
141
145
  end
142
146
 
143
147
  # @see the `==` method
@@ -149,7 +153,7 @@ module TrinsicApi
149
153
  # Calculates hash code according to all attributes.
150
154
  # @return [Integer] Hash code
151
155
  def hash
152
- [line1, line2, line3, city, state, postal_code, country].hash
156
+ [type, title, status, detail, instance, errors].hash
153
157
  end
154
158
 
155
159
  # Builds the object from hash