Class: K2ConnectRuby::K2Services::Payloads::Webhooks::CardTransactionVoided

Inherits:
K2CommonEvents show all
Defined in:
lib/k2-connect-ruby/k2_services/payloads/webhooks/card_transaction_voided.rb

Constant Summary

Constants inherited from K2CommonEvents

K2CommonEvents::REFERENCE_EXCEPTIONS

Instance Attribute Summary collapse

Attributes inherited from K2CommonEvents

#amount, #currency, #origination_time, #reference, #status

Attributes inherited from K2Webhooks

#created_at, #event_resource, #event_type, #id, #links_resource, #links_self, #resource_id, #topic

Instance Method Summary collapse

Constructor Details

#initialize(payload) ⇒ CardTransactionVoided

Returns a new instance of CardTransactionVoided.



8
9
10
11
12
# File 'lib/k2-connect-ruby/k2_services/payloads/webhooks/card_transaction_voided.rb', line 8

def initialize(payload)
  super
  @customer_cc_number = payload.dig("event", "resource", "customer_cc_number")
  @till_number = payload.dig("event", "resource", "till_number")
end

Instance Attribute Details

#customer_cc_numberObject (readonly)

Returns the value of attribute customer_cc_number.



6
7
8
# File 'lib/k2-connect-ruby/k2_services/payloads/webhooks/card_transaction_voided.rb', line 6

def customer_cc_number
  @customer_cc_number
end

#till_numberObject (readonly)

Returns the value of attribute till_number.



6
7
8
# File 'lib/k2-connect-ruby/k2_services/payloads/webhooks/card_transaction_voided.rb', line 6

def till_number
  @till_number
end