The Guide

Tracking the changes in Product Data

Keep up to date

All catalog endpoints are responding with an X/Catalog/Last-Update-Timestamp header that shows you current version of the provided product data. Whenever we are updating parts of the provided product data, the X/Catalog/Last-Update-Timestamp value will change. Moreover we using an ETag header with an hash value to identify an OKAPI response. If the response changes through new product data the ETag header will be changed.

Response header:

X/Catalog/Last-Update-Timestamp ETag
Value: Timestamp UTC Value: Unique Hashcode
Identifies catalog product data with value Identifies an OKAPI response with value
Example: Fri, 31 Jul 2020 02:41:18 UTC Example: e3c780bf6e4a11b8

Same request processed after a given time interval. In between action X is happening.

X1: New data in OKAPI for requested endpoint(ETag change + Timestamp change)

There is a different response because updated data. Both headers will be affected

X2: New data in Okapi but not listed in requested endpoint(ETag same + Timestamp change)

In this example the ETag header stays the same, because the response body of OKAPI doesn’t changed. The specific product data aren’t visible in the given endpoint. But the Timestamp changes, because there was a new import for this Catalog data.

X3: : No new data in OKAPI(ETag same + Timestamp same)

There is no new data in Okapi.

X4: Using a query parameter(ETag change + Timestamp same)

When catalog endpoints requested with a query parameter the OKAPI response change, but not the catalog data.

Etag in the request:

You can provide the ETag value as request header (if-none-match) and the data has not changed, all catalog resources will respond with the http status code 304 not modified.

Request header:

header description
If-None-Match Your stored ETag hash of a former request.