QuadPay Integration

Welcome! Integrating QuadPay into your online store is straightforward. Here you'll find comprehensive guides and documentation to support integrating QuadPay into your site as quickly as possible. Let's jump right in!


Integrate QuadPay

QuadPay provides Spree stores the spree_quad_pay gem for integrating QuadPay into your Spree store.


  1. Add this extension to your Gemfile with this line:
gem 'spree_quad_pay', github: 'quadpay/quadpay-spree', branch: '3-3-stable'
  1. Install the gem using Bundler:
bundle install
  1. Copy & run migrations
bundle exec rails g spree_quad_pay:install
  1. Setup a task scheduler to synchronize QuadPay order status

If your environment supports cronjobs, you can use whenever to schedule the recurring tasks to synchronize orders:

bundle exec whenever --update-crontab

If you are using Heroku or another environment that doesn't support cronjobs, use rake task combine with Heroku Scheduler or another background job processing framework:

rake quad_pay_tasks:sync_orders


  1. Create the QuadPay Payment Method.

    • Login into the Spree Admin Dashboard and go to Configurations > Payment Method, click the button New Payment Method.
    • On the new payment method page, set the PROVIDER field to Spree::BillingIntegration::QuadPayCheckout and enter a Name and Description.
    • Click Create.
  2. Setup the QuadPay API keys and Settings.

Go to Configurations > QuadPay Settings and enter the information below:


Data type


Site URL

String, eg. https://www.mycompany.shop

This URL is used for QuadPay callback calls

Merchant Name

String, eg. my-company

Merchant Name provided by QuadPay

Client ID


Client ID provided by QuadPay

Min Amount

Any positive integer

The Order minimum product/cart amount as agreed upon with QuadPay

Max Amount

Any positive integer

The Order maximum product/cart amount as agreed upon with QuadPay

Display Widget At Product Page


Display Widget At Cart Page


Test Mode


Toggle Test Mode or Live Mode

  1. Restart your server

Integration with Order Management Systems

By default, the gem hooks into the regular Spree workflows for Refunds and Order cancellation.

If you are using custom workflows for Shipping, Refunds or Cancellations, you may wish to explore the built in Spree::BillingIntegration::QuadPayCheckout object to trigger QuadPay commands. The following actions are supported:

* create_order: create QuadPay Order
* find_order: find QuadPay Order based on token provided
* refund: refund with QuadPay payment based on the Payment's response code
* credit: partial refund back to User
* cancel: full refund


For guidance on customizing the styling of the widget, visit the QuadPay Widget Integration Guide.


These instructions are for a Spree store using a lightly customized theme. If the store's theme is heavily customized, further customization may be necessary. If you would like support with the QuadPay integration please get in touch with us.

Updated 2 years ago

What's Next

Now that you've added the QuadPay gateway and integrated the QuadPay widget, be sure to follow these quality assurance steps:


Integrate QuadPay

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.