Skip to main content
Skip table of contents

Product information sync

Triggering product_information_sync

Product information sync directive is fired on a schedule every 1 hour. It requests information for products specified in the directive request body.

Expected data from sync

We’re expecting a subset of information on the product, which is going to extend in the future.

Here are the attributes that are expected with log of changes below.

CODE
{
  price: Int,
  compare_at_price: Int
}
  • 1.0 - Initial batch

Servicing the directive

product_information_sync directive comes with data. It provides Katalys product id and the external_id associated with the id. This is the identifier from the integration.

Format of the request data:

JSON
{
  "directives": [
    {
      "args": {
        "product_ids": [
          {
            "id": product_id,
            "external_id": external_product_id
            "variants": [
              {
                "id": variant_id,
                "external_id": external_variant_id
              }
            ]
          }
        ]
      },
      "directive": "product_information_sync"
    }
  ]
}

Use external_id to identify the correct product on the store and attach data needed for the sync. It is specified in the section above.

Minimal response must include expected data and Katalys id inside the attribute id.

Format of the response data:

CODE
{
  "results": [
    {
      "data": [
        {
          "id": "katalys_product_id",
          "variants": [
            {
              "id": "katalys_variant_id",
              "compare_at_price": Int,
              "currency": "currency",
              "price": Int
            },
            {
              "id": "katalys_variant_id",
              "compare_at_price": Int,
              "currency": "currency",
              "price": Int
            },
          ]
        },
        {
          "id": "katalys_product_id",
          "variants": [
            {
              "id": "katalys_variant_id",
              "compare_at_price": Int,
              "currency": "currency",
              "price": Int
            },
          ]
        }
      ],
      "source_directive": "product_information_sync",
      "source_id": "directive_id",
      "status": "ok"
    }
  ]
}

Note

  1. There can be multiple Katalys Products with the same external_id. That’s why Katalys ID is required in the response.

  2. A Katalys Product has an ID that is unique in the Katalys' database

  3. A Katalys Product has an external_id that is unique in the Merchant’s database

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.