Class: CyberSourceMergedSpec::ProcessingInformation61

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/cyber_source_merged_spec/models/processing_information61.rb

Overview

ProcessingInformation61 Model.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from BaseModel

#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json

Constructor Details

#initialize(business_application_id: SKIP, network_routing_order: SKIP, commerce_indicator: SKIP, reconciliation_id: SKIP, payouts_options: SKIP, transaction_reason: SKIP, purpose_of_payment: SKIP, funding_options: SKIP, language_code: SKIP, purchase_options: SKIP, account_verification_code: SKIP, additional_properties: nil) ⇒ ProcessingInformation61

Returns a new instance of ProcessingInformation61.



148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 148

def initialize(business_application_id: SKIP, network_routing_order: SKIP,
               commerce_indicator: SKIP, reconciliation_id: SKIP,
               payouts_options: SKIP, transaction_reason: SKIP,
               purpose_of_payment: SKIP, funding_options: SKIP,
               language_code: SKIP, purchase_options: SKIP,
               account_verification_code: SKIP, additional_properties: nil)
  # Add additional model properties to the instance
  additional_properties = {} if additional_properties.nil?

  @business_application_id = business_application_id unless business_application_id == SKIP
  @network_routing_order = network_routing_order unless network_routing_order == SKIP
  @commerce_indicator = commerce_indicator unless commerce_indicator == SKIP
  @reconciliation_id = reconciliation_id unless reconciliation_id == SKIP
  @payouts_options = payouts_options unless payouts_options == SKIP
  @transaction_reason = transaction_reason unless transaction_reason == SKIP
  @purpose_of_payment = purpose_of_payment unless purpose_of_payment == SKIP
  @funding_options = funding_options unless funding_options == SKIP
  @language_code = language_code unless language_code == SKIP
  @purchase_options = purchase_options unless purchase_options == SKIP
  unless  == SKIP
    @account_verification_code =
      
  end
  @additional_properties = additional_properties
end

Instance Attribute Details

#account_verification_codeArray[String]

Account verification code will inform what Payment Account Verification should be performed. With this array of codes, a merchant can choose à la carte what verifications to run. This field is optional, and the default is 1 if it is not passed in. This means that a full validation of the fields will be performed. Valid verification codes:

  • 1 = Full Account Verification (Card Account, CVN, CAVV, TAVV, Address, Name, eMail, Phone, Identity)
  • 2 = Card Account Verification
  • 3 = Address Verification
  • 4 = Card Authentication Method (CAM) (Cryptogram)
  • 5 = Cardholder Authentication Verification (CAVV)
  • 6 = Cardholder Identity Verification
  • 7 = CVV2 Verification
  • 8 = eMail Verification
  • 9 = Name Verification
  • 10 = Phone Verification

Returns:

  • (Array[String])


107
108
109
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 107

def 
  @account_verification_code
end

#business_application_idString

Payouts transaction type. Applicable Processors: FDC Compass, Paymentech, CtV Possible values: Credit Card Bill Payment

  • CP: credit card bill payment Funds Disbursement
  • FD: funds disbursement
  • GD: government disbursement
  • MD: merchant disbursement Money Transfer
  • AA: account to account. Sender and receiver are same person.
  • PP: person to person. Sender and receiver are different. Prepaid Load
  • TU: top up

Returns:

  • (String)


27
28
29
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 27

def business_application_id
  @business_application_id
end

#commerce_indicatorString

Type of transaction. Value for an OCT transaction:

  • internet

Returns:

  • (String)


51
52
53
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 51

def commerce_indicator
  @commerce_indicator
end

#funding_optionsFundingOptions

This field is applicable for AFT and OCT transactions. For list of supported values, please refer to Developer Guide.

Returns:



79
80
81
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 79

def funding_options
  @funding_options
end

#language_codeString

Contains the ISO 639-2 defined language Code

Returns:

  • (String)


83
84
85
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 83

def language_code
  @language_code
end

#network_routing_orderString

This field is optionally used by Push Payments Gateway participants (merchants and acquirers) to get the attributes for specified networks only. The networks specified in this field must be a subset of the information provided during program enrollment. Refer to Sharing Group Code/Network Routing Order. Note: Supported only in US for domestic transactions involving Push Payments Gateway Service. VisaNet checks to determine if there are issuer routing preferences for any of the networks specified by the network routing order. 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.

Returns:

  • (String)


45
46
47
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 45

def network_routing_order
  @network_routing_order
end

#payouts_optionsPayoutsOptions

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).

Returns:



65
66
67
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 65

def payouts_options
  @payouts_options
end

#purchase_optionsPurchaseOptions3

Contains the ISO 639-2 defined language Code

Returns:



87
88
89
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 87

def purchase_options
  @purchase_options
end

#purpose_of_paymentString

This field is applicable for AFT and OCT transactions. For list of supported values, please refer to Developer Guide.

Returns:

  • (String)


74
75
76
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 74

def purpose_of_payment
  @purpose_of_payment
end

#reconciliation_idString

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).

Returns:

  • (String)


58
59
60
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 58

def reconciliation_id
  @reconciliation_id
end

#transaction_reasonString

Transaction reason code.

Returns:

  • (String)


69
70
71
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 69

def transaction_reason
  @transaction_reason
end

Class Method Details

.from_element(root) ⇒ Object



221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 221

def self.from_element(root)
  business_application_id = XmlUtilities.from_element(
    root, 'businessApplicationId', String
  )
  network_routing_order = XmlUtilities.from_element(root,
                                                    'networkRoutingOrder',
                                                    String)
  commerce_indicator = XmlUtilities.from_element(root, 'commerceIndicator',
                                                 String)
  reconciliation_id = XmlUtilities.from_element(root, 'reconciliationId',
                                                String)
  payouts_options = XmlUtilities.from_element(root, 'PayoutsOptions',
                                              PayoutsOptions)
  transaction_reason = XmlUtilities.from_element(root, 'transactionReason',
                                                 String)
  purpose_of_payment = XmlUtilities.from_element(root, 'purposeOfPayment',
                                                 String)
  funding_options = XmlUtilities.from_element(root, 'FundingOptions',
                                              FundingOptions)
  language_code = XmlUtilities.from_element(root, 'languageCode', String)
  purchase_options = XmlUtilities.from_element(root, 'PurchaseOptions3',
                                               PurchaseOptions3)
   = XmlUtilities.from_element_to_array(
    root, 'accountVerificationCode', String
  )

  new(business_application_id: business_application_id,
      network_routing_order: network_routing_order,
      commerce_indicator: commerce_indicator,
      reconciliation_id: reconciliation_id,
      payouts_options: payouts_options,
      transaction_reason: transaction_reason,
      purpose_of_payment: purpose_of_payment,
      funding_options: funding_options,
      language_code: language_code,
      purchase_options: purchase_options,
      account_verification_code: ,
      additional_properties: additional_properties)
end

.from_hash(hash) ⇒ Object

Creates an instance of the object from a hash.



175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 175

def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  business_application_id =
    hash.key?('businessApplicationId') ? hash['businessApplicationId'] : SKIP
  network_routing_order =
    hash.key?('networkRoutingOrder') ? hash['networkRoutingOrder'] : SKIP
  commerce_indicator =
    hash.key?('commerceIndicator') ? hash['commerceIndicator'] : SKIP
  reconciliation_id =
    hash.key?('reconciliationId') ? hash['reconciliationId'] : SKIP
  payouts_options = PayoutsOptions.from_hash(hash['payoutsOptions']) if hash['payoutsOptions']
  transaction_reason =
    hash.key?('transactionReason') ? hash['transactionReason'] : SKIP
  purpose_of_payment =
    hash.key?('purposeOfPayment') ? hash['purposeOfPayment'] : SKIP
  funding_options = FundingOptions.from_hash(hash['fundingOptions']) if hash['fundingOptions']
  language_code = hash.key?('languageCode') ? hash['languageCode'] : SKIP
  purchase_options = PurchaseOptions3.from_hash(hash['purchaseOptions']) if
    hash['purchaseOptions']
   =
    hash.key?('accountVerificationCode') ? hash['accountVerificationCode'] : SKIP

  # Create a new hash for additional properties, removing known properties.
  new_hash = hash.reject { |k, _| names.value?(k) }

  additional_properties = APIHelper.get_additional_properties(
    new_hash, proc { |value| value }
  )

  # Create object from extracted values.
  ProcessingInformation61.new(business_application_id: business_application_id,
                              network_routing_order: network_routing_order,
                              commerce_indicator: commerce_indicator,
                              reconciliation_id: reconciliation_id,
                              payouts_options: payouts_options,
                              transaction_reason: transaction_reason,
                              purpose_of_payment: purpose_of_payment,
                              funding_options: funding_options,
                              language_code: language_code,
                              purchase_options: purchase_options,
                              account_verification_code: ,
                              additional_properties: additional_properties)
end

.namesObject

A mapping from model property names to API property names.



110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 110

def self.names
  @_hash = {} if @_hash.nil?
  @_hash['business_application_id'] = 'businessApplicationId'
  @_hash['network_routing_order'] = 'networkRoutingOrder'
  @_hash['commerce_indicator'] = 'commerceIndicator'
  @_hash['reconciliation_id'] = 'reconciliationId'
  @_hash['payouts_options'] = 'payoutsOptions'
  @_hash['transaction_reason'] = 'transactionReason'
  @_hash['purpose_of_payment'] = 'purposeOfPayment'
  @_hash['funding_options'] = 'fundingOptions'
  @_hash['language_code'] = 'languageCode'
  @_hash['purchase_options'] = 'purchaseOptions'
  @_hash['account_verification_code'] = 'accountVerificationCode'
  @_hash
end

.nullablesObject

An array for nullable fields



144
145
146
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 144

def self.nullables
  []
end

.optionalsObject

An array for optional fields



127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 127

def self.optionals
  %w[
    business_application_id
    network_routing_order
    commerce_indicator
    reconciliation_id
    payouts_options
    transaction_reason
    purpose_of_payment
    funding_options
    language_code
    purchase_options
    account_verification_code
  ]
end

Instance Method Details

#inspectObject

Provides a debugging-friendly string with detailed object information.



304
305
306
307
308
309
310
311
312
313
314
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 304

def inspect
  class_name = self.class.name.split('::').last
  "<#{class_name} business_application_id: #{@business_application_id.inspect},"\
  " network_routing_order: #{@network_routing_order.inspect}, commerce_indicator:"\
  " #{@commerce_indicator.inspect}, reconciliation_id: #{@reconciliation_id.inspect},"\
  " payouts_options: #{@payouts_options.inspect}, transaction_reason:"\
  " #{@transaction_reason.inspect}, purpose_of_payment: #{@purpose_of_payment.inspect},"\
  " funding_options: #{@funding_options.inspect}, language_code: #{@language_code.inspect},"\
  " purchase_options: #{@purchase_options.inspect}, account_verification_code:"\
  " #{@account_verification_code.inspect}, additional_properties: #{@additional_properties}>"
end

#to_sObject

Provides a human-readable string representation of the object.



292
293
294
295
296
297
298
299
300
301
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 292

def to_s
  class_name = self.class.name.split('::').last
  "<#{class_name} business_application_id: #{@business_application_id},"\
  " network_routing_order: #{@network_routing_order}, commerce_indicator:"\
  " #{@commerce_indicator}, reconciliation_id: #{@reconciliation_id}, payouts_options:"\
  " #{@payouts_options}, transaction_reason: #{@transaction_reason}, purpose_of_payment:"\
  " #{@purpose_of_payment}, funding_options: #{@funding_options}, language_code:"\
  " #{@language_code}, purchase_options: #{@purchase_options}, account_verification_code:"\
  " #{@account_verification_code}, additional_properties: #{@additional_properties}>"
end

#to_xml_element(doc, root_name) ⇒ Object



261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
# File 'lib/cyber_source_merged_spec/models/processing_information61.rb', line 261

def to_xml_element(doc, root_name)
  root = doc.create_element(root_name)

  XmlUtilities.add_as_subelement(doc, root, 'businessApplicationId',
                                 business_application_id)
  XmlUtilities.add_as_subelement(doc, root, 'networkRoutingOrder',
                                 network_routing_order)
  XmlUtilities.add_as_subelement(doc, root, 'commerceIndicator',
                                 commerce_indicator)
  XmlUtilities.add_as_subelement(doc, root, 'reconciliationId',
                                 reconciliation_id)
  XmlUtilities.add_as_subelement(doc, root, 'PayoutsOptions',
                                 payouts_options)
  XmlUtilities.add_as_subelement(doc, root, 'transactionReason',
                                 transaction_reason)
  XmlUtilities.add_as_subelement(doc, root, 'purposeOfPayment',
                                 purpose_of_payment)
  XmlUtilities.add_as_subelement(doc, root, 'FundingOptions',
                                 funding_options)
  XmlUtilities.add_as_subelement(doc, root, 'languageCode', language_code)
  XmlUtilities.add_as_subelement(doc, root, 'PurchaseOptions3',
                                 purchase_options)
  XmlUtilities.add_array_as_subelement(doc, root, 'accountVerificationCode',
                                       )
  XmlUtilities.add_as_subelement(doc, root, 'additional_properties',
                                 additional_properties)

  root
end