OBTAINING SHOPIFY CREDENTIALS
Credentials are the conduit for communications between Business Central and Shopify ...
As part of the setup process, it is necessary to obtain credentials from Shopify that will grant CSM with the necessary permission to access relevant Shopify records. These credentials are assigned to corresponding sales channels in Business Central and can be used in the Shopify Quick Start Wizard.
Prerequisites: Before starting, make sure you have:
- Access to Microsoft Business Central
- CSM API Engine installed
- Shopify Developer account
- Provided API Set JSON file found HERE
- Required Shopify scopes from Suite Engine
STEP 1: IMPORT SHOPIFY ACCESS TOKEN API SET
- Open Business Central.
- In the search bar, search for: API Set
- Select API Set (do NOT select CSM API Set).
- Open the API Set list.
- Click Import.
- Select the provided JSON file.
- Upload the file.
After import, a new API Set named "Shopify Access Token" will appear.
STEP 2: CONFIGURE API CREDENTIALS
- Open the Shopify Access Token API Set.
- Click Related → Credentials.
- Open the generated credential.
Configure Endpoints:
- Update the Authorization Endpoint.
- Replace the placeholder YourShopName with your Shopify store name.
- Update the Token Endpoint URL.
- Enter the required scopes.
STEP 3: CREATE SHOPIFY APP
- Open a browser.
- Go to: https://dev.shopify.com
- Log in to the Shopify Developer Portal.
- Click Create App.
- Enter an app name (example: CSM Demo).
- Click Create.
STEP 4: CONFIGURE APP SETTINGS
Disable Embedded App:
- Open your app settings.
- Uncheck "Embed app in Shopify Admin".
- Replace the example URL with: https://businesscentral.dynamics.com
Configure Scopes:
- Add the required scopes.
- Use the same scopes as in your API Set.
Configure Redirect URL:
- Set the redirect URL to:
https://businesscentral.dynamics.com/OAuthLanding.htm - Click Release.
- Create a version (example: V1).
STEP 5: GET CLIENT ID AND CLIENT SECRET
- Go to Settings in your Shopify app.
- Copy the Client ID and Client Secret.
- Open API Credential in Business Central.
- Paste the values into their fields.
STEP 6: AUTHORIZE THE APP
- Open API Credential.
- Find the OAuth2 section.
- Click Authorize.
- Log in to your Shopify store.
- Approve and install the app.
STEP 7: GENERATE ACCESS TOKEN
- Go back to API Set.
- Click Home → API Function.
- Execute the function.
- Ignore localhost error if shown.
- Open API Message.
- Copy the generated access token.
STEP 8: SAVE TOKEN IN CSM API SET
- Copy the access token.
- Search for: CSM API Set
- Open CSM API Set.
- Open Shopify credential.
- Paste:
- Access Token into Password field
- Client ID into Username field
STEP 9: TEST COMMUNICATION
- Open CSM Sales Channel.
- Go to Actions → APIs → Test Communication.
- Run the test.
If successful, the integration is active.
STEP 10: DELETE HELPER API SET
- Return to API Set.
- Locate Shopify Access Token.
- Delete this API Set.
Do NOT delete CSM API Set.
IMPORTANT NOTES
- Always use API Set, not CSM API Set, when importing.
- Re-generate token if scopes change.
- Store credentials securely.
- Delete helper API Set after setup.
PROCESS SUMMARY
- Import helper API Set
- Configure credentials
- Create Shopify app
- Set scopes and redirect URL
- Copy credentials
- Authorize app
- Generate token
- Save in CSM
- Test connection
- Clean up helper API Set
Next: Shopify Quick Setup Wizard