Class: VisaAcceptanceMergedSpec::ConsumerAuthenticationInformation2
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- VisaAcceptanceMergedSpec::ConsumerAuthenticationInformation2
- Defined in:
- lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb
Overview
ConsumerAuthenticationInformation2 Model.
Instance Attribute Summary collapse
-
#authentication_transaction_context_id ⇒ String
Payer authentication transaction identifier passed to link the validation and authorization calls.
-
#cavv ⇒ String
Unique identifier generated by the card-issuing bank for Visa, American Express, JCB, Diners Club, and Discover transactions after the customer is authenticated.
-
#transaction_token ⇒ String
Web based token used to authenticate consumer with Rupay authentication provider.
-
#xid ⇒ String
Transaction identifier generated by Visa Acceptance for successful enrollment or validation checks.
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(authentication_transaction_context_id: SKIP, cavv: SKIP, transaction_token: SKIP, xid: SKIP, additional_properties: nil) ⇒ ConsumerAuthenticationInformation2
constructor
A new instance of ConsumerAuthenticationInformation2.
-
#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(authentication_transaction_context_id: SKIP, cavv: SKIP, transaction_token: SKIP, xid: SKIP, additional_properties: nil) ⇒ ConsumerAuthenticationInformation2
Returns a new instance of ConsumerAuthenticationInformation2.
69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 69 def initialize(authentication_transaction_context_id: SKIP, cavv: SKIP, transaction_token: SKIP, xid: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? unless authentication_transaction_context_id == SKIP @authentication_transaction_context_id = authentication_transaction_context_id end @cavv = cavv unless cavv == SKIP @transaction_token = transaction_token unless transaction_token == SKIP @xid = xid unless xid == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#authentication_transaction_context_id ⇒ String
Payer authentication transaction identifier passed to link the validation and authorization calls.
15 16 17 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 15 def authentication_transaction_context_id @authentication_transaction_context_id end |
#cavv ⇒ String
Unique identifier generated by the card-issuing bank for Visa, American Express, JCB, Diners Club, and Discover transactions after the customer is authenticated. The value is in base64. When you request the card authorization service, Visa Acceptance automatically converts the value, not the field name, to the format required by your payment processor.
25 26 27 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 25 def cavv @cavv end |
#transaction_token ⇒ String
Web based token used to authenticate consumer with Rupay authentication provider.
30 31 32 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 30 def transaction_token @transaction_token end |
#xid ⇒ String
Transaction identifier generated by Visa Acceptance for successful enrollment or validation checks. Use this value, which is in base64, to match an outgoing PAReq with an incoming PARes. Visa Acceptance forwards the XID with the card authorization service to these payment processors in these cases:
- Barclays
- Streamline (when the ecommerceIndicator
=spa)
41 42 43 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 41 def xid @xid end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 86 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. authentication_transaction_context_id = hash.key?('authenticationTransactionContextId') ? hash['authenticationTransactionContextId'] : SKIP cavv = hash.key?('cavv') ? hash['cavv'] : SKIP transaction_token = hash.key?('transactionToken') ? hash['transactionToken'] : SKIP xid = hash.key?('xid') ? hash['xid'] : 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. ConsumerAuthenticationInformation2.new(authentication_transaction_context_id: authentication_transaction_context_id, cavv: cavv, transaction_token: transaction_token, xid: xid, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
44 45 46 47 48 49 50 51 52 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 44 def self.names @_hash = {} if @_hash.nil? @_hash['authentication_transaction_context_id'] = 'authenticationTransactionContextId' @_hash['cavv'] = 'cavv' @_hash['transaction_token'] = 'transactionToken' @_hash['xid'] = 'xid' @_hash end |
.nullables ⇒ Object
An array for nullable fields
65 66 67 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 65 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
55 56 57 58 59 60 61 62 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 55 def self.optionals %w[ authentication_transaction_context_id cavv transaction_token xid ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
121 122 123 124 125 126 127 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 121 def inspect class_name = self.class.name.split('::').last "<#{class_name} authentication_transaction_context_id:"\ " #{@authentication_transaction_context_id.inspect}, cavv: #{@cavv.inspect},"\ " transaction_token: #{@transaction_token.inspect}, xid: #{@xid.inspect},"\ " additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
113 114 115 116 117 118 |
# File 'lib/visa_acceptance_merged_spec/models/consumer_authentication_information2.rb', line 113 def to_s class_name = self.class.name.split('::').last "<#{class_name} authentication_transaction_context_id:"\ " #{@authentication_transaction_context_id}, cavv: #{@cavv}, transaction_token:"\ " #{@transaction_token}, xid: #{@xid}, additional_properties: #{@additional_properties}>" end |