Class: VisaAcceptanceMergedSpec::ClientReferenceInformation2
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- VisaAcceptanceMergedSpec::ClientReferenceInformation2
- Defined in:
- lib/visa_acceptance_merged_spec/models/client_reference_information2.rb
Overview
ClientReferenceInformation2 Model.
Instance Attribute Summary collapse
-
#application_name ⇒ String
The name of the Connection Method client (such as Virtual Terminal or SOAP Toolkit API) that the merchant uses to send a transaction request to Visa Acceptance.
-
#application_user ⇒ String
The entity that is responsible for running the transaction and submitting the processing request to Visa Acceptance.
-
#application_version ⇒ String
Version of the Visa Acceptance application or integration used for a transaction.
-
#code ⇒ String
Merchant-generated order reference or tracking number.
-
#partner ⇒ Partner1
Merchant-generated order reference or tracking number.
-
#transaction_id ⇒ String
Identifier that you assign to the transaction.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(code: SKIP, partner: SKIP, application_name: SKIP, application_version: SKIP, application_user: SKIP, transaction_id: SKIP, additional_properties: nil) ⇒ ClientReferenceInformation2
constructor
A new instance of ClientReferenceInformation2.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(code: SKIP, partner: SKIP, application_name: SKIP, application_version: SKIP, application_user: SKIP, transaction_id: SKIP, additional_properties: nil) ⇒ ClientReferenceInformation2
Returns a new instance of ClientReferenceInformation2.
114 115 116 117 118 119 120 121 122 123 124 125 126 127 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 114 def initialize(code: SKIP, partner: SKIP, application_name: SKIP, application_version: SKIP, application_user: SKIP, transaction_id: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @code = code unless code == SKIP @partner = partner unless partner == SKIP @application_name = application_name unless application_name == SKIP @application_version = application_version unless application_version == SKIP @application_user = application_user unless application_user == SKIP @transaction_id = transaction_id unless transaction_id == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#application_name ⇒ String
The name of the Connection Method client (such as Virtual Terminal or SOAP Toolkit API) that the merchant uses to send a transaction request to Visa Acceptance.
58 59 60 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 58 def application_name @application_name end |
#application_user ⇒ String
The entity that is responsible for running the transaction and submitting the processing request to Visa Acceptance. This could be a person, a system, or a connection method.
69 70 71 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 69 def application_user @application_user end |
#application_version ⇒ String
Version of the Visa Acceptance application or integration used for a transaction.
63 64 65 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 63 def application_version @application_version end |
#code ⇒ String
Merchant-generated order reference or tracking number. It is recommended that you send a unique value for each transaction so that you can perform meaningful searches for the transaction.
Used by
Authorization Required field.
PIN Debit
Requests for PIN debit reversals need to use the same merchant reference number that was used in the transaction that is being reversed. Required field for all PIN Debit requests (purchase, credit, and reversal).
FDC Nashville Global
Certain circumstances can cause the processor to truncate this value to 15 or 17 characters for Level II and Level III processing, which can cause a discrepancy between the value you submit and the value included in some processor reports.
31 32 33 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 31 def code @code end |
#partner ⇒ Partner1
Merchant-generated order reference or tracking number. It is recommended that you send a unique value for each transaction so that you can perform meaningful searches for the transaction.
Used by
Authorization Required field.
PIN Debit
Requests for PIN debit reversals need to use the same merchant reference number that was used in the transaction that is being reversed. Required field for all PIN Debit requests (purchase, credit, and reversal).
FDC Nashville Global
Certain circumstances can cause the processor to truncate this value to 15 or 17 characters for Level II and Level III processing, which can cause a discrepancy between the value you submit and the value included in some processor reports.
52 53 54 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 52 def partner @partner end |
#transaction_id ⇒ String
Identifier that you assign to the transaction. Normally generated by a client server to identify a unique API request. Note Use this field only if you want to support merchant-initiated reversal and void operations.
Used by
Authorization, Authorization Reversal, Capture, Credit, and Void Optional field.
PIN Debit
For a PIN debit reversal, your request must include a request ID or a merchant transaction identifier. Optional field for PIN debit purchase or credit requests.
83 84 85 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 83 def transaction_id @transaction_id end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 130 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. code = hash.key?('code') ? hash['code'] : SKIP partner = Partner1.from_hash(hash['partner']) if hash['partner'] application_name = hash.key?('applicationName') ? hash['applicationName'] : SKIP application_version = hash.key?('applicationVersion') ? hash['applicationVersion'] : SKIP application_user = hash.key?('applicationUser') ? hash['applicationUser'] : SKIP transaction_id = hash.key?('transactionId') ? hash['transactionId'] : 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. ClientReferenceInformation2.new(code: code, partner: partner, application_name: application_name, application_version: application_version, application_user: application_user, transaction_id: transaction_id, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
86 87 88 89 90 91 92 93 94 95 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 86 def self.names @_hash = {} if @_hash.nil? @_hash['code'] = 'code' @_hash['partner'] = 'partner' @_hash['application_name'] = 'applicationName' @_hash['application_version'] = 'applicationVersion' @_hash['application_user'] = 'applicationUser' @_hash['transaction_id'] = 'transactionId' @_hash end |
.nullables ⇒ Object
An array for nullable fields
110 111 112 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 110 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
98 99 100 101 102 103 104 105 106 107 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 98 def self.optionals %w[ code partner application_name application_version application_user transaction_id ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
171 172 173 174 175 176 177 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 171 def inspect class_name = self.class.name.split('::').last "<#{class_name} code: #{@code.inspect}, partner: #{@partner.inspect}, application_name:"\ " #{@application_name.inspect}, application_version: #{@application_version.inspect},"\ " application_user: #{@application_user.inspect}, transaction_id:"\ " #{@transaction_id.inspect}, additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
162 163 164 165 166 167 168 |
# File 'lib/visa_acceptance_merged_spec/models/client_reference_information2.rb', line 162 def to_s class_name = self.class.name.split('::').last "<#{class_name} code: #{@code}, partner: #{@partner}, application_name:"\ " #{@application_name}, application_version: #{@application_version}, application_user:"\ " #{@application_user}, transaction_id: #{@transaction_id}, additional_properties:"\ " #{@additional_properties}>" end |