cybersource_rest_client 0.0.50 → 0.0.52

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. checksums.yaml +4 -4
  2. data/lib/AuthenticationSDK/authentication/jwt/JwtToken.rb +4 -2
  3. data/lib/cybersource_rest_client/api/payments_api.rb +2 -2
  4. data/lib/cybersource_rest_client/models/create_bundled_decision_manager_case_request.rb +13 -4
  5. data/lib/cybersource_rest_client/models/create_payment_request.rb +13 -4
  6. data/lib/cybersource_rest_client/models/invoicing_v2_invoice_settings_get200_response_invoice_settings_information.rb +32 -8
  7. data/lib/cybersource_rest_client/models/invoicingv2invoice_settings_invoice_settings_information.rb +32 -4
  8. data/lib/cybersource_rest_client/models/invoicingv2invoices_customer_information.rb +13 -4
  9. data/lib/cybersource_rest_client/models/invoicingv2invoices_customer_information_company.rb +190 -0
  10. data/lib/cybersource_rest_client/models/invoicingv2invoices_order_information_amount_details_freight.rb +20 -4
  11. data/lib/cybersource_rest_client/models/invoicingv2invoices_order_information_line_items.rb +84 -4
  12. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response.rb +13 -4
  13. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_error_information.rb +1 -1
  14. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_order_information.rb +13 -4
  15. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_order_information_bill_to.rb +206 -0
  16. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_payment_information_tokenized_card.rb +21 -5
  17. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_processor_information.rb +17 -1
  18. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_processor_information_electronic_verification_results.rb +102 -6
  19. data/lib/cybersource_rest_client/models/{risk_v1_export_compliance_inquiries_post201_response_export_compliance_information.rb → pts_v2_payments_post201_response_watchlist_screening_information.rb} +2 -2
  20. data/lib/cybersource_rest_client/models/{risk_v1_export_compliance_inquiries_post201_response_export_compliance_information_watch_list.rb → pts_v2_payments_post201_response_watchlist_screening_information_watch_list.rb} +2 -2
  21. data/lib/cybersource_rest_client/models/{risk_v1_export_compliance_inquiries_post201_response_watch_list_matches.rb → pts_v2_payments_post201_response_watchlist_screening_information_watch_list_matches.rb} +1 -1
  22. data/lib/cybersource_rest_client/models/pts_v2_payments_refund_post201_response_processor_information.rb +20 -4
  23. data/lib/cybersource_rest_client/models/pts_v2_payouts_post201_response_recipient_information_card.rb +1 -1
  24. data/lib/cybersource_rest_client/models/ptsv2payments_merchant_information.rb +26 -1
  25. data/lib/cybersource_rest_client/models/ptsv2payments_merchant_information_merchant_descriptor.rb +20 -4
  26. data/lib/cybersource_rest_client/models/ptsv2payments_merchant_information_service_location.rb +238 -0
  27. data/lib/cybersource_rest_client/models/ptsv2payments_order_information_amount_details.rb +1 -1
  28. data/lib/cybersource_rest_client/models/ptsv2payments_order_information_bill_to.rb +36 -4
  29. data/lib/cybersource_rest_client/models/ptsv2payments_order_information_line_items.rb +26 -4
  30. data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_payment_type.rb +11 -1
  31. data/lib/cybersource_rest_client/models/ptsv2payments_payment_information_tokenized_card.rb +21 -5
  32. data/lib/cybersource_rest_client/models/ptsv2payments_point_of_sale_information.rb +1 -1
  33. data/lib/cybersource_rest_client/models/ptsv2payments_processing_information.rb +12 -2
  34. data/lib/cybersource_rest_client/models/ptsv2payments_processing_information_authorization_options.rb +14 -4
  35. data/lib/cybersource_rest_client/models/ptsv2payments_watchlist_screening_information.rb +215 -0
  36. data/lib/cybersource_rest_client/models/{riskv1exportcomplianceinquiries_export_compliance_information_weights.rb → ptsv2payments_watchlist_screening_information_weights.rb} +1 -1
  37. data/lib/cybersource_rest_client/models/ptsv2paymentsidcaptures_order_information_amount_details.rb +1 -1
  38. data/lib/cybersource_rest_client/models/ptsv2payouts_processing_information_payouts_options.rb +20 -4
  39. data/lib/cybersource_rest_client/models/risk_v1_decisions_post201_response.rb +10 -1
  40. data/lib/cybersource_rest_client/models/risk_v1_decisions_post201_response_error_information.rb +1 -1
  41. data/lib/cybersource_rest_client/models/risk_v1_export_compliance_inquiries_post201_response.rb +1 -1
  42. data/lib/cybersource_rest_client/models/riskv1decisions_order_information_line_items.rb +26 -4
  43. data/lib/cybersource_rest_client/models/riskv1decisions_processing_information.rb +2 -2
  44. data/lib/cybersource_rest_client/models/riskv1exportcomplianceinquiries_export_compliance_information.rb +1 -1
  45. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response.rb +10 -1
  46. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information.rb +40 -1
  47. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_brands.rb +194 -0
  48. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_card.rb +27 -1
  49. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_features.rb +286 -0
  50. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_issuer_information.rb +238 -0
  51. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payment_information_network.rb +190 -0
  52. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_payout_options.rb +190 -0
  53. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_processing_information.rb +11 -1
  54. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_processor_information_electronic_verification_results.rb +2 -2
  55. data/lib/cybersource_rest_client/models/tss_v2_transactions_get200_response_token_information.rb +24 -4
  56. data/lib/cybersource_rest_client.rb +13 -4
  57. metadata +31 -8
@@ -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 TssV2TransactionsGet200ResponsePaymentInformationIssuerInformation
17
+ # This field contains the issuer name.
18
+ attr_accessor :name
19
+
20
+ # This field contains [2-character ISO Country Codes](http://apps.cybersource.com/library/documentation/sbc/quickref/countries_alpha_list.pdf) for the issuer.
21
+ attr_accessor :country
22
+
23
+ # This field contains the length of the BIN.
24
+ attr_accessor :bin_length
25
+
26
+ # This field contains the customer service phone number for the issuer.
27
+ attr_accessor :phone_number
28
+
29
+ # Attribute mapping from ruby-style variable name to JSON key.
30
+ def self.attribute_map
31
+ {
32
+ :'name' => :'name',
33
+ :'country' => :'country',
34
+ :'bin_length' => :'binLength',
35
+ :'phone_number' => :'phoneNumber'
36
+ }
37
+ end
38
+
39
+ # Attribute type mapping.
40
+ def self.swagger_types
41
+ {
42
+ :'name' => :'String',
43
+ :'country' => :'String',
44
+ :'bin_length' => :'String',
45
+ :'phone_number' => :'String'
46
+ }
47
+ end
48
+
49
+ # Initializes the object
50
+ # @param [Hash] attributes Model attributes in the form of hash
51
+ def initialize(attributes = {})
52
+ return unless attributes.is_a?(Hash)
53
+
54
+ # convert string to symbol for hash key
55
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
56
+
57
+ if attributes.has_key?(:'name')
58
+ self.name = attributes[:'name']
59
+ end
60
+
61
+ if attributes.has_key?(:'country')
62
+ self.country = attributes[:'country']
63
+ end
64
+
65
+ if attributes.has_key?(:'binLength')
66
+ self.bin_length = attributes[:'binLength']
67
+ end
68
+
69
+ if attributes.has_key?(:'phoneNumber')
70
+ self.phone_number = attributes[:'phoneNumber']
71
+ end
72
+ end
73
+
74
+ # Show invalid properties with the reasons. Usually used together with valid?
75
+ # @return Array for valid properties with the reasons
76
+ def list_invalid_properties
77
+ invalid_properties = Array.new
78
+ invalid_properties
79
+ end
80
+
81
+ # Check to see if the all the properties in the model are valid
82
+ # @return true if the model is valid
83
+ def valid?
84
+ true
85
+ end
86
+
87
+ # Custom attribute writer method with validation
88
+ # @param [Object] name Value to be assigned
89
+ def name=(name)
90
+ @name = name
91
+ end
92
+
93
+ # Custom attribute writer method with validation
94
+ # @param [Object] country Value to be assigned
95
+ def country=(country)
96
+ @country = country
97
+ end
98
+
99
+ # Custom attribute writer method with validation
100
+ # @param [Object] bin_length Value to be assigned
101
+ def bin_length=(bin_length)
102
+ @bin_length = bin_length
103
+ end
104
+
105
+ # Custom attribute writer method with validation
106
+ # @param [Object] phone_number Value to be assigned
107
+ def phone_number=(phone_number)
108
+ @phone_number = phone_number
109
+ end
110
+
111
+ # Checks equality by comparing each attribute.
112
+ # @param [Object] Object to be compared
113
+ def ==(o)
114
+ return true if self.equal?(o)
115
+ self.class == o.class &&
116
+ name == o.name &&
117
+ country == o.country &&
118
+ bin_length == o.bin_length &&
119
+ phone_number == o.phone_number
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
+ [name, country, bin_length, phone_number].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("#{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("#{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
@@ -0,0 +1,190 @@
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 TssV2TransactionsGet200ResponsePaymentInformationNetwork
17
+ # This field contains a code that identifies the network. Please refer [Network ID and Sharing Group Code](https://developer.visa.com/request_response_codes#network_id_and_sharing_group_code)
18
+ attr_accessor :id
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'id' => :'id'
24
+ }
25
+ end
26
+
27
+ # Attribute type mapping.
28
+ def self.swagger_types
29
+ {
30
+ :'id' => :'String'
31
+ }
32
+ end
33
+
34
+ # Initializes the object
35
+ # @param [Hash] attributes Model attributes in the form of hash
36
+ def initialize(attributes = {})
37
+ return unless attributes.is_a?(Hash)
38
+
39
+ # convert string to symbol for hash key
40
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
41
+
42
+ if attributes.has_key?(:'id')
43
+ self.id = attributes[:'id']
44
+ end
45
+ end
46
+
47
+ # Show invalid properties with the reasons. Usually used together with valid?
48
+ # @return Array for valid properties with the reasons
49
+ def list_invalid_properties
50
+ invalid_properties = Array.new
51
+ invalid_properties
52
+ end
53
+
54
+ # Check to see if the all the properties in the model are valid
55
+ # @return true if the model is valid
56
+ def valid?
57
+ true
58
+ end
59
+
60
+ # Custom attribute writer method with validation
61
+ # @param [Object] id Value to be assigned
62
+ def id=(id)
63
+ @id = id
64
+ end
65
+
66
+ # Checks equality by comparing each attribute.
67
+ # @param [Object] Object to be compared
68
+ def ==(o)
69
+ return true if self.equal?(o)
70
+ self.class == o.class &&
71
+ id == o.id
72
+ end
73
+
74
+ # @see the `==` method
75
+ # @param [Object] Object to be compared
76
+ def eql?(o)
77
+ self == o
78
+ end
79
+
80
+ # Calculates hash code according to all attributes.
81
+ # @return [Fixnum] Hash code
82
+ def hash
83
+ [id].hash
84
+ end
85
+
86
+ # Builds the object from hash
87
+ # @param [Hash] attributes Model attributes in the form of hash
88
+ # @return [Object] Returns the model itself
89
+ def build_from_hash(attributes)
90
+ return nil unless attributes.is_a?(Hash)
91
+ self.class.swagger_types.each_pair do |key, type|
92
+ if type =~ /\AArray<(.*)>/i
93
+ # check to ensure the input is an array given that the the attribute
94
+ # is documented as an array but the input is not
95
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
96
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
97
+ end
98
+ elsif !attributes[self.class.attribute_map[key]].nil?
99
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
100
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
101
+ end
102
+
103
+ self
104
+ end
105
+
106
+ # Deserializes the data based on type
107
+ # @param string type Data type
108
+ # @param string value Value to be deserialized
109
+ # @return [Object] Deserialized data
110
+ def _deserialize(type, value)
111
+ case type.to_sym
112
+ when :DateTime
113
+ DateTime.parse(value)
114
+ when :Date
115
+ Date.parse(value)
116
+ when :String
117
+ value.to_s
118
+ when :Integer
119
+ value.to_i
120
+ when :Float
121
+ value.to_f
122
+ when :BOOLEAN
123
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
124
+ true
125
+ else
126
+ false
127
+ end
128
+ when :Object
129
+ # generic object (usually a Hash), return directly
130
+ value
131
+ when /\AArray<(?<inner_type>.+)>\z/
132
+ inner_type = Regexp.last_match[:inner_type]
133
+ value.map { |v| _deserialize(inner_type, v) }
134
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
135
+ k_type = Regexp.last_match[:k_type]
136
+ v_type = Regexp.last_match[:v_type]
137
+ {}.tap do |hash|
138
+ value.each do |k, v|
139
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
140
+ end
141
+ end
142
+ else # model
143
+ temp_model = CyberSource.const_get(type).new
144
+ temp_model.build_from_hash(value)
145
+ end
146
+ end
147
+
148
+ # Returns the string representation of the object
149
+ # @return [String] String presentation of the object
150
+ def to_s
151
+ to_hash.to_s
152
+ end
153
+
154
+ # to_body is an alias to to_hash (backward compatibility)
155
+ # @return [Hash] Returns the object in the form of hash
156
+ def to_body
157
+ to_hash
158
+ end
159
+
160
+ # Returns the object in the form of hash
161
+ # @return [Hash] Returns the object in the form of hash
162
+ def to_hash
163
+ hash = {}
164
+ self.class.attribute_map.each_pair do |attr, param|
165
+ value = self.send(attr)
166
+ next if value.nil?
167
+ hash[param] = _to_hash(value)
168
+ end
169
+ hash
170
+ end
171
+
172
+ # Outputs non-array value in the form of hash
173
+ # For object, use to_hash. Otherwise, just return the value
174
+ # @param [Object] value Any valid value
175
+ # @return [Hash] Returns the value in the form of hash
176
+ def _to_hash(value)
177
+ if value.is_a?(Array)
178
+ value.compact.map { |v| _to_hash(v) }
179
+ elsif value.is_a?(Hash)
180
+ {}.tap do |hash|
181
+ value.each { |k, v| hash[k] = _to_hash(v) }
182
+ end
183
+ elsif value.respond_to? :to_hash
184
+ value.to_hash
185
+ else
186
+ value
187
+ end
188
+ end
189
+ end
190
+ end
@@ -0,0 +1,190 @@
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 TssV2TransactionsGet200ResponsePayoutOptions
17
+ # If true then provide attributes related to fund transfer/payouts. If payout information not found then response will have standard account lookup. Possible values: - `true` - `false`
18
+ attr_accessor :payout_inquiry
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'payout_inquiry' => :'payoutInquiry'
24
+ }
25
+ end
26
+
27
+ # Attribute type mapping.
28
+ def self.swagger_types
29
+ {
30
+ :'payout_inquiry' => :'String'
31
+ }
32
+ end
33
+
34
+ # Initializes the object
35
+ # @param [Hash] attributes Model attributes in the form of hash
36
+ def initialize(attributes = {})
37
+ return unless attributes.is_a?(Hash)
38
+
39
+ # convert string to symbol for hash key
40
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
41
+
42
+ if attributes.has_key?(:'payoutInquiry')
43
+ self.payout_inquiry = attributes[:'payoutInquiry']
44
+ end
45
+ end
46
+
47
+ # Show invalid properties with the reasons. Usually used together with valid?
48
+ # @return Array for valid properties with the reasons
49
+ def list_invalid_properties
50
+ invalid_properties = Array.new
51
+ invalid_properties
52
+ end
53
+
54
+ # Check to see if the all the properties in the model are valid
55
+ # @return true if the model is valid
56
+ def valid?
57
+ true
58
+ end
59
+
60
+ # Custom attribute writer method with validation
61
+ # @param [Object] payout_inquiry Value to be assigned
62
+ def payout_inquiry=(payout_inquiry)
63
+ @payout_inquiry = payout_inquiry
64
+ end
65
+
66
+ # Checks equality by comparing each attribute.
67
+ # @param [Object] Object to be compared
68
+ def ==(o)
69
+ return true if self.equal?(o)
70
+ self.class == o.class &&
71
+ payout_inquiry == o.payout_inquiry
72
+ end
73
+
74
+ # @see the `==` method
75
+ # @param [Object] Object to be compared
76
+ def eql?(o)
77
+ self == o
78
+ end
79
+
80
+ # Calculates hash code according to all attributes.
81
+ # @return [Fixnum] Hash code
82
+ def hash
83
+ [payout_inquiry].hash
84
+ end
85
+
86
+ # Builds the object from hash
87
+ # @param [Hash] attributes Model attributes in the form of hash
88
+ # @return [Object] Returns the model itself
89
+ def build_from_hash(attributes)
90
+ return nil unless attributes.is_a?(Hash)
91
+ self.class.swagger_types.each_pair do |key, type|
92
+ if type =~ /\AArray<(.*)>/i
93
+ # check to ensure the input is an array given that the the attribute
94
+ # is documented as an array but the input is not
95
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
96
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
97
+ end
98
+ elsif !attributes[self.class.attribute_map[key]].nil?
99
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
100
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
101
+ end
102
+
103
+ self
104
+ end
105
+
106
+ # Deserializes the data based on type
107
+ # @param string type Data type
108
+ # @param string value Value to be deserialized
109
+ # @return [Object] Deserialized data
110
+ def _deserialize(type, value)
111
+ case type.to_sym
112
+ when :DateTime
113
+ DateTime.parse(value)
114
+ when :Date
115
+ Date.parse(value)
116
+ when :String
117
+ value.to_s
118
+ when :Integer
119
+ value.to_i
120
+ when :Float
121
+ value.to_f
122
+ when :BOOLEAN
123
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
124
+ true
125
+ else
126
+ false
127
+ end
128
+ when :Object
129
+ # generic object (usually a Hash), return directly
130
+ value
131
+ when /\AArray<(?<inner_type>.+)>\z/
132
+ inner_type = Regexp.last_match[:inner_type]
133
+ value.map { |v| _deserialize(inner_type, v) }
134
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
135
+ k_type = Regexp.last_match[:k_type]
136
+ v_type = Regexp.last_match[:v_type]
137
+ {}.tap do |hash|
138
+ value.each do |k, v|
139
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
140
+ end
141
+ end
142
+ else # model
143
+ temp_model = CyberSource.const_get(type).new
144
+ temp_model.build_from_hash(value)
145
+ end
146
+ end
147
+
148
+ # Returns the string representation of the object
149
+ # @return [String] String presentation of the object
150
+ def to_s
151
+ to_hash.to_s
152
+ end
153
+
154
+ # to_body is an alias to to_hash (backward compatibility)
155
+ # @return [Hash] Returns the object in the form of hash
156
+ def to_body
157
+ to_hash
158
+ end
159
+
160
+ # Returns the object in the form of hash
161
+ # @return [Hash] Returns the object in the form of hash
162
+ def to_hash
163
+ hash = {}
164
+ self.class.attribute_map.each_pair do |attr, param|
165
+ value = self.send(attr)
166
+ next if value.nil?
167
+ hash[param] = _to_hash(value)
168
+ end
169
+ hash
170
+ end
171
+
172
+ # Outputs non-array value in the form of hash
173
+ # For object, use to_hash. Otherwise, just return the value
174
+ # @param [Object] value Any valid value
175
+ # @return [Hash] Returns the value in the form of hash
176
+ def _to_hash(value)
177
+ if value.is_a?(Array)
178
+ value.compact.map { |v| _to_hash(v) }
179
+ elsif value.is_a?(Hash)
180
+ {}.tap do |hash|
181
+ value.each { |k, v| hash[k] = _to_hash(v) }
182
+ end
183
+ elsif value.respond_to? :to_hash
184
+ value.to_hash
185
+ else
186
+ value
187
+ end
188
+ end
189
+ end
190
+ end
@@ -14,6 +14,9 @@ require 'date'
14
14
 
15
15
  module CyberSource
16
16
  class TssV2TransactionsGet200ResponseProcessingInformation
17
+ # Bin Source File Identifier. Possible values: - itmx - rupay
18
+ attr_accessor :bin_source
19
+
17
20
  # Indicates that the transaction includes industry-specific data. Possible Values: - `airline` - `restaurant` - `lodging` - `auto_rental` - `transit` - `healthcare_medical` - `healthcare_transit` - `transit` #### Card Present, Airlines and Auto Rental You must set this field to `airline` in order for airline data to be sent to the processor. For example, if this field is not set to `airline` or is not included in the request, no airline data is sent to the processor. You must set this field to `restaurant` in order for restaurant data to be sent to the processor. When this field is not set to `restaurant` or is not included in the request, no restaurant data is sent to the processor. You must set this field to `auto_rental` in order for auto rental data to be sent to the processor. For example, if this field is not set to `auto_rental` or is not included in the request, no auto rental data is sent to the processor. Restaurant data is supported only on CyberSource through VisaNet.
18
21
  attr_accessor :industry_data_type
19
22
 
@@ -38,6 +41,7 @@ module CyberSource
38
41
  # Attribute mapping from ruby-style variable name to JSON key.
39
42
  def self.attribute_map
40
43
  {
44
+ :'bin_source' => :'binSource',
41
45
  :'industry_data_type' => :'industryDataType',
42
46
  :'payment_solution' => :'paymentSolution',
43
47
  :'commerce_indicator' => :'commerceIndicator',
@@ -52,6 +56,7 @@ module CyberSource
52
56
  # Attribute type mapping.
53
57
  def self.swagger_types
54
58
  {
59
+ :'bin_source' => :'String',
55
60
  :'industry_data_type' => :'String',
56
61
  :'payment_solution' => :'String',
57
62
  :'commerce_indicator' => :'String',
@@ -71,6 +76,10 @@ module CyberSource
71
76
  # convert string to symbol for hash key
72
77
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
73
78
 
79
+ if attributes.has_key?(:'binSource')
80
+ self.bin_source = attributes[:'binSource']
81
+ end
82
+
74
83
  if attributes.has_key?(:'industryDataType')
75
84
  self.industry_data_type = attributes[:'industryDataType']
76
85
  end
@@ -146,6 +155,7 @@ module CyberSource
146
155
  def ==(o)
147
156
  return true if self.equal?(o)
148
157
  self.class == o.class &&
158
+ bin_source == o.bin_source &&
149
159
  industry_data_type == o.industry_data_type &&
150
160
  payment_solution == o.payment_solution &&
151
161
  commerce_indicator == o.commerce_indicator &&
@@ -165,7 +175,7 @@ module CyberSource
165
175
  # Calculates hash code according to all attributes.
166
176
  # @return [Fixnum] Hash code
167
177
  def hash
168
- [industry_data_type, payment_solution, commerce_indicator, commerce_indicator_label, business_application_id, authorization_options, bank_transfer_options, japan_payment_options].hash
178
+ [bin_source, industry_data_type, payment_solution, commerce_indicator, commerce_indicator_label, business_application_id, authorization_options, bank_transfer_options, japan_payment_options].hash
169
179
  end
170
180
 
171
181
  # Builds the object from hash
@@ -20,10 +20,10 @@ module CyberSource
20
20
  # Raw Electronic Verification response code from the processor for the customer’s email address.
21
21
  attr_accessor :email_raw
22
22
 
23
- # Mapped Electronic Verification response code for the customer’s name.
23
+ # #### Visa Platform Connect Mapped Electronic Verification response code for the customer’s name. Valid values : 'Y' Yes, the data Matches 'N' No Match 'O' Partial Match
24
24
  attr_accessor :name
25
25
 
26
- # Raw Electronic Verification response code from the processor for the customer’s name.
26
+ # #### Visa Platform Connect Raw Electronic Verification response code from the processor for the customer’s name. Valid values : '01' Match '50' Partial Match '99' No Match
27
27
  attr_accessor :name_raw
28
28
 
29
29
  # Mapped Electronic Verification response code for the customer’s phone number. For details, see `auth_ev_phone_number` field description in the [Credit Card Services Using the SCMP API Guide.](https://apps.cybersource.com/library/documentation/dev_guides/CC_Svcs_SCMP_API/html/)