Salesforce Commerce Cloud (SFCC)

Connect Simon Data to Your SFCC Account Using OCAPI

Salesforce Commerce Cloud (SFCC) enables authorised users to access data using the Open Commerce API (OCAPI). Follow the steps to below give us access to this API so it can be used as another data source within your Simon Data account.

📘

Salesforce documentation

Simon Data connects to your SFCC account via the OCAPI by obtaining a Business Manager grant. You can learn more about this approach here.

There are two primary steps to granting OCAPI access:

Set Up an API Client in SFCC

  1. Log in to the SFCC account manager as an admin
  2. Within the account manager, navigate to the API Client screen then click Add API Client
  3. Enter Simon Data or any other display name you prefer to identify the API Client
  4. Enter a password. This will be your client secret.
  5. Leave the defaults in JWT and OpenID.
  6. From the Token Endpoint Auth Method menu choose client_secret_basic
  7. Click Add.
  8. Make a note of the 'API Client ID' that is generated.
  9. Enter your 'API Client ID' into the SFCC credentials form on the integrations page.

Update OCAPI Settings to Grant Required Permissions

  1. From the SFCC Business Manager, navigate to Administration > Site Development > Open Commerce API Settings.
  2. Select Shop as the Type and 'store-specific' as the context.
  3. In the text field, paste the following JSON. If you already have permissions configured, you need to merge in the following JSON. Be sure to replace the client_id field with the API Client ID from step 8 above.
{
 "_v": "20.4",
 "clients": [
   {
     "client_id": "YOUR_API_CLIENT_ID",
     "allowed_origins": [
       "https://www.<YOUR_WEBSITE>.com"
     ],
     "resources": [
       {
         "resource_id": "/orders/*",
         "methods": [
           "get"
         ],
         "read_attributes": "(**)"
       },
       {
         "resource_id": "/order_search",
         "methods": [
           "post"
         ],
         "read_attributes": "(**)",
         "write_attributes": "(**)"
       },
       {
         "resource_id": "/products/*",
         "methods": [
           "get"
         ],
         "read_attributes": "(**)",
         "write_attributes": "(**)"
       },
       {
         "resource_id": "/product_search*",
         "methods": [
           "get"
         ],
         "read_attributes": "(**)",
         "write_attributes": "(**)"
       },
       {
         "resource_id": "/customers/auth",
         "methods": [
           "post"
         ],
         "read_attributes": "(**)",
         "write_attributes": "(**)"
       }
     ]
   }
 ]
}
  1. Once complete, click Save.

Supported Endpoints


Did this page help you?