Set up the cartridge

Set up the cartridge in the Adyen Customer Area and in the Business Manager.

Before you begin

Make sure that you have:

Step 1: Set up the cartridge path

To set up the cartridge path in the Business Manager: 

  1. Go to Administration > Sites > Manage Sites > [yourSite] > Settings

  2. In the Cartridges box: 
    • If you are using SFRA, enter:
      int_adyen_SFRA:int_adyen_overlay:app_storefront_base
    • If you are using a controller-based SiteGenesis, enter:
      int_adyen_controllers:int_adyen_overlay:app_storefront_controllers:app_storefront_core

Step 2: Set up the Business Manager

In the following steps, you will need to copy over several settings from the Adyen Customer Area to the Business Manager.

  1. In the Business Manager, go to Merchant tools > Site Preferences > Custom Preferences > Adyen.

    Account structure

    With Adyen, you have a single company account, together with one or more merchant accounts. For more information, refer to Account structure.

  2. In the merchantCode box, enter the name of your Adyen merchant account for which the payments will be processed. You can find this in the upper-right corner of your Customer Area.
  3. Set Test/Production mode to (TEST).
  4. To enable debug logging, set Enable Adyen debug mode to Yes. This displays the Pay button before redirecting to Adyen, allowing you to check the parameters sent in the request.
  5. Click Save in the upper-right corner of the screen.

Step 3: Connect your Commerce Cloud store to the Adyen API

To connect your Commerce Cloud store to the Adyen API, you need to set up a web service (ws) password in the Adyen Customer Area, and copy the ws credentials over to the Business Manager. 

Set up a ws password in the Adyen Customer Area

  1. In the Adyen Customer Area, go to Account > Users.

  2. From the drop-down menu in the first column, select System.
  3. Click the ws user (ws@Company.[YourCompanyAccount]).
    This opens a page with the settings for this ws user.
  4. In the Authentication pane, click Generate Password.
  5. Copy the ws password and store it securely in your system.
  6. Click Save.

Copy the ws credentials over to the Business Manager

  1. In the Business Manager, go to Administration > Operations > Services.
    This opens a page with services named Adyen[serviceName] that were added when you imported the metadata.
  2. In the Credentials column, click on the service that you want to set up. 
  3. In the User and Password box, enter the ws username and password from your Adyen Customer Area.
  4. Click Apply.

Step 4: Set up Client-Side Encryption 

Our Client-Side Encryption (CSE) integration lets you accept payments while encrypting card data in your shopper's browser using the Adyen encryption library. To set up CSE, you need to get the library token from the Adyen Customer Area, and copy it over to the Business Manager. 

Get the library token from the Adyen Customer Area

  1. In the Adyen Customer Area, go to Account > Users.

  2. From the drop-down menu in the first column, select System.
  3. Click the ws user (ws@Company.[YourCompanyAccount]).
    This opens a page with the settings for this ws user.
  4. In the Client-Side Encryption pane, copy the Library token.

Set up CSE in the Business Manager

  1. In the Business Manager, go to Merchant tools > Site Preferences > Custom Preferences > Adyen.
  2. In the CSE library token box, paste the library token from your Adyen Customer Area.
  3. Set CSE Enabled to Yes
  4. Click Save in the upper-right corner of the screen.

Step 5: Set up a skin

skin is an interface overlay that is applied to the Adyen Hosted Payment Page (HPP) to create a seamless checkout experience for your shoppers.

Create a skin in the Adyen Customer Area

  1. In the Adyen Customer Area, go to Account > Skins.
  2. Click the New tab. 
    This opens a page with settings for the new skin. 
  3. In the Description box, enter a description for your skin.
  4. Click Generate new HMAC key for the Test platform.
  5. Copy this key and store it securely in your system.
  6. Leave the Result URLs and Continue-to URLs empty.
  7. Click Create New Skin on Test.

Copy the skin information over to the Business Manager

  1. In the Business Manager, go to Merchant tools > Site Preferences > Custom Preferences > Adyen.
  2. In the skinCode and HMACkey box, enter the Skin Code and the test HMAC key from your Adyen Customer Area.

  3. Click Save in the upper-right corner of the screen.

Step 6: Receive payment status updates 

To inform your Commerce Cloud store of payment status changes, Adyen uses notifications, sent as HTTP callbacks (webhooks) to endpoints on your server. To receive notifications, you need to enter your server's details in the Adyen Customer Area, and copy over the notification credentials to the Business Manager.

Set up notifications in the Adyen Customer Area

  1. In the Adyen Customer Area, switch to your merchant-level account (by clicking the name of your merchant account in the upper-right corner). 
  2. Go to Account > Server Communications.
  3. Next to Standard Notification, click Add
  4. In the URL box, enter your website URL followed by /Adyen-Notify.
  5. From the SSL Version dropdown, select TLSv.1.2.
  6. Select the Active checkbox.
  7. From the Method dropdown, select HTTP.
  8. In the Authentication pane, enter a User Name and Password for notifications.
  9. Store these credentials securely in your system.
  10. Click Save Configuration.

Copy notification credentials over to the Business Manager

  1. In the Business Manager, go to Merchant tools > Site Preferences > Custom Preferences > Adyen.
  2. In the Adyen Notifications User and Adyen Notifications Password box, enter the username and password for notifications from your Adyen Customer Area.

Test notifications

Test whether notifications have been configured correctly:

  1. In the Adyen Customer Area, switch to your merchant-level account (by clicking the name of your merchant account in the upper-right corner). 
  2. Go to Account > Server Communications.
  3. Next to Standard Notification, click Edit & Test
  4. In the Test Notifications pane, click Test Configuration
  5. If the result is [Accepted], your notifications are working correctly.

Configure scheduled jobs

Notifications are stored in Commerce Cloud as custom object instances to be processed by scheduled jobs.

After the metadata import, a scheduled job with ID Process is added to the Business Manager: Administration > Operations > Job Schedules. This scheduled job has two steps (you can check this in the Step Configurator tab): 

  • Process – Processes the notification and updates the payment status of the order.
  • Clean –  Deletes the custom object instance, once it has been processed.

We recommend that you set the frequency of this scheduled job to 1 minute: 

  1. Go to the Schedule and History tab for the Process scheduled job.
  2. Set Trigger to Recurring Interval.
  3. In the Run Time pane, set Amount to 1, and Interval to Minutes

Step 7 (optional): Set up recurring payments 

Adyen can securely store payment details of your shoppers, allowing you to offer recurring payments.

If you want to enable recurring payments, make sure that you entered the ws credentials for the AdyenRecurring and AdyenRecurringDisable services in the Business Manager in Step 3. 

You also need to set up recurring payments in the Business Manager:

  1. Go to Merchant tools > Site Preferences > Custom Preferences > Adyen.
  2. Set Adyen recurring payments enabled to Yes.
  3. Set Recurring type to the type of the recurring contract that you want to use. Possible values:

    Recurring payments

    For more information about recurring transaction types, refer to Recurring payments.

    • RECURRING  – Enable stored payment methods for recurring transactions, where you can complete the payment without the shopper being present.
    • ONECLICK – Enable stored payment methods for one-click transactions, where the shopper needs to enter their CVC/CVV to complete the payment.
    • RECURRING,ONECLICK – Enable stored payment methods for both one-click and recurring transactions.

Next steps

Set up payment methods

Set up the payment methods that you wish to offer.

link

Test and go live

Test your integration and start processing live transactions.

link

See also