wallee-ruby-sdk 1.0.1 → 1.0.2

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 (132) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +21 -11
  3. data/lib/wallee-ruby-sdk/models/abstract_debt_collection_case_update.rb +270 -0
  4. data/lib/wallee-ruby-sdk/models/abstract_payment_link_update.rb +302 -0
  5. data/lib/wallee-ruby-sdk/models/abstract_subscription_affiliate_update.rb +230 -0
  6. data/lib/wallee-ruby-sdk/models/abstract_transaction_pending.rb +14 -4
  7. data/lib/wallee-ruby-sdk/models/criteria_operator.rb +1 -0
  8. data/lib/wallee-ruby-sdk/models/debt_collection_case.rb +502 -0
  9. data/lib/wallee-ruby-sdk/models/debt_collection_case_create.rb +310 -0
  10. data/lib/wallee-ruby-sdk/models/debt_collection_case_document.rb +300 -0
  11. data/lib/wallee-ruby-sdk/models/debt_collection_case_source.rb +232 -0
  12. data/lib/wallee-ruby-sdk/models/debt_collection_case_state.rb +48 -0
  13. data/lib/wallee-ruby-sdk/models/debt_collection_case_update.rb +300 -0
  14. data/lib/wallee-ruby-sdk/models/debt_collection_environment.rb +43 -0
  15. data/lib/wallee-ruby-sdk/models/debt_collection_receipt.rb +288 -0
  16. data/lib/wallee-ruby-sdk/models/debt_collection_receipt_source.rb +222 -0
  17. data/lib/wallee-ruby-sdk/models/debt_collector.rb +222 -0
  18. data/lib/wallee-ruby-sdk/models/debt_collector_condition.rb +258 -0
  19. data/lib/wallee-ruby-sdk/models/debt_collector_condition_type.rb +222 -0
  20. data/lib/wallee-ruby-sdk/models/debt_collector_configuration.rb +302 -0
  21. data/lib/wallee-ruby-sdk/models/document_template_type.rb +1 -11
  22. data/lib/wallee-ruby-sdk/models/entity_export_request.rb +215 -0
  23. data/lib/wallee-ruby-sdk/models/entity_query.rb +1 -1
  24. data/lib/wallee-ruby-sdk/models/entity_query_order_by.rb +10 -0
  25. data/lib/wallee-ruby-sdk/models/environment.rb +43 -0
  26. data/lib/wallee-ruby-sdk/models/metric_usage.rb +232 -0
  27. data/lib/wallee-ruby-sdk/models/payment_connector.rb +23 -1
  28. data/lib/wallee-ruby-sdk/models/payment_contract.rb +338 -0
  29. data/lib/wallee-ruby-sdk/models/payment_contract_state.rb +46 -0
  30. data/lib/wallee-ruby-sdk/models/payment_contract_type.rb +232 -0
  31. data/lib/wallee-ruby-sdk/models/payment_link.rb +382 -0
  32. data/lib/wallee-ruby-sdk/models/payment_link_active.rb +342 -0
  33. data/lib/wallee-ruby-sdk/models/payment_link_create.rb +337 -0
  34. data/lib/wallee-ruby-sdk/models/payment_link_protection_mode.rb +43 -0
  35. data/lib/wallee-ruby-sdk/models/payment_link_update.rb +332 -0
  36. data/lib/wallee-ruby-sdk/models/payment_method.rb +13 -1
  37. data/lib/wallee-ruby-sdk/models/payment_processor_configuration.rb +11 -1
  38. data/lib/wallee-ruby-sdk/models/refund.rb +11 -1
  39. data/lib/wallee-ruby-sdk/models/rest_address_format.rb +234 -0
  40. data/lib/wallee-ruby-sdk/models/rest_address_format_field.rb +51 -0
  41. data/lib/wallee-ruby-sdk/models/rest_country.rb +11 -1
  42. data/lib/wallee-ruby-sdk/models/subscription.rb +11 -1
  43. data/lib/wallee-ruby-sdk/models/subscription_affiliate.rb +290 -0
  44. data/lib/wallee-ruby-sdk/models/subscription_affiliate_create.rb +255 -0
  45. data/lib/wallee-ruby-sdk/models/subscription_affiliate_deleted.rb +290 -0
  46. data/lib/wallee-ruby-sdk/models/subscription_affiliate_deleting.rb +290 -0
  47. data/lib/wallee-ruby-sdk/models/subscription_affiliate_inactive.rb +260 -0
  48. data/lib/wallee-ruby-sdk/models/subscription_affiliate_update.rb +260 -0
  49. data/lib/wallee-ruby-sdk/models/subscription_change_request.rb +2 -2
  50. data/lib/wallee-ruby-sdk/models/subscription_create_request.rb +2 -2
  51. data/lib/wallee-ruby-sdk/models/subscription_pending.rb +11 -1
  52. data/lib/wallee-ruby-sdk/models/tokenizationn_mode.rb +44 -0
  53. data/lib/wallee-ruby-sdk/models/transaction.rb +63 -3
  54. data/lib/wallee-ruby-sdk/models/transaction_create.rb +41 -1
  55. data/lib/wallee-ruby-sdk/models/transaction_environment_selection_strategy.rb +43 -0
  56. data/lib/wallee-ruby-sdk/models/transaction_invoice.rb +11 -1
  57. data/lib/wallee-ruby-sdk/models/transaction_pending.rb +11 -1
  58. data/lib/wallee-ruby-sdk/models/unencrypted_card_data.rb +228 -0
  59. data/lib/wallee-ruby-sdk/models/unencrypted_card_data_create.rb +233 -0
  60. data/lib/wallee-ruby-sdk/models/webhook_listener_entity.rb +1 -11
  61. data/lib/wallee-ruby-sdk/services/account_service_api.rb +2 -2
  62. data/lib/wallee-ruby-sdk/services/application_user_service_api.rb +2 -2
  63. data/lib/wallee-ruby-sdk/services/card_processing_service_api.rb +176 -0
  64. data/lib/wallee-ruby-sdk/services/charge_attempt_service_api.rb +2 -2
  65. data/lib/wallee-ruby-sdk/services/charge_flow_level_service_api.rb +4 -4
  66. data/lib/wallee-ruby-sdk/services/charge_flow_service_api.rb +6 -6
  67. data/lib/wallee-ruby-sdk/services/condition_type_service_api.rb +4 -4
  68. data/lib/wallee-ruby-sdk/services/country_service_api.rb +2 -2
  69. data/lib/wallee-ruby-sdk/services/country_state_service_api.rb +4 -4
  70. data/lib/wallee-ruby-sdk/services/currency_service_api.rb +2 -2
  71. data/lib/wallee-ruby-sdk/services/debt_collection_case_service_api.rb +800 -0
  72. data/lib/wallee-ruby-sdk/services/debt_collector_configuration_service_api.rb +217 -0
  73. data/lib/wallee-ruby-sdk/services/debt_collector_service_api.rb +143 -0
  74. data/lib/wallee-ruby-sdk/services/delivery_indication_service_api.rb +6 -6
  75. data/lib/wallee-ruby-sdk/services/document_template_service_api.rb +2 -2
  76. data/lib/wallee-ruby-sdk/services/document_template_type_service_api.rb +4 -4
  77. data/lib/wallee-ruby-sdk/services/human_user_service_api.rb +59 -2
  78. data/lib/wallee-ruby-sdk/services/installment_payment_service_api.rb +4 -4
  79. data/lib/wallee-ruby-sdk/services/installment_payment_slice_service_api.rb +2 -2
  80. data/lib/wallee-ruby-sdk/services/installment_plan_calculation_service_api.rb +2 -2
  81. data/lib/wallee-ruby-sdk/services/installment_plan_configuration_service_api.rb +2 -2
  82. data/lib/wallee-ruby-sdk/services/installment_plan_slice_configuration_service_api.rb +2 -2
  83. data/lib/wallee-ruby-sdk/services/label_description_group_service_api.rb +4 -4
  84. data/lib/wallee-ruby-sdk/services/label_description_service_api.rb +4 -4
  85. data/lib/wallee-ruby-sdk/services/language_service_api.rb +2 -2
  86. data/lib/wallee-ruby-sdk/services/legal_organization_form_service_api.rb +201 -0
  87. data/lib/wallee-ruby-sdk/services/manual_task_service_api.rb +2 -2
  88. data/lib/wallee-ruby-sdk/services/mertic_usage_service_api.rb +100 -0
  89. data/lib/wallee-ruby-sdk/services/payment_connector_configuration_service_api.rb +2 -2
  90. data/lib/wallee-ruby-sdk/services/payment_connector_service_api.rb +4 -4
  91. data/lib/wallee-ruby-sdk/services/payment_link_service_api.rb +402 -0
  92. data/lib/wallee-ruby-sdk/services/payment_method_configuration_service_api.rb +2 -2
  93. data/lib/wallee-ruby-sdk/services/payment_method_service_api.rb +4 -4
  94. data/lib/wallee-ruby-sdk/services/payment_processor_configuration_service_api.rb +2 -2
  95. data/lib/wallee-ruby-sdk/services/payment_processor_service_api.rb +4 -4
  96. data/lib/wallee-ruby-sdk/services/permission_service_api.rb +4 -4
  97. data/lib/wallee-ruby-sdk/services/refund_service_api.rb +10 -10
  98. data/lib/wallee-ruby-sdk/services/space_service_api.rb +2 -2
  99. data/lib/wallee-ruby-sdk/services/static_value_service_api.rb +4 -4
  100. data/lib/wallee-ruby-sdk/services/subscriber_service_api.rb +2 -2
  101. data/lib/wallee-ruby-sdk/services/subscription_affiliate_service_api.rb +402 -0
  102. data/lib/wallee-ruby-sdk/services/subscription_charge_service_api.rb +4 -4
  103. data/lib/wallee-ruby-sdk/services/subscription_ledger_entry_service_api.rb +2 -2
  104. data/lib/wallee-ruby-sdk/services/subscription_metric_service_api.rb +2 -2
  105. data/lib/wallee-ruby-sdk/services/subscription_metric_usage_service_api.rb +2 -2
  106. data/lib/wallee-ruby-sdk/services/subscription_period_bill_service_api.rb +2 -2
  107. data/lib/wallee-ruby-sdk/services/subscription_product_component_group_service_api.rb +2 -2
  108. data/lib/wallee-ruby-sdk/services/subscription_product_component_service_api.rb +2 -2
  109. data/lib/wallee-ruby-sdk/services/subscription_product_fee_tier_service_api.rb +2 -2
  110. data/lib/wallee-ruby-sdk/services/subscription_product_metered_fee_service_api.rb +2 -2
  111. data/lib/wallee-ruby-sdk/services/subscription_product_period_fee_service_api.rb +2 -2
  112. data/lib/wallee-ruby-sdk/services/subscription_product_retirement_service_api.rb +2 -2
  113. data/lib/wallee-ruby-sdk/services/subscription_product_service_api.rb +2 -2
  114. data/lib/wallee-ruby-sdk/services/subscription_product_setup_fee_service_api.rb +2 -2
  115. data/lib/wallee-ruby-sdk/services/subscription_product_version_retirement_service_api.rb +2 -2
  116. data/lib/wallee-ruby-sdk/services/subscription_product_version_service_api.rb +2 -2
  117. data/lib/wallee-ruby-sdk/services/subscription_service_api.rb +12 -12
  118. data/lib/wallee-ruby-sdk/services/subscription_suspension_service_api.rb +2 -2
  119. data/lib/wallee-ruby-sdk/services/subscription_version_service_api.rb +2 -2
  120. data/lib/wallee-ruby-sdk/services/token_service_api.rb +2 -2
  121. data/lib/wallee-ruby-sdk/services/token_version_service_api.rb +4 -4
  122. data/lib/wallee-ruby-sdk/services/transaction_completion_service_api.rb +6 -6
  123. data/lib/wallee-ruby-sdk/services/transaction_invoice_service_api.rb +6 -6
  124. data/lib/wallee-ruby-sdk/services/transaction_service_api.rb +143 -18
  125. data/lib/wallee-ruby-sdk/services/transaction_void_service_api.rb +6 -6
  126. data/lib/wallee-ruby-sdk/services/user_account_role_service_api.rb +6 -6
  127. data/lib/wallee-ruby-sdk/services/user_space_role_service_api.rb +9 -9
  128. data/lib/wallee-ruby-sdk/services/webhook_listener_service_api.rb +2 -2
  129. data/lib/wallee-ruby-sdk/services/webhook_url_service_api.rb +2 -2
  130. data/lib/wallee-ruby-sdk/version.rb +1 -1
  131. data/lib/wallee-ruby-sdk.rb +47 -0
  132. metadata +50 -3
@@ -0,0 +1,43 @@
1
+ =begin
2
+ Wallee API: 1.0.0
3
+
4
+ The wallee API allows an easy interaction with the wallee web service.
5
+
6
+
7
+
8
+ Licensed under the Apache License, Version 2.0 (the "License");
9
+ you may not use this file except in compliance with the License.
10
+ You may obtain a copy of the License at
11
+
12
+ http://www.apache.org/licenses/LICENSE-2.0
13
+
14
+ Unless required by applicable law or agreed to in writing, software
15
+ distributed under the License is distributed on an "AS IS" BASIS,
16
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17
+ See the License for the specific language governing permissions and
18
+ limitations under the License.
19
+
20
+ =end
21
+
22
+ require 'date'
23
+
24
+ module Wallee
25
+ class PaymentLinkProtectionMode
26
+
27
+ NO_PROTECTION = "NO_PROTECTION".freeze
28
+ ACCESS_KEY = "ACCESS_KEY".freeze
29
+
30
+ # Builds the object from hash
31
+ # @param [Hash] attributes Model attributes in the form of hash
32
+ # @return [Object] Returns the model itself
33
+ def build_from_hash(value)
34
+
35
+ consantValues = PaymentLinkProtectionMode.constants.select{|c| c.to_s == value}
36
+ raise "Invalid ENUM value #{value} for class #PaymentLinkProtectionMode" if consantValues.empty?
37
+
38
+ value
39
+
40
+ end
41
+ end
42
+
43
+ end
@@ -0,0 +1,332 @@
1
+ =begin
2
+ Wallee API: 1.0.0
3
+
4
+ The wallee API allows an easy interaction with the wallee web service.
5
+
6
+
7
+
8
+ Licensed under the Apache License, Version 2.0 (the "License");
9
+ you may not use this file except in compliance with the License.
10
+ You may obtain a copy of the License at
11
+
12
+ http://www.apache.org/licenses/LICENSE-2.0
13
+
14
+ Unless required by applicable law or agreed to in writing, software
15
+ distributed under the License is distributed on an "AS IS" BASIS,
16
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17
+ See the License for the specific language governing permissions and
18
+ limitations under the License.
19
+
20
+ =end
21
+
22
+ require 'date'
23
+
24
+ module Wallee
25
+ # The payment link defines an URL to automatically create transactions.
26
+ class PaymentLinkUpdate
27
+ # The ID is the primary key of the entity. The ID identifies the entity uniquely.
28
+ attr_accessor :id
29
+
30
+ # The version number indicates the version of the entity. The version is incremented whenever the entity is changed.
31
+ attr_accessor :version
32
+
33
+ # The allowed payment method configurations restrict the payment methods which can be used with this payment link.
34
+ attr_accessor :allowed_payment_method_configurations
35
+
36
+ # The payment link can be conducted in a specific space view. The space view may apply a specific design to the payment page.
37
+ attr_accessor :applied_space_view
38
+
39
+ # The available from date defines the earliest date on which the payment link can be used. When no date is specified there will be no restriction.
40
+ attr_accessor :available_from
41
+
42
+ # The available from date defines the latest date on which the payment link can be used to initialize a transaction. When no date is specified there will be no restriction.
43
+ attr_accessor :available_until
44
+
45
+ # By making the billing address required the transaction can only be created when a billing address is provided within the request.
46
+ attr_accessor :billing_address_required
47
+
48
+ # The currency defines in which currency the payment is executed in. If no currency is defined it has to be specified within the request parameter 'currency'.
49
+ attr_accessor :currency
50
+
51
+ # The language defines the language of the payment page. If no language is provided it can be provided through the request parameter.
52
+ attr_accessor :language
53
+
54
+ # The line items allows to define the line items for this payment link. When the line items are defined they cannot be overridden through the request parameters.
55
+ attr_accessor :line_items
56
+
57
+ # The maximal number of transactions limits the number of transactions which can be created with this payment link.
58
+ attr_accessor :maximal_number_of_transactions
59
+
60
+ # The payment link name is used internally to identify the payment link. For example the name is used within search fields and hence it should be distinct and descriptive.
61
+ attr_accessor :name
62
+
63
+ # By making the shipping address required the transaction can only be created when a shipping address is provided within the request.
64
+ attr_accessor :shipping_address_required
65
+
66
+
67
+ # Attribute mapping from ruby-style variable name to JSON key.
68
+ def self.attribute_map
69
+ {
70
+ :'id' => :'id',
71
+ :'version' => :'version',
72
+ :'allowed_payment_method_configurations' => :'allowedPaymentMethodConfigurations',
73
+ :'applied_space_view' => :'appliedSpaceView',
74
+ :'available_from' => :'availableFrom',
75
+ :'available_until' => :'availableUntil',
76
+ :'billing_address_required' => :'billingAddressRequired',
77
+ :'currency' => :'currency',
78
+ :'language' => :'language',
79
+ :'line_items' => :'lineItems',
80
+ :'maximal_number_of_transactions' => :'maximalNumberOfTransactions',
81
+ :'name' => :'name',
82
+ :'shipping_address_required' => :'shippingAddressRequired'
83
+ }
84
+ end
85
+
86
+ # Attribute type mapping.
87
+ def self.swagger_types
88
+ {
89
+ :'id' => :'Integer',
90
+ :'version' => :'Integer',
91
+ :'allowed_payment_method_configurations' => :'Array<PaymentMethodConfiguration>',
92
+ :'applied_space_view' => :'Integer',
93
+ :'available_from' => :'DateTime',
94
+ :'available_until' => :'DateTime',
95
+ :'billing_address_required' => :'BOOLEAN',
96
+ :'currency' => :'String',
97
+ :'language' => :'String',
98
+ :'line_items' => :'Array<LineItemCreate>',
99
+ :'maximal_number_of_transactions' => :'Integer',
100
+ :'name' => :'String',
101
+ :'shipping_address_required' => :'BOOLEAN'
102
+ }
103
+ end
104
+
105
+ # Initializes the object
106
+ # @param [Hash] attributes Model attributes in the form of hash
107
+ def initialize(attributes = {})
108
+ return unless attributes.is_a?(Hash)
109
+
110
+ # convert string to symbol for hash key
111
+ attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
112
+
113
+ if attributes.has_key?(:'id')
114
+ self.id = attributes[:'id']
115
+ end
116
+
117
+ if attributes.has_key?(:'version')
118
+ self.version = attributes[:'version']
119
+ end
120
+
121
+ if attributes.has_key?(:'allowedPaymentMethodConfigurations')
122
+ if (value = attributes[:'allowedPaymentMethodConfigurations']).is_a?(Array)
123
+ self.allowed_payment_method_configurations = value
124
+ end
125
+ end
126
+
127
+ if attributes.has_key?(:'appliedSpaceView')
128
+ self.applied_space_view = attributes[:'appliedSpaceView']
129
+ end
130
+
131
+ if attributes.has_key?(:'availableFrom')
132
+ self.available_from = attributes[:'availableFrom']
133
+ end
134
+
135
+ if attributes.has_key?(:'availableUntil')
136
+ self.available_until = attributes[:'availableUntil']
137
+ end
138
+
139
+ if attributes.has_key?(:'billingAddressRequired')
140
+ self.billing_address_required = attributes[:'billingAddressRequired']
141
+ end
142
+
143
+ if attributes.has_key?(:'currency')
144
+ self.currency = attributes[:'currency']
145
+ end
146
+
147
+ if attributes.has_key?(:'language')
148
+ self.language = attributes[:'language']
149
+ end
150
+
151
+ if attributes.has_key?(:'lineItems')
152
+ if (value = attributes[:'lineItems']).is_a?(Array)
153
+ self.line_items = value
154
+ end
155
+ end
156
+
157
+ if attributes.has_key?(:'maximalNumberOfTransactions')
158
+ self.maximal_number_of_transactions = attributes[:'maximalNumberOfTransactions']
159
+ end
160
+
161
+ if attributes.has_key?(:'name')
162
+ self.name = attributes[:'name']
163
+ end
164
+
165
+ if attributes.has_key?(:'shippingAddressRequired')
166
+ self.shipping_address_required = attributes[:'shippingAddressRequired']
167
+ end
168
+
169
+ end
170
+
171
+ # Show invalid properties with the reasons. Usually used together with valid?
172
+ # @return Array for valid properies with the reasons
173
+ def list_invalid_properties
174
+ invalid_properties = Array.new
175
+ if @id.nil?
176
+ invalid_properties.push("invalid value for 'id', id cannot be nil.")
177
+ end
178
+
179
+ if @version.nil?
180
+ invalid_properties.push("invalid value for 'version', version cannot be nil.")
181
+ end
182
+
183
+ return invalid_properties
184
+ end
185
+
186
+ # Check to see if the all the properties in the model are valid
187
+ # @return true if the model is valid
188
+ def valid?
189
+ return false if @id.nil?
190
+ return false if @version.nil?
191
+ return true
192
+ end
193
+
194
+ # Checks equality by comparing each attribute.
195
+ # @param [Object] Object to be compared
196
+ def ==(o)
197
+ return true if self.equal?(o)
198
+ self.class == o.class &&
199
+ id == o.id &&
200
+ version == o.version &&
201
+ allowed_payment_method_configurations == o.allowed_payment_method_configurations &&
202
+ applied_space_view == o.applied_space_view &&
203
+ available_from == o.available_from &&
204
+ available_until == o.available_until &&
205
+ billing_address_required == o.billing_address_required &&
206
+ currency == o.currency &&
207
+ language == o.language &&
208
+ line_items == o.line_items &&
209
+ maximal_number_of_transactions == o.maximal_number_of_transactions &&
210
+ name == o.name &&
211
+ shipping_address_required == o.shipping_address_required
212
+ end
213
+
214
+ # @see the `==` method
215
+ # @param [Object] Object to be compared
216
+ def eql?(o)
217
+ self == o
218
+ end
219
+
220
+ # Calculates hash code according to all attributes.
221
+ # @return [Fixnum] Hash code
222
+ def hash
223
+ [id, version, allowed_payment_method_configurations, applied_space_view, available_from, available_until, billing_address_required, currency, language, line_items, maximal_number_of_transactions, name, shipping_address_required].hash
224
+ end
225
+
226
+ # Builds the object from hash
227
+ # @param [Hash] attributes Model attributes in the form of hash
228
+ # @return [Object] Returns the model itself
229
+ def build_from_hash(attributes)
230
+ return nil unless attributes.is_a?(Hash)
231
+ self.class.swagger_types.each_pair do |key, type|
232
+ if type =~ /\AArray<(.*)>/i
233
+ # check to ensure the input is an array given that the the attribute
234
+ # is documented as an array but the input is not
235
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
236
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
237
+ end
238
+ elsif !attributes[self.class.attribute_map[key]].nil?
239
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
240
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
241
+ end
242
+
243
+ self
244
+ end
245
+
246
+ # Deserializes the data based on type
247
+ # @param string type Data type
248
+ # @param string value Value to be deserialized
249
+ # @return [Object] Deserialized data
250
+ def _deserialize(type, value)
251
+ case type.to_sym
252
+ when :DateTime
253
+ DateTime.parse(value)
254
+ when :Date
255
+ Date.parse(value)
256
+ when :String
257
+ value.to_s
258
+ when :Integer
259
+ value.to_i
260
+ when :Float
261
+ value.to_f
262
+ when :BOOLEAN
263
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
264
+ true
265
+ else
266
+ false
267
+ end
268
+ when :Object
269
+ # generic object (usually a Hash), return directly
270
+ value
271
+ when /\AArray<(?<inner_type>.+)>\z/
272
+ inner_type = Regexp.last_match[:inner_type]
273
+ value.map { |v| _deserialize(inner_type, v) }
274
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
275
+ k_type = Regexp.last_match[:k_type]
276
+ v_type = Regexp.last_match[:v_type]
277
+ {}.tap do |hash|
278
+ value.each do |k, v|
279
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
280
+ end
281
+ end
282
+ else # model
283
+ temp_model = Wallee.const_get(type).new
284
+ temp_model.build_from_hash(value)
285
+ end
286
+ end
287
+
288
+ # Returns the string representation of the object
289
+ # @return [String] String presentation of the object
290
+ def to_s
291
+ to_hash.to_s
292
+ end
293
+
294
+ # to_body is an alias to to_hash (backward compatibility)
295
+ # @return [Hash] Returns the object in the form of hash
296
+ def to_body
297
+ to_hash
298
+ end
299
+
300
+ # Returns the object in the form of hash
301
+ # @return [Hash] Returns the object in the form of hash
302
+ def to_hash
303
+ hash = {}
304
+ self.class.attribute_map.each_pair do |attr, param|
305
+ value = self.send(attr)
306
+ next if value.nil?
307
+ hash[param] = _to_hash(value)
308
+ end
309
+ hash
310
+ end
311
+
312
+ # Outputs non-array value in the form of hash
313
+ # For object, use to_hash. Otherwise, just return the value
314
+ # @param [Object] value Any valid value
315
+ # @return [Hash] Returns the value in the form of hash
316
+ def _to_hash(value)
317
+ if value.is_a?(Array)
318
+ value.compact.map{ |v| _to_hash(v) }
319
+ elsif value.is_a?(Hash)
320
+ {}.tap do |hash|
321
+ value.each { |k, v| hash[k] = _to_hash(v) }
322
+ end
323
+ elsif value.respond_to? :to_hash
324
+ value.to_hash
325
+ else
326
+ value
327
+ end
328
+ end
329
+
330
+ end
331
+
332
+ end
@@ -36,6 +36,9 @@ module Wallee
36
36
  #
37
37
  attr_accessor :image_path
38
38
 
39
+ #
40
+ attr_accessor :merchant_description
41
+
39
42
  #
40
43
  attr_accessor :name
41
44
 
@@ -50,6 +53,7 @@ module Wallee
50
53
  :'description' => :'description',
51
54
  :'id' => :'id',
52
55
  :'image_path' => :'imagePath',
56
+ :'merchant_description' => :'merchantDescription',
53
57
  :'name' => :'name',
54
58
  :'supported_currencies' => :'supportedCurrencies'
55
59
  }
@@ -62,6 +66,7 @@ module Wallee
62
66
  :'description' => :'Hash<String, String>',
63
67
  :'id' => :'Integer',
64
68
  :'image_path' => :'String',
69
+ :'merchant_description' => :'Hash<String, String>',
65
70
  :'name' => :'Hash<String, String>',
66
71
  :'supported_currencies' => :'Array<String>'
67
72
  }
@@ -95,6 +100,12 @@ module Wallee
95
100
  self.image_path = attributes[:'imagePath']
96
101
  end
97
102
 
103
+ if attributes.has_key?(:'merchantDescription')
104
+ if (value = attributes[:'merchantDescription']).is_a?(Array)
105
+ self.merchant_description = value
106
+ end
107
+ end
108
+
98
109
  if attributes.has_key?(:'name')
99
110
  if (value = attributes[:'name']).is_a?(Array)
100
111
  self.name = value
@@ -131,6 +142,7 @@ module Wallee
131
142
  description == o.description &&
132
143
  id == o.id &&
133
144
  image_path == o.image_path &&
145
+ merchant_description == o.merchant_description &&
134
146
  name == o.name &&
135
147
  supported_currencies == o.supported_currencies
136
148
  end
@@ -144,7 +156,7 @@ module Wallee
144
156
  # Calculates hash code according to all attributes.
145
157
  # @return [Fixnum] Hash code
146
158
  def hash
147
- [data_collection_types, description, id, image_path, name, supported_currencies].hash
159
+ [data_collection_types, description, id, image_path, merchant_description, name, supported_currencies].hash
148
160
  end
149
161
 
150
162
  # Builds the object from hash
@@ -24,6 +24,9 @@ require 'date'
24
24
  module Wallee
25
25
  #
26
26
  class PaymentProcessorConfiguration
27
+ # The contract links the processor configuration with the contract that is used to process payments.
28
+ attr_accessor :contract_id
29
+
27
30
  # The ID is the primary key of the entity. The ID identifies the entity uniquely.
28
31
  attr_accessor :id
29
32
 
@@ -49,6 +52,7 @@ module Wallee
49
52
  # Attribute mapping from ruby-style variable name to JSON key.
50
53
  def self.attribute_map
51
54
  {
55
+ :'contract_id' => :'contractId',
52
56
  :'id' => :'id',
53
57
  :'linked_space_id' => :'linkedSpaceId',
54
58
  :'name' => :'name',
@@ -62,6 +66,7 @@ module Wallee
62
66
  # Attribute type mapping.
63
67
  def self.swagger_types
64
68
  {
69
+ :'contract_id' => :'Integer',
65
70
  :'id' => :'Integer',
66
71
  :'linked_space_id' => :'Integer',
67
72
  :'name' => :'String',
@@ -80,6 +85,10 @@ module Wallee
80
85
  # convert string to symbol for hash key
81
86
  attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
82
87
 
88
+ if attributes.has_key?(:'contractId')
89
+ self.contract_id = attributes[:'contractId']
90
+ end
91
+
83
92
  if attributes.has_key?(:'id')
84
93
  self.id = attributes[:'id']
85
94
  end
@@ -128,6 +137,7 @@ module Wallee
128
137
  def ==(o)
129
138
  return true if self.equal?(o)
130
139
  self.class == o.class &&
140
+ contract_id == o.contract_id &&
131
141
  id == o.id &&
132
142
  linked_space_id == o.linked_space_id &&
133
143
  name == o.name &&
@@ -146,7 +156,7 @@ module Wallee
146
156
  # Calculates hash code according to all attributes.
147
157
  # @return [Fixnum] Hash code
148
158
  def hash
149
- [id, linked_space_id, name, planned_purge_date, processor, state, version].hash
159
+ [contract_id, id, linked_space_id, name, planned_purge_date, processor, state, version].hash
150
160
  end
151
161
 
152
162
  # Builds the object from hash
@@ -36,6 +36,9 @@ module Wallee
36
36
  # The created on date indicates the date on which the entity was stored into the database.
37
37
  attr_accessor :created_on
38
38
 
39
+ #
40
+ attr_accessor :environment
41
+
39
42
  # The external id helps to identify duplicate calls to the refund service. As such the external ID has to be unique per transaction.
40
43
  attr_accessor :external_id
41
44
 
@@ -107,6 +110,7 @@ module Wallee
107
110
  :'base_line_items' => :'baseLineItems',
108
111
  :'created_by' => :'createdBy',
109
112
  :'created_on' => :'createdOn',
113
+ :'environment' => :'environment',
110
114
  :'external_id' => :'externalId',
111
115
  :'failed_on' => :'failedOn',
112
116
  :'failure_reason' => :'failureReason',
@@ -138,6 +142,7 @@ module Wallee
138
142
  :'base_line_items' => :'Array<LineItem>',
139
143
  :'created_by' => :'Integer',
140
144
  :'created_on' => :'DateTime',
145
+ :'environment' => :'Environment',
141
146
  :'external_id' => :'String',
142
147
  :'failed_on' => :'DateTime',
143
148
  :'failure_reason' => :'FailureReason',
@@ -188,6 +193,10 @@ module Wallee
188
193
  self.created_on = attributes[:'createdOn']
189
194
  end
190
195
 
196
+ if attributes.has_key?(:'environment')
197
+ self.environment = attributes[:'environment']
198
+ end
199
+
191
200
  if attributes.has_key?(:'externalId')
192
201
  self.external_id = attributes[:'externalId']
193
202
  end
@@ -306,6 +315,7 @@ module Wallee
306
315
  base_line_items == o.base_line_items &&
307
316
  created_by == o.created_by &&
308
317
  created_on == o.created_on &&
318
+ environment == o.environment &&
309
319
  external_id == o.external_id &&
310
320
  failed_on == o.failed_on &&
311
321
  failure_reason == o.failure_reason &&
@@ -338,7 +348,7 @@ module Wallee
338
348
  # Calculates hash code according to all attributes.
339
349
  # @return [Fixnum] Hash code
340
350
  def hash
341
- [amount, base_line_items, created_by, created_on, external_id, failed_on, failure_reason, id, labels, language, line_items, linked_space_id, merchant_reference, next_update_on, planned_purge_date, processor_reference, reduced_line_items, reductions, state, succeeded_on, taxes, timeout_on, transaction, type, version].hash
351
+ [amount, base_line_items, created_by, created_on, environment, external_id, failed_on, failure_reason, id, labels, language, line_items, linked_space_id, merchant_reference, next_update_on, planned_purge_date, processor_reference, reduced_line_items, reductions, state, succeeded_on, taxes, timeout_on, transaction, type, version].hash
342
352
  end
343
353
 
344
354
  # Builds the object from hash