cybersource_rest_client 0.0.53 → 0.0.55
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/AuthenticationSDK/authentication/http/GetSignatureParameter.rb +2 -2
- data/lib/AuthenticationSDK/authentication/http/HttpSignatureHeader.rb +6 -6
- data/lib/AuthenticationSDK/core/MerchantConfig.rb +6 -0
- data/lib/AuthenticationSDK/util/Cache.rb +15 -1
- data/lib/AuthenticationSDK/util/Constants.rb +1 -1
- data/lib/AuthenticationSDK/util/JWEUtility.rb +14 -0
- data/lib/cybersource_rest_client/api/batches_api.rb +12 -12
- data/lib/cybersource_rest_client/api/billing_agreements_api.rb +231 -0
- data/lib/cybersource_rest_client/api/decision_manager_api.rb +142 -0
- data/lib/cybersource_rest_client/api/invoice_settings_api.rb +2 -2
- data/lib/cybersource_rest_client/api/invoices_api.rb +6 -6
- data/lib/cybersource_rest_client/api/keymanagement_api.rb +3 -3
- data/lib/cybersource_rest_client/api/payments_api.rb +2 -2
- data/lib/cybersource_rest_client/api/plans_api.rb +32 -32
- data/lib/cybersource_rest_client/api/subscriptions_api.rb +32 -32
- data/lib/cybersource_rest_client/api/void_api.rb +2 -2
- data/lib/cybersource_rest_client/models/access_token_response.rb +244 -244
- data/lib/cybersource_rest_client/models/activate_deactivate_plan_response.rb +239 -0
- data/lib/cybersource_rest_client/models/{inline_response_200_9.rb → activate_subscription_response.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_200_9_subscription_information.rb → activate_subscription_response_subscription_information.rb} +1 -1
- data/lib/cybersource_rest_client/models/bad_request_error.rb +192 -192
- data/lib/cybersource_rest_client/models/{inline_response_202_1.rb → cancel_subscription_response.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_202_subscription_information.rb → cancel_subscription_response_subscription_information.rb} +1 -1
- data/lib/cybersource_rest_client/models/case_management_actions_request.rb +200 -0
- data/lib/cybersource_rest_client/models/case_management_comments_request.rb +206 -0
- data/lib/cybersource_rest_client/models/create_access_token_request.rb +254 -254
- data/lib/cybersource_rest_client/models/{inline_response_200_14.rb → create_billing_agreement.rb} +65 -88
- data/lib/cybersource_rest_client/models/create_bundled_decision_manager_case_request.rb +15 -5
- data/lib/cybersource_rest_client/models/create_plan_response.rb +239 -0
- data/lib/cybersource_rest_client/models/{inline_response_201_plan_information.rb → create_plan_response_plan_information.rb} +1 -1
- data/lib/cybersource_rest_client/models/create_subscription_request.rb +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_201_1.rb → create_subscription_response.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_201_1__links.rb → create_subscription_response__links.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_201_1_subscription_information.rb → create_subscription_response_subscription_information.rb} +1 -1
- data/lib/cybersource_rest_client/models/delete_plan_response.rb +202 -0
- data/lib/cybersource_rest_client/models/{inline_response_202_2.rb → get_all_plans_response.rb} +31 -18
- data/lib/cybersource_rest_client/models/{inline_response_200__links.rb → get_all_plans_response__links.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_order_information.rb → get_all_plans_response_order_information.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_200_order_information_amount_details.rb → get_all_plans_response_order_information_amount_details.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_plan_information.rb → get_all_plans_response_plan_information.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_200_plan_information_billing_cycles.rb → get_all_plans_response_plan_information_billing_cycles.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_plan_information_billing_period.rb → get_all_plans_response_plan_information_billing_period.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_plans.rb → get_all_plans_response_plans.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_200_6.rb → get_all_subscriptions_response.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_200_6__links.rb → get_all_subscriptions_response__links.rb} +1 -1
- data/lib/cybersource_rest_client/models/get_all_subscriptions_response_order_information.rb +200 -0
- data/lib/cybersource_rest_client/models/{inline_response_200_6_order_information_bill_to.rb → get_all_subscriptions_response_order_information_bill_to.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_6_payment_information.rb → get_all_subscriptions_response_payment_information.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_200_6_payment_information_customer.rb → get_all_subscriptions_response_payment_information_customer.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_6_plan_information.rb → get_all_subscriptions_response_plan_information.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_200_6_plan_information_billing_cycles.rb → get_all_subscriptions_response_plan_information_billing_cycles.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_6_subscription_information.rb → get_all_subscriptions_response_subscription_information.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_6_subscriptions.rb → get_all_subscriptions_response_subscriptions.rb} +6 -6
- data/lib/cybersource_rest_client/models/{inline_response_200_5.rb → get_plan_code_response.rb} +1 -1
- data/lib/cybersource_rest_client/models/get_plan_response.rb +238 -0
- data/lib/cybersource_rest_client/models/{inline_response_200_10.rb → get_subscription_code_response.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_7.rb → get_subscription_response.rb} +6 -6
- data/lib/cybersource_rest_client/models/inline_response_200.rb +30 -25
- data/lib/cybersource_rest_client/models/inline_response_200_1.rb +50 -40
- data/lib/cybersource_rest_client/models/{inline_response_200_11_keys.rb → inline_response_200_1_keys.rb} +1 -1
- data/lib/cybersource_rest_client/models/inline_response_200_2.rb +67 -17
- data/lib/cybersource_rest_client/models/{inline_response_200_12__embedded.rb → inline_response_200_2__embedded.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_200_12__embedded__links.rb → inline_response_200_2__embedded__links.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_200_12__embedded__links_reports.rb → inline_response_200_2__embedded__links_reports.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_12__embedded_batches.rb → inline_response_200_2__embedded_batches.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_200_12__embedded_totals.rb → inline_response_200_2__embedded_totals.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_12__links.rb → inline_response_200_2__links.rb} +1 -1
- data/lib/cybersource_rest_client/models/inline_response_200_3.rb +81 -29
- data/lib/cybersource_rest_client/models/{inline_response_200_13__links.rb → inline_response_200_3__links.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_202_2__links_status.rb → inline_response_200_3__links_report.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_13_billing.rb → inline_response_200_3_billing.rb} +1 -1
- data/lib/cybersource_rest_client/models/inline_response_200_4.rb +96 -42
- data/lib/cybersource_rest_client/models/{inline_response_200_14_records.rb → inline_response_200_4_records.rb} +3 -3
- data/lib/cybersource_rest_client/models/{inline_response_200_14_response_record.rb → inline_response_200_4_response_record.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_200_14_response_record_additional_updates.rb → inline_response_200_4_response_record_additional_updates.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_14_source_record.rb → inline_response_200_4_source_record.rb} +1 -1
- data/lib/cybersource_rest_client/models/inline_response_200__embedded.rb +201 -0
- data/lib/cybersource_rest_client/models/inline_response_200__embedded_capture.rb +202 -0
- data/lib/cybersource_rest_client/models/inline_response_200__embedded_capture__links.rb +191 -0
- data/lib/cybersource_rest_client/models/inline_response_200__embedded_capture__links_self.rb +203 -0
- data/lib/cybersource_rest_client/models/inline_response_200__embedded_reversal.rb +202 -0
- data/lib/cybersource_rest_client/models/inline_response_200__embedded_reversal__links.rb +191 -0
- data/lib/cybersource_rest_client/models/inline_response_200__embedded_reversal__links_self.rb +203 -0
- data/lib/cybersource_rest_client/models/inline_response_201.rb +7 -27
- data/lib/cybersource_rest_client/models/inline_response_202.rb +17 -45
- data/lib/cybersource_rest_client/models/{inline_response_202_2__links.rb → inline_response_202__links.rb} +2 -2
- data/lib/cybersource_rest_client/models/{inline_response_200_13__links_report.rb → inline_response_202__links_status.rb} +1 -1
- data/lib/cybersource_rest_client/models/inline_response_400_1.rb +3 -3
- data/lib/cybersource_rest_client/models/inline_response_400_2.rb +1 -1
- data/lib/cybersource_rest_client/models/inline_response_400_3.rb +37 -60
- data/lib/cybersource_rest_client/models/inline_response_400_4.rb +61 -37
- data/lib/cybersource_rest_client/models/{inline_response_400_3_fields.rb → inline_response_400_4_fields.rb} +1 -1
- data/lib/cybersource_rest_client/models/inline_response_400_5.rb +10 -11
- data/lib/cybersource_rest_client/models/inline_response_400_6.rb +35 -75
- data/lib/cybersource_rest_client/models/inline_response_400_7.rb +276 -0
- data/lib/cybersource_rest_client/models/{inline_response_400_6_details.rb → inline_response_400_7_details.rb} +1 -1
- data/lib/cybersource_rest_client/models/inline_response_403_1.rb +236 -0
- data/lib/cybersource_rest_client/models/inline_response_422.rb +236 -0
- data/lib/cybersource_rest_client/models/inline_response_500_1.rb +20 -8
- data/lib/cybersource_rest_client/models/inline_response_500_2.rb +224 -0
- data/lib/cybersource_rest_client/models/inline_response_502.rb +13 -12
- data/lib/cybersource_rest_client/models/inline_response_502_1.rb +235 -0
- data/lib/cybersource_rest_client/models/inline_response_503.rb +236 -0
- data/lib/cybersource_rest_client/models/{inline_response_200_12.rb → intimate_billing_agreement.rb} +37 -59
- data/lib/cybersource_rest_client/models/invoicing_v2_invoices_all_get200_response.rb +1 -1
- data/lib/cybersource_rest_client/models/modify_billing_agreement.rb +270 -0
- data/lib/cybersource_rest_client/models/pts_v2_credits_post201_response_1.rb +239 -0
- data/lib/cybersource_rest_client/models/pts_v2_credits_post201_response_1_installment_information.rb +197 -0
- data/lib/cybersource_rest_client/models/pts_v2_credits_post201_response_1_processor_information.rb +214 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_aggregator_information.rb +207 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_consumer_authentication_information.rb +242 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_device_information.rb +231 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_installment_information.rb +327 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_merchant_information.rb +235 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_merchant_information_merchant_descriptor.rb +242 -0
- data/lib/cybersource_rest_client/models/{inline_response_200_6_order_information.rb → ptsv2billingagreements_order_information.rb} +3 -3
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_order_information_bill_to.rb +401 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_payment_information.rb +200 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_payment_information_card.rb +259 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_payment_information_tokenized_card.rb +276 -0
- data/lib/cybersource_rest_client/models/ptsv2billingagreements_processing_information.rb +210 -0
- data/lib/cybersource_rest_client/models/ptsv2payments_order_information.rb +12 -1
- data/lib/cybersource_rest_client/models/ptsv2payments_processing_information_authorization_options.rb +16 -5
- data/lib/cybersource_rest_client/models/rbsv1plans_plan_information.rb +1 -1
- data/lib/cybersource_rest_client/models/rbsv1plansid_plan_information.rb +1 -1
- data/lib/cybersource_rest_client/models/rbsv1subscriptions_plan_information.rb +1 -1
- data/lib/cybersource_rest_client/models/resource_not_found_error.rb +192 -192
- data/lib/cybersource_rest_client/models/risk_v1_decisions_post201_response_consumer_authentication_information.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1authenticationsetups_token_information.rb +22 -5
- data/lib/cybersource_rest_client/models/riskv1decisions_order_information.rb +12 -1
- data/lib/cybersource_rest_client/models/riskv1decisions_processing_information.rb +1 -1
- data/lib/cybersource_rest_client/models/riskv1decisions_token_information.rb +197 -0
- data/lib/cybersource_rest_client/models/riskv1decisionsidactions_decision_information.rb +208 -0
- data/lib/cybersource_rest_client/models/riskv1decisionsidactions_processing_information.rb +193 -0
- data/lib/cybersource_rest_client/models/suspend_subscription_response.rb +239 -0
- data/lib/cybersource_rest_client/models/{inline_response_202_1_subscription_information.rb → suspend_subscription_response_subscription_information.rb} +1 -1
- data/lib/cybersource_rest_client/models/unauthorized_client_error.rb +192 -192
- data/lib/cybersource_rest_client/models/update_plan_request.rb +1 -1
- data/lib/cybersource_rest_client/models/update_plan_response.rb +239 -0
- data/lib/cybersource_rest_client/models/{inline_response_200_3_plan_information.rb → update_plan_response_plan_information.rb} +1 -1
- data/lib/cybersource_rest_client/models/{inline_response_200_8.rb → update_subscription_response.rb} +3 -3
- data/lib/cybersource_rest_client/models/validate_request.rb +15 -5
- data/lib/cybersource_rest_client/utilities/jwe_utility.rb +12 -0
- data/lib/cybersource_rest_client.rb +95 -54
- metadata +112 -57
- data/lib/cybersource_rest_client/models/inline_response_200_11.rb +0 -248
- data/lib/cybersource_rest_client/models/inline_response_200_13.rb +0 -291
@@ -13,7 +13,7 @@ Swagger Codegen version: 2.2.3
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module CyberSource
|
16
|
-
class
|
16
|
+
class GetAllSubscriptionsResponsePlanInformation
|
17
17
|
# Plan code
|
18
18
|
attr_accessor :code
|
19
19
|
|
@@ -49,8 +49,8 @@ module CyberSource
|
|
49
49
|
{
|
50
50
|
:'code' => :'String',
|
51
51
|
:'name' => :'String',
|
52
|
-
:'billing_period' => :'
|
53
|
-
:'billing_cycles' => :'
|
52
|
+
:'billing_period' => :'GetAllPlansResponsePlanInformationBillingPeriod',
|
53
|
+
:'billing_cycles' => :'GetAllSubscriptionsResponsePlanInformationBillingCycles'
|
54
54
|
}
|
55
55
|
end
|
56
56
|
|
@@ -13,7 +13,7 @@ Swagger Codegen version: 2.2.3
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module CyberSource
|
16
|
-
class
|
16
|
+
class GetAllSubscriptionsResponsePlanInformationBillingCycles
|
17
17
|
# Describe total number of billing cycles
|
18
18
|
attr_accessor :total
|
19
19
|
|
@@ -14,7 +14,7 @@ require 'date'
|
|
14
14
|
|
15
15
|
module CyberSource
|
16
16
|
# Subscription list
|
17
|
-
class
|
17
|
+
class GetAllSubscriptionsResponseSubscriptions
|
18
18
|
attr_accessor :_links
|
19
19
|
|
20
20
|
# An unique identification number generated by Cybersource to identify the submitted request. Returned by all services. It is also appended to the endpoint of the resource. On incremental authorizations, this value with be the same as the identification number returned in the original authorization response.
|
@@ -55,12 +55,12 @@ module CyberSource
|
|
55
55
|
# Attribute type mapping.
|
56
56
|
def self.swagger_types
|
57
57
|
{
|
58
|
-
:'_links' => :'
|
58
|
+
:'_links' => :'GetAllSubscriptionsResponseLinks',
|
59
59
|
:'id' => :'String',
|
60
|
-
:'plan_information' => :'
|
61
|
-
:'subscription_information' => :'
|
62
|
-
:'payment_information' => :'
|
63
|
-
:'order_information' => :'
|
60
|
+
:'plan_information' => :'GetAllSubscriptionsResponsePlanInformation',
|
61
|
+
:'subscription_information' => :'GetAllSubscriptionsResponseSubscriptionInformation',
|
62
|
+
:'payment_information' => :'GetAllSubscriptionsResponsePaymentInformation',
|
63
|
+
:'order_information' => :'GetAllSubscriptionsResponseOrderInformation'
|
64
64
|
}
|
65
65
|
end
|
66
66
|
|
@@ -0,0 +1,238 @@
|
|
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
|
+
class GetPlanResponse
|
17
|
+
attr_accessor :_links
|
18
|
+
|
19
|
+
# An unique identification number generated by Cybersource to identify the submitted request. Returned by all services. It is also appended to the endpoint of the resource. On incremental authorizations, this value with be the same as the identification number returned in the original authorization response.
|
20
|
+
attr_accessor :id
|
21
|
+
|
22
|
+
# Time of request in UTC. Format: `YYYY-MM-DDThh:mm:ssZ` **Example** `2016-08-11T22:47:57Z` equals August 11, 2016, at 22:47:57 (10:47:57 p.m.). The `T` separates the date and the time. The `Z` indicates UTC. Returned by Cybersource for all services.
|
23
|
+
attr_accessor :submit_time_utc
|
24
|
+
|
25
|
+
attr_accessor :plan_information
|
26
|
+
|
27
|
+
attr_accessor :order_information
|
28
|
+
|
29
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
30
|
+
def self.attribute_map
|
31
|
+
{
|
32
|
+
:'_links' => :'_links',
|
33
|
+
:'id' => :'id',
|
34
|
+
:'submit_time_utc' => :'submitTimeUtc',
|
35
|
+
:'plan_information' => :'planInformation',
|
36
|
+
:'order_information' => :'orderInformation'
|
37
|
+
}
|
38
|
+
end
|
39
|
+
|
40
|
+
# Attribute mapping from JSON key to ruby-style variable name.
|
41
|
+
def self.json_map
|
42
|
+
{
|
43
|
+
:'_links' => :'_links',
|
44
|
+
:'id' => :'id',
|
45
|
+
:'submit_time_utc' => :'submit_time_utc',
|
46
|
+
:'plan_information' => :'plan_information',
|
47
|
+
:'order_information' => :'order_information'
|
48
|
+
}
|
49
|
+
end
|
50
|
+
|
51
|
+
# Attribute type mapping.
|
52
|
+
def self.swagger_types
|
53
|
+
{
|
54
|
+
:'_links' => :'PtsV2IncrementalAuthorizationPatch201ResponseLinks',
|
55
|
+
:'id' => :'String',
|
56
|
+
:'submit_time_utc' => :'String',
|
57
|
+
:'plan_information' => :'GetAllPlansResponsePlanInformation',
|
58
|
+
:'order_information' => :'GetAllPlansResponseOrderInformation'
|
59
|
+
}
|
60
|
+
end
|
61
|
+
|
62
|
+
# Initializes the object
|
63
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
64
|
+
def initialize(attributes = {})
|
65
|
+
return unless attributes.is_a?(Hash)
|
66
|
+
|
67
|
+
# convert string to symbol for hash key
|
68
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
69
|
+
|
70
|
+
if attributes.has_key?(:'_links')
|
71
|
+
self._links = attributes[:'_links']
|
72
|
+
end
|
73
|
+
|
74
|
+
if attributes.has_key?(:'id')
|
75
|
+
self.id = attributes[:'id']
|
76
|
+
end
|
77
|
+
|
78
|
+
if attributes.has_key?(:'submitTimeUtc')
|
79
|
+
self.submit_time_utc = attributes[:'submitTimeUtc']
|
80
|
+
end
|
81
|
+
|
82
|
+
if attributes.has_key?(:'planInformation')
|
83
|
+
self.plan_information = attributes[:'planInformation']
|
84
|
+
end
|
85
|
+
|
86
|
+
if attributes.has_key?(:'orderInformation')
|
87
|
+
self.order_information = attributes[:'orderInformation']
|
88
|
+
end
|
89
|
+
end
|
90
|
+
|
91
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
92
|
+
# @return Array for valid properties with the reasons
|
93
|
+
def list_invalid_properties
|
94
|
+
invalid_properties = Array.new
|
95
|
+
invalid_properties
|
96
|
+
end
|
97
|
+
|
98
|
+
# Check to see if the all the properties in the model are valid
|
99
|
+
# @return true if the model is valid
|
100
|
+
def valid?
|
101
|
+
true
|
102
|
+
end
|
103
|
+
|
104
|
+
# Custom attribute writer method with validation
|
105
|
+
# @param [Object] id Value to be assigned
|
106
|
+
def id=(id)
|
107
|
+
@id = id
|
108
|
+
end
|
109
|
+
|
110
|
+
# Checks equality by comparing each attribute.
|
111
|
+
# @param [Object] Object to be compared
|
112
|
+
def ==(o)
|
113
|
+
return true if self.equal?(o)
|
114
|
+
self.class == o.class &&
|
115
|
+
_links == o._links &&
|
116
|
+
id == o.id &&
|
117
|
+
submit_time_utc == o.submit_time_utc &&
|
118
|
+
plan_information == o.plan_information &&
|
119
|
+
order_information == o.order_information
|
120
|
+
end
|
121
|
+
|
122
|
+
# @see the `==` method
|
123
|
+
# @param [Object] Object to be compared
|
124
|
+
def eql?(o)
|
125
|
+
self == o
|
126
|
+
end
|
127
|
+
|
128
|
+
# Calculates hash code according to all attributes.
|
129
|
+
# @return [Fixnum] Hash code
|
130
|
+
def hash
|
131
|
+
[_links, id, submit_time_utc, plan_information, order_information].hash
|
132
|
+
end
|
133
|
+
|
134
|
+
# Builds the object from hash
|
135
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
136
|
+
# @return [Object] Returns the model itself
|
137
|
+
def build_from_hash(attributes)
|
138
|
+
return nil unless attributes.is_a?(Hash)
|
139
|
+
self.class.swagger_types.each_pair do |key, type|
|
140
|
+
if type =~ /\AArray<(.*)>/i
|
141
|
+
# check to ensure the input is an array given that the the attribute
|
142
|
+
# is documented as an array but the input is not
|
143
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
144
|
+
self.send("#{self.class.json_map[key]}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
145
|
+
end
|
146
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
147
|
+
self.send("#{self.class.json_map[key]}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
148
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
149
|
+
end
|
150
|
+
|
151
|
+
self
|
152
|
+
end
|
153
|
+
|
154
|
+
# Deserializes the data based on type
|
155
|
+
# @param string type Data type
|
156
|
+
# @param string value Value to be deserialized
|
157
|
+
# @return [Object] Deserialized data
|
158
|
+
def _deserialize(type, value)
|
159
|
+
case type.to_sym
|
160
|
+
when :DateTime
|
161
|
+
DateTime.parse(value)
|
162
|
+
when :Date
|
163
|
+
Date.parse(value)
|
164
|
+
when :String
|
165
|
+
value.to_s
|
166
|
+
when :Integer
|
167
|
+
value.to_i
|
168
|
+
when :Float
|
169
|
+
value.to_f
|
170
|
+
when :BOOLEAN
|
171
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
172
|
+
true
|
173
|
+
else
|
174
|
+
false
|
175
|
+
end
|
176
|
+
when :Object
|
177
|
+
# generic object (usually a Hash), return directly
|
178
|
+
value
|
179
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
180
|
+
inner_type = Regexp.last_match[:inner_type]
|
181
|
+
value.map { |v| _deserialize(inner_type, v) }
|
182
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
183
|
+
k_type = Regexp.last_match[:k_type]
|
184
|
+
v_type = Regexp.last_match[:v_type]
|
185
|
+
{}.tap do |hash|
|
186
|
+
value.each do |k, v|
|
187
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
188
|
+
end
|
189
|
+
end
|
190
|
+
else # model
|
191
|
+
temp_model = CyberSource.const_get(type).new
|
192
|
+
temp_model.build_from_hash(value)
|
193
|
+
end
|
194
|
+
end
|
195
|
+
|
196
|
+
# Returns the string representation of the object
|
197
|
+
# @return [String] String presentation of the object
|
198
|
+
def to_s
|
199
|
+
to_hash.to_s
|
200
|
+
end
|
201
|
+
|
202
|
+
# to_body is an alias to to_hash (backward compatibility)
|
203
|
+
# @return [Hash] Returns the object in the form of hash
|
204
|
+
def to_body
|
205
|
+
to_hash
|
206
|
+
end
|
207
|
+
|
208
|
+
# Returns the object in the form of hash
|
209
|
+
# @return [Hash] Returns the object in the form of hash
|
210
|
+
def to_hash
|
211
|
+
hash = {}
|
212
|
+
self.class.attribute_map.each_pair do |attr, param|
|
213
|
+
value = self.send(attr)
|
214
|
+
next if value.nil?
|
215
|
+
hash[param] = _to_hash(value)
|
216
|
+
end
|
217
|
+
hash
|
218
|
+
end
|
219
|
+
|
220
|
+
# Outputs non-array value in the form of hash
|
221
|
+
# For object, use to_hash. Otherwise, just return the value
|
222
|
+
# @param [Object] value Any valid value
|
223
|
+
# @return [Hash] Returns the value in the form of hash
|
224
|
+
def _to_hash(value)
|
225
|
+
if value.is_a?(Array)
|
226
|
+
value.compact.map { |v| _to_hash(v) }
|
227
|
+
elsif value.is_a?(Hash)
|
228
|
+
{}.tap do |hash|
|
229
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
230
|
+
end
|
231
|
+
elsif value.respond_to? :to_hash
|
232
|
+
value.to_hash
|
233
|
+
else
|
234
|
+
value
|
235
|
+
end
|
236
|
+
end
|
237
|
+
end
|
238
|
+
end
|
data/lib/cybersource_rest_client/models/{inline_response_200_7.rb → get_subscription_response.rb}
RENAMED
@@ -13,7 +13,7 @@ Swagger Codegen version: 2.2.3
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module CyberSource
|
16
|
-
class
|
16
|
+
class GetSubscriptionResponse
|
17
17
|
attr_accessor :_links
|
18
18
|
|
19
19
|
# An unique identification number generated by Cybersource to identify the submitted request. Returned by all services. It is also appended to the endpoint of the resource. On incremental authorizations, this value with be the same as the identification number returned in the original authorization response.
|
@@ -59,13 +59,13 @@ module CyberSource
|
|
59
59
|
# Attribute type mapping.
|
60
60
|
def self.swagger_types
|
61
61
|
{
|
62
|
-
:'_links' => :'
|
62
|
+
:'_links' => :'GetAllSubscriptionsResponseLinks',
|
63
63
|
:'id' => :'String',
|
64
64
|
:'submit_time_utc' => :'String',
|
65
|
-
:'plan_information' => :'
|
66
|
-
:'subscription_information' => :'
|
67
|
-
:'payment_information' => :'
|
68
|
-
:'order_information' => :'
|
65
|
+
:'plan_information' => :'GetAllSubscriptionsResponsePlanInformation',
|
66
|
+
:'subscription_information' => :'GetAllSubscriptionsResponseSubscriptionInformation',
|
67
|
+
:'payment_information' => :'GetAllSubscriptionsResponsePaymentInformation',
|
68
|
+
:'order_information' => :'GetAllSubscriptionsResponseOrderInformation'
|
69
69
|
}
|
70
70
|
end
|
71
71
|
|
@@ -14,43 +14,44 @@ require 'date'
|
|
14
14
|
|
15
15
|
module CyberSource
|
16
16
|
class InlineResponse200
|
17
|
-
|
17
|
+
# UUID uniquely generated for this comments.
|
18
|
+
attr_accessor :id
|
18
19
|
|
19
20
|
# Time of request in UTC. Format: `YYYY-MM-DDThh:mm:ssZ` **Example** `2016-08-11T22:47:57Z` equals August 11, 2016, at 22:47:57 (10:47:57 p.m.). The `T` separates the date and the time. The `Z` indicates UTC. Returned by Cybersource for all services.
|
20
21
|
attr_accessor :submit_time_utc
|
21
22
|
|
22
|
-
#
|
23
|
-
attr_accessor :
|
23
|
+
# The status of the submitted transaction. Possible values are: - `ACCEPTED` - `REJECTED`
|
24
|
+
attr_accessor :status
|
24
25
|
|
25
|
-
attr_accessor :
|
26
|
+
attr_accessor :_embedded
|
26
27
|
|
27
28
|
# Attribute mapping from ruby-style variable name to JSON key.
|
28
29
|
def self.attribute_map
|
29
30
|
{
|
30
|
-
:'
|
31
|
+
:'id' => :'id',
|
31
32
|
:'submit_time_utc' => :'submitTimeUtc',
|
32
|
-
:'
|
33
|
-
:'
|
33
|
+
:'status' => :'status',
|
34
|
+
:'_embedded' => :'_embedded'
|
34
35
|
}
|
35
36
|
end
|
36
37
|
|
37
38
|
# Attribute mapping from JSON key to ruby-style variable name.
|
38
39
|
def self.json_map
|
39
40
|
{
|
40
|
-
:'
|
41
|
+
:'id' => :'id',
|
41
42
|
:'submit_time_utc' => :'submit_time_utc',
|
42
|
-
:'
|
43
|
-
:'
|
43
|
+
:'status' => :'status',
|
44
|
+
:'_embedded' => :'_embedded'
|
44
45
|
}
|
45
46
|
end
|
46
47
|
|
47
48
|
# Attribute type mapping.
|
48
49
|
def self.swagger_types
|
49
50
|
{
|
50
|
-
:'
|
51
|
+
:'id' => :'String',
|
51
52
|
:'submit_time_utc' => :'String',
|
52
|
-
:'
|
53
|
-
:'
|
53
|
+
:'status' => :'String',
|
54
|
+
:'_embedded' => :'InlineResponse200Embedded'
|
54
55
|
}
|
55
56
|
end
|
56
57
|
|
@@ -62,22 +63,20 @@ module CyberSource
|
|
62
63
|
# convert string to symbol for hash key
|
63
64
|
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
64
65
|
|
65
|
-
if attributes.has_key?(:'
|
66
|
-
self.
|
66
|
+
if attributes.has_key?(:'id')
|
67
|
+
self.id = attributes[:'id']
|
67
68
|
end
|
68
69
|
|
69
70
|
if attributes.has_key?(:'submitTimeUtc')
|
70
71
|
self.submit_time_utc = attributes[:'submitTimeUtc']
|
71
72
|
end
|
72
73
|
|
73
|
-
if attributes.has_key?(:'
|
74
|
-
self.
|
74
|
+
if attributes.has_key?(:'status')
|
75
|
+
self.status = attributes[:'status']
|
75
76
|
end
|
76
77
|
|
77
|
-
if attributes.has_key?(:'
|
78
|
-
|
79
|
-
self.plans = value
|
80
|
-
end
|
78
|
+
if attributes.has_key?(:'_embedded')
|
79
|
+
self._embedded = attributes[:'_embedded']
|
81
80
|
end
|
82
81
|
end
|
83
82
|
|
@@ -94,15 +93,21 @@ module CyberSource
|
|
94
93
|
true
|
95
94
|
end
|
96
95
|
|
96
|
+
# Custom attribute writer method with validation
|
97
|
+
# @param [Object] id Value to be assigned
|
98
|
+
def id=(id)
|
99
|
+
@id = id
|
100
|
+
end
|
101
|
+
|
97
102
|
# Checks equality by comparing each attribute.
|
98
103
|
# @param [Object] Object to be compared
|
99
104
|
def ==(o)
|
100
105
|
return true if self.equal?(o)
|
101
106
|
self.class == o.class &&
|
102
|
-
|
107
|
+
id == o.id &&
|
103
108
|
submit_time_utc == o.submit_time_utc &&
|
104
|
-
|
105
|
-
|
109
|
+
status == o.status &&
|
110
|
+
_embedded == o._embedded
|
106
111
|
end
|
107
112
|
|
108
113
|
# @see the `==` method
|
@@ -114,7 +119,7 @@ module CyberSource
|
|
114
119
|
# Calculates hash code according to all attributes.
|
115
120
|
# @return [Fixnum] Hash code
|
116
121
|
def hash
|
117
|
-
[
|
122
|
+
[id, submit_time_utc, status, _embedded].hash
|
118
123
|
end
|
119
124
|
|
120
125
|
# Builds the object from hash
|
@@ -13,49 +13,58 @@ Swagger Codegen version: 2.2.3
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module CyberSource
|
16
|
+
# Successful searchKeysResponse
|
16
17
|
class InlineResponse2001
|
17
|
-
|
18
|
+
# Time of request in UTC. `Format: YYYY-MM-DDThh:mm:ssZ` Example 2016-08-11T22:47:57Z equals August 11, 2016, at 22:47:57 (10:47:57 p.m.). The T separates the date and the time. The Z indicates UTC.
|
19
|
+
attr_accessor :submit_time_utc
|
18
20
|
|
19
|
-
#
|
20
|
-
attr_accessor :
|
21
|
+
# Specifies the total number of items found based on the request
|
22
|
+
attr_accessor :total_count
|
21
23
|
|
22
|
-
#
|
23
|
-
attr_accessor :
|
24
|
+
# Specifies the record offset from the records are returned part of the response
|
25
|
+
attr_accessor :offset
|
26
|
+
|
27
|
+
# Specifies the maximum number of records requested part of the response
|
28
|
+
attr_accessor :limit
|
24
29
|
|
25
|
-
|
30
|
+
# Specifies a comma separated list of field names based on which the result is sorted.
|
31
|
+
attr_accessor :sort
|
26
32
|
|
27
|
-
attr_accessor :
|
33
|
+
attr_accessor :keys
|
28
34
|
|
29
35
|
# Attribute mapping from ruby-style variable name to JSON key.
|
30
36
|
def self.attribute_map
|
31
37
|
{
|
32
|
-
:'_links' => :'_links',
|
33
|
-
:'id' => :'id',
|
34
38
|
:'submit_time_utc' => :'submitTimeUtc',
|
35
|
-
:'
|
36
|
-
:'
|
39
|
+
:'total_count' => :'totalCount',
|
40
|
+
:'offset' => :'offset',
|
41
|
+
:'limit' => :'limit',
|
42
|
+
:'sort' => :'sort',
|
43
|
+
:'keys' => :'keys'
|
37
44
|
}
|
38
45
|
end
|
39
46
|
|
40
47
|
# Attribute mapping from JSON key to ruby-style variable name.
|
41
48
|
def self.json_map
|
42
49
|
{
|
43
|
-
:'_links' => :'_links',
|
44
|
-
:'id' => :'id',
|
45
50
|
:'submit_time_utc' => :'submit_time_utc',
|
46
|
-
:'
|
47
|
-
:'
|
51
|
+
:'total_count' => :'total_count',
|
52
|
+
:'offset' => :'offset',
|
53
|
+
:'limit' => :'limit',
|
54
|
+
:'sort' => :'sort',
|
55
|
+
:'keys' => :'keys'
|
48
56
|
}
|
49
57
|
end
|
50
58
|
|
51
59
|
# Attribute type mapping.
|
52
60
|
def self.swagger_types
|
53
61
|
{
|
54
|
-
:'_links' => :'PtsV2IncrementalAuthorizationPatch201ResponseLinks',
|
55
|
-
:'id' => :'String',
|
56
62
|
:'submit_time_utc' => :'String',
|
57
|
-
:'
|
58
|
-
:'
|
63
|
+
:'total_count' => :'Integer',
|
64
|
+
:'offset' => :'Integer',
|
65
|
+
:'limit' => :'Integer',
|
66
|
+
:'sort' => :'String',
|
67
|
+
:'keys' => :'Array<InlineResponse2001Keys>'
|
59
68
|
}
|
60
69
|
end
|
61
70
|
|
@@ -67,24 +76,30 @@ module CyberSource
|
|
67
76
|
# convert string to symbol for hash key
|
68
77
|
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
69
78
|
|
70
|
-
if attributes.has_key?(:'
|
71
|
-
self.
|
79
|
+
if attributes.has_key?(:'submitTimeUtc')
|
80
|
+
self.submit_time_utc = attributes[:'submitTimeUtc']
|
72
81
|
end
|
73
82
|
|
74
|
-
if attributes.has_key?(:'
|
75
|
-
self.
|
83
|
+
if attributes.has_key?(:'totalCount')
|
84
|
+
self.total_count = attributes[:'totalCount']
|
76
85
|
end
|
77
86
|
|
78
|
-
if attributes.has_key?(:'
|
79
|
-
self.
|
87
|
+
if attributes.has_key?(:'offset')
|
88
|
+
self.offset = attributes[:'offset']
|
89
|
+
end
|
90
|
+
|
91
|
+
if attributes.has_key?(:'limit')
|
92
|
+
self.limit = attributes[:'limit']
|
80
93
|
end
|
81
94
|
|
82
|
-
if attributes.has_key?(:'
|
83
|
-
self.
|
95
|
+
if attributes.has_key?(:'sort')
|
96
|
+
self.sort = attributes[:'sort']
|
84
97
|
end
|
85
98
|
|
86
|
-
if attributes.has_key?(:'
|
87
|
-
|
99
|
+
if attributes.has_key?(:'keys')
|
100
|
+
if (value = attributes[:'keys']).is_a?(Array)
|
101
|
+
self.keys = value
|
102
|
+
end
|
88
103
|
end
|
89
104
|
end
|
90
105
|
|
@@ -101,22 +116,17 @@ module CyberSource
|
|
101
116
|
true
|
102
117
|
end
|
103
118
|
|
104
|
-
# Custom attribute writer method with validation
|
105
|
-
# @param [Object] id Value to be assigned
|
106
|
-
def id=(id)
|
107
|
-
@id = id
|
108
|
-
end
|
109
|
-
|
110
119
|
# Checks equality by comparing each attribute.
|
111
120
|
# @param [Object] Object to be compared
|
112
121
|
def ==(o)
|
113
122
|
return true if self.equal?(o)
|
114
123
|
self.class == o.class &&
|
115
|
-
_links == o._links &&
|
116
|
-
id == o.id &&
|
117
124
|
submit_time_utc == o.submit_time_utc &&
|
118
|
-
|
119
|
-
|
125
|
+
total_count == o.total_count &&
|
126
|
+
offset == o.offset &&
|
127
|
+
limit == o.limit &&
|
128
|
+
sort == o.sort &&
|
129
|
+
keys == o.keys
|
120
130
|
end
|
121
131
|
|
122
132
|
# @see the `==` method
|
@@ -128,7 +138,7 @@ module CyberSource
|
|
128
138
|
# Calculates hash code according to all attributes.
|
129
139
|
# @return [Fixnum] Hash code
|
130
140
|
def hash
|
131
|
-
[
|
141
|
+
[submit_time_utc, total_count, offset, limit, sort, keys].hash
|
132
142
|
end
|
133
143
|
|
134
144
|
# Builds the object from hash
|