Skip to main content

JSON product feed

The following steps outline how to get a JSON product feed integrated in Content Studio to be able to browse and select products.

What you'll need
Link copied!

To configure your JSON feed integration in Content Studio you'll need the following:

  • JSON feed URL
  • JSON path to map to the property containing an array of products
  • JSON path for individual product properties:
    • ID/SKU
    • Name
    • Description
    • Image(s)
JSON feed limitations

JSON feeds integrations are primarily aimed at small categories, testing and demoing product data and as a result, these types of feed integrations have some limitations.

  • The JSON feed must be a public URL
  • The JSON feed must be less than 2MB in size

Setting up the Content Studio integration
Link copied!

  • In Content Studio choose the Commerce Repositories icon and click "Add Commerce Repository"
  • Choose "JSON Feed" from the dialog options and add the integration.

Importing a JSON feed

  • Provide the JSON paths for the list of products in the feed and individual product properties (ID, name, description, images).

Default values are available by clicking on each box and selecting the value.

You can use a JSON Path evaluator such as the JSON Path online evaluator to determine the JSON paths for your feed. See JSON feed example for an example feed and configuration. See Determining JSON paths for more details.

Configuring a JSON feed

Once the integration is set up, your product data is available to browse and add when using Content Studio templates such as "Rewrite product description".

Choosing product data to generate content in a Content Studio template

JSON feed example
Link copied!

An example JSON feed is hosted at the following URL.

https://amp-product.s3.eu-west-1.amazonaws.com/content-studio/commerce-repository/product-feed-examples/products.json

The data structure is as follows (showing one product):

{
"products": [
{
"id": "e3b5c192-2f17-433c-b73c-12a7c7e87dc6",
"name": "Handbag Moschino Love white",
"slug": "moschino-love-handbag-JC4235PP0XXJ0100-white",
"variants": [
{
"sku": "A0E2000000021S0",
"prices": {
"list": "256.25",
"sale": "256.25"
},
"images": [
{
"url": "https://cdn.media.amplience.net/s/willow/079310?w=1000"
},
{
"url": "https://cdn.media.amplience.net/s/willow/079310/2?w=1000"
},
{
"url": "https://cdn.media.amplience.net/s/willow/079310/3?w=1000"
},
{
"url": "https://cdn.media.amplience.net/s/willow/079310/4?w=1000"
}
],
"attributes": {
"articleNumberMax": "79310",
"size": "one size",
"color": "white"
},
"listPrice": "256.25",
"salePrice": "256.25"
}
],
"categories": [
{
"id": "dd2a39d9-2b0e-4084-9f8e-eb45246a3dcb",
"parent": {
"typeId": "category",
"id": "d38cf3e8-492a-4da1-ad29-945faae3afbd"
},
"ancestors": [
{
"typeId": "category",
"id": "d38cf3e8-492a-4da1-ad29-945faae3afbd"
}
],
"name": "Women",
"slug": "sale-women"
},
{
"id": "72d8e722-4415-42c2-9c57-b167a173bd7f",
"parent": {
"typeId": "category",
"id": "467e79a2-161a-4a64-9e33-b3054c827d38"
},
"ancestors": [
{
"typeId": "category",
"id": "81cf879f-5597-4c48-8706-f0fc58733313"
},
{
"typeId": "category",
"id": "467e79a2-161a-4a64-9e33-b3054c827d38"
}
],
"name": "Handbag",
"slug": "women-bags-handbag"
}
],
"productType": "f90cb115-f260-4f44-ba46-2a4aeb50ce94",
"imageSetId": "79310",
"lowPrice": "256.25",
"highPrice": "256.25",
"longDescription": "Handbag Moschino Love white"
}
]
}

Example mappings
Link copied!

The JSON path mappings for the attributes are shown below:

AttributeMapping
Products$.products[*]
ID/SKU$.id
Name$.name
Description$.longDescription
Images$.variants[0].images[*].url

Content Studio- generating content