Integrating this SagePay gem into a clean app before I try anything crazy with existing code [unmaintained]
Ruby HTML CSS JavaScript
Latest commit 8efefee May 17, 2016 @mathie Merge pull request #2 from kmclellan/master
Updated gem requirements, README and added a change log.


Sage Pay Rails Example

This is an example application to demonstrate the sage_pay gem for interfacing with Sage Pay's server interface.

The current version (0.2.12) works with the same version number of the gem.

To get it working you first need to grab it:

git clone git://

Then you need to:

  1. Create a database and update database.yml with your settings
  2. rake db:migrate
  3. rake db:seed
  4. edit config/initializers/sage_pay.rb - adding your vendor ID and update the notification_url
  5. Ensure the appropriate gems are installed.

That should be it!

If you are interested in using SagePay Direct then look at dooks' modifications here (version 0.2.12):


If you want to copy this example into your rails application then please note:

  1. Not everything works (e.g. Refunds);
  2. It relies heavily on gems - in particular:

Inherited Resources

Provides all standard rest actions in controlers by default. It also provides the following helpers in views:

resource #=> @project
collection #=> @projects
resource_class #=> Project

Please note inherited_resources has it's own dependancies.


Allows you to quickly show a model's information with I18n features

Validation Reflection

Adds reflective access to validations