cybersource_rest_client 0.0.29 → 0.0.33
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/authentication/oauth/OAuthToken.rb +15 -0
- data/lib/AuthenticationSDK/core/Authorization.rb +4 -1
- data/lib/AuthenticationSDK/core/MerchantConfig.rb +93 -19
- data/lib/AuthenticationSDK/util/Constants.rb +78 -76
- data/lib/cybersource_rest_client.rb +19 -9
- data/lib/cybersource_rest_client/api/customer_payment_instrument_api.rb +3 -3
- data/lib/cybersource_rest_client/api/instrument_identifier_api.rb +3 -3
- data/lib/cybersource_rest_client/api/o_auth_api.rb +104 -0
- data/lib/cybersource_rest_client/api/payments_api.rb +2 -2
- data/lib/cybersource_rest_client/api/refund_api.rb +4 -4
- data/lib/cybersource_rest_client/api/void_api.rb +4 -4
- data/lib/cybersource_rest_client/api_client.rb +31 -8
- data/lib/cybersource_rest_client/configuration.rb +2 -2
- data/lib/cybersource_rest_client/models/access_token_response.rb +244 -0
- data/lib/cybersource_rest_client/models/add_negative_list_request.rb +1 -1
- data/lib/cybersource_rest_client/models/bad_request_error.rb +192 -0
- data/lib/cybersource_rest_client/models/create_access_token_request.rb +254 -0
- data/lib/cybersource_rest_client/models/fraud_marking_action_request.rb +1 -1
- data/lib/cybersource_rest_client/models/invoicing_v2_invoices_all_get200_response_customer_information.rb +20 -4
- data/lib/cybersource_rest_client/models/invoicingv2invoices_customer_information.rb +20 -4
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer.rb → payment_instrument_list.rb} +3 -3
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer__embedded.rb → payment_instrument_list__embedded.rb} +1 -1
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer__links.rb → payment_instrument_list__links.rb} +6 -6
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer__links_first.rb → payment_instrument_list__links_first.rb} +1 -1
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer__links_last.rb → payment_instrument_list__links_last.rb} +1 -1
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer__links_next.rb → payment_instrument_list__links_next.rb} +1 -1
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer__links_prev.rb → payment_instrument_list__links_prev.rb} +1 -1
- data/lib/cybersource_rest_client/models/{payment_instrument_list_for_customer__links_self.rb → payment_instrument_list__links_self.rb} +1 -1
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response.rb +10 -1
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_consumer_authentication_information.rb +11 -1
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_order_information.rb +13 -4
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_order_information_reward_points_details.rb +270 -0
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_account_information.rb +183 -0
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_account_information_card.rb +242 -0
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_information.rb +1 -1
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_information_tokenized_card.rb +1 -1
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_processing_information.rb +1 -1
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_processor_information.rb +17 -1
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_processor_information_routing.rb +3 -3
- data/lib/cybersource_rest_client/models/pts_v2_payouts_post201_response_merchant_information_merchant_descriptor.rb +6 -0
- data/lib/cybersource_rest_client/models/pts_v2_payouts_post201_response_recipient_information_card.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2credits_processing_information.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2payments_client_reference_information.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2payments_consumer_authentication_information.rb +60 -2
- data/lib/cybersource_rest_client/models/ptsv2payments_health_care_information_amount_details.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2payments_merchant_information_merchant_descriptor.rb +6 -0
- data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_card.rb +4 -4
- data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_fluid_data.rb +3 -3
- data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_tokenized_card.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2payments_point_of_sale_information.rb +36 -38
- data/lib/cybersource_rest_client/models/ptsv2payments_processing_information.rb +15 -5
- data/lib/cybersource_rest_client/models/ptsv2payments_processing_information_authorization_options.rb +7 -7
- data/lib/cybersource_rest_client/models/ptsv2payments_recurring_payment_information.rb +24 -4
- data/lib/cybersource_rest_client/models/ptsv2payments_risk_information.rb +15 -4
- data/lib/cybersource_rest_client/models/ptsv2payments_risk_information_auxiliary_data.rb +207 -0
- data/lib/cybersource_rest_client/models/ptsv2paymentsidcaptures_payment_information_card.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2paymentsidcaptures_processing_information.rb +15 -5
- data/lib/cybersource_rest_client/models/ptsv2paymentsidrefunds_payment_information_card.rb +4 -4
- data/lib/cybersource_rest_client/models/ptsv2paymentsidrefunds_processing_information.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2paymentsidreversals_client_reference_information.rb +17 -1
- data/lib/cybersource_rest_client/models/ptsv2paymentsidreversals_processing_information.rb +1 -1
- data/lib/cybersource_rest_client/models/ptsv2payouts_merchant_information_merchant_descriptor.rb +6 -0
- data/lib/cybersource_rest_client/models/ptsv2payouts_payment_information_card.rb +4 -4
- data/lib/cybersource_rest_client/models/resource_not_found_error.rb +192 -0
- data/lib/cybersource_rest_client/models/riskv1authenticationresults_consumer_authentication_information.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1authenticationresults_payment_information_card.rb +3 -3
- data/lib/cybersource_rest_client/models/riskv1authenticationresults_payment_information_tokenized_card.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1authentications_payment_information_card.rb +3 -3
- data/lib/cybersource_rest_client/models/riskv1authentications_payment_information_tokenized_card.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1authenticationsetups_payment_information_card.rb +3 -3
- data/lib/cybersource_rest_client/models/riskv1authenticationsetups_payment_information_fluid_data.rb +3 -3
- data/lib/cybersource_rest_client/models/riskv1authenticationsetups_payment_information_tokenized_card.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1authenticationsetups_processing_information.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1decisions_client_reference_information.rb +17 -1
- data/lib/cybersource_rest_client/models/riskv1decisions_consumer_authentication_information.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1decisions_device_information.rb +1 -11
- data/lib/cybersource_rest_client/models/riskv1decisions_payment_information_card.rb +3 -3
- data/lib/cybersource_rest_client/models/riskv1decisions_payment_information_tokenized_card.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1decisions_risk_information.rb +15 -4
- data/lib/cybersource_rest_client/models/riskv1liststypeentries_client_reference_information.rb +224 -0
- data/lib/cybersource_rest_client/models/riskv1liststypeentries_payment_information_card.rb +1 -1
- data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_card.rb +5 -5
- data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_processing_information_authorization_options.rb +13 -4
- data/lib/cybersource_rest_client/models/tss_v2_transactions_post201_response__embedded_payment_information_card.rb +3 -3
- data/lib/cybersource_rest_client/models/tss_v2_transactions_post201_response__embedded_processing_information.rb +1 -1
- data/lib/cybersource_rest_client/models/unauthorized_client_error.rb +192 -0
- data/lib/cybersource_rest_client/models/validate_export_compliance_request.rb +1 -1
- data/lib/cybersource_rest_client/models/verify_customer_address_request.rb +1 -1
- metadata +120 -101
- data/lib/AuthenticationSDK/resource/TRRReports.json +0 -12
- data/lib/AuthenticationSDK/resource/cybs.yml +0 -31
- data/lib/AuthenticationSDK/resource/request.json +0 -54
- data/lib/AuthenticationSDK/resource/request_capture.json +0 -11
- data/lib/AuthenticationSDK/resource/testrest.p12 +0 -0
- data/lib/AuthenticationSDK/spec/Authorization_spec.rb +0 -274
- data/lib/AuthenticationSDK/spec/MerchantConfigData.rb +0 -59
- data/lib/AuthenticationSDK/spec/MerchantConfig_spec.rb +0 -116
- data/lib/AuthenticationSDK/spec/PostRequestData.json +0 -54
- data/lib/AuthenticationSDK/spec/PutRequestData.json +0 -12
- data/lib/AuthenticationSDK/spec/ResponseCodeMessage_spec.rb +0 -60
- data/lib/AuthenticationSDK/spec/spec_helper.rb +0 -12
- data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_information_card.rb +0 -184
|
@@ -32,7 +32,7 @@ module CyberSource
|
|
|
32
32
|
# Type of transaction. Some payment card companies use this information when determining discount rates. #### Used by **Authorization** Required payer authentication transactions; otherwise, optional. **Credit** Required for standalone credits on Chase Paymentech solutions; otherwise, optional. Only `internet`, `moto`, `install`, `recurring`, and `recurring_internet` are valid values. #### Ingenico ePayments When you omit this field for Ingenico ePayments, the processor uses the default transaction type they have on file for you instead of the default value (listed in Appendix I, \"Commerce Indicators,\" on page 441.) #### Payer Authentication Transactions For the possible values and requirements, see \"Payer Authentication,\" page 195. #### Other Types of Transactions See Appendix I, \"Commerce Indicators,\" on page 441. #### Card Present You must set this field to `retail`. This field is required for a card-present transaction. Note that this should ONLY be used when the cardholder and card are present at the time of the transaction. For all keyed transactions originated from a POS terminal where the cardholder and card are not present, commerceIndicator should be submitted as “moto\"
|
|
33
33
|
attr_accessor :commerce_indicator
|
|
34
34
|
|
|
35
|
-
# Type of digital payment solution for the transaction. Possible Values: - `visacheckout`: Visa Checkout. This value is required for Visa Checkout transactions. For details, see `payment_solution` field description in [Visa Checkout Using the SCMP API.](https://apps.cybersource.com/library/documentation/dev_guides/VCO_SCMP_API/html/) - `001`: Apple Pay. - `004`: Cybersource In-App Solution. - `005`: Masterpass. This value is required for Masterpass transactions on OmniPay Direct. For details, see \"Masterpass\" in the [Credit Card Services Using the SCMP API Guide.](https://apps.cybersource.com/library/documentation/dev_guides/CC_Svcs_SCMP_API/html/) - `006`: Android Pay. - `007`: Chase Pay. - `008`: Samsung Pay. - `012`: Google Pay. - `014`: Mastercard credential on file (COF) payment network token. Returned in authorizations that use a payment network token associated with a TMS token. - `015`: Visa credential on file (COF) payment network token. Returned in authorizations that use a payment network token associated with a TMS token.
|
|
35
|
+
# Type of digital payment solution for the transaction. Possible Values: - `visacheckout`: Visa Checkout. This value is required for Visa Checkout transactions. For details, see `payment_solution` field description in [Visa Checkout Using the SCMP API.](https://apps.cybersource.com/library/documentation/dev_guides/VCO_SCMP_API/html/) - `001`: Apple Pay. - `004`: Cybersource In-App Solution. - `005`: Masterpass. This value is required for Masterpass transactions on OmniPay Direct. For details, see \"Masterpass\" in the [Credit Card Services Using the SCMP API Guide.](https://apps.cybersource.com/library/documentation/dev_guides/CC_Svcs_SCMP_API/html/) - `006`: Android Pay. - `007`: Chase Pay. - `008`: Samsung Pay. - `012`: Google Pay. - `013`: Cybersource P2PE Decryption - `014`: Mastercard credential on file (COF) payment network token. Returned in authorizations that use a payment network token associated with a TMS token. - `015`: Visa credential on file (COF) payment network token. Returned in authorizations that use a payment network token associated with a TMS token. - `027`: Click to Pay.
|
|
36
36
|
attr_accessor :payment_solution
|
|
37
37
|
|
|
38
38
|
# Please check with Cybersource customer support to see if your merchant account is configured correctly so you can include this field in your request. * For Payouts: max length for FDCCompass is String (22).
|
|
@@ -84,6 +84,9 @@ module CyberSource
|
|
|
84
84
|
# On PIN Debit Gateways: This U.S.-only field is optionally used by participants (merchants and acquirers) to specify the network access priority. VisaNet checks to determine if there are issuer routing preferences for any of the networks specified by the sharing group code. If an issuer preference exists for one of the specified debit networks, VisaNet makes a routing selection based on the issuer’s preference. If an issuer preference exists for more than one of the specified debit networks, or if no issuer preference exists, VisaNet makes a selection based on the acquirer’s routing priorities. #### PIN debit Priority order of the networks through which he transaction will be routed. Set this value to a series of one-character network codes in your preferred order. This is a list of the network codes: | Network | Code | | --- | --- | | Accel | E | | AFFN | U | | Alaska Option | 3 | | CU24 | C | | Interlink | G | | Maestro | 8 | | NETS | P | | NYCE | F | | Pulse | H | | Shazam | 7 | | Star | M | | Visa | V | For example, if the Star network is your first preference and Pulse is your second preference, set this field to a value of `MH`. When you do not include this value in your PIN debit request, the list of network codes from your account is used. **Note** This field is supported only for businesses located in the U.S. Optional field for PIN debit credit or PIN debit purchase.
|
|
85
85
|
attr_accessor :network_routing_order
|
|
86
86
|
|
|
87
|
+
# Flag that indicates if the transaction is pay by points transaction true: Transaction uses loyalty points false: Transaction does not use loyalty points Default: false
|
|
88
|
+
attr_accessor :pay_by_points_indicator
|
|
89
|
+
|
|
87
90
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
88
91
|
def self.attribute_map
|
|
89
92
|
{
|
|
@@ -112,7 +115,8 @@ module CyberSource
|
|
|
112
115
|
:'japan_payment_options' => :'japanPaymentOptions',
|
|
113
116
|
:'mobile_remote_payment_type' => :'mobileRemotePaymentType',
|
|
114
117
|
:'extended_credit_total_count' => :'extendedCreditTotalCount',
|
|
115
|
-
:'network_routing_order' => :'networkRoutingOrder'
|
|
118
|
+
:'network_routing_order' => :'networkRoutingOrder',
|
|
119
|
+
:'pay_by_points_indicator' => :'payByPointsIndicator'
|
|
116
120
|
}
|
|
117
121
|
end
|
|
118
122
|
|
|
@@ -144,7 +148,8 @@ module CyberSource
|
|
|
144
148
|
:'japan_payment_options' => :'Ptsv2paymentsProcessingInformationJapanPaymentOptions',
|
|
145
149
|
:'mobile_remote_payment_type' => :'String',
|
|
146
150
|
:'extended_credit_total_count' => :'String',
|
|
147
|
-
:'network_routing_order' => :'String'
|
|
151
|
+
:'network_routing_order' => :'String',
|
|
152
|
+
:'pay_by_points_indicator' => :'BOOLEAN'
|
|
148
153
|
}
|
|
149
154
|
end
|
|
150
155
|
|
|
@@ -265,6 +270,10 @@ module CyberSource
|
|
|
265
270
|
if attributes.has_key?(:'networkRoutingOrder')
|
|
266
271
|
self.network_routing_order = attributes[:'networkRoutingOrder']
|
|
267
272
|
end
|
|
273
|
+
|
|
274
|
+
if attributes.has_key?(:'payByPointsIndicator')
|
|
275
|
+
self.pay_by_points_indicator = attributes[:'payByPointsIndicator']
|
|
276
|
+
end
|
|
268
277
|
end
|
|
269
278
|
|
|
270
279
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -394,7 +403,8 @@ module CyberSource
|
|
|
394
403
|
japan_payment_options == o.japan_payment_options &&
|
|
395
404
|
mobile_remote_payment_type == o.mobile_remote_payment_type &&
|
|
396
405
|
extended_credit_total_count == o.extended_credit_total_count &&
|
|
397
|
-
network_routing_order == o.network_routing_order
|
|
406
|
+
network_routing_order == o.network_routing_order &&
|
|
407
|
+
pay_by_points_indicator == o.pay_by_points_indicator
|
|
398
408
|
end
|
|
399
409
|
|
|
400
410
|
# @see the `==` method
|
|
@@ -406,7 +416,7 @@ module CyberSource
|
|
|
406
416
|
# Calculates hash code according to all attributes.
|
|
407
417
|
# @return [Fixnum] Hash code
|
|
408
418
|
def hash
|
|
409
|
-
[action_list, action_token_types, capture, processor_id, business_application_id, commerce_indicator, payment_solution, reconciliation_id, link_id, purchase_level, report_group, visa_checkout_id, industry_data_type, authorization_options, capture_options, recurring_options, bank_transfer_options, purchase_options, electronic_benefits_transfer, loan_options, wallet_type, national_net_domestic_data, japan_payment_options, mobile_remote_payment_type, extended_credit_total_count, network_routing_order].hash
|
|
419
|
+
[action_list, action_token_types, capture, processor_id, business_application_id, commerce_indicator, payment_solution, reconciliation_id, link_id, purchase_level, report_group, visa_checkout_id, industry_data_type, authorization_options, capture_options, recurring_options, bank_transfer_options, purchase_options, electronic_benefits_transfer, loan_options, wallet_type, national_net_domestic_data, japan_payment_options, mobile_remote_payment_type, extended_credit_total_count, network_routing_order, pay_by_points_indicator].hash
|
|
410
420
|
end
|
|
411
421
|
|
|
412
422
|
# Builds the object from hash
|
|
@@ -53,7 +53,7 @@ module CyberSource
|
|
|
53
53
|
attr_accessor :redemption_inquiry
|
|
54
54
|
|
|
55
55
|
# Type of transportation mode : Possible Values: - 00 = Unknown - 01 = Urban bus - 02 = Interurban bus - 03=Lighttrainmasstransit(Underground Metro LTR) - 04 = Train - 05 = Commuter train - 06 = Water-borne vehicle - 07 = Toll - 08 = Parking - 09 = Taxi - 10 = High-speed train - 11 = Rural bus - 12 = Express commuter train - 13 = Para transit - 14 = Self drive vehicle - 15 = Coach - 16 = Locomotive - 17 = Powered motor coach - 18 = Trailer - 19 = Regional train - 20 = Inter-city - 21 = Funicular train - 22 = Cable car
|
|
56
|
-
attr_accessor :
|
|
56
|
+
attr_accessor :transportation_mode
|
|
57
57
|
|
|
58
58
|
# Indicates if transaction is an aggregated auth Possible values: - **true** - **false**
|
|
59
59
|
attr_accessor :aggregated_auth_indicator
|
|
@@ -80,7 +80,7 @@ module CyberSource
|
|
|
80
80
|
:'bill_payment' => :'billPayment',
|
|
81
81
|
:'bill_payment_type' => :'billPaymentType',
|
|
82
82
|
:'redemption_inquiry' => :'redemptionInquiry',
|
|
83
|
-
:'
|
|
83
|
+
:'transportation_mode' => :'transportationMode',
|
|
84
84
|
:'aggregated_auth_indicator' => :'aggregatedAuthIndicator',
|
|
85
85
|
:'debt_recovery_indicator' => :'debtRecoveryIndicator',
|
|
86
86
|
:'deferred_auth_indicator' => :'deferredAuthIndicator'
|
|
@@ -103,7 +103,7 @@ module CyberSource
|
|
|
103
103
|
:'bill_payment' => :'BOOLEAN',
|
|
104
104
|
:'bill_payment_type' => :'String',
|
|
105
105
|
:'redemption_inquiry' => :'BOOLEAN',
|
|
106
|
-
:'
|
|
106
|
+
:'transportation_mode' => :'String',
|
|
107
107
|
:'aggregated_auth_indicator' => :'String',
|
|
108
108
|
:'debt_recovery_indicator' => :'String',
|
|
109
109
|
:'deferred_auth_indicator' => :'BOOLEAN'
|
|
@@ -176,8 +176,8 @@ module CyberSource
|
|
|
176
176
|
self.redemption_inquiry = attributes[:'redemptionInquiry']
|
|
177
177
|
end
|
|
178
178
|
|
|
179
|
-
if attributes.has_key?(:'
|
|
180
|
-
self.
|
|
179
|
+
if attributes.has_key?(:'transportationMode')
|
|
180
|
+
self.transportation_mode = attributes[:'transportationMode']
|
|
181
181
|
end
|
|
182
182
|
|
|
183
183
|
if attributes.has_key?(:'aggregatedAuthIndicator')
|
|
@@ -248,7 +248,7 @@ module CyberSource
|
|
|
248
248
|
bill_payment == o.bill_payment &&
|
|
249
249
|
bill_payment_type == o.bill_payment_type &&
|
|
250
250
|
redemption_inquiry == o.redemption_inquiry &&
|
|
251
|
-
|
|
251
|
+
transportation_mode == o.transportation_mode &&
|
|
252
252
|
aggregated_auth_indicator == o.aggregated_auth_indicator &&
|
|
253
253
|
debt_recovery_indicator == o.debt_recovery_indicator &&
|
|
254
254
|
deferred_auth_indicator == o.deferred_auth_indicator
|
|
@@ -263,7 +263,7 @@ module CyberSource
|
|
|
263
263
|
# Calculates hash code according to all attributes.
|
|
264
264
|
# @return [Fixnum] Hash code
|
|
265
265
|
def hash
|
|
266
|
-
[auth_type, verbal_auth_code, verbal_auth_transaction_id, auth_indicator, partial_auth_indicator, balance_inquiry, ignore_avs_result, decline_avs_flags, ignore_cv_result, initiator, bill_payment, bill_payment_type, redemption_inquiry,
|
|
266
|
+
[auth_type, verbal_auth_code, verbal_auth_transaction_id, auth_indicator, partial_auth_indicator, balance_inquiry, ignore_avs_result, decline_avs_flags, ignore_cv_result, initiator, bill_payment, bill_payment_type, redemption_inquiry, transportation_mode, aggregated_auth_indicator, debt_recovery_indicator, deferred_auth_indicator].hash
|
|
267
267
|
end
|
|
268
268
|
|
|
269
269
|
# Builds the object from hash
|
|
@@ -21,15 +21,23 @@ module CyberSource
|
|
|
21
21
|
# Integer value indicating the minimum number of days between recurring authorizations. A frequency of monthly is indicated by the value 28. Multiple of 28 days will be used to indicate months. Example: 6 months = 168 Example values accepted (31 days): - 31 - 031 - 0031 **Note** This field is required for recurring transactions.
|
|
22
22
|
attr_accessor :frequency
|
|
23
23
|
|
|
24
|
+
# Total number of payments for the duration of the recurring subscription.
|
|
25
|
+
attr_accessor :number_of_payments
|
|
26
|
+
|
|
24
27
|
# Date of original purchase. Required for recurring transactions. Format: `YYYY-MM-DDTHH:MM:SSZ` **Note**: If this field is empty, the current date is used.
|
|
25
28
|
attr_accessor :original_purchase_date
|
|
26
29
|
|
|
30
|
+
# This field is mandatory for Cartes Bancaires recurring transactions on Credit Mutuel-CIC. This field records recurring sequence, e.g. 1st for initial, 2 for subsequent, 3 etc
|
|
31
|
+
attr_accessor :sequence_number
|
|
32
|
+
|
|
27
33
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
28
34
|
def self.attribute_map
|
|
29
35
|
{
|
|
30
36
|
:'end_date' => :'endDate',
|
|
31
37
|
:'frequency' => :'frequency',
|
|
32
|
-
:'
|
|
38
|
+
:'number_of_payments' => :'numberOfPayments',
|
|
39
|
+
:'original_purchase_date' => :'originalPurchaseDate',
|
|
40
|
+
:'sequence_number' => :'sequenceNumber'
|
|
33
41
|
}
|
|
34
42
|
end
|
|
35
43
|
|
|
@@ -38,7 +46,9 @@ module CyberSource
|
|
|
38
46
|
{
|
|
39
47
|
:'end_date' => :'String',
|
|
40
48
|
:'frequency' => :'Integer',
|
|
41
|
-
:'
|
|
49
|
+
:'number_of_payments' => :'Integer',
|
|
50
|
+
:'original_purchase_date' => :'String',
|
|
51
|
+
:'sequence_number' => :'Integer'
|
|
42
52
|
}
|
|
43
53
|
end
|
|
44
54
|
|
|
@@ -58,9 +68,17 @@ module CyberSource
|
|
|
58
68
|
self.frequency = attributes[:'frequency']
|
|
59
69
|
end
|
|
60
70
|
|
|
71
|
+
if attributes.has_key?(:'numberOfPayments')
|
|
72
|
+
self.number_of_payments = attributes[:'numberOfPayments']
|
|
73
|
+
end
|
|
74
|
+
|
|
61
75
|
if attributes.has_key?(:'originalPurchaseDate')
|
|
62
76
|
self.original_purchase_date = attributes[:'originalPurchaseDate']
|
|
63
77
|
end
|
|
78
|
+
|
|
79
|
+
if attributes.has_key?(:'sequenceNumber')
|
|
80
|
+
self.sequence_number = attributes[:'sequenceNumber']
|
|
81
|
+
end
|
|
64
82
|
end
|
|
65
83
|
|
|
66
84
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -95,7 +113,9 @@ module CyberSource
|
|
|
95
113
|
self.class == o.class &&
|
|
96
114
|
end_date == o.end_date &&
|
|
97
115
|
frequency == o.frequency &&
|
|
98
|
-
|
|
116
|
+
number_of_payments == o.number_of_payments &&
|
|
117
|
+
original_purchase_date == o.original_purchase_date &&
|
|
118
|
+
sequence_number == o.sequence_number
|
|
99
119
|
end
|
|
100
120
|
|
|
101
121
|
# @see the `==` method
|
|
@@ -107,7 +127,7 @@ module CyberSource
|
|
|
107
127
|
# Calculates hash code according to all attributes.
|
|
108
128
|
# @return [Fixnum] Hash code
|
|
109
129
|
def hash
|
|
110
|
-
[end_date, frequency, original_purchase_date].hash
|
|
130
|
+
[end_date, frequency, number_of_payments, original_purchase_date, sequence_number].hash
|
|
111
131
|
end
|
|
112
132
|
|
|
113
133
|
# Builds the object from hash
|
|
@@ -22,12 +22,15 @@ module CyberSource
|
|
|
22
22
|
|
|
23
23
|
attr_accessor :buyer_history
|
|
24
24
|
|
|
25
|
+
attr_accessor :auxiliary_data
|
|
26
|
+
|
|
25
27
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
26
28
|
def self.attribute_map
|
|
27
29
|
{
|
|
28
30
|
:'profile' => :'profile',
|
|
29
31
|
:'event_type' => :'eventType',
|
|
30
|
-
:'buyer_history' => :'buyerHistory'
|
|
32
|
+
:'buyer_history' => :'buyerHistory',
|
|
33
|
+
:'auxiliary_data' => :'auxiliaryData'
|
|
31
34
|
}
|
|
32
35
|
end
|
|
33
36
|
|
|
@@ -36,7 +39,8 @@ module CyberSource
|
|
|
36
39
|
{
|
|
37
40
|
:'profile' => :'Ptsv2paymentsRiskInformationProfile',
|
|
38
41
|
:'event_type' => :'String',
|
|
39
|
-
:'buyer_history' => :'Ptsv2paymentsRiskInformationBuyerHistory'
|
|
42
|
+
:'buyer_history' => :'Ptsv2paymentsRiskInformationBuyerHistory',
|
|
43
|
+
:'auxiliary_data' => :'Array<Ptsv2paymentsRiskInformationAuxiliaryData>'
|
|
40
44
|
}
|
|
41
45
|
end
|
|
42
46
|
|
|
@@ -59,6 +63,12 @@ module CyberSource
|
|
|
59
63
|
if attributes.has_key?(:'buyerHistory')
|
|
60
64
|
self.buyer_history = attributes[:'buyerHistory']
|
|
61
65
|
end
|
|
66
|
+
|
|
67
|
+
if attributes.has_key?(:'auxiliaryData')
|
|
68
|
+
if (value = attributes[:'auxiliaryData']).is_a?(Array)
|
|
69
|
+
self.auxiliary_data = value
|
|
70
|
+
end
|
|
71
|
+
end
|
|
62
72
|
end
|
|
63
73
|
|
|
64
74
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -87,7 +97,8 @@ module CyberSource
|
|
|
87
97
|
self.class == o.class &&
|
|
88
98
|
profile == o.profile &&
|
|
89
99
|
event_type == o.event_type &&
|
|
90
|
-
buyer_history == o.buyer_history
|
|
100
|
+
buyer_history == o.buyer_history &&
|
|
101
|
+
auxiliary_data == o.auxiliary_data
|
|
91
102
|
end
|
|
92
103
|
|
|
93
104
|
# @see the `==` method
|
|
@@ -99,7 +110,7 @@ module CyberSource
|
|
|
99
110
|
# Calculates hash code according to all attributes.
|
|
100
111
|
# @return [Fixnum] Hash code
|
|
101
112
|
def hash
|
|
102
|
-
[profile, event_type, buyer_history].hash
|
|
113
|
+
[profile, event_type, buyer_history, auxiliary_data].hash
|
|
103
114
|
end
|
|
104
115
|
|
|
105
116
|
# Builds the object from hash
|
|
@@ -0,0 +1,207 @@
|
|
|
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.2.3
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
|
|
15
|
+
module CyberSource
|
|
16
|
+
# Contains auxiliary key-value pairs.
|
|
17
|
+
class Ptsv2paymentsRiskInformationAuxiliaryData
|
|
18
|
+
# Fields that you can use to send additional data to Risk services. **Warning** Auxiliary fields are not intended to and MUST NOT be used to capture personally identifying information. Accordingly, merchants are prohibited from capturing, obtaining, and/or transmitting any personally identifying information in or via the auxiliary data fields. Personally identifying information includes, but is not limited to, address, credit card number, social security number, driver's license number, state-issued identification number, passport number, and card verification numbers (CVV, CVC2, CVV2, CID, CVN). In the event CyberSource discovers that a merchant is capturing and/or transmitting personally identifying information via the auxiliary data fields, whether or not intentionally, CyberSource WILL immediately suspend the merchant's account, which will result in a rejection of any and all transaction requests submitted by the merchant after the point of suspension.
|
|
19
|
+
attr_accessor :key
|
|
20
|
+
|
|
21
|
+
# String value for the key
|
|
22
|
+
attr_accessor :value
|
|
23
|
+
|
|
24
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
25
|
+
def self.attribute_map
|
|
26
|
+
{
|
|
27
|
+
:'key' => :'key',
|
|
28
|
+
:'value' => :'value'
|
|
29
|
+
}
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
# Attribute type mapping.
|
|
33
|
+
def self.swagger_types
|
|
34
|
+
{
|
|
35
|
+
:'key' => :'String',
|
|
36
|
+
:'value' => :'String'
|
|
37
|
+
}
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
# Initializes the object
|
|
41
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
42
|
+
def initialize(attributes = {})
|
|
43
|
+
return unless attributes.is_a?(Hash)
|
|
44
|
+
|
|
45
|
+
# convert string to symbol for hash key
|
|
46
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
|
47
|
+
|
|
48
|
+
if attributes.has_key?(:'key')
|
|
49
|
+
self.key = attributes[:'key']
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
if attributes.has_key?(:'value')
|
|
53
|
+
self.value = attributes[:'value']
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
58
|
+
# @return Array for valid properties with the reasons
|
|
59
|
+
def list_invalid_properties
|
|
60
|
+
invalid_properties = Array.new
|
|
61
|
+
invalid_properties
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
# Check to see if the all the properties in the model are valid
|
|
65
|
+
# @return true if the model is valid
|
|
66
|
+
def valid?
|
|
67
|
+
true
|
|
68
|
+
end
|
|
69
|
+
|
|
70
|
+
# Custom attribute writer method with validation
|
|
71
|
+
# @param [Object] key Value to be assigned
|
|
72
|
+
def key=(key)
|
|
73
|
+
@key = key
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
# Custom attribute writer method with validation
|
|
77
|
+
# @param [Object] value Value to be assigned
|
|
78
|
+
def value=(value)
|
|
79
|
+
@value = value
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
# Checks equality by comparing each attribute.
|
|
83
|
+
# @param [Object] Object to be compared
|
|
84
|
+
def ==(o)
|
|
85
|
+
return true if self.equal?(o)
|
|
86
|
+
self.class == o.class &&
|
|
87
|
+
key == o.key &&
|
|
88
|
+
value == o.value
|
|
89
|
+
end
|
|
90
|
+
|
|
91
|
+
# @see the `==` method
|
|
92
|
+
# @param [Object] Object to be compared
|
|
93
|
+
def eql?(o)
|
|
94
|
+
self == o
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
# Calculates hash code according to all attributes.
|
|
98
|
+
# @return [Fixnum] Hash code
|
|
99
|
+
def hash
|
|
100
|
+
[key, value].hash
|
|
101
|
+
end
|
|
102
|
+
|
|
103
|
+
# Builds the object from hash
|
|
104
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
105
|
+
# @return [Object] Returns the model itself
|
|
106
|
+
def build_from_hash(attributes)
|
|
107
|
+
return nil unless attributes.is_a?(Hash)
|
|
108
|
+
self.class.swagger_types.each_pair do |key, type|
|
|
109
|
+
if type =~ /\AArray<(.*)>/i
|
|
110
|
+
# check to ensure the input is an array given that the the attribute
|
|
111
|
+
# is documented as an array but the input is not
|
|
112
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
113
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
114
|
+
end
|
|
115
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
116
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
117
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
|
118
|
+
end
|
|
119
|
+
|
|
120
|
+
self
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# Deserializes the data based on type
|
|
124
|
+
# @param string type Data type
|
|
125
|
+
# @param string value Value to be deserialized
|
|
126
|
+
# @return [Object] Deserialized data
|
|
127
|
+
def _deserialize(type, value)
|
|
128
|
+
case type.to_sym
|
|
129
|
+
when :DateTime
|
|
130
|
+
DateTime.parse(value)
|
|
131
|
+
when :Date
|
|
132
|
+
Date.parse(value)
|
|
133
|
+
when :String
|
|
134
|
+
value.to_s
|
|
135
|
+
when :Integer
|
|
136
|
+
value.to_i
|
|
137
|
+
when :Float
|
|
138
|
+
value.to_f
|
|
139
|
+
when :BOOLEAN
|
|
140
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
141
|
+
true
|
|
142
|
+
else
|
|
143
|
+
false
|
|
144
|
+
end
|
|
145
|
+
when :Object
|
|
146
|
+
# generic object (usually a Hash), return directly
|
|
147
|
+
value
|
|
148
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
149
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
150
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
151
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
152
|
+
k_type = Regexp.last_match[:k_type]
|
|
153
|
+
v_type = Regexp.last_match[:v_type]
|
|
154
|
+
{}.tap do |hash|
|
|
155
|
+
value.each do |k, v|
|
|
156
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
157
|
+
end
|
|
158
|
+
end
|
|
159
|
+
else # model
|
|
160
|
+
temp_model = CyberSource.const_get(type).new
|
|
161
|
+
temp_model.build_from_hash(value)
|
|
162
|
+
end
|
|
163
|
+
end
|
|
164
|
+
|
|
165
|
+
# Returns the string representation of the object
|
|
166
|
+
# @return [String] String presentation of the object
|
|
167
|
+
def to_s
|
|
168
|
+
to_hash.to_s
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
172
|
+
# @return [Hash] Returns the object in the form of hash
|
|
173
|
+
def to_body
|
|
174
|
+
to_hash
|
|
175
|
+
end
|
|
176
|
+
|
|
177
|
+
# Returns the object in the form of hash
|
|
178
|
+
# @return [Hash] Returns the object in the form of hash
|
|
179
|
+
def to_hash
|
|
180
|
+
hash = {}
|
|
181
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
182
|
+
value = self.send(attr)
|
|
183
|
+
next if value.nil?
|
|
184
|
+
hash[param] = _to_hash(value)
|
|
185
|
+
end
|
|
186
|
+
hash
|
|
187
|
+
end
|
|
188
|
+
|
|
189
|
+
# Outputs non-array value in the form of hash
|
|
190
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
191
|
+
# @param [Object] value Any valid value
|
|
192
|
+
# @return [Hash] Returns the value in the form of hash
|
|
193
|
+
def _to_hash(value)
|
|
194
|
+
if value.is_a?(Array)
|
|
195
|
+
value.compact.map { |v| _to_hash(v) }
|
|
196
|
+
elsif value.is_a?(Hash)
|
|
197
|
+
{}.tap do |hash|
|
|
198
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
199
|
+
end
|
|
200
|
+
elsif value.respond_to? :to_hash
|
|
201
|
+
value.to_hash
|
|
202
|
+
else
|
|
203
|
+
value
|
|
204
|
+
end
|
|
205
|
+
end
|
|
206
|
+
end
|
|
207
|
+
end
|