AppFrontier

☰ Menu

Realex Payments Salesforce Integration Chargent


Integrating Realex with Salesforce using Chargent

This guide contains instructions for integrating your Salesforce.com environment with the Realex payment gateway—using the Chargent payment processing plug-in.

Click a link to go directly to one of these sections:


Overview

Realex Payments, a division of Global Payments Inc., is one of Europe’s leading providers of ecommerce payment solutions. Realex works with thousands of small to medium-sized businesses to enable them to scale their online business and expand their international reach. Over the past 16 years, Realex has established a strong reputation in the industry and amongst our customers for ecommerce expertise, payments knowledge, and dedication to excellent customer service.

Realex


Using the stepwise instructions in this guide, it’s easy to connect Salesforce to the Realex Payments gateway with the Chargent app. Chargent has many features to offer, including automating and streamlining Salesforce payment processes, easy subscription management, click-to-charge buttons, payment request emails, and more.

Integrating Realex with Chargent gives you the ability to easily build a seamless process for completing payment for orders that you manage in Salesforce. The integration connects the Realex gateway directly to Salesforce. Chargent also supports Realex gateway tokenization for processing credit card payments. See Configuring Salesforce for Realex Integration for additional information on the gateways.


Distinctives for the Realex Gateway

Realex Payments offers two types of transaction refunds, refunds and rebates. Rebate is the default type, and will refund money to the same credit card for the initial transaction. The refund amount limit for a rebate is 115% of the original transaction value.

If you want to refund any amount of money to any credit card any amount of money, choose the refund type. This is available in the custom settings. In the Chargent Settings tab, click the Advanced Settings tab and then check the box for Use RealEx Rebate Method.

Realex Rebate Method


Whitelisting: Keep in mind that Realex may need to whitelist Salesforce IP addresses for your account.


Your Realex Sandbox Account

The first task is to get a sandbox / test account from Realex so that you can run test transactions from Salesforce. To being the process for obtaining a sandbox account, complete the form on the sign up page.

Realex Sandbox Account



Username and temporary password

Upon approval, you’ll receive an email that contains these testing credentials:

  • User ID
  • Temporary password


Click the link in the email to go to the test test login page.

Login with your username and temporary password, and then follow the prompts to change your password.

Need help? Contact Realex through the options given on their Support page.


Permanent password

On your first successful login, you’ll get a prompt to enter a permanent password of your own choosing. Take note of any restrictions on the required strength of the password.

NOTE: You must get each of these gateway credentials from Realex before moving on to the steps in the next section, Configuring Salesforce for Realex Integration.


Configuring Salesforce for Realex Integration

NOTES

  • The steps in this section are written with the assumption that Chargent has not already been installed into your Salesforce account.

  • Before moving on to the procedure below, you must successfully complete all of the steps given in the previous section, Obtain a Realex Sandbox Account.


Follow the steps below to configure Salesforce to integrate with Realex:

  1. Install the Chargent Base Package into Salesforce, as we describe on the Chargent Installation page.

  2. Install only one of the Chargent Transaction Packages in Salesforce, as we describe on the Chargent Installation page. There are three Transaction Packages to choose from: Chargent Orders, Opportunities, or Cases.

  3. Complete the basic Chargent setup, such as assigning user licenses and updating page layouts. For more information, please consult our Quick Start Guide.

  4. Select the Chargent item in upper-right corner of Salesforce.

  5. In the upper-left of the Salesforce page, click the Gateways tab, then click the Create New drop-down, and then select Gateway.

    Realex Gateways


  6. In the Gateway Record Type panel, select the Realex item from the Record Type drop-down, and then click the Continue button.

    Realex Record Type


  7. On the Gateway Edit page, begin by entering a Gateway Name (such as “Realex Test”). This is merely an internal Salesforce name that you choose for the gateway.

  8. Use the table below for guidance when entering the remaining necessary values for the Gateway Edit page:

    Gateway Page Field Value
    Gateway Name Enter an easily recognizable name for this gateway, such as “Realex Test”.
    Merchant ID Merchant ID
    Merchant Security Key Realex Shared Secret and Refund Password, merged by a "@" symbol. Example: secret@refund"
    Active Check this box
    Test Endpoint Check this box

    NOTE: The Merchant ID, Shared Secret, and Refund Password are taken from your Realex introductory email message(s). See the section above, Get your Merchant Security Key.

  9. Your Gateway page should look similar to the figure below. Click the Save button to commit your changes.

    Realex Gateway Save



Testing the Integration

This section contains the procedure for testing the integration that you set up according to the procedure given in Configuring Salesforce for Realex Integration, using your Realex sandbox credentials.

Follow the steps below to verify that the integration is correct.

  1. In the upper-left corner of the Salesforce page, click the + tab to open the All Tabs page.

  2. In the tabs listing, locate the link that corresponds to the Chargent Transaction Package that you installed during the Configuring Salesforce for Realex Integration procedure.

    See the figure below, which indicates Chargent Orders for the purpose of illustration. (If you installed the Chargent Opportunities or Cases package, you would use that object for testing).

    Realex


  3. On the next page, click the New button (see the figure below).

    Realex Chargent New


  4. Taken from the Realex Test Cards page, the table below contains are valid test credit card numbers. Using a particular test card number will generate various approved and declined transactions for each credit card type. You can trigger an error by varying the using any of the card numbers other than those denoted by “Successful” in the Comments column.

    Card Type Card Number Comments
    Visa 4263970000005262 Successful
    Visa 4000120000001154 Declined
    Visa 4000130000001724 Referral A
    Visa 4000160000004147 Referral B
    Visa 4009830000001985 Comms Error
    Mastercard 5425230000004415 Successful
    Mastercard 5114610000004778 Declined
    Mastercard 5114630000009791 Referral A
    Mastercard 5121220000006921 Referral B
    Mastercard 5135020000005871 Comms Error
    American Express 374101000000608 Successful
    American Express 376525000000010 Declined
    American Express 375425000000907 Referral A
    American Express 343452000000306 Referral B
    American Express 372349000000852 Comms Error
    3D Secure 4012001038443335 Cardholder Not Enrolled ECI 6 **
    3D Secure 4012001038488884 Unable to Verify Enrolment ECI 7 **
    3D Secure 4012001036298889 Invalid response from Enrolment Server ECI 7 **
    3D Secure 4012001036853337 Enrolled but invalid response from ACS ECI 7 **
    3D Secure 4012001037141112 Successful Authentication ECI 5 **
    3D Secure 4012001037167778 Authentication Attempt Acknowledged ECI 6 **
    3D Secure 4012001037461114 Incorrect Password entered ECI 7 **
    3D Secure 4012001037484447 Authentication Unavailable ECI 7 **
    3D Secure 4012001037490006 Invalid Response from ACS
  5. In the Chargent Order Edit page, enter or select information to correctly complete the essential parts of the form, including:

    • Gateway

    • Billing First Name

    • Billing Last Name

    • Billing Address (City, State, Zipcode)

    • Billing Email Address (to get a receipt)

    • Charge Amount (check Manual Charge if this amount is not calculated from Subtotal + Tax + Shipping)

    • Payment Method

    • Card Type

    • Card Number

    • Card Expiration Month

    • Card Expiration Year (use a future year)

    • Card Last 4

    • Customer IP

    See the figure below for the placement of these fields.

    Realex Chargent Edit Order


  6. Click the Save button to commit the changes on the form. On the next page, click the Charge button (as shown below).

    Realex Chargent Charge


  7. When the transaction is complete, you see a small pop-up as shown in this figure. Click the OK button to close the pop-up window, then scroll to the bottom of the Order page.

    Realex Chargent Popup


  8. A record is created for each error and each successful transaction, and this record contains the response messages and details that are sent back from Realex. See the figure below for an example.

    Realex Chargent Transactions



Sending Live Transactions from a Salesforce Sandbox

When Chargent is installed in a Salesforce Sandbox, transactions are always sent to the payment gateway's test / sandbox / development environment, regardless of whether Chargent's Test Endpoint checkbox is checked. This is done as a security precaution, to prevent real transactions from being accidentally sent from a Salesforce Sandbox.

When Chargent is installed in a production or developer Salesforce org, the Test Endpoint checkbox on the Gateway record will select between sending to the payment gateway's live and test environments. (There are a few exceptions, such as Stripe, which has a single endpoint to send transactions to, and different credentials for live versus test transactions).

If you wish to send live transactions from a Salesforce Sandbox, as a final step in testing, simply use Chargent's Endpoint Override field on the Gateway record, and enter the production endpoint of your chosen gateway there.

Here is the production endpoint URL for Chargent's integration with Realex:

https://epage.payandshop.com/epage-remote.cgi

Note that the full endpoint URL must be entered in the Endpoint Override field, and the domain must be present in the Remote Site Settings (for standard Chargent integrations it should be already present).


Understanding Transactions

When a transaction occurs between Chargent and the Realex gateway, a new transaction record is created in Salesforce. The listing of transactions can be found in the Transaction section near the bottom of the Chargent Order page (or Opportunities or Cases, if you are using those packages). See the figure above.

On the order page, scroll down to that Transactions section and click a Transaction ID link to see the details, as shown in the figure below. This transaction record contains the entire set of data that Realex sends in its response, including transaction Type (Charge, Authorize, Refund or Void), the Response Status (Approved, Declined, Error), and any related approval or error messages.

Realex Transaction Detail


Verifying Transactions in the Realex Dashboard

You can compare the transaction records in Salesforce with the records in your Realex dashboard. Login to the Realex test portal and click the Batched link at the top. See the figure below.

Realex Verifying


You’ll see a transaction listing similar to this one.

Realex Verifying


Locate the transaction of interest in the listing, and click on the transaction row, then click again on the item of interest on the next page to see the details for that transaction.

Realex Verifying



Correspondence in the Transaction Fields

The Salesforce Gateway ID is the Realex Pas Ref combined with the Realex Order ID, with an underscore between them.


Moving to Production

This section contains the procedure for configuring the integration in a production system.

Get your Production Credentials

In the same email that contains your credentials you also find a Shared Secret and Refund Password, merged by a "@" symbol (for example, “secret@refund) This is the value for Merchant Security Key in Salesforce.

Production account: You’ll also need to register for a production account. When you’re ready, use the contact information in the enrollment email messages to work with Realex Support and obtain the same set of credentials for your production account.

NOTE: It’s important that you do not proceed here until the testing procedure described in Testing the Integration is successful.

Follow these steps to configure the production in Salesforce:

  1. First, obtain the production credentials for the Realex production gateway account (similar to the method given for sandbox credentials in Obtain a Realex Sandbox Account.

  2. Get these production credentials from your enrollment email message(s):

    • User ID
    • Password
    • Realex Shared Secret and Refund Password, merged by a "@" symbol. For example, “secret@refund". This will be the Merchant Security Key in Salesforce.

  3. Repeat the steps in the Configuring Salesforce for Realex Integration section above, but substitute the production credentials.

  4. Repeat the steps in the Testing the Realex Integration section above with respect to the SalesForce production environment, using the production credentials.

    Void a transaction: If you’re using an actual credit card and want to prevent the charge from settling, remember to void the transaction after testing.

  5. Be sure to successfully transmit at least one real credit card transaction using company or personal accounts. We recommend that you submit a transaction with a very small amount and then void that transaction afterwards. This ensures that the system works with your production credentials.


Correspondence in the Transaction Fields

This table contains the mapping information between the gateway and Salesforce fields.

Salesforce field Direction Gateway field
Gateway ID < First part of the Pass Ref field plus 2nd part of the Order ID at top of Realex detail page
Gateway ID > 2nd part of the Order ID at top of Realex detail page
Gateway Date/Time > Date/Time in listing