Module: ActiveMerchant::Billing::Integrations::Allpay

Defined in:
lib/active_merchant/billing/integrations/allpay.rb,
lib/active_merchant/billing/integrations/allpay/helper.rb,
lib/active_merchant/billing/integrations/allpay/notification.rb

Defined Under Namespace

Classes: Helper, Notification

Constant Summary collapse

PAYMENT_CREDIT_CARD =
'Credit'
PAYMENT_ATM =
'ATM'
PAYMENT_CVS =
'CVS'
PAYMENT_ALIPAY =
'Alipay'
PAYMENT_BARCODE =
'BARCODE'
SUBPAYMENT_ATM_TAISHIN =
'TAISHIN'
SUBPAYMENT_ATM_ESUN =
'ESUN'
SUBPAYMENT_ATM_HUANAN =
'HUANAN'
SUBPAYMENT_ATM_BOT =
'BOT'
SUBPAYMENT_ATM_FUBON =
'FUBON'
SUBPAYMENT_ATM_CHINATRUST =
'CHINATRUST'
SUBPAYMENT_ATM_FIRST =
'FIRST'
SUBPAYMENT_CVS_CVS =
'CVS'
SUBPAYMENT_CVS_OK =
'OK'
SUBPAYMENT_CVS_FAMILY =
'FAMILY'
SUBPAYMENT_CVS_HILIFE =
'HILIFE'
SUBPAYMENT_CVS_IBON =
'IBON'
PAYMENT_TYPE =
'aio'

Class Method Summary collapse

Class Method Details

.notification(post) ⇒ Object



53
54
55
# File 'lib/active_merchant/billing/integrations/allpay.rb', line 53

def self.notification(post)
  Notification.new(post)
end

.service_urlObject



39
40
41
42
43
44
45
46
47
48
49
50
51
# File 'lib/active_merchant/billing/integrations/allpay.rb', line 39

def self.service_url
  mode = ActiveMerchant::Billing::Base.integration_mode
  case mode
    when :production
      'https://payment.allpay.com.tw/Cashier/AioCheckOut'
    when :development
      'http://payment-stage.allpay.com.tw/Cashier/AioCheckOut'
    when :test
      'http://payment-stage.allpay.com.tw/Cashier/AioCheckOut'
    else
      raise StandardError, "Integration mode set to an invalid value: #{mode}"
  end
end

.setup {|_self| ... } ⇒ Object

Yields:

  • (_self)

Yield Parameters:



57
58
59
# File 'lib/active_merchant/billing/integrations/allpay.rb', line 57

def self.setup
  yield(self)
end