Class: ActiveMerchant::Billing::SecureNetGateway
- Defined in:
- lib/active_merchant/billing/gateways/secure_net.rb
Constant Summary collapse
- API_VERSION =
"4.0"
- TRANSACTIONS =
{ :auth_only => "0000", # :partial_auth_only => "0001", :auth_capture => "0100", # :partial_auth_capture => "0101", :prior_auth_capture => "0200", :capture_only => "0300", # :void => "0400", # :partial_void => "0401", :credit => "0500", # :credit_authonly => "0501", :credit_priorauthcapture => "0502", :force_credit => "0600", :force_credit_authonly => "0601", :force_credit_priorauthcapture => "0602", :verification => "0700", :auth_increment => "0800", :issue => "0900", :activate => "0901", :redeem => "0902", :redeem_partial => "0903", :deactivate => "0904", :reactivate => "0905", :inquiry_balance => "0906" }
- XML_ATTRIBUTES =
{ 'xmlns' => "http://gateway.securenet.com/API/Contracts", 'xmlns:i' => "http://www.w3.org/2001/XMLSchema-instance" }
- NIL_ATTRIBUTE =
{ 'i:nil' => "true" }
- TEST_URL =
TEST_URL = ‘certify.securenet.com/api/Gateway.svc’
'https://certify.securenet.com/API/gateway.svc/webHttp/ProcessTransaction'
- LIVE_URL =
'https://gateway.securenet.com/api/Gateway.svc'
- CARD_CODE_ERRORS =
%w( N S )
- AVS_ERRORS =
%w( A E N R W Z )
Constants inherited from Gateway
Gateway::CURRENCIES_WITHOUT_FRACTIONS, Gateway::DEBIT_CARDS
Instance Attribute Summary
Attributes inherited from Gateway
Instance Method Summary collapse
- #authorize(money, creditcard, options = {}) ⇒ Object
- #capture(money, creditcard, authorization, options = {}) ⇒ Object
- #credit(money, creditcard, authorization, options = {}) ⇒ Object
-
#initialize(options = {}) ⇒ SecureNetGateway
constructor
A new instance of SecureNetGateway.
- #purchase(money, creditcard, options = {}) ⇒ Object
- #void(money, creditcard, authorization, options = {}) ⇒ Object
Methods inherited from Gateway
#card_brand, card_brand, inherited, supports?, #test?
Methods included from Utils
Methods included from CreditCardFormatting
Methods included from RequiresParameters
Methods included from PostsData
included, #raw_ssl_request, #ssl_get, #ssl_post, #ssl_request
Constructor Details
#initialize(options = {}) ⇒ SecureNetGateway
Returns a new instance of SecureNetGateway.
59 60 61 62 63 |
# File 'lib/active_merchant/billing/gateways/secure_net.rb', line 59 def initialize( = {}) requires!(, :login, :password) @options = super end |
Instance Method Details
#authorize(money, creditcard, options = {}) ⇒ Object
65 66 67 |
# File 'lib/active_merchant/billing/gateways/secure_net.rb', line 65 def (money, creditcard, = {}) commit((creditcard, , :auth_only), money) end |
#capture(money, creditcard, authorization, options = {}) ⇒ Object
73 74 75 |
# File 'lib/active_merchant/billing/gateways/secure_net.rb', line 73 def capture(money, creditcard, , = {}) commit(build_capture_request(, creditcard, , :prior_auth_capture), money) end |
#credit(money, creditcard, authorization, options = {}) ⇒ Object
81 82 83 |
# File 'lib/active_merchant/billing/gateways/secure_net.rb', line 81 def credit(money, creditcard, , = {}) commit(build_credit_request(, creditcard, , :credit), money) end |
#purchase(money, creditcard, options = {}) ⇒ Object
69 70 71 |
# File 'lib/active_merchant/billing/gateways/secure_net.rb', line 69 def purchase(money, creditcard, = {}) commit((creditcard, , :auth_capture), money) end |
#void(money, creditcard, authorization, options = {}) ⇒ Object
77 78 79 |
# File 'lib/active_merchant/billing/gateways/secure_net.rb', line 77 def void(money, creditcard, , = {}) commit(build_void_request(, creditcard, , :void), money) end |