Usage

Caching

Multi-layer caching architecture, response headers, and purge policy

Caching Architecture

Assets API uses a multi-layer caching strategy for maximum performance:

Browser  ──▶  Edge CDN  ──▶  Memory Cache  ──▶  Disk Cache  ──▶  Transform + Store
 1yr          1yr immutable          200 MB / 30min      Persistent       On-demand
LayerTTLSizeNotes
Browser1 year (max-age=31536000, immutable)Use c param for cache busting
Edge CDNFollows Cache-ControlGlobal edge distribution
In-memory (originals)5 minutes100 MBHot originals
In-memory (processed)30 minutes200 MBHot transformed variants
Disk cache (processed)PermanentStored in processed-assets container

Response headers

HeaderExampleMeaning
Cache-Controlpublic, max-age=31536000, immutableCached forever at all layers
ETag"a1b2c3..."Content-based hash for conditional requests
X-CacheMEM / DISK / PROCWhere the response was served from
Content-Typeimage/webpOutput format

Copyright © 2026