Salesforce Commerce Cloud
Last updated: September 4, 2024
Get started with our Salesforce Commerce Cloud (SFCC) integration, from installing the LINK cartridges to making your first test payment.
Information
You can use our LINK cartridges with Storefront Reference Architecture (SFRA) or controller-based SiteGenesis.
- Manual capture, void, and refund from the Dashboard and the SFCC Business Manager
- Multiple partial captures via the Business Manager
- Multiple partial refunds via the Business Manager
- Embedded payment form using our Full card details API
- Saved cards (stored credit cards)
- Invoice generation
- 3D Secure 2.0
- Webhook notifications for up-to-date payment statuses
- Gift certificates on SiteGenesis
To set up our SFCC integration, you'll need 3 API keys: a secret key, a public key, and an authorization header key. You can create your secret and public keys in the Dashboard. The authorization header key is generated when you create a webhook for your business.
Webhooks are notifications that we send when an event occurs on your account (for example, when a payment is captured). These are used by the SFCC plugin to update the status of an order. Read more about webhooks.
- Sign in to the Dashboard.
- Go to Developers > Webhooks.
- Select New webhook.
- Give the new webhook a name to make it easier to identify in the future.
- Enter a webhook URL that starts with either
https://
orhttp://
. - Enter an authorization key. To validate that the webhook is genuine, this will be in the header of every webhook notification we send you.
- Enter a signature key. Checkout.com generates a hash-based message authentication code (HMAC) from the webhook notification contents, using the key provided in your workflow's webhook action. The HMAC will be in every notification you receive.
- You can configure HTTP headers which will be included in each webhook notification. You can use this feature to configure a key that you want to provide in your webhook notifications' Authorization HTTP header, allowing you to authenticate requests with your server.
- Select the events you want to receive webhooks for. There is no limit to the number of events you can select per endpoint.
- Webhooks are set up at a client level, which means you will receive notifications for all entities and processing channels. However, you can filter the updates to specific entities and processing channels.
- Select Create webhook to publish your endpoint. It will be live from this point onwards.
- Download our installation package from GitHub. This package includes the front-end cartridges for SFRA (
int_checkoutcom_sfra
) and SiteGenesis (int_checkoutcom
), as well as the back-end cartridge (bm_checkoutcom
), which is compatible with both SFRA and SiteGenesis. - Upload the relevant cartridges to your server, using a tool like UX Studio:
- If you're using SFRA, install
int_checkoutcom_sfra
andbm_checkoutcom
. - If you're using SiteGenesis, install
int_checkoutcom
andbm_checkoutcom
.
- If you're using SFRA, install
- Sign in to your Business Manager account, and go to Administration > Sites > Manage Sites > [your site] > Settings.
- In the Cartridges field, add one of the following to the front of the cartridge path and select Apply:
- For SFRA, add
int_checkoutcom_sfra:
. - For SiteGenesis, add
int_checkoutcom:
.
- For SFRA, add
- In the Business Manager, go to Administration > Sites > Manage Sites.
- Go to the Business Manager Site section and select Business Manager.
- Add
bm_checkoutcom:
to the front of the cartridge path and select Apply.
- In a file browser, open the
metadata
folder in the installation package you downloaded earlier, then go into thesites
subfolder. - Rename the default named folder to the name of the site for which you want to import the cartridge:
- For SFRA, rename the
RefArchGlobal
folder to the name of your site. - For SiteGenesis, rename the
SiteGenesisGlobal
folder to the name of your site.
- For SFRA, rename the
- Navigate back to the package's root folder, and zip the
metadata
folder. - Next, log in to Business Manager and go to Administration > Site Development > Site Import & Export.
- Under Upload Archive, select Local and then Choose file.
- Find the
metadata.zip
you just created, select Open and then Upload.
Note
The Checkout.com credit card form is not compatible with the default SiteGenesis credit card form. Please disable the default credit card form if using the Checkout.com credit card form, and vice versa.
If you use SiteGenesis, you also need to edit the payment methods template in order to show the Checkout.com payment option on the billing page.
To do so, add the following code snippet to the /app_storefront_core/cartridge/templates/default/checkout/billing/paymentmethods.isml
file:
1<iscomment>2Checkout.com - Integration example Add this code to your paymentmethods.isml file3--------------------------------------------------------------4</iscomment>5<isif condition="${(dw.system.Site.getCurrent().getCustomPreferenceValue("ckoEnabled"))}">67<isinclude template="ckoPayments" />89<iselse>10<iscomment>11Site Genesis - Default Credit card block Add the default SiteGenesis credit card form code here.12--------------------------------------------------------------13</iscomment></iselse14>
This will display the Checkout.com credit card form if enabled in the custom preferences, and display the default Site Genesis credit card form if not.
Information
If your site is also using the default SiteGenesis credit card form, place the code of the form (found in the core paymentmethods.isml
template file) after the <iselse>
block in the snippet shown above.
- Sign in to Business Manager, and go to Merchant Tools > Site Preferences > Custom Preferences > CKO [1] Sandbox Keys.
- Set ABC or NAS Enabled to NAS.
- Enter the public key and secret key from your sandbox Dashboard account, prefixed with
Bearer
(for example,Bearer pk_sbox_xxxxxx
). - Enter the authorization header key from your sandbox Dashboard account, and select Save.
- Go back to the custom site preferences page and select CKO [4] Payment Settings.
- Make sure Enable is set to Yes, to enable the Checkout.com card payment form.
- Set Mode to Sandbox, so you can start testing card payments.
- If you'd like to log gateway requests in the request log, set Enable debug mode to Yes.
- Choose whether or not you want to Auto capture your payment. Set this field to Yes if you want payments to be captured immediately after being authorized. Set it to No if you want to capture payments manually.
- If you set Auto capture to Yes, you can specify the delay (in minutes) before the payment is captured. The default is
0
. - Go back to the custom site preferences page and select CKO [3] Business Details.
- Enter your business name (the name of your shop), and fill in the business address, city and country fields.
- Select Save.
That's it! You're ready to start testing card payments.
- Go to your storefront and add a product to your cart.
- Go to your cart and proceed to the checkout.
- Enter the required billing details. You can put anything here, though we recommend using a real email address so you can receive the order confirmation.
- Select the Pay by Card with Checkout.com method.
- Enter test card details (you can use any future expiry date).
- Select Place order, and you will be redirected to the order confirmation page. If you entered a real email address in the billing details, you'll also receive an order confirmation email.
- Sign in to Business Manager.
- Go to Merchant Tools > Ordering > Orders and select Find to show your orders. Your test order will be displayed there with a
New
status. This indicates that the payment has been successfully authorized and captured. The transaction will also appear in the Payments section of your sandbox Dashboard account.
You can now either go live as-is or extend your configuration.
You'll find more test cards and a range of scenarios to trigger in our testing guide.
Note
If this test does not work, first check you have configured your webhooks correctly. For the plugin to work, they must be formatted correctly. If you have configured them properly, check your server: if it's password-protected or it restricts unfamiliar IP addresses, it may be blocking webhook notifications. Contact our Support team at [email protected] if you need help.
If you're happy with the outcome of your testing and want to start taking payments right away, please contact our Sales team in order to move to a live account.
Note
Before you go live, remember to:
- Switch the cartridge Mode from Sandbox to Live in Business Manager.
- Enter your live public, secret and authorization header API keys in the Checkout.com Live API section of Custom Site Preferences.
- Configure the webhook URLs in your live Dashboard account.
You can extend your Salesforce Commerce Cloud integration in multiple ways to suit all your business needs.
In this section, you'll learn how to:
- Add more payment methods
- Enable 3D Secure payments
- Enable Mada card payments
- Set a billing descriptor
- Manually capture, void and refund payments
Note
In order to start accepting an alternative payment method, we first need to enable it on your account. Please contact your Account Manager or our Sales team to get started.
We support the following payment methods on SFCC:
Check the individual payment method pages to see which ones you can support. It will depend on your location, as well as the currency and billing address of your customer.
- Sign in to Business Manager.
- Go to Merchant Tools > Site Preferences > Custom Preferences > CKO [5] APM Settings.
- Set the payment methods you want to support to Yes.
- Select Save.
Information
Before going through these steps, you need to set up and configure Apple Pay.
- Sign in to Business Manager.
- Go to Merchant Tools > Ordering > Payment Methods.
- Set Enable to Yes for CHECKOUTCOM_APPLE_PAY and save the changes.
- Go to Merchant Tools > Site Preferences > Apple Pay.
- Choose in which environment you want to run Apple Pay: Test or Production.
- Toggle the Apple Pay Enabled? option.
- Enter your Apple Merchant ID and Apple Merchant Name. You'll find these in your Apple Developer account.
- Enter the two-letter ISO 3166 country code for your site's locale.
- Check the 3DS option in Merchant Capabilities, leaving the other options unchecked.
- Select Supported Networks.
- Select the Required Shipping Address fields.
- Select Name and Postal Address for the Required Billing Address fields.
- Select whether to place the Apple Pay button on the cart and/or mini-cart pages.
- Select whether to enable the automatic redirect of product detail pages to HTTPS.
Information
Pages where the Apple Pay button appears must be served via HTTPS, so you might need to redirect certain pages on your site.
- Select Submit. A domain name should appear in the Registration section. If you don't have an alias registered for your site, you'll see a domain similar like
staging-merchant.demandware.net
orproduction-merchant.demandware.net
. If you do have an alias registered, the domain will be something likemystore.com
. - Register your site with the Apple sandbox or production server. You only need one merchant ID to register with both servers. If your domain is registered with Apple sandbox, only devices signed in to an iCloud Sandbox Tester Account can make payments on that site. If your domain is registered with the Apple production server, any regular iCloud account can pay on that site.
Information
See our Google Pay documentation for more information.
- Sign in to Business Manager.
- Go to Merchant Tools > Site Preferences > Custom Preferences > CKO [6] Google Pay Settings.
- Set Enable Google Pay to Yes.
- Choose in which environment you want to run Google Pay: Test or Production.
- Enter your Google Pay merchant ID. You can find this in your Google payments profile.
- Select the appearance of the Google Pay button with the Button Style option. See the Google Pay documentation for more detail.
Activate this feature if you want your transactions to be 3D Secure (3DS) authenticated. Our SFCC plugin supports 3DS2, the new authentication standard.
Note
If you enable this feature, every transaction will trigger a 3DS check. If you only want to trigger it for certain transactions, contact your Account Manager.
- Sign in to Business Manager.
- Go to Merchant Tools > Site Preferences > Custom Preferences > CKO [4] Payment Settings.
- Set 3D Secure to Yes.
- Select whether or not you want to Attempt Non 3D Secure transactions. If you select Yes, any cards that do not support 3DS will go through without a 3DS check. If you select No, cards that do not support 3DS will be blocked.
- Select Save.
Mada is a local card scheme in Saudi Arabia. If you are going to be processing Mada cards, you should enable this setting.
- Sign in to Business Manager.
- Go to Merchant Tools > Site Preferences > Custom Preferences > CKO [4] Payment Settings.
- Set Enable MADA Payment Cards to Yes.
- Configure BINs for Mada cards.
- Select Save.
The billing descriptor is an extra field you can send to the issuer, appearing on the customer's bank statement as an additional description of the payment.
- Sign in to Business Manager.
- Go to Merchant Tools > Site Preferences > Custom Preferences > CKO [3] Business Details.
- Enter Billing Descriptor Line1. This is usually the name of your shop.
- Enter Billing Descriptor Line2. This is usually the city of your merchant address.
- Select Save.
As well as doing so through the Dashboard, you can also manually capture, void and refund payments from Business Manager. These actions will show in both Business Manager and the Dashboard.
- Sign in to Business Manager, and go to Merchant Tools > Checkout.com Manager > Checkout.com Transactions.
- To capture a payment, find the payment you want to capture (must be type
AUTH
), select Capture in the Actions column and then select Submit. - To void a payment, find the payment you want to void (must be type
AUTH
), select Void in the Actions column and then select Submit. - To refund a payment, find the payment you want to refund (must be type
CAPTURE
), select Refund in the Actions column and then select Submit.