Class: ActiveMerchant::Billing::Integrations::Dwolla::Notification

Inherits:
Notification
  • Object
show all
Defined in:
lib/active_merchant/billing/integrations/dwolla/notification.rb

Instance Attribute Summary

Attributes inherited from Notification

#params, #raw

Instance Method Summary collapse

Methods inherited from Notification

#amount, #empty!, #gross_cents, #initialize, #valid_sender?

Constructor Details

This class inherits a constructor from ActiveMerchant::Billing::Integrations::Notification

Instance Method Details

#acknowledgeObject



37
38
39
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 37

def acknowledge      
  true
end

#complete?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 8

def complete?
  status == "Completed"
end

#currencyObject



20
21
22
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 20

def currency
  "USD"
end

#errorObject



28
29
30
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 28

def error
  params['Message']
end

#grossObject



24
25
26
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 24

def gross
  params['Amount']
end

#statusObject



12
13
14
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 12

def status
  params["Status"]
end

#test?Boolean

Was this a test transaction?

Returns:

  • (Boolean)


33
34
35
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 33

def test?
  params['TestMode']
end

#transaction_idObject



16
17
18
# File 'lib/active_merchant/billing/integrations/dwolla/notification.rb', line 16

def transaction_id
  params['OrderId']
end