Configuration of Sana Commerce Add-on
Warning
Sana Commerce is available as a custom add-on, so it cannot be found in Sana Commerce add-ons. If you'd like to use it you need to enable custom add-ons in your Sana Commerce Cloud and download *.sanapkg from our integration folder.
Setup in Business Central
- Choose the Search icon (or use Alt + Q), enter Web Services, then choose the related link.
- Create a new line and set:
- set Object Type to Codeunit
- set Object Id to 70113807. The name of the object is PIMX SC Web Service
- set Service Name to PimicsSC
- set it Published
Enable Application Area
- Go to Catalog Setup
- Enable Sana Commerce in group Application Area
- If you don't see the Sana Commerce, you need to first enable Beta Preview in the same group, then log out and log in again.
- Close the page.
Set up the publication
The integration follow the idea of the publications. So data are synchronize from the publications, and the publication needs to be set it correctly. More details about Publications.
We offer a configuration package for the default setup of the Pimics - Sana integration. Please import it.
Publication Structure Type in tab Control has to be Single Item. External Code has to be named of the web shop in Sana. Export Channel has to have Sana Commerce in Publication Type. Read more about channels.
Go to Publication Groups and select the Sana Item Publication Group. In the group setup, configure the following rule in the Publication Rule section:
- Type = Field Contains a Value
- Set the parameters as described: Table No. = 27, Field No. = 11123302, Value = 1
After closing the window, the rule should look like this: "Only items where the field "Visible in Webshop" contains the value "1" will be included.
We also recommend setting the publication to be updated in the background. Read more about job queues for publications.
Setup in Sana Commerce
The integration is delivered as an add-on package. Please, follow the instructions of Sana to get the add-on installed.
After the installation of the add-on, you can set the connection.
PRECONDITIONS
Pimics add-on needs to be installed into Sana Commerce Cloud. You need to have an application in Microsoft Entry Id and know Tenant Id, Client Id and Client Secret, with permission to Business Central API. You have a valid configuration for Sana Store and BC. Follow Sana's documentation
- Open Business Central. Choose the Search icon (or use Alt + Q), enter Microsoft Entra Applications, then choose the related link.
- Select your Client Id
- If the client Id is not listed you need to create a new one, these fields are important:
- Client Id is the client id from Microsoft Entry Id
- set Description to Pimics
- set State to Enabled
- If the client Id is not listed you need to create a new one, these fields are important:
- The application needs to have permissions to read Pimics. In User Permission Sets create a new line
- Select PIMX USER in Permission Set
- Select a company with data for Sana Commerce in field Company
- Close Business Central
- Open Sana Commerce Administration (https://{yoursanastore.something}/admin)
- Go to App Center -> Apps
- Select tab Custom Apps
- If there is no Pimics Connector 0.0.0 add-on you need to install it first
- Open a configuration of Pimics add-on
- Web Service URL (Business Central) is a link to web service of Pimics Codeunit.
-
Important
We use OData V4 end-point, so the URL is not the same as you can see in Business Central under SOAP URL. It needs to follow Microsoft praciticies for ODataV4
- cloud:
https://api.businesscentral.dynamics.com/v2.0/{tenantId}/{enviromentName}/ODataV4/PimicsSC_Service?company={companyName} - on-premise:
https://{address}:{port}/{instance}/ODataV4/PimicsSC_Service?company={companyName}&tenant={tenant}Note
company and tenant have not required it depends on your configuration.
-
- Fill up your client ID in fields Client Id or BC User and Client id (SharePoint)
- Fill up your secret in fields Client Secret or BC web key and Client Secret (SharePoint)
- Fill up your tenant ID in field Tenant Guid
- Set Refresh only items changed in ERP to Yes
- Keep Use Basic instead of OAuth as No
- Close the configuration by action Save changes
- Web Service URL (Business Central) is a link to web service of Pimics Codeunit.
- Enabled the add-on
Only OAuth (Bearer/Microsoft Entry ID) and Basic authentication are supported right now. If you use Basic authentication, you need to align configuration and provide user and password instead of client ID and client secret. For Basic authentication the field Use Basic instead of OAuth needs be set to Yes. SharePoint supports only OAuth, so put there any working client ID and set up Pimics the way that it will send public links instead of SharePoint links.
Synchronize Categories
Categories from Pimics are synchronized using process Configure categories from ERP in Sana Admin.
- Open Sana Commerce Administration (https://{yoursanastore.something}/admin)
- Go to Setup -> Navigation
- Select Edit on Main navigation
- In tab Items select Configure categories from ERP
- Run synchronization by
- Selecting Import from ERP if there is no category
- Selecting Re-import all available categories if you have already a category

Additional Info
All the communication between Sana and Pimics is tracked and saved in Pimics Activity Log.