cf markdown agents
/install cf-markdown-agents
Cloudflare Markdown for Agents
This skill enables fetching web content using Cloudflare's Markdown for Agents protocol, which automatically converts HTML pages to clean, structured Markdown format.
What is Markdown for Agents?
Cloudflare's Markdown for Agents is a content negotiation feature that:
- Automatically converts HTML to Markdown at the edge
- Reduces token usage by ~80% compared to raw HTML
- Returns clean, structured content perfect for AI processing
- Adds
x-markdown-tokensheader showing estimated token count - Includes
Content-Signalheaders for AI usage permissions
Usage
Basic Fetch
Use the provided script to fetch any URL with Markdown for Agents support:
scripts/fetch-markdown.sh \x3CURL>
Example:
scripts/fetch-markdown.sh "https://developers.cloudflare.com/agents/"
In Code
TypeScript/JavaScript example:
const response = await fetch("https://example.com/page", {
headers: {
Accept: "text/markdown, text/html",
},
});
const tokenCount = response.headers.get("x-markdown-tokens");
const markdown = await response.text();
cURL example:
curl https://example.com/page -H "Accept: text/markdown"
Response Headers
content-type: text/markdown; charset=utf-8- Content is Markdownx-markdown-tokens: \x3Cnumber>- Estimated token countcontent-signal: ai-train=yes, search=yes, ai-input=yes- Usage permissions
Supported Sites
Any site using Cloudflare with Markdown for Agents enabled:
- Cloudflare Developer Documentation (developers.cloudflare.com)
- Cloudflare Blog (blog.cloudflare.com)
- Any site with the feature enabled in Cloudflare dashboard
Benefits
| Aspect | HTML | Markdown |
|---|---|---|
| Tokens | 16,180 | 3,150 |
| Reduction | - | ~80% |
| Structure | Complex | Clean |
| AI Parsing | Hard | Easy |
References
- Full protocol details: references/protocol.md
- API examples: references/examples.md
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install cf-markdown-agents - After installation, invoke the skill by name or use
/cf-markdown-agents - Provide required inputs per the skill's parameter spec and get structured output
What is cf markdown agents?
Fetch web content using Cloudflare's Markdown for Agents protocol. Automatically converts HTML to Markdown with 80% token reduction. Use when fetching web pa... It is an AI Agent Skill for Claude Code / OpenClaw, with 227 downloads so far.
How do I install cf markdown agents?
Run "/install cf-markdown-agents" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is cf markdown agents free?
Yes, cf markdown agents is completely free, licensed under MIT-0. You can download, install and use it at no cost.
Which platforms does cf markdown agents support?
cf markdown agents is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).
Who created cf markdown agents?
It is built and maintained by xinian5216 (@xinian5216); the current version is v1.0.0.