Prerequisites

Request the cartridge from this page.

Step 1 - SFCC Credentials

Create Credentials

Create OAuth Client Credentials:

  • Enter Display Name: OwnID Integration
  • Enter a password
  • Assign your organization
  • Assign the following roles: Sandbox API User and Salesforce Commerce Cloud
  • Token Endpoint Auth Method: private_key_jwt
  • Save Changes.

You will get a Client Id and Secret. (Save this values for later)

Assign Permissions

Go to Administration > Site Development > Open Commerce API Settings:

Configure shop tab

Add the following JSON to the shop tab:

Change “Your Client ID” value in the json by the Client Id created in the previous step.
shop
{
  "_v": "23.1",
  "clients": [
    {
      "allowed_origins": [
      ],
      "client_id": "Your Client ID",
      "resources": [
        {
          "resource_id": "/customers/auth/trustedsystem",
          "methods": [
            "post"
          ],
          "read_attributes": "(**)",
          "write_attributes": "(**)"
        },
        {
          "resource_id": "/sessions",
	           "methods": [
            "post"
          ],
          "read_attributes": "(**)",
          "write_attributes": "(**)"
        }
     ]
   }
 ]
}

Note: If the OCAPI configuration is already in place, simply include the following resource into the resources section:

{
  "resource_id": "/customers/auth/trustedsystem",
   "methods": [
       "post"
   ],
   "read_attributes": "(**)",
   "write_attributes": "(**)"
},
{
   "resource_id": "/sessions",
   "methods": [
       "post"
   ],
   "read_attributes": "(**)",
   "write_attributes": "(**)"
}

Configure data tab

Add the following JSON to the data tab:

Change “Your Client ID” value in the json by the Client Id created in the previous step.
data
{
  "_v": "23.1",
  "clients": [
    {
      "allowed_origins": [
      ],
      "client_id": "Your Client ID",
      "resources": [
       {
          "resource_id": "/customer_lists/*/customers/*",
          "methods": ["get", "patch"],
          "read_attributes": "(**)",
          "write_attributes": "(**)"
       },
       {
         "resource_id":"/customer_lists/*/customer_search",
         "methods": ["post"],
         "read_attributes": "(**)",
         "write_attributes": "(**)"
        },
   {
    "resource_id":"/ocapi_configs/*",
    "methods": ["get"],
    "read_attributes": "(**)",
    "write_attributes": "(**)"
   }
   ]   
  }
  ]
}

Step 2 - OwnID Application

  • Login to the OwnID Console.
  • Create a new application.
  • Name the application and select its type as the SFCC Connector.
Your application is created!
  • In your Salesforce integration page, fill in the following information:
    • Instance Hostname - e.g: xyzb-001.dx.commercecloud.salesforce.com (only the domain, without protocol)
    • Site ID - e.g: RefArch (case sensitive)
    • API Client ID (generated in the previous step)
    • API Client Secret (generated in the previous step)
    • SFCC Username (get it from account-manager)
    • SFCC Password
  • Save Changes

Copy the appId. You will use it in the next step.

Step 3 - SFCC Cartridge Installation

  • Upload and add the cartridge to the target site.

  • Navigate to Merchant Tools > Site Preferences > Custom Preferences > OwnID and set the following preferences:

    • EnableOwnId: Set to true to display the OwnID widget.
    • Env: Select the OwnID production environment.
    • AppId: Enter the previously copied OwnID appId from the OwnID console.
Congratulations! Enjoy your passwordless authentication!