How can we help?



The products collection contains all product data related to your product catalog(s). Product data can be used to personalize message content.

The most common product-related attributes are provided by default as part of the schema, including product name, category, price, and other related data. Some attributes are set as arrays and can include customizable name/value pairs such as color:blue and size:large.

How Cordial stores products

Product records are stored in the products collection as JSON objects. Below is a simple example of how a product is stored in Cordial. It shows the standard fields of productID, productName, and price, as well as an array of variants containing the SKU and product attributes.

    "productID": "skirt0912",
    "productName": "Denim Skirt",
    "price": 19.99,
    "variants": [
        "sku": "skirt0912",
        "attr": {
          "color": "blue",
          "size": "8"

Import products

Product catalogs are loaded into Cordial via API.

In addition to Cordial's API, product data can be added by the JavaScript Listeners on your website. The crdl(cartitem) method adds data about the products placed in the shopping cart by site visitors. Similarly, the crdl(order) method adds data associated with a purchase event, including the supplied product details.

Products are automatically added to the products collection when an order event is received. This allows marketers to take advantage of product data without having to import an entire product catalog.

View products

You can view your product data in the UI or via API call.

1. To view a product collection in the UI, log in to Cordial and navigate to Data > Product Data. You'll see a list of all the products in the collection. Depending on your preference, you can view products in thumbnail or table view.

2. To view details of each product in JSON format, hover over the arrow in the product row (or thumbnail) and click Details.

Use products in a message

Message content can be personalized with products from your catalog using the Smarty getProducts method.

Use case

You could use this method to send contacts messages showing items on sale, recently added products, or products relevant to their purchase and/or site browsing history.

Display products in a message based on past orders

When displaying products in a message based on an order, we recommend that you use product data from the product catalog as opposed to product data from the order. This is because product catalog data (branding, images, and descriptions) may be more up to date than product data stored with an order that happened in the past.

Use case

You could send a message to a contact who ordered a product last year. If you update your product catalog on a regular basis, the product images may be different at the time the message is sent. Using Smarty, you can reference the product ID from an order and connect that to the product data stored in the product catalog. This way you can display the most recent updates to the product.


In the next article, you can learn about orders.



Please sign in to leave a comment.