Integrating ModusLink with Salesforce using Chargent
- Configuring ModusLink for Integration
- Configuring Salesforce For Integration
- Testing the Integration
- Understanding Transactions
- Going Live
- Field Mapping
ModusLink is a cloud-based, e-commerce platform that removes the complexities and risk of managing a global web store, optimizing each stage of the online buying experience so that customers can quickly and easily purchase products. The ModusLink end-to-end solution is entirely integral with global payment, CRM, and fulfillment systems.
Integrating ModusLink with Chargent gives you the ability to easily build a seamless process for completing payment for orders that you manage in Salesforce. The integration depends squarely on the ModusLink payment gateway, since it uses the tokenization of the gateway for processing credit card payments but not for ACH/eCheck payments.
We begin by explaining the configurations, then we walk through the testing of the entire set-up, and finally we discuss moving into production. There are also sections that help you understand gateway transactions, tokenization, and the field mappings.
Configuring ModusLink for Integration
In this section and the next, you’ll find the procedures for configuring the integrations for both Moduslink and Salesforce. It’s important to follow each of the steps carefully, and in the correct order.
Begin by contacting ModusLink Global Solutions to obtain a merchant account and get credentials—for both a sandbox account and a production account.
You should get these three credentials for each account:
- User ID
- Entity ID
NOTE: You must get gateway credentials from Moduslink before moving on to the steps in the next section, Configuring Salesforce For Integration.
Configuring Salesforce For Integration
This subsection contains the procedure for setting up Salesforce for the integration with Moduslink.
Follow the steps below to configure Salesforce to integrate with Moduslink:
- Install the Chargent Gateway Package into Salesforce, as we describe on the Chargent Installation page.
NOTE: Both the sandbox and production installation of Chargent include a free, 30-day trial license.
- Install the Chargent Orders Transaction Package in Salesforce, as we describe on the Chargent Installation page.
- Complete the basic Chargent setup, such as assigning user licenses and updating page layouts. For more information, please consult our Quick Start Guide.
As shown in the figure below, Select the Chargent item in upper-right corner of Salesforce.
In the upper-left of the Salesforce page, click the Gateways tab, then click the Create New drop-down, and then select Gateway-as shown in the figure.
In the Gateway Record Type panel, select the ModusLink item from the Record Type drop-down, and then click the Continue button.
- On the Gateway Edit page, enter the Gateway Name, which is an internal Salesforce name that you choose for the gateway.
- To test with the ModusLink sandbox account, check the Test Endpoint box. (See the figure below.)
Enter the test credentials given to you by ModusLink:
- Merchant ID - the ModusLink sandbox User ID.
- Merchant Security Key - this is the Password.
- Merchant Reference - this is the Entity ID.
Click the Save button. (See the figure below.)
Testing the Integration
This section contains the procedure for testing the integrations that were set up in Configuring ModusLink for Integration and Configuring Salesforce For Integration-using the ModusLink test credentials in Salesforce.
Follow the steps below to ensure that the integration is correct.
- In the upper-left corner of the Salesforce page, click the + tab to open the All Tabs page.
In the tabs listing, locate the link that corresponds to the Chargent Transaction Package that you installed during the Configuring Salesforce For Integration procedure. See the figure below, in which we show Chargent Orders for the purpose of illustration here.
On the next page, click the New button (see the figure below).
For ModusLink, these are valid test credit card numbers:
- VISA - 4200000000000000
- MasterCard - 5454545454545454
- American Express - 377777777777770
In the Chargent Order Edit page, enter or select information to correctly complete the essential parts of the form, including:
- Billing First Name
- Billing Last Name
- Billing Address, Billing City, Billing State, Billing Zip/Postal
- Billing Email Address
- Charge Amount
- Payment Method
- Card Type
- Card Number
- Card Expiration Month
- Card Expiration Year (use a future year)
- Card Last 4
See the figure below for the placement of these fields.
Click the Save button to commit the changes on the form. On the next page, click the Charge button (as shown below).
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.
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 ModusLink. See the figure below for an example.
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 ModusLink:
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).
When a transaction occurs between Chargent and the ModusLink gateway, a new transaction record is created, which 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).
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 Moduslink sends in its response, including transaction Type (Charge, Authorize, Refund or Void), the Response Status (Approved, Declined, Error).
The Gateway Date is the timestamp for the submission to ModusLink, and the Gateway ID field corresponds to the ModusLink ID for use in reconciliation between two systems.
See the figure below.
The figure below depicts how the same transaction appears in the ModusLink Transactions page:
This section contains the procedure for configuring the integration in a production system.
NOTE: Do not proceed here until the testing procedure described in Testing the Integration is successful.
First, obtain the production credentials for the ModusLink production gateway account (the productions credentials from Configuring ModusLink for Integration). This includes:
- Merchant ID = User ID
- Merchant Security Key = Password
- Merchant Reference = Entity ID
- Repeat the steps in the Configuring SalesForce for Integration section above, but substitute the production credentials.
- Repeat the steps in the Testing the Integration section above with respect to the SalesForce production environment, using the production credentials.
NOTE: Remember to void the transaction after testing, if you are using a real credit card and want to prevent the charge from settling.
- Be sure to successfully transmit at least one real credit card transaction and one real ACH transaction-using company or personal accounts. We recommend that you submit a transaction with a very small amount and then voiding that transaction afterwards.
This section contains the procedure for configuring the use of tokens that pass between Chargent and ModusLink. ModusLink uses a token system to maximize data security.
NOTE: This integration uses tokens only for credit card transactions.
From the drop-down in the upper-right of the Salesforce page, choose Chargent as the app.
Click Gateway tab in Chargent app.
Click on the Gateway Name that you are using for the integration.
Double click on the Use Tokenization field, then check the Use Tokenization box.
Double-click on Credit Card Data Handling field.
A drop-down will open, as shown in the figure below. Choose one of the following items from the Credit Card Data Handling drop-down:
- Never Clear - Chargent will not automatically remove card data.
- Clear After Successful Charge - Chargent will clear the credit card number, expiration dates, and card security code only after a successful charge occurs for a card.
- Clear After All Transactions - Chargent will erase the credit card number, expiration date, and card security code after any transaction (Charge, Void, Refund) occurs for a card.
- Clear When Token Present - Chargent will erase the credit card number, expiration date, and card security code after any transaction (Charge, Void, Refund) for a card only if there is a value in the token field.
- Never Clear - Chargent will not automatically remove card data.
- Click Save to commit your changes.
NOTE: After your first successful transaction, the token is stored in the Chargent Token field in Salesforce and the credit card fields are handled according to the choice in the Credit Card Data Handling field.
This table contains the mapping information between Moduslink and Salesforce fields.
|Salesforce field||Direction||Merchants field|
|Opp / Order / Case ID||>||Descriptor|
|Invoice Number||>||Merchant Invoice ID|
|Order Information||>||Cart Items Description|