Skip to main content
To ensure optimal performance and minimize load on connected systems, all data retrieved through the Chift API is temporarily cached on our side. Here’s how caching works and how to use it safely.

How Caching Works

  • Cache Duration: Data retrieved via the API is cached for a maximum of 5 minutes.
  • Refreshing Cached Data: When new data is fetched (e.g., retrieving a later page of results), the cache is updated and the 5-minute lifetime is reset.
  • Scope: Caching applies to all GET requests, including paginated responses. The cache may contain more items than the page requested to reduce the number of calls made to the source system. For connectors that support bigger page sizes than the ones served by Chift, optimizations are made to reduce the number of requests. This can lead to multiple pages worth of data being cached from the first page requested. When non-cached data is requested, already cached data has its lifetime reset to ensure consistency with the newly fetched data.

Forcing a Refresh

In cases where fresh data is required immediately—such as after creating a new object—you can bypass the cache using the x-chift-force-refresh HTTP header:
GET /journals
x-chift-force-refresh: true
The response fetched with this header is also cached.
A typical workflow using this header looks like this:
  1. Get Journals (without header)
  2. Create Journals
  3. Get Journals (with x-chift-force-refresh header)

Important Considerations

  • The x-chift-force-refresh header should only be used in specific scenarios, such as retrieving data immediately after creating a new object.
  • Using this header indiscriminately can impact API performance. Chift reserves the right to temporarily block excessive calls that misuse this header.
  • In general, relying on cached responses is recommended to ensure consistent performance and minimize load on both Chift and connected systems.