paya-logo

Integrating Paya and Salesforce using Chargent

Chargent Payment Processing for Salesforce is the leading payments application available on the Salesforce AppExchange. This guide shows you how you can easily connect the Paya Direct Payment Gateway (formerly known as Sage Exchange/Sage Payments) to Salesforce using Chargent. Chargent allows you to charge credit cards and ACH transactions directly from within Salesforce.

Not yet a Chargent customer? Get started today with a free 30-day trial!

Create a Paya Account

If you don’t already have a Paya Virtual Terminal Account, contact your Paya sales representative or submit a ticket with Paya to create one.

For more information, visit How to access a Virtual Terminal Account.

Once you’ve activated your Paya Virtual Terminal Account, you can login here.

Convert Your Paya Account for Testing

Before processing any live transactions, you should test your integration using test transactions. To test your transactions, you must convert your Virtual Terminal Account into a testing environment.

  • Log in to your Paya Virtual Terminal Account.
  • From the Home tab, scroll down to the Account Overview section and click Switch under Mode.
  • Click Confirm.

For more information, see How do I switch my Virtual Terminal Account into a Testing Environment?

Visit Paya’s Support Documentation to learn more about your Paya account.

Install and Configure Chargent

If you haven’t installed Chargent yet, follow the step-by-step Installation and Setup Guide.

Verify Your Gateway Credentials

During the setup process, you must create a Gateway record and verify your Paya credentials using the Gateway Setup Wizard.

Initially, we recommend creating a gateway specifically for testing. If you are in the testing phase, select the ‘Test Transactions’ tab when verifying your credentials.

  • Merchant ID (MID)
  • Merchant Key

For more information about the Gateway Setup Wizard, including troubleshooting tips, visit our Gateway Setup Wizard documentation.

Test Your Integration

After completing the Installation and Setup Guide, follow our Testing Chargent Guide. Use Paya’s test credit cards, test account numbers, and test response codes to ensure that your gateway is integrated correctly before going live.

Test Credit Card Numbers

The following credit card information can be used to test your credit card transactions:

Test Card Type Test Card Number
VISA 4111111111111111
Mastercard 5499740000000057
Discover 6011000993026909
American Express 37144963539237

For more information, see Paya’s complete List of Test Credit Card Numbers.

Test Account Numbers for ACH

The following account number can be used to test your ACH transactions:

Field Value
Routing Number 056008849
Account Number 12345678901234
Bank Account Type DDA

Testing Response Codes

It is important to test for various response codes to ensure that your transactions are processed as expected. To generate specific response codes, AVS responses, and CVV2 responses, the transaction amount can be used to generate a desired value.

For a list of transaction amounts used to generate specific response codes, see Paya’s Test Data documentation.

To learn more about Paya’s response codes, visit the Response Codes section of this guide.

Sending Live Transactions from a Sandbox

To avoid unintentionally processing live transactions in your sandbox, Chargent’s Paya integration does not allow you to test live transactions in a Salesforce sandbox. We recommend testing all live transactions in Production.

Production Endpoints

When testing your transactions in a sandbox, a value is not required in your Gateway record’s Endpoint Override field. However, the Endpoint Override field must be populated in a production environment.

  • Test Transactions in a Production Environment: https://api-cert.sagepayments.com
  • Live Transactions in a Production Environment: https://api.sagepayments.com

For more information about the Endpoint Override field, see Gateway Fields.

Features Supported via Paya Integration

Chargent’s Paya Gateway Integration supports many types of card network transactions, providing you with multiple options when it comes to taking payments in Salesforce.

Payment Methods

The following Payment Methods are supported in our Paya integration:

  • Credit Card
  • ACH (Automated Clearing House)

For more information about the difference between Credit Card and ACH payments, visit ACH Payments versus Credit Cards.

Transaction Types

Our Paya Gateway Integration supports the following transaction types:

Currencies

Our Paya integration currently supports the United States Dollar (USD) .

Tokenization

Tokenization is supported for both credit card and ACH transactions via our Paya integration. To learn more about why we recommend tokenization, visit Salesforce Tokenization.

Address Verification System (AVS)

Paya includes Address Verification System (AVS), a system used to prevent fraud and validate the ownership of a credit card by checking the billing address of a credit card with the data on file at the credit card issuing company.

You can change the AVS Settings for your Paya Account by visiting How to change the Address Verification (AVS) Settings in Paya Exchange.

Response Codes

Response codes are saved in the Reason Code field of Transaction records in Salesforce. A response code is specific to your gateway provider and explains why a transaction was successful, declined, or encountered an error. Use the Reason Code field, along with the Gateway Response field, to troubleshoot your transactions.

For a list of Paya’s response codes and their description, please see Paya’s Decline Codes.

Paya also provides codes related to Address Verification System (AVS). AVS codes are saved in the AVS Response Code field of transaction records in Salesforce. See Paya’s MasterCard and Discover AVS Codes for more information.

Field Mapping

These are a few of the most relevant field mappings between Chargent and Paya.

Salesforce Field Label Field Type Paya Field Label
Invoice Number String OrderNumber
Token String Authorization Token
Gateway ID String Transaction ID