Class: ActiveMerchant::Billing::MaxipagoGateway
- Defined in:
- lib/active_merchant/billing/gateways/maxipago.rb
Constant Summary collapse
- API_VERSION =
'3.1.1.15'
Constants inherited from Gateway
Gateway::CREDIT_DEPRECATION_MESSAGE, Gateway::CURRENCIES_WITHOUT_FRACTIONS, Gateway::DEBIT_CARDS, Gateway::RECURRING_DEPRECATION_MESSAGE, Gateway::STANDARD_ERROR_CODE
Instance Attribute Summary
Attributes inherited from Gateway
Instance Method Summary collapse
- #authorize(money, creditcard, options = {}) ⇒ Object
- #capture(money, authorization, options = {}) ⇒ Object
-
#initialize(options = {}) ⇒ MaxipagoGateway
constructor
A new instance of MaxipagoGateway.
- #purchase(money, creditcard, options = {}) ⇒ Object
Methods inherited from Gateway
#card_brand, card_brand, #generate_unique_id, inherited, non_fractional_currency?, #scrub, supported_countries, #supported_countries, supported_countries=, supports?, #supports_network_tokenization?, #supports_scrubbing?, #test?
Methods included from CreditCardFormatting
Methods included from PostsData
included, #raw_ssl_request, #ssl_get, #ssl_post, #ssl_request
Constructor Details
#initialize(options = {}) ⇒ MaxipagoGateway
Returns a new instance of MaxipagoGateway.
18 19 20 21 |
# File 'lib/active_merchant/billing/gateways/maxipago.rb', line 18 def initialize( = {}) requires!(, :login, :password) super end |
Instance Method Details
#authorize(money, creditcard, options = {}) ⇒ Object
34 35 36 37 38 39 40 41 42 43 |
# File 'lib/active_merchant/billing/gateways/maxipago.rb', line 34 def (money, creditcard, = {}) post = {} add_aux_data(post, ) add_amount(post, money) add_creditcard(post, creditcard) add_name(post, creditcard) add_address(post, ) commit(build_sale_request(post, "auth")) end |
#capture(money, authorization, options = {}) ⇒ Object
45 46 47 48 49 50 |
# File 'lib/active_merchant/billing/gateways/maxipago.rb', line 45 def capture(money, , = {}) post = {} add_amount(post, money) add_aux_data(post, ) commit(build_capture_request(, post)) end |
#purchase(money, creditcard, options = {}) ⇒ Object
23 24 25 26 27 28 29 30 31 32 |
# File 'lib/active_merchant/billing/gateways/maxipago.rb', line 23 def purchase(money, creditcard, = {}) post = {} add_aux_data(post, ) add_amount(post, money) add_creditcard(post, creditcard) add_name(post, creditcard) add_address(post, ) commit(build_sale_request(post)) end |