Class: CyberSource::UnifiedriskAuthentication
- Inherits:
-
Object
- Object
- CyberSource::UnifiedriskAuthentication
- Defined in:
- lib/cybersource_rest_client/models/unifiedrisk_authentication.rb
Instance Attribute Summary collapse
-
#authentication_date ⇒ Object
The date and time when the cardholder completed authentication, used for tracking authentication timing and fraud analysis.
-
#authentication_id ⇒ Object
Unique identifier assigned to an authentication attempt.
-
#authentication_indicator ⇒ Object
Indicates the type of authentication request being made, such as payment authentication, non-payment authentication, or recurring/installment transactions.
-
#challenge ⇒ Object
Returns the value of attribute challenge.
-
#decoupled_indicator ⇒ Object
Indicates whether decoupled authentication is requested or supported, allowing the cardholder to authenticate outside the main transaction flow.
-
#decoupled_max_time ⇒ Object
Maximum time in minutes allowed for the cardholder to complete a decoupled authentication, after which the session expires.
-
#email ⇒ Object
Email address used for authentication (e.g., verification code delivery).
-
#language_preference ⇒ Object
The cardholder's preferred language for the authentication challenge interface, expressed as an IETF BCP 47 language tag (e.g., en-US, fr-FR).
-
#method ⇒ Object
Authentication method used during the authentication/MFA process.
-
#mfa_successful ⇒ Object
Whether multi-factor authentication was completed successfully.
-
#other ⇒ Object
Additional authentication-related information not captured by other fields.
-
#phone_number ⇒ Object
Phone number used for authentication (e.g., SMS/voice MFA).
-
#spc_incomplete_indicator ⇒ Object
Indicates the reason why an SPC (Secure Payment Confirmation) transaction was not completed, helping distinguish cardholder-initiated abandonment from technical failures.
-
#spc_support ⇒ Object
Indicates whether the merchant's environment supports the Secure Payment Confirmation (SPC) protocol for frictionless authentication using FIDO2/WebAuthn credentials.
-
#three_ds_requestor_id ⇒ Object
Unique identifier assigned to the 3D Secure requestor (typically the merchant or payment service provider) by the directory server for authentication routing.
-
#three_ds_requestor_name ⇒ Object
The business or brand name of the 3D Secure requestor as registered with the card network directory server.
-
#three_ri_indicator ⇒ Object
Indicates the reason for the 3DS Requestor Initiated (3RI) transaction - a merchant-initiated authentication without active cardholder participation.
-
#version ⇒ Object
The 3D Secure protocol version used for this authentication attempt (e.g., "2.1.0", "2.2.0"), which determines which fields and features are supported.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.json_map ⇒ Object
Attribute mapping from JSON key to ruby-style variable name.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
-
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type.
-
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ UnifiedriskAuthentication
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility).
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Constructor Details
#initialize(attributes = {}) ⇒ UnifiedriskAuthentication
Initializes the object
143 144 145 146 147 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 173 174 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 220 221 222 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 143 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } if attributes.has_key?(:'authenticationId') self.authentication_id = attributes[:'authenticationId'] end if attributes.has_key?(:'method') self.method = attributes[:'method'] end if attributes.has_key?(:'mfaSuccessful') self.mfa_successful = attributes[:'mfaSuccessful'] end if attributes.has_key?(:'phoneNumber') self.phone_number = attributes[:'phoneNumber'] end if attributes.has_key?(:'email') self.email = attributes[:'email'] end if attributes.has_key?(:'other') self.other = attributes[:'other'] end if attributes.has_key?(:'threeDSRequestorId') self.three_ds_requestor_id = attributes[:'threeDSRequestorId'] end if attributes.has_key?(:'threeDSRequestorName') self.three_ds_requestor_name = attributes[:'threeDSRequestorName'] end if attributes.has_key?(:'challenge') self.challenge = attributes[:'challenge'] end if attributes.has_key?(:'decoupledIndicator') self.decoupled_indicator = attributes[:'decoupledIndicator'] end if attributes.has_key?(:'decoupledMaxTime') self.decoupled_max_time = attributes[:'decoupledMaxTime'] end if attributes.has_key?(:'threeRIIndicator') self.three_ri_indicator = attributes[:'threeRIIndicator'] end if attributes.has_key?(:'authenticationIndicator') self.authentication_indicator = attributes[:'authenticationIndicator'] end if attributes.has_key?(:'authenticationDate') self.authentication_date = attributes[:'authenticationDate'] end if attributes.has_key?(:'languagePreference') if (value = attributes[:'languagePreference']).is_a?(Array) self.language_preference = value end end if attributes.has_key?(:'spcSupport') self.spc_support = attributes[:'spcSupport'] end if attributes.has_key?(:'spcIncompleteIndicator') self.spc_incomplete_indicator = attributes[:'spcIncompleteIndicator'] end if attributes.has_key?(:'version') self.version = attributes[:'version'] end end |
Instance Attribute Details
#authentication_date ⇒ Object
The date and time when the cardholder completed authentication, used for tracking authentication timing and fraud analysis
55 56 57 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 55 def authentication_date @authentication_date end |
#authentication_id ⇒ Object
Unique identifier assigned to an authentication attempt
17 18 19 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 17 def authentication_id @authentication_id end |
#authentication_indicator ⇒ Object
Indicates the type of authentication request being made, such as payment authentication, non-payment authentication, or recurring/installment transactions
52 53 54 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 52 def authentication_indicator @authentication_indicator end |
#challenge ⇒ Object
Returns the value of attribute challenge.
40 41 42 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 40 def challenge @challenge end |
#decoupled_indicator ⇒ Object
Indicates whether decoupled authentication is requested or supported, allowing the cardholder to authenticate outside the main transaction flow. Values - "Y" (supported and preferred), "N" (do not use)
43 44 45 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 43 def decoupled_indicator @decoupled_indicator end |
#decoupled_max_time ⇒ Object
Maximum time in minutes allowed for the cardholder to complete a decoupled authentication, after which the session expires
46 47 48 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 46 def decoupled_max_time @decoupled_max_time end |
#email ⇒ Object
Email address used for authentication (e.g., verification code delivery)
29 30 31 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 29 def email @email end |
#language_preference ⇒ Object
The cardholder's preferred language for the authentication challenge interface, expressed as an IETF BCP 47 language tag (e.g., en-US, fr-FR)
58 59 60 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 58 def language_preference @language_preference end |
#method ⇒ Object
Authentication method used during the authentication/MFA process
20 21 22 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 20 def method @method end |
#mfa_successful ⇒ Object
Whether multi-factor authentication was completed successfully
23 24 25 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 23 def mfa_successful @mfa_successful end |
#other ⇒ Object
Additional authentication-related information not captured by other fields
32 33 34 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 32 def other @other end |
#phone_number ⇒ Object
Phone number used for authentication (e.g., SMS/voice MFA)
26 27 28 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 26 def phone_number @phone_number end |
#spc_incomplete_indicator ⇒ Object
Indicates the reason why an SPC (Secure Payment Confirmation) transaction was not completed, helping distinguish cardholder-initiated abandonment from technical failures
64 65 66 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 64 def spc_incomplete_indicator @spc_incomplete_indicator end |
#spc_support ⇒ Object
Indicates whether the merchant's environment supports the Secure Payment Confirmation (SPC) protocol for frictionless authentication using FIDO2/WebAuthn credentials
61 62 63 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 61 def spc_support @spc_support end |
#three_ds_requestor_id ⇒ Object
Unique identifier assigned to the 3D Secure requestor (typically the merchant or payment service provider) by the directory server for authentication routing
35 36 37 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 35 def three_ds_requestor_id @three_ds_requestor_id end |
#three_ds_requestor_name ⇒ Object
The business or brand name of the 3D Secure requestor as registered with the card network directory server
38 39 40 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 38 def three_ds_requestor_name @three_ds_requestor_name end |
#three_ri_indicator ⇒ Object
Indicates the reason for the 3DS Requestor Initiated (3RI) transaction - a merchant-initiated authentication without active cardholder participation. Values defined by EMVCo 3DS specification
49 50 51 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 49 def three_ri_indicator @three_ri_indicator end |
#version ⇒ Object
The 3D Secure protocol version used for this authentication attempt (e.g., "2.1.0", "2.2.0"), which determines which fields and features are supported
67 68 69 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 67 def version @version end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 70 def self.attribute_map { :'authentication_id' => :'authenticationId', :'method' => :'method', :'mfa_successful' => :'mfaSuccessful', :'phone_number' => :'phoneNumber', :'email' => :'email', :'other' => :'other', :'three_ds_requestor_id' => :'threeDSRequestorId', :'three_ds_requestor_name' => :'threeDSRequestorName', :'challenge' => :'challenge', :'decoupled_indicator' => :'decoupledIndicator', :'decoupled_max_time' => :'decoupledMaxTime', :'three_ri_indicator' => :'threeRIIndicator', :'authentication_indicator' => :'authenticationIndicator', :'authentication_date' => :'authenticationDate', :'language_preference' => :'languagePreference', :'spc_support' => :'spcSupport', :'spc_incomplete_indicator' => :'spcIncompleteIndicator', :'version' => :'version' } end |
.json_map ⇒ Object
Attribute mapping from JSON key to ruby-style variable name.
94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 94 def self.json_map { :'authentication_id' => :'authentication_id', :'method' => :'method', :'mfa_successful' => :'mfa_successful', :'phone_number' => :'phone_number', :'email' => :'email', :'other' => :'other', :'three_ds_requestor_id' => :'three_ds_requestor_id', :'three_ds_requestor_name' => :'three_ds_requestor_name', :'challenge' => :'challenge', :'decoupled_indicator' => :'decoupled_indicator', :'decoupled_max_time' => :'decoupled_max_time', :'three_ri_indicator' => :'three_ri_indicator', :'authentication_indicator' => :'authentication_indicator', :'authentication_date' => :'authentication_date', :'language_preference' => :'language_preference', :'spc_support' => :'spc_support', :'spc_incomplete_indicator' => :'spc_incomplete_indicator', :'version' => :'version' } end |
.swagger_types ⇒ Object
Attribute type mapping.
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 118 def self.swagger_types { :'authentication_id' => :'String', :'method' => :'String', :'mfa_successful' => :'BOOLEAN', :'phone_number' => :'String', :'email' => :'String', :'other' => :'String', :'three_ds_requestor_id' => :'String', :'three_ds_requestor_name' => :'String', :'challenge' => :'UnifiedriskAuthenticationChallenge', :'decoupled_indicator' => :'String', :'decoupled_max_time' => :'String', :'three_ri_indicator' => :'String', :'authentication_indicator' => :'String', :'authentication_date' => :'String', :'language_preference' => :'Array<String>', :'spc_support' => :'String', :'spc_incomplete_indicator' => :'String', :'version' => :'String' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 263 def ==(o) return true if self.equal?(o) self.class == o.class && authentication_id == o.authentication_id && method == o.method && mfa_successful == o.mfa_successful && phone_number == o.phone_number && email == o.email && other == o.other && three_ds_requestor_id == o.three_ds_requestor_id && three_ds_requestor_name == o.three_ds_requestor_name && challenge == o.challenge && decoupled_indicator == o.decoupled_indicator && decoupled_max_time == o.decoupled_max_time && three_ri_indicator == o.three_ri_indicator && authentication_indicator == o.authentication_indicator && authentication_date == o.authentication_date && language_preference == o.language_preference && spc_support == o.spc_support && spc_incomplete_indicator == o.spc_incomplete_indicator && version == o.version end |
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type
322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 322 def _deserialize(type, value) case type.to_sym when :DateTime DateTime.parse(value) when :Date Date.parse(value) when :String value.to_s when :Integer value.to_i when :Float value.to_f when :BOOLEAN if value.to_s =~ /\A(true|t|yes|y|1)\z/i true else false end when :Object # generic object (usually a Hash), return directly value when /\AArray<(?<inner_type>.+)>\z/ inner_type = Regexp.last_match[:inner_type] value.map { |v| _deserialize(inner_type, v) } when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/ k_type = Regexp.last_match[:k_type] v_type = Regexp.last_match[:v_type] {}.tap do |hash| value.each do |k, v| hash[_deserialize(k_type, k)] = _deserialize(v_type, v) end end else # model temp_model = CyberSource.const_get(type).new temp_model.build_from_hash(value) end end |
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value
388 389 390 391 392 393 394 395 396 397 398 399 400 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 388 def _to_hash(value) if value.is_a?(Array) value.compact.map { |v| _to_hash(v) } elsif value.is_a?(Hash) {}.tap do |hash| value.each { |k, v| hash[k] = _to_hash(v) } end elsif value.respond_to? :to_hash value.to_hash else value end end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 301 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) self.send("#{self.class.json_map[key]}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) end elsif !attributes[self.class.attribute_map[key]].nil? self.send("#{self.class.json_map[key]}=", _deserialize(type, attributes[self.class.attribute_map[key]])) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(o) ⇒ Boolean
288 289 290 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 288 def eql?(o) self == o end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
294 295 296 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 294 def hash [authentication_id, method, mfa_successful, phone_number, email, other, three_ds_requestor_id, three_ds_requestor_name, challenge, decoupled_indicator, decoupled_max_time, three_ri_indicator, authentication_indicator, authentication_date, language_preference, spc_support, spc_incomplete_indicator, version].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
226 227 228 229 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 226 def list_invalid_properties invalid_properties = Array.new invalid_properties end |
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility)
368 369 370 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 368 def to_body to_hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
374 375 376 377 378 379 380 381 382 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 374 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = self.send(attr) next if value.nil? hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
362 363 364 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 362 def to_s to_hash.to_s end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
233 234 235 |
# File 'lib/cybersource_rest_client/models/unifiedrisk_authentication.rb', line 233 def valid? true end |