cybersource_rest_client 0.0.74 → 0.0.75
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.
- checksums.yaml +4 -4
- data/lib/AuthenticationSDK/core/MerchantConfig.rb +2 -1
- data/lib/cybersource_rest_client/api/bin_lookup_api.rb +5 -5
- data/lib/cybersource_rest_client/api/create_new_webhooks_api.rb +6 -6
- data/lib/cybersource_rest_client/api/decision_manager_api.rb +3 -3
- data/lib/cybersource_rest_client/api/manage_webhooks_api.rb +9 -9
- data/lib/cybersource_rest_client/api/merchant_boarding_api.rb +3 -3
- data/lib/cybersource_rest_client/api/payment_tokens_api.rb +96 -0
- data/lib/cybersource_rest_client/models/create_order_request.rb +269 -229
- data/lib/cybersource_rest_client/models/de_association_request_body.rb +190 -190
- data/lib/cybersource_rest_client/models/generate_capture_context_request.rb +240 -240
- data/lib/cybersource_rest_client/models/generate_unified_checkout_capture_context_request.rb +303 -303
- data/lib/cybersource_rest_client/models/get_subscription_response.rb +267 -267
- data/lib/cybersource_rest_client/models/get_subscription_response_reactivation_information.rb +213 -213
- data/lib/cybersource_rest_client/models/inline_response_200_10.rb +292 -292
- data/lib/cybersource_rest_client/models/inline_response_200_10_records.rb +209 -209
- data/lib/cybersource_rest_client/models/inline_response_200_10_response_record.rb +307 -307
- data/lib/cybersource_rest_client/models/inline_response_200_10_response_record_additional_updates.rb +242 -242
- data/lib/cybersource_rest_client/models/inline_response_200_10_source_record.rb +295 -295
- data/lib/cybersource_rest_client/models/inline_response_200_2.rb +253 -253
- data/lib/cybersource_rest_client/models/inline_response_200_5.rb +247 -247
- data/lib/cybersource_rest_client/models/inline_response_200_5_devices.rb +357 -357
- data/lib/cybersource_rest_client/models/inline_response_200_6.rb +202 -202
- data/lib/cybersource_rest_client/models/inline_response_200_7.rb +247 -247
- data/lib/cybersource_rest_client/models/inline_response_200_7_devices.rb +371 -371
- data/lib/cybersource_rest_client/models/inline_response_200_7_payment_processor_to_terminal_map.rb +200 -200
- data/lib/cybersource_rest_client/models/inline_response_200_8.rb +251 -251
- data/lib/cybersource_rest_client/models/inline_response_200_8__embedded.rb +191 -191
- data/lib/cybersource_rest_client/models/inline_response_200_8__embedded__links.rb +191 -191
- data/lib/cybersource_rest_client/models/inline_response_200_8__embedded__links_reports.rb +190 -190
- data/lib/cybersource_rest_client/models/inline_response_200_8__embedded_batches.rb +295 -295
- data/lib/cybersource_rest_client/models/inline_response_200_8__embedded_totals.rb +229 -229
- data/lib/cybersource_rest_client/models/inline_response_200_8__links.rb +200 -200
- data/lib/cybersource_rest_client/models/inline_response_200_9.rb +290 -290
- data/lib/cybersource_rest_client/models/inline_response_200_9__links.rb +201 -201
- data/lib/cybersource_rest_client/models/inline_response_200_9__links_report.rb +189 -189
- data/lib/cybersource_rest_client/models/inline_response_200_9_billing.rb +219 -219
- data/lib/cybersource_rest_client/models/inline_response_201.rb +227 -218
- data/lib/cybersource_rest_client/models/inline_response_201_1.rb +218 -248
- data/lib/cybersource_rest_client/models/inline_response_201_2.rb +248 -281
- data/lib/cybersource_rest_client/models/{inline_response_201_1_payout_information.rb → inline_response_201_2_payout_information.rb} +216 -216
- data/lib/cybersource_rest_client/models/{inline_response_201_1_payout_information_pull_funds.rb → inline_response_201_2_payout_information_pull_funds.rb} +213 -213
- data/lib/cybersource_rest_client/models/{inline_response_201_1_payout_information_push_funds.rb → inline_response_201_2_payout_information_push_funds.rb} +417 -417
- data/lib/cybersource_rest_client/models/inline_response_201_3.rb +281 -222
- data/lib/cybersource_rest_client/models/{inline_response_201_2_integration_information.rb → inline_response_201_3_integration_information.rb} +192 -192
- data/lib/cybersource_rest_client/models/{inline_response_201_2_integration_information_tenant_configurations.rb → inline_response_201_3_integration_information_tenant_configurations.rb} +253 -253
- data/lib/cybersource_rest_client/models/{inline_response_201_2_organization_information.rb → inline_response_201_3_organization_information.rb} +217 -217
- data/lib/cybersource_rest_client/models/{inline_response_201_2_product_information_setups.rb → inline_response_201_3_product_information_setups.rb} +214 -214
- data/lib/cybersource_rest_client/models/{inline_response_201_2_registration_information.rb → inline_response_201_3_registration_information.rb} +222 -222
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups.rb → inline_response_201_3_setups.rb} +219 -219
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_commerce_solutions.rb → inline_response_201_3_setups_commerce_solutions.rb} +209 -209
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_payments.rb → inline_response_201_3_setups_payments.rb} +369 -369
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_payments_alternative_payment_methods.rb → inline_response_201_3_setups_payments_alternative_payment_methods.rb} +221 -221
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_payments_alternative_payment_methods_configuration_status.rb → inline_response_201_3_setups_payments_alternative_payment_methods_configuration_status.rb} +200 -200
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_payments_card_processing.rb → inline_response_201_3_setups_payments_card_processing.rb} +199 -199
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_payments_card_processing_configuration_status.rb → inline_response_201_3_setups_payments_card_processing_configuration_status.rb} +255 -255
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_payments_card_processing_subscription_status.rb → inline_response_201_3_setups_payments_card_processing_subscription_status.rb} +234 -234
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_payments_digital_payments.rb → inline_response_201_3_setups_payments_digital_payments.rb} +189 -189
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_risk.rb → inline_response_201_3_setups_risk.rb} +199 -199
- data/lib/cybersource_rest_client/models/{inline_response_201_2_setups_value_added_services.rb → inline_response_201_3_setups_value_added_services.rb} +209 -209
- data/lib/cybersource_rest_client/models/inline_response_201_4.rb +222 -312
- data/lib/cybersource_rest_client/models/{inline_response_201_3_key_information.rb → inline_response_201_4_key_information.rb} +300 -300
- data/lib/cybersource_rest_client/models/{inline_response_201_3_key_information_error_information.rb → inline_response_201_4_key_information_error_information.rb} +202 -202
- data/lib/cybersource_rest_client/models/{inline_response_201_3_key_information_error_information_details.rb → inline_response_201_4_key_information_error_information_details.rb} +201 -201
- data/lib/cybersource_rest_client/models/inline_response_201_5.rb +312 -277
- data/lib/cybersource_rest_client/models/inline_response_201_6.rb +277 -202
- data/lib/cybersource_rest_client/models/{inline_response_201_5_payloads.rb → inline_response_201_6_payloads.rb} +189 -189
- data/lib/cybersource_rest_client/models/{inline_response_201_5_payloads_test_payload.rb → inline_response_201_6_payloads_test_payload.rb} +190 -190
- data/lib/cybersource_rest_client/models/inline_response_201_7.rb +202 -0
- data/lib/cybersource_rest_client/models/inline_response_201_order_information.rb +189 -0
- data/lib/cybersource_rest_client/models/inline_response_201_order_information_ship_to.rb +315 -0
- data/lib/cybersource_rest_client/models/inline_response_201_payment_information.rb +199 -0
- data/lib/cybersource_rest_client/models/inline_response_201_payment_information_e_wallet.rb +196 -0
- data/lib/cybersource_rest_client/models/inline_response_201_payment_information_tokenized_payment_method.rb +213 -0
- data/lib/cybersource_rest_client/models/payments_products.rb +379 -379
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout.rb +199 -199
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout_configuration_information.rb +189 -189
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout_configuration_information_configurations.rb +189 -189
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout_configuration_information_configurations_features.rb +189 -189
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout_configuration_information_configurations_features_paze.rb +213 -213
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout_subscription_information.rb +225 -225
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout_subscription_information_features.rb +189 -189
- data/lib/cybersource_rest_client/models/payments_products_unified_checkout_subscription_information_features_paze_for_unified_checkout.rb +190 -190
- data/lib/cybersource_rest_client/models/post_device_search_request.rb +223 -223
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_installment_information.rb +609 -609
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_account_information_card.rb +269 -269
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_information.rb +364 -354
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_information_tokenized_card.rb +309 -309
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_information_tokenized_payment_method.rb +213 -0
- data/lib/cybersource_rest_client/models/pts_v2_retrieve_payment_token_get400_response.rb +252 -0
- data/lib/cybersource_rest_client/models/pts_v2_retrieve_payment_token_get502_response.rb +240 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_payment_information_card.rb +258 -258
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_payment_information_tokenized_card.rb +275 -275
- data/lib/cybersource_rest_client/models/ptsv2intents_event_information.rb +212 -0
- data/lib/cybersource_rest_client/models/ptsv2intents_order_information_ship_to.rb +354 -332
- data/lib/cybersource_rest_client/models/ptsv2intents_payment_information.rb +220 -189
- data/lib/cybersource_rest_client/models/ptsv2intents_payment_information_e_wallet.rb +196 -0
- data/lib/cybersource_rest_client/models/ptsv2intents_payment_information_tokenized_payment_method.rb +241 -0
- data/lib/cybersource_rest_client/models/ptsv2intents_processing_information.rb +351 -219
- data/lib/cybersource_rest_client/models/ptsv2intents_recipient_information.rb +245 -0
- data/lib/cybersource_rest_client/models/ptsv2intents_sender_information.rb +277 -0
- data/lib/cybersource_rest_client/models/ptsv2intents_sender_information_account.rb +190 -0
- data/lib/cybersource_rest_client/models/ptsv2intents_travel_information.rb +211 -0
- data/lib/cybersource_rest_client/models/ptsv2intents_travel_information_agency.rb +245 -0
- data/lib/cybersource_rest_client/models/ptsv2intentsid_payment_information.rb +189 -0
- data/lib/cybersource_rest_client/models/ptsv2paymentreferences_order_information_amount_details.rb +417 -400
- data/lib/cybersource_rest_client/models/ptsv2paymentreferences_payment_information_card.rb +275 -275
- data/lib/cybersource_rest_client/models/ptsv2payments_installment_information.rb +433 -416
- data/lib/cybersource_rest_client/models/ptsv2payments_order_information_amount_details.rb +668 -651
- data/lib/cybersource_rest_client/models/ptsv2payments_order_information_line_items.rb +716 -699
- data/lib/cybersource_rest_client/models/ptsv2payments_payment_information.rb +356 -346
- data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_card.rb +445 -445
- data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_tokenized_card.rb +377 -377
- data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_tokenized_payment_method.rb +196 -0
- data/lib/cybersource_rest_client/models/ptsv2paymentsidcaptures_installment_information.rb +604 -604
- data/lib/cybersource_rest_client/models/ptsv2paymentsidrefunds_payment_information_card.rb +377 -377
- data/lib/cybersource_rest_client/models/ptsv2paymenttokens_payment_information.rb +199 -0
- data/lib/cybersource_rest_client/models/ptsv2paymenttokens_processing_information.rb +192 -0
- data/lib/cybersource_rest_client/models/ptsv2payouts_payment_information_card.rb +258 -258
- data/lib/cybersource_rest_client/models/request.rb +199 -0
- data/lib/cybersource_rest_client/models/riskv1authenticationresults_payment_information_card.rb +241 -241
- data/lib/cybersource_rest_client/models/riskv1authenticationresults_payment_information_tokenized_card.rb +258 -258
- data/lib/cybersource_rest_client/models/riskv1authentications_payment_information_tokenized_card.rb +351 -351
- data/lib/cybersource_rest_client/models/riskv1authenticationsetups_payment_information_card.rb +268 -268
- data/lib/cybersource_rest_client/models/riskv1authenticationsetups_payment_information_tokenized_card.rb +299 -299
- data/lib/cybersource_rest_client/models/riskv1decisions_payment_information_card.rb +259 -259
- data/lib/cybersource_rest_client/models/riskv1decisions_payment_information_tokenized_card.rb +259 -259
- data/lib/cybersource_rest_client/models/riskv1decisions_travel_information_legs.rb +252 -252
- data/lib/cybersource_rest_client/models/riskv1liststypeentries_payment_information_card.rb +224 -224
- data/lib/cybersource_rest_client/models/tms_bin_lookup_issuer_information.rb +264 -264
- data/lib/cybersource_rest_client/models/tms_bin_lookup_payment_account_information_card.rb +277 -277
- data/lib/cybersource_rest_client/models/tms_bin_lookup_payment_account_information_card_brands.rb +213 -213
- data/lib/cybersource_rest_client/models/tms_bin_lookup_payment_account_information_features.rb +430 -430
- data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_brands.rb +201 -201
- data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_card.rb +365 -365
- data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_processor_information.rb +394 -394
- data/lib/cybersource_rest_client/models/tss_v2_transactions_post201_response__embedded_payment_information_card.rb +218 -218
- data/lib/cybersource_rest_client/models/tss_v2_transactions_post201_response__embedded_processor_information.rb +245 -234
- data/lib/cybersource_rest_client/models/update_order_request.rb +229 -229
- data/lib/cybersource_rest_client/models/upv1capturecontexts_capture_mandate.rb +297 -297
- data/lib/cybersource_rest_client/models/upv1capturecontexts_complete_mandate.rb +219 -219
- data/lib/cybersource_rest_client.rb +47 -24
- metadata +49 -26
@@ -1,229 +1,269 @@
|
|
1
|
-
=begin
|
2
|
-
#CyberSource Merged Spec
|
3
|
-
|
4
|
-
#All CyberSource API specs merged together. These are available at https://developer.cybersource.com/api/reference/api-reference.html
|
5
|
-
|
6
|
-
OpenAPI spec version: 0.0.1
|
7
|
-
|
8
|
-
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.4.38
|
10
|
-
=end
|
11
|
-
|
12
|
-
require 'date'
|
13
|
-
|
14
|
-
module CyberSource
|
15
|
-
class CreateOrderRequest
|
16
|
-
attr_accessor :client_reference_information
|
17
|
-
|
18
|
-
attr_accessor :processing_information
|
19
|
-
|
20
|
-
attr_accessor :merchant_information
|
21
|
-
|
22
|
-
attr_accessor :payment_information
|
23
|
-
|
24
|
-
attr_accessor :order_information
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
:'
|
41
|
-
:'
|
42
|
-
:'
|
43
|
-
:'
|
44
|
-
:'
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
:'
|
53
|
-
:'
|
54
|
-
:'
|
55
|
-
:'
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
#
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
#
|
188
|
-
# @return [
|
189
|
-
def
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
value
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
1
|
+
=begin
|
2
|
+
#CyberSource Merged Spec
|
3
|
+
|
4
|
+
#All CyberSource API specs merged together. These are available at https://developer.cybersource.com/api/reference/api-reference.html
|
5
|
+
|
6
|
+
OpenAPI spec version: 0.0.1
|
7
|
+
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.4.38
|
10
|
+
=end
|
11
|
+
|
12
|
+
require 'date'
|
13
|
+
|
14
|
+
module CyberSource
|
15
|
+
class CreateOrderRequest
|
16
|
+
attr_accessor :client_reference_information
|
17
|
+
|
18
|
+
attr_accessor :processing_information
|
19
|
+
|
20
|
+
attr_accessor :merchant_information
|
21
|
+
|
22
|
+
attr_accessor :payment_information
|
23
|
+
|
24
|
+
attr_accessor :order_information
|
25
|
+
|
26
|
+
attr_accessor :sender_information
|
27
|
+
|
28
|
+
attr_accessor :event_information
|
29
|
+
|
30
|
+
attr_accessor :travel_information
|
31
|
+
|
32
|
+
attr_accessor :recipient_information
|
33
|
+
|
34
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
35
|
+
def self.attribute_map
|
36
|
+
{
|
37
|
+
:'client_reference_information' => :'clientReferenceInformation',
|
38
|
+
:'processing_information' => :'processingInformation',
|
39
|
+
:'merchant_information' => :'merchantInformation',
|
40
|
+
:'payment_information' => :'paymentInformation',
|
41
|
+
:'order_information' => :'orderInformation',
|
42
|
+
:'sender_information' => :'senderInformation',
|
43
|
+
:'event_information' => :'eventInformation',
|
44
|
+
:'travel_information' => :'travelInformation',
|
45
|
+
:'recipient_information' => :'recipientInformation'
|
46
|
+
}
|
47
|
+
end
|
48
|
+
|
49
|
+
# Attribute mapping from JSON key to ruby-style variable name.
|
50
|
+
def self.json_map
|
51
|
+
{
|
52
|
+
:'client_reference_information' => :'client_reference_information',
|
53
|
+
:'processing_information' => :'processing_information',
|
54
|
+
:'merchant_information' => :'merchant_information',
|
55
|
+
:'payment_information' => :'payment_information',
|
56
|
+
:'order_information' => :'order_information',
|
57
|
+
:'sender_information' => :'sender_information',
|
58
|
+
:'event_information' => :'event_information',
|
59
|
+
:'travel_information' => :'travel_information',
|
60
|
+
:'recipient_information' => :'recipient_information'
|
61
|
+
}
|
62
|
+
end
|
63
|
+
|
64
|
+
# Attribute type mapping.
|
65
|
+
def self.swagger_types
|
66
|
+
{
|
67
|
+
:'client_reference_information' => :'Ptsv2intentsClientReferenceInformation',
|
68
|
+
:'processing_information' => :'Ptsv2intentsProcessingInformation',
|
69
|
+
:'merchant_information' => :'Ptsv2intentsMerchantInformation',
|
70
|
+
:'payment_information' => :'Ptsv2intentsPaymentInformation',
|
71
|
+
:'order_information' => :'Ptsv2intentsOrderInformation',
|
72
|
+
:'sender_information' => :'Ptsv2intentsSenderInformation',
|
73
|
+
:'event_information' => :'Ptsv2intentsEventInformation',
|
74
|
+
:'travel_information' => :'Ptsv2intentsTravelInformation',
|
75
|
+
:'recipient_information' => :'Ptsv2intentsRecipientInformation'
|
76
|
+
}
|
77
|
+
end
|
78
|
+
|
79
|
+
# Initializes the object
|
80
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
81
|
+
def initialize(attributes = {})
|
82
|
+
return unless attributes.is_a?(Hash)
|
83
|
+
|
84
|
+
# convert string to symbol for hash key
|
85
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
86
|
+
|
87
|
+
if attributes.has_key?(:'clientReferenceInformation')
|
88
|
+
self.client_reference_information = attributes[:'clientReferenceInformation']
|
89
|
+
end
|
90
|
+
|
91
|
+
if attributes.has_key?(:'processingInformation')
|
92
|
+
self.processing_information = attributes[:'processingInformation']
|
93
|
+
end
|
94
|
+
|
95
|
+
if attributes.has_key?(:'merchantInformation')
|
96
|
+
self.merchant_information = attributes[:'merchantInformation']
|
97
|
+
end
|
98
|
+
|
99
|
+
if attributes.has_key?(:'paymentInformation')
|
100
|
+
self.payment_information = attributes[:'paymentInformation']
|
101
|
+
end
|
102
|
+
|
103
|
+
if attributes.has_key?(:'orderInformation')
|
104
|
+
self.order_information = attributes[:'orderInformation']
|
105
|
+
end
|
106
|
+
|
107
|
+
if attributes.has_key?(:'senderInformation')
|
108
|
+
self.sender_information = attributes[:'senderInformation']
|
109
|
+
end
|
110
|
+
|
111
|
+
if attributes.has_key?(:'eventInformation')
|
112
|
+
self.event_information = attributes[:'eventInformation']
|
113
|
+
end
|
114
|
+
|
115
|
+
if attributes.has_key?(:'travelInformation')
|
116
|
+
self.travel_information = attributes[:'travelInformation']
|
117
|
+
end
|
118
|
+
|
119
|
+
if attributes.has_key?(:'recipientInformation')
|
120
|
+
self.recipient_information = attributes[:'recipientInformation']
|
121
|
+
end
|
122
|
+
end
|
123
|
+
|
124
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
125
|
+
# @return Array for valid properties with the reasons
|
126
|
+
def list_invalid_properties
|
127
|
+
invalid_properties = Array.new
|
128
|
+
invalid_properties
|
129
|
+
end
|
130
|
+
|
131
|
+
# Check to see if the all the properties in the model are valid
|
132
|
+
# @return true if the model is valid
|
133
|
+
def valid?
|
134
|
+
true
|
135
|
+
end
|
136
|
+
|
137
|
+
# Checks equality by comparing each attribute.
|
138
|
+
# @param [Object] Object to be compared
|
139
|
+
def ==(o)
|
140
|
+
return true if self.equal?(o)
|
141
|
+
self.class == o.class &&
|
142
|
+
client_reference_information == o.client_reference_information &&
|
143
|
+
processing_information == o.processing_information &&
|
144
|
+
merchant_information == o.merchant_information &&
|
145
|
+
payment_information == o.payment_information &&
|
146
|
+
order_information == o.order_information &&
|
147
|
+
sender_information == o.sender_information &&
|
148
|
+
event_information == o.event_information &&
|
149
|
+
travel_information == o.travel_information &&
|
150
|
+
recipient_information == o.recipient_information
|
151
|
+
end
|
152
|
+
|
153
|
+
# @see the `==` method
|
154
|
+
# @param [Object] Object to be compared
|
155
|
+
def eql?(o)
|
156
|
+
self == o
|
157
|
+
end
|
158
|
+
|
159
|
+
# Calculates hash code according to all attributes.
|
160
|
+
# @return [Fixnum] Hash code
|
161
|
+
def hash
|
162
|
+
[client_reference_information, processing_information, merchant_information, payment_information, order_information, sender_information, event_information, travel_information, recipient_information].hash
|
163
|
+
end
|
164
|
+
|
165
|
+
# Builds the object from hash
|
166
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
167
|
+
# @return [Object] Returns the model itself
|
168
|
+
def build_from_hash(attributes)
|
169
|
+
return nil unless attributes.is_a?(Hash)
|
170
|
+
self.class.swagger_types.each_pair do |key, type|
|
171
|
+
if type =~ /\AArray<(.*)>/i
|
172
|
+
# check to ensure the input is an array given that the the attribute
|
173
|
+
# is documented as an array but the input is not
|
174
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
175
|
+
self.send("#{self.class.json_map[key]}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
176
|
+
end
|
177
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
178
|
+
self.send("#{self.class.json_map[key]}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
179
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
180
|
+
end
|
181
|
+
|
182
|
+
self
|
183
|
+
end
|
184
|
+
|
185
|
+
# Deserializes the data based on type
|
186
|
+
# @param string type Data type
|
187
|
+
# @param string value Value to be deserialized
|
188
|
+
# @return [Object] Deserialized data
|
189
|
+
def _deserialize(type, value)
|
190
|
+
case type.to_sym
|
191
|
+
when :DateTime
|
192
|
+
DateTime.parse(value)
|
193
|
+
when :Date
|
194
|
+
Date.parse(value)
|
195
|
+
when :String
|
196
|
+
value.to_s
|
197
|
+
when :Integer
|
198
|
+
value.to_i
|
199
|
+
when :Float
|
200
|
+
value.to_f
|
201
|
+
when :BOOLEAN
|
202
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
203
|
+
true
|
204
|
+
else
|
205
|
+
false
|
206
|
+
end
|
207
|
+
when :Object
|
208
|
+
# generic object (usually a Hash), return directly
|
209
|
+
value
|
210
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
211
|
+
inner_type = Regexp.last_match[:inner_type]
|
212
|
+
value.map { |v| _deserialize(inner_type, v) }
|
213
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
214
|
+
k_type = Regexp.last_match[:k_type]
|
215
|
+
v_type = Regexp.last_match[:v_type]
|
216
|
+
{}.tap do |hash|
|
217
|
+
value.each do |k, v|
|
218
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
219
|
+
end
|
220
|
+
end
|
221
|
+
else # model
|
222
|
+
temp_model = CyberSource.const_get(type).new
|
223
|
+
temp_model.build_from_hash(value)
|
224
|
+
end
|
225
|
+
end
|
226
|
+
|
227
|
+
# Returns the string representation of the object
|
228
|
+
# @return [String] String presentation of the object
|
229
|
+
def to_s
|
230
|
+
to_hash.to_s
|
231
|
+
end
|
232
|
+
|
233
|
+
# to_body is an alias to to_hash (backward compatibility)
|
234
|
+
# @return [Hash] Returns the object in the form of hash
|
235
|
+
def to_body
|
236
|
+
to_hash
|
237
|
+
end
|
238
|
+
|
239
|
+
# Returns the object in the form of hash
|
240
|
+
# @return [Hash] Returns the object in the form of hash
|
241
|
+
def to_hash
|
242
|
+
hash = {}
|
243
|
+
self.class.attribute_map.each_pair do |attr, param|
|
244
|
+
value = self.send(attr)
|
245
|
+
next if value.nil?
|
246
|
+
hash[param] = _to_hash(value)
|
247
|
+
end
|
248
|
+
hash
|
249
|
+
end
|
250
|
+
|
251
|
+
# Outputs non-array value in the form of hash
|
252
|
+
# For object, use to_hash. Otherwise, just return the value
|
253
|
+
# @param [Object] value Any valid value
|
254
|
+
# @return [Hash] Returns the value in the form of hash
|
255
|
+
def _to_hash(value)
|
256
|
+
if value.is_a?(Array)
|
257
|
+
value.compact.map { |v| _to_hash(v) }
|
258
|
+
elsif value.is_a?(Hash)
|
259
|
+
{}.tap do |hash|
|
260
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
261
|
+
end
|
262
|
+
elsif value.respond_to? :to_hash
|
263
|
+
value.to_hash
|
264
|
+
else
|
265
|
+
value
|
266
|
+
end
|
267
|
+
end
|
268
|
+
end
|
269
|
+
end
|