Class | ActiveMerchant::Billing::AuthorizeNetCimGateway |
In: |
lib/active_merchant/billing/gateways/authorize_net_cim.rb
|
Parent: | Gateway |
The Authorize.Net Customer Information Manager (CIM) is an optional additional service that allows you to store sensitive payment information on Authorize.Net‘s servers, simplifying payments for returning customers and recurring transactions. It can also help with Payment Card Industry (PCI) Data Security Standard compliance, since customer data is no longer stored locally.
To use the AuthorizeNetCimGateway CIM must be enabled for your account.
Information about CIM is available on the Authorize.Net website. Information about the CIM API is available at the Authorize.Net Integration Center
The login and password are not the username and password you use to login to the Authorize.Net Merchant Interface. Instead, you will use the API Login ID as the login and Transaction Key as the password.
AUTHORIZE_NET_CIM_NAMESPACE | = | 'AnetApi/xml/v1/schema/AnetApiSchema.xsd' |
CIM_ACTIONS | = | { :create_customer_profile => 'createCustomerProfile', :create_customer_payment_profile => 'createCustomerPaymentProfile', :create_customer_shipping_address => 'createCustomerShippingAddress', :get_customer_profile => 'getCustomerProfile', :get_customer_payment_profile => 'getCustomerPaymentProfile', :get_customer_shipping_address => 'getCustomerShippingAddress', :delete_customer_profile => 'deleteCustomerProfile', :delete_customer_payment_profile => 'deleteCustomerPaymentProfile', :delete_customer_shipping_address => 'deleteCustomerShippingAddress', :update_customer_profile => 'updateCustomerProfile', :update_customer_payment_profile => 'updateCustomerPaymentProfile', :update_customer_shipping_address => 'updateCustomerShippingAddress', :create_customer_profile_transaction => 'createCustomerProfileTransaction', :validate_customer_payment_profile => 'validateCustomerPaymentProfile' |
CIM_TRANSACTION_TYPES | = | { :auth_capture => 'profileTransAuthCapture', :auth_only => 'profileTransAuthOnly', :capture_only => 'profileTransCaptureOnly' |
CIM_VALIDATION_MODES | = | { :none => 'none', :test => 'testMode', :live => 'liveMode' |
BANK_ACCOUNT_TYPES | = | { :checking => 'checking', :savings => 'savings', :business_checking => 'businessChecking' |
ECHECK_TYPES | = | { :ccd => 'CCD', :ppd => 'PPD' |
Creates a new AuthorizeNetCimGateway
The gateway requires that a valid API Login ID and Transaction Key be passed in the options hash.
Creates a new customer payment profile for an existing customer profile.
Creates a new customer profile along with any customer payment profiles and customer shipping addresses for the customer profile.
Returns a Response with the Customer Profile ID of the new customer profile in the authorization field. It is CRITICAL that you save this ID. There is no way to retrieve this through the API. You will not be able to create another Customer Profile with the same information.
TODO
Creates a new payment transaction from an existing customer profile
This is what is used to charge a customer whose information you have stored in a Customer Profile.
Returns a Response object that contains the result of the transaction in params[‘direct_response’]
Creates a new customer shipping address for an existing customer profile.
Deletes a customer payment profile from an existing customer profile.
Deletes an existing customer profile along with all associated customer payment profiles and customer shipping addresses.
Deletes a customer shipping address from an existing customer profile.
Retrieve a customer payment profile for an existing customer profile.
Returns a Response whose params hash contains all the payment profile information. Sensitive information such as credit card numbers will be masked.
Retrieves an existing customer profile along with all the associated customer payment profiles and customer shipping addresses.
Returns a Response whose params hash contains all the profile information.
Retrieve a customer shipping address for an existing customer profile.
Returns a Response whose params hash contains all the shipping address information.
Updates a customer payment profile for an existing customer profile.
Warning: if you do not provide a parameter in the :payment_profile hash, it is automatically set to nil at Authorize.Net. You will most likely want to first get the profile hash using get_customer_payment_profile and then only change the elements you wish to change.
Updates an existing customer profile.
Warning: if you do not provide a parameter in the :payment_profile hash, it is automatically set to nil at Authorize.Net. You will most likely want to first get the profile hash using get_customer_profile and then only change the elements you wish to change.
Updates a customer shipping address for an existing customer profile.
Warning: if you do not provide a parameter in the :address hash, it is automatically set to nil at Authorize.Net. You will most likely want to first get the profile hash using get_customer_shipping_address and then only change the elements you wish to change.
Verifies an existing customer payment profile by generating a test transaction
Returns a Response object that contains the result of the transaction in params[‘direct_response’]