Module: BreadMachine::SecureTrading::PaymentMethods

Included in:
BreadMachine
Defined in:
lib/breadmachine/secure_trading/payment_methods.rb

Instance Method Summary collapse

Instance Method Details

#auth(*args) ⇒ Object



6
7
8
9
# File 'lib/breadmachine/secure_trading/payment_methods.rb', line 6

def auth(*args)
  request = SecureTrading::AuthRequest.new(*args)
  return SecureTrading::XPay.exchange(request)
end

#moto_auth(*args) ⇒ Object



11
12
13
14
# File 'lib/breadmachine/secure_trading/payment_methods.rb', line 11

def moto_auth(*args)
  request = SecureTrading::MotoAuthRequest.new(*args)
  return SecureTrading::XPay.exchange(request)
end

#reverse(*args) ⇒ Object



32
33
34
35
# File 'lib/breadmachine/secure_trading/payment_methods.rb', line 32

def reverse(*args)
  request = SecureTrading::AuthReversalRequest.new(*args)
  return SecureTrading::XPay.exchange(request)
end

#three_d_auth(*args) ⇒ Object



27
28
29
30
# File 'lib/breadmachine/secure_trading/payment_methods.rb', line 27

def three_d_auth(*args)
  request = SecureTrading::St3dAuthRequest.new(*args)
  return SecureTrading::XPay.exchange(request)
end

#three_d_secure_enrolled?(*args) ⇒ Boolean

Checks to see whether a card is enrolled in 3-D Secure. Returns a ST3DCardQueryResponse which can tell us whether the card is enrolled and what kind of authorisation to perform.

Arguments are: amount, creditcard, customer_info, order_info

Returns:

  • (Boolean)


22
23
24
25
# File 'lib/breadmachine/secure_trading/payment_methods.rb', line 22

def three_d_secure_enrolled?(*args)
  request = SecureTrading::St3dCardQueryRequest.new(*args)
  return SecureTrading::XPay.exchange(request)
end