File: psigate.rb [activemerchant-1.20.0 Documentation]

Last Modified
  2015-05-25 14:11:42 +0000
Requires
  - rexml/document

## Description

This class implements the Psigate gateway for the ActiveMerchant module. Psigate = www.psigate.com/ The class is currently set up to use the psigate test server while rails is in testing or developement mode. The real server will be used while in production mode.

Modifications by Sean O'Hara ( sohara at sohara dot com )

Usage for a PreAuth (authorize) is as follows:

twenty = 2000 gateway = PsigateGateway.new(

    :login => 'teststore',
    :password => 'psigate1234'

)

creditcard = CreditCard.new(

    :number => '4242424242424242',
    :month => 8,
    :year => 2006,
    :first_name => 'Longbob',
    :last_name => 'Longsen'

) response = @gateway.authorize(twenty, creditcard,

     :order_id =>  1234,
     :billing_address => {
           :address1 => '123 fairweather Lane',
           :address2 => 'Apt B',
           :city => 'New York',
           :state => 'NY',
           :country => 'U.S.A.',
           :zip => '10010'
    },
    :email => 'jack@yahoo.com'

)