API Caching
Learn how API Caching stores cacheable API responses at the CDN edge to reduce latency, improve scalability, and decrease origin load.
API Caching stores cacheable API responses on CDN edge servers, allowing repeated requests to be served without contacting the origin. This reduces response times and backend processing for APIs that return identical responses to multiple clients.
For content such as HTML pages and other dynamically generated website resources, see Dynamic Content Acceleration.
Understanding API Caching
Unlike static assets, API responses are typically generated by backend services. However, many APIs produce identical responses for multiple requests during short time periods.
API Caching allows these responses to be temporarily stored at the CDN edge and reused until the configured cache policy expires.
For static assets such as images, CSS, JavaScript, fonts, and downloadable files, see Static Content Delivery.
Typical examples include:
Product catalogs
Public content APIs
Exchange rates
News feeds
Search suggestions
Configuration endpoints
How API Caching works
A client sends a request to an API endpoint.
The request reaches the nearest Medianova edge server.
The CDN checks whether a valid cached response exists.
If a cache hit occurs, the cached response is returned immediately.
Otherwise, the request is forwarded to the origin.
The origin response is cached according to the configured cache policy.
Subsequent matching requests are served from the CDN until the cached response expires.
Benefits
API Caching can help:
Reduce response latency
Decrease origin requests
Lower backend processing
Improve scalability during traffic spikes
Increase cache efficiency for repetitive requests
When to use API Caching
API Caching is well suited for:
Read-heavy APIs
Frequently requested public data
Responses that change at predictable intervals
High-volume endpoints shared by many users
Avoid caching:
Authentication endpoints
Checkout workflows
User-specific responses
Session-dependent APIs
Real-time transactional operations
To configure API caching behavior for a CDN Resource, see Dynamic CDN Resource.
Last updated
Was this helpful?