Class: Io::Flow::V0::Models::AdyenIdentifyShopperData

Inherits:
AdyenNativeData show all
Defined in:
lib/flow_commerce/flow_api_v0_client.rb

Overview

Data required to assist in identifying a customer natively.

Instance Attribute Summary collapse

Attributes inherited from AdyenNativeData

#discriminator

Instance Method Summary collapse

Methods inherited from AdyenNativeData

from_json, #to_hash

Constructor Details

#initialize(incoming = {}) ⇒ AdyenIdentifyShopperData

Returns a new instance of AdyenIdentifyShopperData.



22536
22537
22538
22539
22540
22541
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 22536

def initialize(incoming={})
  super(:discriminator => AdyenNativeData::Types::ADYEN_IDENTIFY_SHOPPER_DATA)
  opts = HttpClient::Helper.symbolize_keys(incoming)
  HttpClient::Preconditions.require_keys(opts, [:fingerprint_token], 'AdyenIdentifyShopperData')
  @fingerprint_token = HttpClient::Preconditions.assert_class('fingerprint_token', opts.delete(:fingerprint_token), String)
end

Instance Attribute Details

#fingerprint_tokenObject (readonly)

Returns the value of attribute fingerprint_token.



22534
22535
22536
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 22534

def fingerprint_token
  @fingerprint_token
end

Instance Method Details

#copy(incoming = {}) ⇒ Object



22547
22548
22549
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 22547

def copy(incoming={})
  AdyenIdentifyShopperData.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
end

#subtype_to_hashObject



22551
22552
22553
22554
22555
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 22551

def subtype_to_hash
  {
    :fingerprint_token => fingerprint_token
  }
end

#to_jsonObject



22543
22544
22545
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 22543

def to_json
  JSON.dump(to_hash)
end