trinsic_api 2.1.1.pre.alpha2 → 2.2.0.pre.alpha1

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 (82) hide show
  1. checksums.yaml +4 -4
  2. data/docs/AppleWalletInput.md +18 -0
  3. data/docs/AttachmentsApi.md +1 -1
  4. data/docs/{CreateAdvancedProviderSessionRequest.md → CreateDirectProviderSessionRequest.md} +5 -3
  5. data/docs/{CreateAdvancedProviderSessionResponse.md → CreateDirectProviderSessionResponse.md} +2 -2
  6. data/docs/CreateHostedProviderSessionRequest.md +3 -1
  7. data/docs/CreateMdlExchangeRequest.md +32 -0
  8. data/docs/CreateMdlExchangeResponse.md +22 -0
  9. data/docs/CreateWidgetSessionRequest.md +3 -1
  10. data/docs/ExternalMdlFieldData.md +20 -0
  11. data/docs/FinalizeMdlExchangeRequest.md +24 -0
  12. data/docs/FinalizeMdlExchangeResponse.md +24 -0
  13. data/docs/GetAttachmentRequest.md +3 -1
  14. data/docs/GoogleWalletInput.md +18 -0
  15. data/docs/MdlApi.md +151 -0
  16. data/docs/MdlCertificateData.md +26 -0
  17. data/docs/MdlExchangeMechanism.md +15 -0
  18. data/docs/MdlFieldDataType.md +15 -0
  19. data/docs/MdlIdentityData.md +22 -0
  20. data/docs/NetworkApi.md +21 -18
  21. data/docs/ProviderContract.md +7 -5
  22. data/docs/ProviderInput.md +4 -0
  23. data/docs/RecommendRequest.md +2 -0
  24. data/docs/SessionsApi.md +103 -27
  25. data/docs/SubmitNativeChallengeResponseRequest.md +20 -0
  26. data/docs/SubmitNativeChallengeResponseResponse.md +18 -0
  27. data/lib/trinsic_api/api/mdl_api.rb +150 -0
  28. data/lib/trinsic_api/api/network_api.rb +22 -14
  29. data/lib/trinsic_api/api/sessions_api.rb +99 -23
  30. data/lib/trinsic_api/models/apple_wallet_input.rb +244 -0
  31. data/lib/trinsic_api/models/{create_advanced_provider_session_request.rb → create_direct_provider_session_request.rb} +32 -5
  32. data/lib/trinsic_api/models/{create_advanced_provider_session_response.rb → create_direct_provider_session_response.rb} +3 -3
  33. data/lib/trinsic_api/models/create_hosted_provider_session_request.rb +29 -2
  34. data/lib/trinsic_api/models/create_mdl_exchange_request.rb +404 -0
  35. data/lib/trinsic_api/models/create_mdl_exchange_response.rb +292 -0
  36. data/lib/trinsic_api/models/create_widget_session_request.rb +29 -2
  37. data/lib/trinsic_api/models/external_mdl_field_data.rb +287 -0
  38. data/lib/trinsic_api/models/finalize_mdl_exchange_request.rb +319 -0
  39. data/lib/trinsic_api/models/finalize_mdl_exchange_response.rb +287 -0
  40. data/lib/trinsic_api/models/get_attachment_request.rb +31 -4
  41. data/lib/trinsic_api/models/google_wallet_input.rb +244 -0
  42. data/lib/trinsic_api/models/integration_capability.rb +2 -1
  43. data/lib/trinsic_api/models/integration_launch_method.rb +2 -1
  44. data/lib/trinsic_api/models/integration_step.rb +1 -1
  45. data/lib/trinsic_api/models/mdl_certificate_data.rb +346 -0
  46. data/lib/trinsic_api/models/mdl_exchange_mechanism.rb +40 -0
  47. data/lib/trinsic_api/models/mdl_field_data_type.rb +43 -0
  48. data/lib/trinsic_api/models/mdl_identity_data.rb +294 -0
  49. data/lib/trinsic_api/models/provider_contract.rb +33 -6
  50. data/lib/trinsic_api/models/provider_input.rb +23 -1
  51. data/lib/trinsic_api/models/recommend_request.rb +28 -1
  52. data/lib/trinsic_api/models/result_collection_method.rb +2 -1
  53. data/lib/trinsic_api/models/session_error_code.rb +3 -1
  54. data/lib/trinsic_api/models/submit_native_challenge_response_request.rb +283 -0
  55. data/lib/trinsic_api/models/submit_native_challenge_response_response.rb +238 -0
  56. data/lib/trinsic_api/version.rb +1 -1
  57. data/lib/trinsic_api.rb +16 -2
  58. data/spec/api/mdl_api_spec.rb +59 -0
  59. data/spec/api/network_api_spec.rb +3 -3
  60. data/spec/api/sessions_api_spec.rb +21 -7
  61. data/spec/models/apple_wallet_input_spec.rb +36 -0
  62. data/spec/models/{create_advanced_provider_session_request_spec.rb → create_direct_provider_session_request_spec.rb} +12 -6
  63. data/spec/models/{create_advanced_provider_session_response_spec.rb → create_direct_provider_session_response_spec.rb} +6 -6
  64. data/spec/models/create_hosted_provider_session_request_spec.rb +6 -0
  65. data/spec/models/create_mdl_exchange_request_spec.rb +78 -0
  66. data/spec/models/create_mdl_exchange_response_spec.rb +48 -0
  67. data/spec/models/create_widget_session_request_spec.rb +6 -0
  68. data/spec/models/external_mdl_field_data_spec.rb +42 -0
  69. data/spec/models/finalize_mdl_exchange_request_spec.rb +54 -0
  70. data/spec/models/finalize_mdl_exchange_response_spec.rb +54 -0
  71. data/spec/models/get_attachment_request_spec.rb +6 -0
  72. data/spec/models/google_wallet_input_spec.rb +36 -0
  73. data/spec/models/mdl_certificate_data_spec.rb +60 -0
  74. data/spec/models/mdl_exchange_mechanism_spec.rb +30 -0
  75. data/spec/models/mdl_field_data_type_spec.rb +30 -0
  76. data/spec/models/mdl_identity_data_spec.rb +48 -0
  77. data/spec/models/provider_contract_spec.rb +6 -0
  78. data/spec/models/provider_input_spec.rb +12 -0
  79. data/spec/models/recommend_request_spec.rb +6 -0
  80. data/spec/models/submit_native_challenge_response_request_spec.rb +42 -0
  81. data/spec/models/submit_native_challenge_response_response_spec.rb +36 -0
  82. metadata +124 -68
@@ -0,0 +1,283 @@
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.13.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module TrinsicApi
17
+ class SubmitNativeChallengeResponseRequest
18
+ # The Results Access Key for the Session in question
19
+ attr_accessor :results_access_key
20
+
21
+ # The response token retrieved from a Trinsic UI SDK's performMdlExchange() call.
22
+ attr_accessor :response_token
23
+
24
+ # Attribute mapping from ruby-style variable name to JSON key.
25
+ def self.attribute_map
26
+ {
27
+ :'results_access_key' => :'resultsAccessKey',
28
+ :'response_token' => :'responseToken'
29
+ }
30
+ end
31
+
32
+ # Returns attribute mapping this model knows about
33
+ def self.acceptable_attribute_map
34
+ attribute_map
35
+ end
36
+
37
+ # Returns all the JSON keys this model knows about
38
+ def self.acceptable_attributes
39
+ acceptable_attribute_map.values
40
+ end
41
+
42
+ # Attribute type mapping.
43
+ def self.openapi_types
44
+ {
45
+ :'results_access_key' => :'String',
46
+ :'response_token' => :'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::SubmitNativeChallengeResponseRequest` initialize method"
61
+ end
62
+
63
+ # check to see if the attribute exists and convert string to symbol for hash key
64
+ acceptable_attribute_map = self.class.acceptable_attribute_map
65
+ attributes = attributes.each_with_object({}) { |(k, v), h|
66
+ if (!acceptable_attribute_map.key?(k.to_sym))
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::SubmitNativeChallengeResponseRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
68
+ end
69
+ h[k.to_sym] = v
70
+ }
71
+
72
+ if attributes.key?(:'results_access_key')
73
+ self.results_access_key = attributes[:'results_access_key']
74
+ else
75
+ self.results_access_key = nil
76
+ end
77
+
78
+ if attributes.key?(:'response_token')
79
+ self.response_token = attributes[:'response_token']
80
+ else
81
+ self.response_token = nil
82
+ end
83
+ end
84
+
85
+ # Show invalid properties with the reasons. Usually used together with valid?
86
+ # @return Array for valid properties with the reasons
87
+ def list_invalid_properties
88
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
89
+ invalid_properties = Array.new
90
+ if @results_access_key.nil?
91
+ invalid_properties.push('invalid value for "results_access_key", results_access_key cannot be nil.')
92
+ end
93
+
94
+ if @results_access_key.to_s.length < 1
95
+ invalid_properties.push('invalid value for "results_access_key", the character length must be great than or equal to 1.')
96
+ end
97
+
98
+ if @response_token.nil?
99
+ invalid_properties.push('invalid value for "response_token", response_token cannot be nil.')
100
+ end
101
+
102
+ if @response_token.to_s.length < 1
103
+ invalid_properties.push('invalid value for "response_token", the character length must be great than or equal to 1.')
104
+ end
105
+
106
+ invalid_properties
107
+ end
108
+
109
+ # Check to see if the all the properties in the model are valid
110
+ # @return true if the model is valid
111
+ def valid?
112
+ warn '[DEPRECATED] the `valid?` method is obsolete'
113
+ return false if @results_access_key.nil?
114
+ return false if @results_access_key.to_s.length < 1
115
+ return false if @response_token.nil?
116
+ return false if @response_token.to_s.length < 1
117
+ true
118
+ end
119
+
120
+ # Custom attribute writer method with validation
121
+ # @param [Object] results_access_key Value to be assigned
122
+ def results_access_key=(results_access_key)
123
+ if results_access_key.nil?
124
+ fail ArgumentError, 'results_access_key cannot be nil'
125
+ end
126
+
127
+ if results_access_key.to_s.length < 1
128
+ fail ArgumentError, 'invalid value for "results_access_key", the character length must be great than or equal to 1.'
129
+ end
130
+
131
+ @results_access_key = results_access_key
132
+ end
133
+
134
+ # Custom attribute writer method with validation
135
+ # @param [Object] response_token Value to be assigned
136
+ def response_token=(response_token)
137
+ if response_token.nil?
138
+ fail ArgumentError, 'response_token cannot be nil'
139
+ end
140
+
141
+ if response_token.to_s.length < 1
142
+ fail ArgumentError, 'invalid value for "response_token", the character length must be great than or equal to 1.'
143
+ end
144
+
145
+ @response_token = response_token
146
+ end
147
+
148
+ # Checks equality by comparing each attribute.
149
+ # @param [Object] Object to be compared
150
+ def ==(o)
151
+ return true if self.equal?(o)
152
+ self.class == o.class &&
153
+ results_access_key == o.results_access_key &&
154
+ response_token == o.response_token
155
+ end
156
+
157
+ # @see the `==` method
158
+ # @param [Object] Object to be compared
159
+ def eql?(o)
160
+ self == o
161
+ end
162
+
163
+ # Calculates hash code according to all attributes.
164
+ # @return [Integer] Hash code
165
+ def hash
166
+ [results_access_key, response_token].hash
167
+ end
168
+
169
+ # Builds the object from hash
170
+ # @param [Hash] attributes Model attributes in the form of hash
171
+ # @return [Object] Returns the model itself
172
+ def self.build_from_hash(attributes)
173
+ return nil unless attributes.is_a?(Hash)
174
+ attributes = attributes.transform_keys(&:to_sym)
175
+ transformed_hash = {}
176
+ openapi_types.each_pair do |key, type|
177
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
178
+ transformed_hash["#{key}"] = nil
179
+ elsif type =~ /\AArray<(.*)>/i
180
+ # check to ensure the input is an array given that the attribute
181
+ # is documented as an array but the input is not
182
+ if attributes[attribute_map[key]].is_a?(Array)
183
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
184
+ end
185
+ elsif !attributes[attribute_map[key]].nil?
186
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
187
+ end
188
+ end
189
+ new(transformed_hash)
190
+ end
191
+
192
+ # Deserializes the data based on type
193
+ # @param string type Data type
194
+ # @param string value Value to be deserialized
195
+ # @return [Object] Deserialized data
196
+ def self._deserialize(type, value)
197
+ case type.to_sym
198
+ when :Time
199
+ Time.parse(value)
200
+ when :Date
201
+ Date.parse(value)
202
+ when :String
203
+ value.to_s
204
+ when :Integer
205
+ value.to_i
206
+ when :Float
207
+ value.to_f
208
+ when :Boolean
209
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
210
+ true
211
+ else
212
+ false
213
+ end
214
+ when :Object
215
+ # generic object (usually a Hash), return directly
216
+ value
217
+ when /\AArray<(?<inner_type>.+)>\z/
218
+ inner_type = Regexp.last_match[:inner_type]
219
+ value.map { |v| _deserialize(inner_type, v) }
220
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
221
+ k_type = Regexp.last_match[:k_type]
222
+ v_type = Regexp.last_match[:v_type]
223
+ {}.tap do |hash|
224
+ value.each do |k, v|
225
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
226
+ end
227
+ end
228
+ else # model
229
+ # models (e.g. Pet) or oneOf
230
+ klass = TrinsicApi.const_get(type)
231
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
232
+ end
233
+ end
234
+
235
+ # Returns the string representation of the object
236
+ # @return [String] String presentation of the object
237
+ def to_s
238
+ to_hash.to_s
239
+ end
240
+
241
+ # to_body is an alias to to_hash (backward compatibility)
242
+ # @return [Hash] Returns the object in the form of hash
243
+ def to_body
244
+ to_hash
245
+ end
246
+
247
+ # Returns the object in the form of hash
248
+ # @return [Hash] Returns the object in the form of hash
249
+ def to_hash
250
+ hash = {}
251
+ self.class.attribute_map.each_pair do |attr, param|
252
+ value = self.send(attr)
253
+ if value.nil?
254
+ is_nullable = self.class.openapi_nullable.include?(attr)
255
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
256
+ end
257
+
258
+ hash[param] = _to_hash(value)
259
+ end
260
+ hash
261
+ end
262
+
263
+ # Outputs non-array value in the form of hash
264
+ # For object, use to_hash. Otherwise, just return the value
265
+ # @param [Object] value Any valid value
266
+ # @return [Hash] Returns the value in the form of hash
267
+ def _to_hash(value)
268
+ if value.is_a?(Array)
269
+ value.compact.map { |v| _to_hash(v) }
270
+ elsif value.is_a?(Hash)
271
+ {}.tap do |hash|
272
+ value.each { |k, v| hash[k] = _to_hash(v) }
273
+ end
274
+ elsif value.respond_to? :to_hash
275
+ value.to_hash
276
+ else
277
+ value
278
+ end
279
+ end
280
+
281
+ end
282
+
283
+ end
@@ -0,0 +1,238 @@
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.13.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module TrinsicApi
17
+ class SubmitNativeChallengeResponseResponse
18
+ # The Session for which the challenge token was submitted
19
+ attr_accessor :session
20
+
21
+ # Attribute mapping from ruby-style variable name to JSON key.
22
+ def self.attribute_map
23
+ {
24
+ :'session' => :'session'
25
+ }
26
+ end
27
+
28
+ # Returns attribute mapping this model knows about
29
+ def self.acceptable_attribute_map
30
+ attribute_map
31
+ end
32
+
33
+ # Returns all the JSON keys this model knows about
34
+ def self.acceptable_attributes
35
+ acceptable_attribute_map.values
36
+ end
37
+
38
+ # Attribute type mapping.
39
+ def self.openapi_types
40
+ {
41
+ :'session' => :'Session'
42
+ }
43
+ end
44
+
45
+ # List of attributes with nullable: true
46
+ def self.openapi_nullable
47
+ Set.new([
48
+ ])
49
+ end
50
+
51
+ # Initializes the object
52
+ # @param [Hash] attributes Model attributes in the form of hash
53
+ def initialize(attributes = {})
54
+ if (!attributes.is_a?(Hash))
55
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::SubmitNativeChallengeResponseResponse` initialize method"
56
+ end
57
+
58
+ # check to see if the attribute exists and convert string to symbol for hash key
59
+ acceptable_attribute_map = self.class.acceptable_attribute_map
60
+ attributes = attributes.each_with_object({}) { |(k, v), h|
61
+ if (!acceptable_attribute_map.key?(k.to_sym))
62
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::SubmitNativeChallengeResponseResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
63
+ end
64
+ h[k.to_sym] = v
65
+ }
66
+
67
+ if attributes.key?(:'session')
68
+ self.session = attributes[:'session']
69
+ else
70
+ self.session = nil
71
+ end
72
+ end
73
+
74
+ # Show invalid properties with the reasons. Usually used together with valid?
75
+ # @return Array for valid properties with the reasons
76
+ def list_invalid_properties
77
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
78
+ invalid_properties = Array.new
79
+ if @session.nil?
80
+ invalid_properties.push('invalid value for "session", session cannot be nil.')
81
+ end
82
+
83
+ invalid_properties
84
+ end
85
+
86
+ # Check to see if the all the properties in the model are valid
87
+ # @return true if the model is valid
88
+ def valid?
89
+ warn '[DEPRECATED] the `valid?` method is obsolete'
90
+ return false if @session.nil?
91
+ true
92
+ end
93
+
94
+ # Custom attribute writer method with validation
95
+ # @param [Object] session Value to be assigned
96
+ def session=(session)
97
+ if session.nil?
98
+ fail ArgumentError, 'session cannot be nil'
99
+ end
100
+
101
+ @session = session
102
+ end
103
+
104
+ # Checks equality by comparing each attribute.
105
+ # @param [Object] Object to be compared
106
+ def ==(o)
107
+ return true if self.equal?(o)
108
+ self.class == o.class &&
109
+ session == o.session
110
+ end
111
+
112
+ # @see the `==` method
113
+ # @param [Object] Object to be compared
114
+ def eql?(o)
115
+ self == o
116
+ end
117
+
118
+ # Calculates hash code according to all attributes.
119
+ # @return [Integer] Hash code
120
+ def hash
121
+ [session].hash
122
+ end
123
+
124
+ # Builds the object from hash
125
+ # @param [Hash] attributes Model attributes in the form of hash
126
+ # @return [Object] Returns the model itself
127
+ def self.build_from_hash(attributes)
128
+ return nil unless attributes.is_a?(Hash)
129
+ attributes = attributes.transform_keys(&:to_sym)
130
+ transformed_hash = {}
131
+ openapi_types.each_pair do |key, type|
132
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
133
+ transformed_hash["#{key}"] = nil
134
+ elsif type =~ /\AArray<(.*)>/i
135
+ # check to ensure the input is an array given that the attribute
136
+ # is documented as an array but the input is not
137
+ if attributes[attribute_map[key]].is_a?(Array)
138
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
139
+ end
140
+ elsif !attributes[attribute_map[key]].nil?
141
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
142
+ end
143
+ end
144
+ new(transformed_hash)
145
+ end
146
+
147
+ # Deserializes the data based on type
148
+ # @param string type Data type
149
+ # @param string value Value to be deserialized
150
+ # @return [Object] Deserialized data
151
+ def self._deserialize(type, value)
152
+ case type.to_sym
153
+ when :Time
154
+ Time.parse(value)
155
+ when :Date
156
+ Date.parse(value)
157
+ when :String
158
+ value.to_s
159
+ when :Integer
160
+ value.to_i
161
+ when :Float
162
+ value.to_f
163
+ when :Boolean
164
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
165
+ true
166
+ else
167
+ false
168
+ end
169
+ when :Object
170
+ # generic object (usually a Hash), return directly
171
+ value
172
+ when /\AArray<(?<inner_type>.+)>\z/
173
+ inner_type = Regexp.last_match[:inner_type]
174
+ value.map { |v| _deserialize(inner_type, v) }
175
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
176
+ k_type = Regexp.last_match[:k_type]
177
+ v_type = Regexp.last_match[:v_type]
178
+ {}.tap do |hash|
179
+ value.each do |k, v|
180
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
181
+ end
182
+ end
183
+ else # model
184
+ # models (e.g. Pet) or oneOf
185
+ klass = TrinsicApi.const_get(type)
186
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
187
+ end
188
+ end
189
+
190
+ # Returns the string representation of the object
191
+ # @return [String] String presentation of the object
192
+ def to_s
193
+ to_hash.to_s
194
+ end
195
+
196
+ # to_body is an alias to to_hash (backward compatibility)
197
+ # @return [Hash] Returns the object in the form of hash
198
+ def to_body
199
+ to_hash
200
+ end
201
+
202
+ # Returns the object in the form of hash
203
+ # @return [Hash] Returns the object in the form of hash
204
+ def to_hash
205
+ hash = {}
206
+ self.class.attribute_map.each_pair do |attr, param|
207
+ value = self.send(attr)
208
+ if value.nil?
209
+ is_nullable = self.class.openapi_nullable.include?(attr)
210
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
211
+ end
212
+
213
+ hash[param] = _to_hash(value)
214
+ end
215
+ hash
216
+ end
217
+
218
+ # Outputs non-array value in the form of hash
219
+ # For object, use to_hash. Otherwise, just return the value
220
+ # @param [Object] value Any valid value
221
+ # @return [Hash] Returns the value in the form of hash
222
+ def _to_hash(value)
223
+ if value.is_a?(Array)
224
+ value.compact.map { |v| _to_hash(v) }
225
+ elsif value.is_a?(Hash)
226
+ {}.tap do |hash|
227
+ value.each { |k, v| hash[k] = _to_hash(v) }
228
+ end
229
+ elsif value.respond_to? :to_hash
230
+ value.to_hash
231
+ else
232
+ value
233
+ end
234
+ end
235
+
236
+ end
237
+
238
+ end
@@ -11,5 +11,5 @@ Generator version: 7.13.0
11
11
  =end
12
12
 
13
13
  module TrinsicApi
14
- VERSION = '2.1.1-alpha2'
14
+ VERSION = '2.2.0-alpha1'
15
15
  end
data/lib/trinsic_api.rb CHANGED
@@ -19,27 +19,34 @@ require 'trinsic_api/configuration'
19
19
  # Models
20
20
  require 'trinsic_api/models/aadhaar_input'
21
21
  require 'trinsic_api/models/address'
22
+ require 'trinsic_api/models/apple_wallet_input'
22
23
  require 'trinsic_api/models/attachment_access_keys'
23
24
  require 'trinsic_api/models/bangladesh_nid_input'
24
25
  require 'trinsic_api/models/brazil_cpf_check_input'
25
26
  require 'trinsic_api/models/brazil_digital_cnh_input'
26
27
  require 'trinsic_api/models/cancel_session_response'
27
28
  require 'trinsic_api/models/contract_field'
28
- require 'trinsic_api/models/create_advanced_provider_session_request'
29
- require 'trinsic_api/models/create_advanced_provider_session_response'
29
+ require 'trinsic_api/models/create_direct_provider_session_request'
30
+ require 'trinsic_api/models/create_direct_provider_session_response'
30
31
  require 'trinsic_api/models/create_hosted_provider_session_request'
31
32
  require 'trinsic_api/models/create_hosted_provider_session_response'
33
+ require 'trinsic_api/models/create_mdl_exchange_request'
34
+ require 'trinsic_api/models/create_mdl_exchange_response'
32
35
  require 'trinsic_api/models/create_widget_session_request'
33
36
  require 'trinsic_api/models/create_widget_session_response'
34
37
  require 'trinsic_api/models/document_data'
35
38
  require 'trinsic_api/models/document_scan_attachments'
36
39
  require 'trinsic_api/models/document_type'
40
+ require 'trinsic_api/models/external_mdl_field_data'
37
41
  require 'trinsic_api/models/field_availability'
42
+ require 'trinsic_api/models/finalize_mdl_exchange_request'
43
+ require 'trinsic_api/models/finalize_mdl_exchange_response'
38
44
  require 'trinsic_api/models/get_attachment_request'
39
45
  require 'trinsic_api/models/get_attachment_response'
40
46
  require 'trinsic_api/models/get_session_response'
41
47
  require 'trinsic_api/models/get_session_result_request'
42
48
  require 'trinsic_api/models/get_session_result_response'
49
+ require 'trinsic_api/models/google_wallet_input'
43
50
  require 'trinsic_api/models/http_validation_problem_details'
44
51
  require 'trinsic_api/models/identity_data'
45
52
  require 'trinsic_api/models/idin_input'
@@ -55,6 +62,10 @@ require 'trinsic_api/models/list_providers_response'
55
62
  require 'trinsic_api/models/list_sessions_response'
56
63
  require 'trinsic_api/models/match'
57
64
  require 'trinsic_api/models/match_data'
65
+ require 'trinsic_api/models/mdl_certificate_data'
66
+ require 'trinsic_api/models/mdl_exchange_mechanism'
67
+ require 'trinsic_api/models/mdl_field_data_type'
68
+ require 'trinsic_api/models/mdl_identity_data'
58
69
  require 'trinsic_api/models/mexico_curp_input'
59
70
  require 'trinsic_api/models/mobile_id_input'
60
71
  require 'trinsic_api/models/nigeria_nin_input'
@@ -85,11 +96,14 @@ require 'trinsic_api/models/south_africa_nid_input'
85
96
  require 'trinsic_api/models/spid_input'
86
97
  require 'trinsic_api/models/step_refresh_info'
87
98
  require 'trinsic_api/models/sub_provider_metadata'
99
+ require 'trinsic_api/models/submit_native_challenge_response_request'
100
+ require 'trinsic_api/models/submit_native_challenge_response_response'
88
101
  require 'trinsic_api/models/trinsic_test_database_lookup_input'
89
102
  require 'trinsic_api/models/trinsic_test_sub_providers_input'
90
103
 
91
104
  # APIs
92
105
  require 'trinsic_api/api/attachments_api'
106
+ require 'trinsic_api/api/mdl_api'
93
107
  require 'trinsic_api/api/network_api'
94
108
  require 'trinsic_api/api/sessions_api'
95
109
 
@@ -0,0 +1,59 @@
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.13.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+
16
+ # Unit tests for TrinsicApi::MdlApi
17
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
18
+ # Please update as you see appropriate
19
+ describe 'MdlApi' do
20
+ before do
21
+ # run before each test
22
+ @api_instance = TrinsicApi::MdlApi.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of MdlApi' do
30
+ it 'should create an instance of MdlApi' do
31
+ expect(@api_instance).to be_instance_of(TrinsicApi::MdlApi)
32
+ end
33
+ end
34
+
35
+ # unit tests for create_mdl_exchange
36
+ # Create mDL Exchange
37
+ # Creates a new mDL Exchange, returning an exchange ID, request object string, and context string. mDL Exchanges are ephemeral until completion -- no state is stored within Trinsic until the exchange is finalized. This API currently only supports Google Wallet on Android via Web or Native. Apple Wallet support is coming soon.
38
+ # @param [Hash] opts the optional parameters
39
+ # @option opts [CreateMdlExchangeRequest] :create_mdl_exchange_request
40
+ # @return [CreateMdlExchangeResponse]
41
+ describe 'create_mdl_exchange test' do
42
+ it 'should work' do
43
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
44
+ end
45
+ end
46
+
47
+ # unit tests for finalize_mdl_exchange
48
+ # Finalize mDL Exchange
49
+ # Finalizes an mDL Exchange, processing the results
50
+ # @param [Hash] opts the optional parameters
51
+ # @option opts [FinalizeMdlExchangeRequest] :finalize_mdl_exchange_request
52
+ # @return [FinalizeMdlExchangeResponse]
53
+ describe 'finalize_mdl_exchange test' do
54
+ it 'should work' do
55
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
56
+ end
57
+ end
58
+
59
+ end
@@ -35,6 +35,7 @@ describe 'NetworkApi' do
35
35
  # unit tests for list_provider_contracts
36
36
  # List Provider Contracts
37
37
  # List the contracts for all Providers available to your App. If your App is in test mode, this call will only return Providers available in test mode. If your App is not in test mode, this call will only return Providers available in production.
38
+ # @param verification_profile_id
38
39
  # @param [Hash] opts the optional parameters
39
40
  # @return [ListProviderContractsResponse]
40
41
  describe 'list_provider_contracts test' do
@@ -44,10 +45,9 @@ describe 'NetworkApi' do
44
45
  end
45
46
 
46
47
  # unit tests for list_providers
47
- # List Providers
48
- # List all identity providers available for use
48
+ # @param verification_profile_id
49
49
  # @param [Hash] opts the optional parameters
50
- # @option opts [String] :health Filter providers by health status. Valid values: \&quot;online\&quot;, \&quot;offline\&quot;, \&quot;all\&quot;. Defaults to \&quot;all\&quot;.
50
+ # @option opts [String] :health
51
51
  # @return [ListProvidersResponse]
52
52
  describe 'list_providers test' do
53
53
  it 'should work' do