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