The Emarsys for Demandware integration uses several custom objects to store the saved configurations for newsletter subscriptions, external events defined on the Emarsys side, transactional emails configuration, initial DB load, and Emarsys profile fields.

There are also several custom site preferences attributes used to define the Demandware fields that appear in the Emarsys Business Manager extension – these custom attributes are used to define the values that will appear in the dropdowns from the configuration screens.

Contents

Custom objects

  • EmarsysExternalEvents – This is used to store the external events defined in the Emarsys platform. This custom object is automatically populated after the Emarsys-Setup workflow schedule is run.
  • EmarsysNewsletterSubscription – This is used to store the configuration for each newsletter subscription type (global footer subscription, checkout subscription, and My Account subscription). Instances of this custom object are created on the fly, when you configure the newsletter subscriptions using the Emarsys Business Manager extension.
  • EmarsysTransactionalEmailsConfig – This is used to store the configurations for Emarsys transactional emails. There will be two instances of this custom object, which will be created automatically when you save the configurations for order and shipping confirmation emails through the Business Manager extension.
  • EmarsysDBLoadConfig – This is used to store the mapping between Demandware and Emarsys fields for the initial DB load. There will be only one instance of the custom object, which will be automatically created when you save the initial DB load mapping through the Business Manager extension.
  • EmarsysProfileFields – This is used to store the Emarsys profile fields. It’s automatically populated after the Emarsys-Setup workflow schedule has finished running.

Custom site preference attributes

  • emarsysOrderConfirmationElements – The JSON used to define the Demandware available fields that can be added to the order confirmation emails.
  • emarsysShippingInformationElements – The JSON used to define the Demandware available fields that can be added to the shipping confirmation emails.
  • emarsysDBLoadAttributes – The JSON used to define the Demandware available fields that can be added to the .csv file that is generated for the initial DB load.
  • emarsysSingleChoiceValueMapping – The JSON used to store all Emarsys single choice fields and the available values for each field. This attribute is used when creating the Emarsys auto-import profile for the initial DB load, and is automatically populated after the Emarsys-Setup workflow schedule has finished running.
  • emarsysContactFieldsMap – The JSON used to define the mapping between several Demandware fields and the corresponding IDs for these fields on the Emarsys side.

Predict custom object

Emarsys Predict uses the EmarsysPredictConfig custom object type to store the list of field mappings for the Predict configuration. This custom object is updated automatically when configs are set up in Predict Business Manager extension.

Example of generated mapped fields:

{"field":"product.ID","placeholder":"item"},{"field":"product.availability","placeholder":"available"},{"field":"product.name","placeholder":"title"},{"field":"product.url","placeholder":"link"},{"field":"product.image","placeholder":"image"},{"field":"product.categories","placeholder":"category"},{"field":"product.price","placeholder":"price"}]

Smart Insight custom object

Smart Insight uses the EmarsysSmartInsightConfiguration custom object type to store the list of field mappings for the Smart Insight configuration. This custom object is updated automatically when configs are set up in Smart Insight Business Manager extension.

Example of generated mapped fields:

{"field":"order.orderNo","placeholder":"order"},{"field":"product.ID","placeholder":"item"},{"field":"product.quantity","placeholder":"quantity"},{"field":"order.customerEmail","placeholder":"c_email"},{"field":"order.totalGrossPrice","placeholder":"c_sales_amount"},{"field":"order.creationDate","placeholder":"date"}

Predict and Smart Insight site preferences

The table below contains the list of Site Preferences for Emarsys Predict and Smart Insight.

Custom attribute Type Description
emarsysPredictMerchantID String Your Predict merchant ID, used to enable the JavaScript tracking code, recommendations, etc. This can be found on the Account Details section of the Predict Dashboard in your Emarsys account.
emarsysPredictEnableJSTrackingCode Boolean This enables/disables the JavaScript tracking code.
emarsysPredictThankYouForOrderPageRecommendationType Enum Of Strings This selects recommendation widget type to show on storefront "thank you for your order" page.
emarsysPredictPDPRecommendationType Enum Of Strings This selects recommendation widget type to show on storefront PDP.
emarsysPredictHomePageRecommendationType Enum Of Strings This selects the recommendation widget type to show on storefront home page.
emarsysPredictCartPageRecommendationType Enum Of Strings This selects the recommendation widget type to show on storefront cart page.
emarsysPredictSearchPageRecommendationType Enum of Strings This selects the recommendation widget type to show on storefront search page.
emarsysPredictCategoryPageRecommendationType Enum of Strings This selects the recommendation widget type to show on storefront category page.
emarsysPredictVariationAttributes Set of String A list of product variation attributes for the Predict Feed.
emarsysPredictSFTPHost String The Predict SFTP host.
emarsysPredictSFTPUsername String The Predict SFTP username.
emarsysPredictSFTPPassword Password The Predict SFTP password.
emarsysPredictSFTPPath String This represents the Predict SFTP path.
emarsysPredictProductAttributes Set Of String The mandatory attributes: item, available, title, link, image, category (path), price for catalog export.
emarsysPredictIMPEXFolder String The Emarsys Predict export folder relative to IMPEX/src/.
emarsysSmartInsightOptIn Boolean This enables Smart Insight.
emarsysSmartInsightDestinationFolder String This sets the destination folder for export.
emarsysEnableSmartInsightTimeframe Boolean This enables the timeframe for exported orders.
emarsysSmartInsightAvailableElements Set Of String A list of the Smart Insight Available Elements.
emarsysSmartInsightTimeframeStart Date This sets up the timeframe start date for the Emarsys historical export job.
emarsysSmartInsightTimeframeEnd Date This sets up the timeframe end date for the Emarsys historical export job.
emarsysSFTPHost String The Emarsys SFTP hostname.
emarsysSFTPUsername String The Emarsys SFTP username.
emarsysSFTPPassword Password The Emarsys SFTP password.