trinsic_api 2.2.0.pre.alpha1 → 2.3.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 (70) hide show
  1. checksums.yaml +4 -4
  2. data/docs/AddRedirectUriResponse.md +18 -0
  3. data/docs/ContractField.md +2 -0
  4. data/docs/ContractIdentifierField.md +22 -0
  5. data/docs/CreateVerificationProfileResponse.md +18 -0
  6. data/docs/EnvironmentRedirectUrisAddRequest.md +18 -0
  7. data/docs/EnvironmentRedirectUrisApi.md +222 -0
  8. data/docs/FaydaProviderOutput.md +18 -0
  9. data/docs/Identifier.md +22 -0
  10. data/docs/IdentityData.md +5 -1
  11. data/docs/ListEnvironmentRedirectUrisResponse.md +20 -0
  12. data/docs/ListVerificationProfilesResponse.md +20 -0
  13. data/docs/MexicoCurpProviderOutput.md +18 -0
  14. data/docs/NetworkApi.md +7 -5
  15. data/docs/ProviderContract.md +2 -0
  16. data/docs/ProviderOutput.md +22 -0
  17. data/docs/RedirectUriResponse.md +20 -0
  18. data/docs/SessionsApi.md +14 -14
  19. data/docs/SpidBillingInformation.md +22 -0
  20. data/docs/SpidInput.md +3 -1
  21. data/docs/SpidProviderOutput.md +26 -0
  22. data/docs/VerificationProfileResponse.md +28 -0
  23. data/docs/VerificationProfilesApi.md +231 -0
  24. data/lib/trinsic_api/api/environment_redirect_uris_api.rb +228 -0
  25. data/lib/trinsic_api/api/network_api.rb +6 -2
  26. data/lib/trinsic_api/api/sessions_api.rb +18 -18
  27. data/lib/trinsic_api/api/verification_profiles_api.rb +273 -0
  28. data/lib/trinsic_api/models/add_redirect_uri_response.rb +237 -0
  29. data/lib/trinsic_api/models/contract_field.rb +28 -1
  30. data/lib/trinsic_api/models/contract_identifier_field.rb +315 -0
  31. data/lib/trinsic_api/models/create_verification_profile_response.rb +238 -0
  32. data/lib/trinsic_api/models/environment_redirect_uris_add_request.rb +237 -0
  33. data/lib/trinsic_api/models/fayda_provider_output.rb +222 -0
  34. data/lib/trinsic_api/models/identifier.rb +289 -0
  35. data/lib/trinsic_api/models/identity_data.rb +43 -5
  36. data/lib/trinsic_api/models/list_environment_redirect_uris_response.rb +268 -0
  37. data/lib/trinsic_api/models/list_verification_profiles_response.rb +266 -0
  38. data/lib/trinsic_api/models/mexico_curp_provider_output.rb +222 -0
  39. data/lib/trinsic_api/models/provider_contract.rb +14 -1
  40. data/lib/trinsic_api/models/provider_output.rb +241 -0
  41. data/lib/trinsic_api/models/redirect_uri_response.rb +263 -0
  42. data/lib/trinsic_api/models/spid_billing_information.rb +293 -0
  43. data/lib/trinsic_api/models/spid_input.rb +16 -5
  44. data/lib/trinsic_api/models/spid_provider_output.rb +266 -0
  45. data/lib/trinsic_api/models/verification_profile_response.rb +375 -0
  46. data/lib/trinsic_api/version.rb +1 -1
  47. data/lib/trinsic_api.rb +16 -0
  48. data/spec/api/environment_redirect_uris_api_spec.rb +72 -0
  49. data/spec/api/network_api_spec.rb +3 -1
  50. data/spec/api/sessions_api_spec.rb +2 -2
  51. data/spec/api/verification_profiles_api_spec.rb +76 -0
  52. data/spec/models/add_redirect_uri_response_spec.rb +36 -0
  53. data/spec/models/contract_field_spec.rb +6 -0
  54. data/spec/models/contract_identifier_field_spec.rb +48 -0
  55. data/spec/models/create_verification_profile_response_spec.rb +36 -0
  56. data/spec/models/environment_redirect_uris_add_request_spec.rb +36 -0
  57. data/spec/models/fayda_provider_output_spec.rb +36 -0
  58. data/spec/models/identifier_spec.rb +48 -0
  59. data/spec/models/identity_data_spec.rb +12 -0
  60. data/spec/models/list_environment_redirect_uris_response_spec.rb +42 -0
  61. data/spec/models/list_verification_profiles_response_spec.rb +42 -0
  62. data/spec/models/mexico_curp_provider_output_spec.rb +36 -0
  63. data/spec/models/provider_contract_spec.rb +6 -0
  64. data/spec/models/provider_output_spec.rb +48 -0
  65. data/spec/models/redirect_uri_response_spec.rb +42 -0
  66. data/spec/models/spid_billing_information_spec.rb +48 -0
  67. data/spec/models/spid_input_spec.rb +6 -0
  68. data/spec/models/spid_provider_output_spec.rb +60 -0
  69. data/spec/models/verification_profile_response_spec.rb +66 -0
  70. metadata +66 -2
@@ -0,0 +1,315 @@
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
+ # Information about an identifier a Provider returns in verification results.
18
+ class ContractIdentifierField
19
+ # The scope of the identifier as it appears in verification results.
20
+ attr_accessor :scope
21
+
22
+ # Indicates when this field will be present in verification results.
23
+ attr_accessor :outputted
24
+
25
+ # A human-readable description of the identifier, written by Trinsic.
26
+ attr_accessor :description
27
+
28
+ class EnumAttributeValidator
29
+ attr_reader :datatype
30
+ attr_reader :allowable_values
31
+
32
+ def initialize(datatype, allowable_values)
33
+ @allowable_values = allowable_values.map do |value|
34
+ case datatype.to_s
35
+ when /Integer/i
36
+ value.to_i
37
+ when /Float/i
38
+ value.to_f
39
+ else
40
+ value
41
+ end
42
+ end
43
+ end
44
+
45
+ def valid?(value)
46
+ !value || allowable_values.include?(value)
47
+ end
48
+ end
49
+
50
+ # Attribute mapping from ruby-style variable name to JSON key.
51
+ def self.attribute_map
52
+ {
53
+ :'scope' => :'scope',
54
+ :'outputted' => :'outputted',
55
+ :'description' => :'description'
56
+ }
57
+ end
58
+
59
+ # Returns attribute mapping this model knows about
60
+ def self.acceptable_attribute_map
61
+ attribute_map
62
+ end
63
+
64
+ # Returns all the JSON keys this model knows about
65
+ def self.acceptable_attributes
66
+ acceptable_attribute_map.values
67
+ end
68
+
69
+ # Attribute type mapping.
70
+ def self.openapi_types
71
+ {
72
+ :'scope' => :'String',
73
+ :'outputted' => :'FieldAvailability',
74
+ :'description' => :'String'
75
+ }
76
+ end
77
+
78
+ # List of attributes with nullable: true
79
+ def self.openapi_nullable
80
+ Set.new([
81
+ ])
82
+ end
83
+
84
+ # Initializes the object
85
+ # @param [Hash] attributes Model attributes in the form of hash
86
+ def initialize(attributes = {})
87
+ if (!attributes.is_a?(Hash))
88
+ fail ArgumentError, "The input argument (attributes) must be a hash in `TrinsicApi::ContractIdentifierField` initialize method"
89
+ end
90
+
91
+ # check to see if the attribute exists and convert string to symbol for hash key
92
+ acceptable_attribute_map = self.class.acceptable_attribute_map
93
+ attributes = attributes.each_with_object({}) { |(k, v), h|
94
+ if (!acceptable_attribute_map.key?(k.to_sym))
95
+ fail ArgumentError, "`#{k}` is not a valid attribute in `TrinsicApi::ContractIdentifierField`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
96
+ end
97
+ h[k.to_sym] = v
98
+ }
99
+
100
+ if attributes.key?(:'scope')
101
+ self.scope = attributes[:'scope']
102
+ else
103
+ self.scope = nil
104
+ end
105
+
106
+ if attributes.key?(:'outputted')
107
+ self.outputted = attributes[:'outputted']
108
+ else
109
+ self.outputted = nil
110
+ end
111
+
112
+ if attributes.key?(:'description')
113
+ self.description = attributes[:'description']
114
+ else
115
+ self.description = nil
116
+ end
117
+ end
118
+
119
+ # Show invalid properties with the reasons. Usually used together with valid?
120
+ # @return Array for valid properties with the reasons
121
+ def list_invalid_properties
122
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
123
+ invalid_properties = Array.new
124
+ if @scope.nil?
125
+ invalid_properties.push('invalid value for "scope", scope cannot be nil.')
126
+ end
127
+
128
+ if @outputted.nil?
129
+ invalid_properties.push('invalid value for "outputted", outputted cannot be nil.')
130
+ end
131
+
132
+ if @description.nil?
133
+ invalid_properties.push('invalid value for "description", description cannot be nil.')
134
+ end
135
+
136
+ invalid_properties
137
+ end
138
+
139
+ # Check to see if the all the properties in the model are valid
140
+ # @return true if the model is valid
141
+ def valid?
142
+ warn '[DEPRECATED] the `valid?` method is obsolete'
143
+ return false if @scope.nil?
144
+ return false if @outputted.nil?
145
+ return false if @description.nil?
146
+ true
147
+ end
148
+
149
+ # Custom attribute writer method with validation
150
+ # @param [Object] scope Value to be assigned
151
+ def scope=(scope)
152
+ if scope.nil?
153
+ fail ArgumentError, 'scope cannot be nil'
154
+ end
155
+
156
+ @scope = scope
157
+ end
158
+
159
+ # Custom attribute writer method with validation
160
+ # @param [Object] outputted Value to be assigned
161
+ def outputted=(outputted)
162
+ if outputted.nil?
163
+ fail ArgumentError, 'outputted cannot be nil'
164
+ end
165
+
166
+ @outputted = outputted
167
+ end
168
+
169
+ # Custom attribute writer method with validation
170
+ # @param [Object] description Value to be assigned
171
+ def description=(description)
172
+ if description.nil?
173
+ fail ArgumentError, 'description cannot be nil'
174
+ end
175
+
176
+ @description = description
177
+ end
178
+
179
+ # Checks equality by comparing each attribute.
180
+ # @param [Object] Object to be compared
181
+ def ==(o)
182
+ return true if self.equal?(o)
183
+ self.class == o.class &&
184
+ scope == o.scope &&
185
+ outputted == o.outputted &&
186
+ description == o.description
187
+ end
188
+
189
+ # @see the `==` method
190
+ # @param [Object] Object to be compared
191
+ def eql?(o)
192
+ self == o
193
+ end
194
+
195
+ # Calculates hash code according to all attributes.
196
+ # @return [Integer] Hash code
197
+ def hash
198
+ [scope, outputted, description].hash
199
+ end
200
+
201
+ # Builds the object from hash
202
+ # @param [Hash] attributes Model attributes in the form of hash
203
+ # @return [Object] Returns the model itself
204
+ def self.build_from_hash(attributes)
205
+ return nil unless attributes.is_a?(Hash)
206
+ attributes = attributes.transform_keys(&:to_sym)
207
+ transformed_hash = {}
208
+ openapi_types.each_pair do |key, type|
209
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
210
+ transformed_hash["#{key}"] = nil
211
+ elsif type =~ /\AArray<(.*)>/i
212
+ # check to ensure the input is an array given that the attribute
213
+ # is documented as an array but the input is not
214
+ if attributes[attribute_map[key]].is_a?(Array)
215
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
216
+ end
217
+ elsif !attributes[attribute_map[key]].nil?
218
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
219
+ end
220
+ end
221
+ new(transformed_hash)
222
+ end
223
+
224
+ # Deserializes the data based on type
225
+ # @param string type Data type
226
+ # @param string value Value to be deserialized
227
+ # @return [Object] Deserialized data
228
+ def self._deserialize(type, value)
229
+ case type.to_sym
230
+ when :Time
231
+ Time.parse(value)
232
+ when :Date
233
+ Date.parse(value)
234
+ when :String
235
+ value.to_s
236
+ when :Integer
237
+ value.to_i
238
+ when :Float
239
+ value.to_f
240
+ when :Boolean
241
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
242
+ true
243
+ else
244
+ false
245
+ end
246
+ when :Object
247
+ # generic object (usually a Hash), return directly
248
+ value
249
+ when /\AArray<(?<inner_type>.+)>\z/
250
+ inner_type = Regexp.last_match[:inner_type]
251
+ value.map { |v| _deserialize(inner_type, v) }
252
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
253
+ k_type = Regexp.last_match[:k_type]
254
+ v_type = Regexp.last_match[:v_type]
255
+ {}.tap do |hash|
256
+ value.each do |k, v|
257
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
258
+ end
259
+ end
260
+ else # model
261
+ # models (e.g. Pet) or oneOf
262
+ klass = TrinsicApi.const_get(type)
263
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
264
+ end
265
+ end
266
+
267
+ # Returns the string representation of the object
268
+ # @return [String] String presentation of the object
269
+ def to_s
270
+ to_hash.to_s
271
+ end
272
+
273
+ # to_body is an alias to to_hash (backward compatibility)
274
+ # @return [Hash] Returns the object in the form of hash
275
+ def to_body
276
+ to_hash
277
+ end
278
+
279
+ # Returns the object in the form of hash
280
+ # @return [Hash] Returns the object in the form of hash
281
+ def to_hash
282
+ hash = {}
283
+ self.class.attribute_map.each_pair do |attr, param|
284
+ value = self.send(attr)
285
+ if value.nil?
286
+ is_nullable = self.class.openapi_nullable.include?(attr)
287
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
288
+ end
289
+
290
+ hash[param] = _to_hash(value)
291
+ end
292
+ hash
293
+ end
294
+
295
+ # Outputs non-array value in the form of hash
296
+ # For object, use to_hash. Otherwise, just return the value
297
+ # @param [Object] value Any valid value
298
+ # @return [Hash] Returns the value in the form of hash
299
+ def _to_hash(value)
300
+ if value.is_a?(Array)
301
+ value.compact.map { |v| _to_hash(v) }
302
+ elsif value.is_a?(Hash)
303
+ {}.tap do |hash|
304
+ value.each { |k, v| hash[k] = _to_hash(v) }
305
+ end
306
+ elsif value.respond_to? :to_hash
307
+ value.to_hash
308
+ else
309
+ value
310
+ end
311
+ end
312
+
313
+ end
314
+
315
+ 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 CreateVerificationProfileResponse
18
+ # The ID of the verification profile
19
+ attr_accessor :id
20
+
21
+ # Attribute mapping from ruby-style variable name to JSON key.
22
+ def self.attribute_map
23
+ {
24
+ :'id' => :'id'
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
+ :'id' => :'String'
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::CreateVerificationProfileResponse` 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::CreateVerificationProfileResponse`. 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?(:'id')
68
+ self.id = attributes[:'id']
69
+ else
70
+ self.id = 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 @id.nil?
80
+ invalid_properties.push('invalid value for "id", id 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 @id.nil?
91
+ true
92
+ end
93
+
94
+ # Custom attribute writer method with validation
95
+ # @param [Object] id Value to be assigned
96
+ def id=(id)
97
+ if id.nil?
98
+ fail ArgumentError, 'id cannot be nil'
99
+ end
100
+
101
+ @id = id
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
+ id == o.id
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
+ [id].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