mx-platform-ruby 0.3.0 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (94) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +3 -3
  3. data/README.md +29 -222
  4. data/docs/ChallengeResponse.md +2 -2
  5. data/docs/{ChallengeImageOptions.md → ImageOptionResponse.md} +2 -2
  6. data/docs/{ChallengeOptions.md → OptionResponse.md} +2 -2
  7. data/lib/mx-platform-ruby/models/challenge_response.rb +2 -2
  8. data/lib/mx-platform-ruby/models/{challenge_image_options.rb → image_option_response.rb} +3 -3
  9. data/lib/mx-platform-ruby/models/{challenge_options.rb → option_response.rb} +3 -3
  10. data/lib/mx-platform-ruby/version.rb +1 -1
  11. data/lib/mx-platform-ruby.rb +2 -2
  12. data/openapi/config.yml +1 -1
  13. data/openapi/templates/README.mustache +71 -0
  14. data/spec/models/{challenge_image_options_spec.rb → image_option_response_spec.rb} +6 -6
  15. data/spec/models/{challenge_options_spec.rb → option_response_spec.rb} +6 -6
  16. metadata +88 -190
  17. data/docs/Account.md +0 -96
  18. data/docs/AccountNumber.md +0 -32
  19. data/docs/AccountOwner.md +0 -40
  20. data/docs/Category.md +0 -32
  21. data/docs/Challenge.md +0 -30
  22. data/docs/ChallengeResponseImageOptions.md +0 -22
  23. data/docs/ChallengeResponseOptions.md +0 -20
  24. data/docs/ConnectWidget.md +0 -20
  25. data/docs/Credential.md +0 -26
  26. data/docs/EnhanceTransaction.md +0 -48
  27. data/docs/Holding.md +0 -52
  28. data/docs/InlineResponse200.md +0 -18
  29. data/docs/Institution.md +0 -36
  30. data/docs/Member.md +0 -40
  31. data/docs/MemberStatus.md +0 -34
  32. data/docs/Merchant.md +0 -28
  33. data/docs/OAuthWindow.md +0 -20
  34. data/docs/Pagination.md +0 -24
  35. data/docs/Statement.md +0 -32
  36. data/docs/Tag.md +0 -22
  37. data/docs/Tagging.md +0 -26
  38. data/docs/Transaction.md +0 -88
  39. data/docs/TransactionRule.md +0 -30
  40. data/docs/User.md +0 -26
  41. data/docs/Widget.md +0 -22
  42. data/lib/mx-platform-ruby/models/account.rb +0 -569
  43. data/lib/mx-platform-ruby/models/account_number.rb +0 -281
  44. data/lib/mx-platform-ruby/models/account_owner.rb +0 -317
  45. data/lib/mx-platform-ruby/models/category.rb +0 -281
  46. data/lib/mx-platform-ruby/models/challenge.rb +0 -276
  47. data/lib/mx-platform-ruby/models/challenge_response_image_options.rb +0 -236
  48. data/lib/mx-platform-ruby/models/challenge_response_options.rb +0 -227
  49. data/lib/mx-platform-ruby/models/connect_widget.rb +0 -227
  50. data/lib/mx-platform-ruby/models/credential.rb +0 -254
  51. data/lib/mx-platform-ruby/models/enhance_transaction.rb +0 -353
  52. data/lib/mx-platform-ruby/models/holding.rb +0 -371
  53. data/lib/mx-platform-ruby/models/inline_response200.rb +0 -218
  54. data/lib/mx-platform-ruby/models/institution.rb +0 -299
  55. data/lib/mx-platform-ruby/models/member.rb +0 -317
  56. data/lib/mx-platform-ruby/models/member_status.rb +0 -292
  57. data/lib/mx-platform-ruby/models/merchant.rb +0 -263
  58. data/lib/mx-platform-ruby/models/o_auth_window.rb +0 -227
  59. data/lib/mx-platform-ruby/models/pagination.rb +0 -245
  60. data/lib/mx-platform-ruby/models/statement.rb +0 -281
  61. data/lib/mx-platform-ruby/models/tag.rb +0 -236
  62. data/lib/mx-platform-ruby/models/tagging.rb +0 -254
  63. data/lib/mx-platform-ruby/models/transaction.rb +0 -533
  64. data/lib/mx-platform-ruby/models/transaction_rule.rb +0 -272
  65. data/lib/mx-platform-ruby/models/user.rb +0 -254
  66. data/lib/mx-platform-ruby/models/widget.rb +0 -236
  67. data/openapi/mx_platform_ruby.yml +0 -11
  68. data/pkg/mx-platform-ruby-0.2.0.gem +0 -0
  69. data/pkg/mx-platform-ruby-0.2.1.gem +0 -0
  70. data/spec/models/account_number_spec.rb +0 -76
  71. data/spec/models/account_owner_spec.rb +0 -100
  72. data/spec/models/account_spec.rb +0 -268
  73. data/spec/models/category_spec.rb +0 -76
  74. data/spec/models/challenge_response_image_options_spec.rb +0 -46
  75. data/spec/models/challenge_response_options_spec.rb +0 -40
  76. data/spec/models/challenge_spec.rb +0 -70
  77. data/spec/models/connect_widget_spec.rb +0 -40
  78. data/spec/models/credential_spec.rb +0 -58
  79. data/spec/models/enhance_transaction_spec.rb +0 -124
  80. data/spec/models/holding_spec.rb +0 -136
  81. data/spec/models/inline_response200_spec.rb +0 -34
  82. data/spec/models/institution_spec.rb +0 -88
  83. data/spec/models/member_spec.rb +0 -100
  84. data/spec/models/member_status_spec.rb +0 -82
  85. data/spec/models/merchant_spec.rb +0 -64
  86. data/spec/models/o_auth_window_spec.rb +0 -40
  87. data/spec/models/pagination_spec.rb +0 -52
  88. data/spec/models/statement_spec.rb +0 -76
  89. data/spec/models/tag_spec.rb +0 -46
  90. data/spec/models/tagging_spec.rb +0 -58
  91. data/spec/models/transaction_rule_spec.rb +0 -70
  92. data/spec/models/transaction_spec.rb +0 -244
  93. data/spec/models/user_spec.rb +0 -58
  94. data/spec/models/widget_spec.rb +0 -46
@@ -1,218 +0,0 @@
1
- =begin
2
- #MX Platform API
3
-
4
- #The MX Platform API is a powerful, fully-featured API designed to make aggregating and enhancing financial data easy and reliable. It can seamlessly connect your app or website to tens of thousands of financial institutions.
5
-
6
- The version of the OpenAPI document: 0.1.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 5.2.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module MxPlatformRuby
17
- class InlineResponse200
18
- attr_accessor :tag
19
-
20
- # Attribute mapping from ruby-style variable name to JSON key.
21
- def self.attribute_map
22
- {
23
- :'tag' => :'tag'
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
- :'tag' => :'Tag'
36
- }
37
- end
38
-
39
- # List of attributes with nullable: true
40
- def self.openapi_nullable
41
- Set.new([
42
- ])
43
- end
44
-
45
- # Initializes the object
46
- # @param [Hash] attributes Model attributes in the form of hash
47
- def initialize(attributes = {})
48
- if (!attributes.is_a?(Hash))
49
- fail ArgumentError, "The input argument (attributes) must be a hash in `MxPlatformRuby::InlineResponse200` initialize method"
50
- end
51
-
52
- # check to see if the attribute exists and convert string to symbol for hash key
53
- attributes = attributes.each_with_object({}) { |(k, v), h|
54
- if (!self.class.attribute_map.key?(k.to_sym))
55
- fail ArgumentError, "`#{k}` is not a valid attribute in `MxPlatformRuby::InlineResponse200`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
- end
57
- h[k.to_sym] = v
58
- }
59
-
60
- if attributes.key?(:'tag')
61
- self.tag = attributes[:'tag']
62
- end
63
- end
64
-
65
- # Show invalid properties with the reasons. Usually used together with valid?
66
- # @return Array for valid properties with the reasons
67
- def list_invalid_properties
68
- invalid_properties = Array.new
69
- invalid_properties
70
- end
71
-
72
- # Check to see if the all the properties in the model are valid
73
- # @return true if the model is valid
74
- def valid?
75
- true
76
- end
77
-
78
- # Checks equality by comparing each attribute.
79
- # @param [Object] Object to be compared
80
- def ==(o)
81
- return true if self.equal?(o)
82
- self.class == o.class &&
83
- tag == o.tag
84
- end
85
-
86
- # @see the `==` method
87
- # @param [Object] Object to be compared
88
- def eql?(o)
89
- self == o
90
- end
91
-
92
- # Calculates hash code according to all attributes.
93
- # @return [Integer] Hash code
94
- def hash
95
- [tag].hash
96
- end
97
-
98
- # Builds the object from hash
99
- # @param [Hash] attributes Model attributes in the form of hash
100
- # @return [Object] Returns the model itself
101
- def self.build_from_hash(attributes)
102
- new.build_from_hash(attributes)
103
- end
104
-
105
- # Builds the object from hash
106
- # @param [Hash] attributes Model attributes in the form of hash
107
- # @return [Object] Returns the model itself
108
- def build_from_hash(attributes)
109
- return nil unless attributes.is_a?(Hash)
110
- self.class.openapi_types.each_pair do |key, type|
111
- if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
112
- self.send("#{key}=", nil)
113
- elsif type =~ /\AArray<(.*)>/i
114
- # check to ensure the input is an array given that the attribute
115
- # is documented as an array but the input is not
116
- if attributes[self.class.attribute_map[key]].is_a?(Array)
117
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
118
- end
119
- elsif !attributes[self.class.attribute_map[key]].nil?
120
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
121
- end
122
- end
123
-
124
- self
125
- end
126
-
127
- # Deserializes the data based on type
128
- # @param string type Data type
129
- # @param string value Value to be deserialized
130
- # @return [Object] Deserialized data
131
- def _deserialize(type, value)
132
- case type.to_sym
133
- when :Time
134
- Time.parse(value)
135
- when :Date
136
- Date.parse(value)
137
- when :String
138
- value.to_s
139
- when :Integer
140
- value.to_i
141
- when :Float
142
- value.to_f
143
- when :Boolean
144
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
145
- true
146
- else
147
- false
148
- end
149
- when :Object
150
- # generic object (usually a Hash), return directly
151
- value
152
- when /\AArray<(?<inner_type>.+)>\z/
153
- inner_type = Regexp.last_match[:inner_type]
154
- value.map { |v| _deserialize(inner_type, v) }
155
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
156
- k_type = Regexp.last_match[:k_type]
157
- v_type = Regexp.last_match[:v_type]
158
- {}.tap do |hash|
159
- value.each do |k, v|
160
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
161
- end
162
- end
163
- else # model
164
- # models (e.g. Pet) or oneOf
165
- klass = MxPlatformRuby.const_get(type)
166
- klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
167
- end
168
- end
169
-
170
- # Returns the string representation of the object
171
- # @return [String] String presentation of the object
172
- def to_s
173
- to_hash.to_s
174
- end
175
-
176
- # to_body is an alias to to_hash (backward compatibility)
177
- # @return [Hash] Returns the object in the form of hash
178
- def to_body
179
- to_hash
180
- end
181
-
182
- # Returns the object in the form of hash
183
- # @return [Hash] Returns the object in the form of hash
184
- def to_hash
185
- hash = {}
186
- self.class.attribute_map.each_pair do |attr, param|
187
- value = self.send(attr)
188
- if value.nil?
189
- is_nullable = self.class.openapi_nullable.include?(attr)
190
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
191
- end
192
-
193
- hash[param] = _to_hash(value)
194
- end
195
- hash
196
- end
197
-
198
- # Outputs non-array value in the form of hash
199
- # For object, use to_hash. Otherwise, just return the value
200
- # @param [Object] value Any valid value
201
- # @return [Hash] Returns the value in the form of hash
202
- def _to_hash(value)
203
- if value.is_a?(Array)
204
- value.compact.map { |v| _to_hash(v) }
205
- elsif value.is_a?(Hash)
206
- {}.tap do |hash|
207
- value.each { |k, v| hash[k] = _to_hash(v) }
208
- end
209
- elsif value.respond_to? :to_hash
210
- value.to_hash
211
- else
212
- value
213
- end
214
- end
215
-
216
- end
217
-
218
- end
@@ -1,299 +0,0 @@
1
- =begin
2
- #MX Platform API
3
-
4
- #The MX Platform API is a powerful, fully-featured API designed to make aggregating and enhancing financial data easy and reliable. It can seamlessly connect your app or website to tens of thousands of financial institutions.
5
-
6
- The version of the OpenAPI document: 0.1.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 5.2.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module MxPlatformRuby
17
- class Institution
18
- attr_accessor :code
19
-
20
- attr_accessor :medium_logo_url
21
-
22
- attr_accessor :name
23
-
24
- attr_accessor :small_logo_url
25
-
26
- attr_accessor :supports_account_identification
27
-
28
- attr_accessor :supports_account_statement
29
-
30
- attr_accessor :supports_account_verification
31
-
32
- attr_accessor :supports_oauth
33
-
34
- attr_accessor :supports_transaction_history
35
-
36
- attr_accessor :url
37
-
38
- # Attribute mapping from ruby-style variable name to JSON key.
39
- def self.attribute_map
40
- {
41
- :'code' => :'code',
42
- :'medium_logo_url' => :'medium_logo_url',
43
- :'name' => :'name',
44
- :'small_logo_url' => :'small_logo_url',
45
- :'supports_account_identification' => :'supports_account_identification',
46
- :'supports_account_statement' => :'supports_account_statement',
47
- :'supports_account_verification' => :'supports_account_verification',
48
- :'supports_oauth' => :'supports_oauth',
49
- :'supports_transaction_history' => :'supports_transaction_history',
50
- :'url' => :'url'
51
- }
52
- end
53
-
54
- # Returns all the JSON keys this model knows about
55
- def self.acceptable_attributes
56
- attribute_map.values
57
- end
58
-
59
- # Attribute type mapping.
60
- def self.openapi_types
61
- {
62
- :'code' => :'String',
63
- :'medium_logo_url' => :'String',
64
- :'name' => :'String',
65
- :'small_logo_url' => :'String',
66
- :'supports_account_identification' => :'Boolean',
67
- :'supports_account_statement' => :'Boolean',
68
- :'supports_account_verification' => :'Boolean',
69
- :'supports_oauth' => :'Boolean',
70
- :'supports_transaction_history' => :'Boolean',
71
- :'url' => :'String'
72
- }
73
- end
74
-
75
- # List of attributes with nullable: true
76
- def self.openapi_nullable
77
- Set.new([
78
- ])
79
- end
80
-
81
- # Initializes the object
82
- # @param [Hash] attributes Model attributes in the form of hash
83
- def initialize(attributes = {})
84
- if (!attributes.is_a?(Hash))
85
- fail ArgumentError, "The input argument (attributes) must be a hash in `MxPlatformRuby::Institution` initialize method"
86
- end
87
-
88
- # check to see if the attribute exists and convert string to symbol for hash key
89
- attributes = attributes.each_with_object({}) { |(k, v), h|
90
- if (!self.class.attribute_map.key?(k.to_sym))
91
- fail ArgumentError, "`#{k}` is not a valid attribute in `MxPlatformRuby::Institution`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
92
- end
93
- h[k.to_sym] = v
94
- }
95
-
96
- if attributes.key?(:'code')
97
- self.code = attributes[:'code']
98
- end
99
-
100
- if attributes.key?(:'medium_logo_url')
101
- self.medium_logo_url = attributes[:'medium_logo_url']
102
- end
103
-
104
- if attributes.key?(:'name')
105
- self.name = attributes[:'name']
106
- end
107
-
108
- if attributes.key?(:'small_logo_url')
109
- self.small_logo_url = attributes[:'small_logo_url']
110
- end
111
-
112
- if attributes.key?(:'supports_account_identification')
113
- self.supports_account_identification = attributes[:'supports_account_identification']
114
- end
115
-
116
- if attributes.key?(:'supports_account_statement')
117
- self.supports_account_statement = attributes[:'supports_account_statement']
118
- end
119
-
120
- if attributes.key?(:'supports_account_verification')
121
- self.supports_account_verification = attributes[:'supports_account_verification']
122
- end
123
-
124
- if attributes.key?(:'supports_oauth')
125
- self.supports_oauth = attributes[:'supports_oauth']
126
- end
127
-
128
- if attributes.key?(:'supports_transaction_history')
129
- self.supports_transaction_history = attributes[:'supports_transaction_history']
130
- end
131
-
132
- if attributes.key?(:'url')
133
- self.url = attributes[:'url']
134
- end
135
- end
136
-
137
- # Show invalid properties with the reasons. Usually used together with valid?
138
- # @return Array for valid properties with the reasons
139
- def list_invalid_properties
140
- invalid_properties = Array.new
141
- invalid_properties
142
- end
143
-
144
- # Check to see if the all the properties in the model are valid
145
- # @return true if the model is valid
146
- def valid?
147
- true
148
- end
149
-
150
- # Checks equality by comparing each attribute.
151
- # @param [Object] Object to be compared
152
- def ==(o)
153
- return true if self.equal?(o)
154
- self.class == o.class &&
155
- code == o.code &&
156
- medium_logo_url == o.medium_logo_url &&
157
- name == o.name &&
158
- small_logo_url == o.small_logo_url &&
159
- supports_account_identification == o.supports_account_identification &&
160
- supports_account_statement == o.supports_account_statement &&
161
- supports_account_verification == o.supports_account_verification &&
162
- supports_oauth == o.supports_oauth &&
163
- supports_transaction_history == o.supports_transaction_history &&
164
- url == o.url
165
- end
166
-
167
- # @see the `==` method
168
- # @param [Object] Object to be compared
169
- def eql?(o)
170
- self == o
171
- end
172
-
173
- # Calculates hash code according to all attributes.
174
- # @return [Integer] Hash code
175
- def hash
176
- [code, medium_logo_url, name, small_logo_url, supports_account_identification, supports_account_statement, supports_account_verification, supports_oauth, supports_transaction_history, url].hash
177
- end
178
-
179
- # Builds the object from hash
180
- # @param [Hash] attributes Model attributes in the form of hash
181
- # @return [Object] Returns the model itself
182
- def self.build_from_hash(attributes)
183
- new.build_from_hash(attributes)
184
- end
185
-
186
- # Builds the object from hash
187
- # @param [Hash] attributes Model attributes in the form of hash
188
- # @return [Object] Returns the model itself
189
- def build_from_hash(attributes)
190
- return nil unless attributes.is_a?(Hash)
191
- self.class.openapi_types.each_pair do |key, type|
192
- if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
193
- self.send("#{key}=", nil)
194
- elsif type =~ /\AArray<(.*)>/i
195
- # check to ensure the input is an array given that the attribute
196
- # is documented as an array but the input is not
197
- if attributes[self.class.attribute_map[key]].is_a?(Array)
198
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
199
- end
200
- elsif !attributes[self.class.attribute_map[key]].nil?
201
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
202
- end
203
- end
204
-
205
- self
206
- end
207
-
208
- # Deserializes the data based on type
209
- # @param string type Data type
210
- # @param string value Value to be deserialized
211
- # @return [Object] Deserialized data
212
- def _deserialize(type, value)
213
- case type.to_sym
214
- when :Time
215
- Time.parse(value)
216
- when :Date
217
- Date.parse(value)
218
- when :String
219
- value.to_s
220
- when :Integer
221
- value.to_i
222
- when :Float
223
- value.to_f
224
- when :Boolean
225
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
226
- true
227
- else
228
- false
229
- end
230
- when :Object
231
- # generic object (usually a Hash), return directly
232
- value
233
- when /\AArray<(?<inner_type>.+)>\z/
234
- inner_type = Regexp.last_match[:inner_type]
235
- value.map { |v| _deserialize(inner_type, v) }
236
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
237
- k_type = Regexp.last_match[:k_type]
238
- v_type = Regexp.last_match[:v_type]
239
- {}.tap do |hash|
240
- value.each do |k, v|
241
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
242
- end
243
- end
244
- else # model
245
- # models (e.g. Pet) or oneOf
246
- klass = MxPlatformRuby.const_get(type)
247
- klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
248
- end
249
- end
250
-
251
- # Returns the string representation of the object
252
- # @return [String] String presentation of the object
253
- def to_s
254
- to_hash.to_s
255
- end
256
-
257
- # to_body is an alias to to_hash (backward compatibility)
258
- # @return [Hash] Returns the object in the form of hash
259
- def to_body
260
- to_hash
261
- end
262
-
263
- # Returns the object in the form of hash
264
- # @return [Hash] Returns the object in the form of hash
265
- def to_hash
266
- hash = {}
267
- self.class.attribute_map.each_pair do |attr, param|
268
- value = self.send(attr)
269
- if value.nil?
270
- is_nullable = self.class.openapi_nullable.include?(attr)
271
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
272
- end
273
-
274
- hash[param] = _to_hash(value)
275
- end
276
- hash
277
- end
278
-
279
- # Outputs non-array value in the form of hash
280
- # For object, use to_hash. Otherwise, just return the value
281
- # @param [Object] value Any valid value
282
- # @return [Hash] Returns the value in the form of hash
283
- def _to_hash(value)
284
- if value.is_a?(Array)
285
- value.compact.map { |v| _to_hash(v) }
286
- elsif value.is_a?(Hash)
287
- {}.tap do |hash|
288
- value.each { |k, v| hash[k] = _to_hash(v) }
289
- end
290
- elsif value.respond_to? :to_hash
291
- value.to_hash
292
- else
293
- value
294
- end
295
- end
296
-
297
- end
298
-
299
- end