Class: ActiveMerchant::Billing::PsigateGateway
- Inherits:
-
Gateway
- Object
- Gateway
- ActiveMerchant::Billing::PsigateGateway
- Defined in:
- lib/active_merchant/billing/gateways/psigate.rb
Constant Summary
- TEST_URL =
'https://dev.psigate.com:7989/Messenger/XMLMessenger'- LIVE_URL =
'https://secure.psigate.com:7934/Messenger/XMLMessenger'- SUCCESS_MESSAGE =
'Success'- FAILURE_MESSAGE =
'The transaction was declined'
Constants inherited from Gateway
Gateway::CREDIT_DEPRECATION_MESSAGE, Gateway::CURRENCIES_WITHOUT_FRACTIONS, Gateway::DEBIT_CARDS
Instance Attribute Summary
Attributes inherited from Gateway
Instance Method Summary (collapse)
-
- (Object) authorize(money, creditcard, options = {})
Psigate PreAuth.
-
- (Object) capture(money, authorization, options = {})
Psigate PostAuth.
-
- (Object) credit(money, authorization, options = {})
Psigate Credit.
-
- (PsigateGateway) initialize(options = {})
constructor
A new instance of PsigateGateway.
-
- (Object) purchase(money, creditcard, options = {})
Psigate Sale.
- - (Object) refund(money, authorization, options = {})
Methods inherited from Gateway
card_brand, #card_brand, inherited, supports?, #test?
Methods included from CreditCardFormatting
Constructor Details
- (PsigateGateway) initialize(options = {})
A new instance of PsigateGateway
53 54 55 56 57 |
# File 'lib/active_merchant/billing/gateways/psigate.rb', line 53 def initialize( = {}) requires!(, :login, :password) @options = super end |
Instance Method Details
- (Object) authorize(money, creditcard, options = {})
Psigate PreAuth
60 61 62 63 64 |
# File 'lib/active_merchant/billing/gateways/psigate.rb', line 60 def (money, creditcard, = {}) requires!(, :order_id) .update({ :CardAction => "1" }) commit(money, creditcard, ) end |
- (Object) capture(money, authorization, options = {})
Psigate PostAuth
74 75 76 77 |
# File 'lib/active_merchant/billing/gateways/psigate.rb', line 74 def capture(money, , = {}) .update({ :CardAction => "2", :order_id => }) commit(money, nil, ) end |
- (Object) credit(money, authorization, options = {})
Psigate Credit
81 82 83 84 |
# File 'lib/active_merchant/billing/gateways/psigate.rb', line 81 def credit(money, , = {}) deprecated CREDIT_DEPRECATION_MESSAGE refund(money, , ) end |
- (Object) purchase(money, creditcard, options = {})
Psigate Sale
67 68 69 70 71 |
# File 'lib/active_merchant/billing/gateways/psigate.rb', line 67 def purchase(money, creditcard, = {}) requires!(, :order_id) .update({ :CardAction => "0" }) commit(money, creditcard, ) end |
- (Object) refund(money, authorization, options = {})
86 87 88 89 |
# File 'lib/active_merchant/billing/gateways/psigate.rb', line 86 def refund(money, , = {}) .update({ :CardAction => "3", :order_id => }) commit(money, nil, ) end |