cloudflare · Cloudflare Workers Docs
Workers How the Cache works
Explains the mechanisms for interacting with the Cloudflare cache via the fetch API and the Cache API, including how to customize cache rules, store custom responses, and handle single-file purges.
Derived skill
Files assembled from official documentation
Viewing SKILL.md
Workers How the Cache works
Explains the mechanisms for interacting with the Cloudflare cache via the fetch API and the Cache API, including how to customize cache rules, store custom responses, and handle single-file purges.
When To Use
Use when you need to implement custom caching logic in a Worker, store non-origin responses using the Cache API, or correctly purge specific assets from the Cloudflare edge cache.
Reference Files
| File | Contains | Use For |
|---|---|---|
SKILL.md | Entry point: scope, routing table, and workflow. | Start here. |
docs/workers-how-the-cache-works-index-workflow-guide.md | An overview of how Cloudflare Workers interacts with the global network cache, including purging assets and the differences between edge and browser caching. | Questions about an overview of how Cloudflare Workers interacts with the global network cache, including purging assets and the diffe... |
What This Skill Covers
- Workers was designed and built on top of Cloudflare's global network to allow developers to interact directly with the Cloudflare cache. The cache can provid...
- Main sections:
Interact with the Cloudflare Cache,Single file purge assets cached by a worker,Purge assets stored with the Cache API,Edge versus browser caching,fetch.
Workflow
- Open the most relevant file under
docs/for the exact documented workflow and wording. - Open
schemas/files for exact structured contracts. - Open
examples/files for concrete requests, commands, snippets, and manifests. - Do not add behavior or configuration that is not present in the attached source files.
Canonical source: https://developers.cloudflare.com/workers/reference/how-the-cache-works/index.md
