← Reference · Home · Print this page

Finance · Payments

ActiveMerchant (Ruby Payments Library)

Reference entry · last updated 20260910

ActiveMerchant is an open-source Ruby payment library extracted from Shopify. It provides a common interface to supported payment gateways and can be used in Rails or standalone Ruby applications.[1]

1. First principles: a gateway adapter

The library translates application calls into gateway-specific requests. A shared method name does not make all gateways support the same capabilities. The project maintains gateway-specific implementations and a supported-features table.[1]

2. Payment operations

The base gateway documents operations including authorize, capture, purchase, void, and refund. Their arguments include amounts, payment credentials or authorization identifiers, and gateway options.[2]

A gateway’s support for partial or multiple captures must be checked separately.

3. Amounts and responses

The README’s dollar example passes integer cents: 1000 represents USD 10.00. Its purchase example checks response.success? and reads response.message.[1]

4. Scope

ActiveMerchant is an integration library. Merchant acquiring arrangements, card-data security responsibilities, and dispute processes remain part of the payment system.

5. See also

6. References

  1. ActiveMerchant. Project README and gateway feature links.
  2. ActiveMerchant. Billing gateway source and interface documentation.