AgentRail. An AI-agent friendly layer for websites AgentRail launched a Cloudflare edge layer that serves deterministic Markdown responses to known AI agents from the same URLs humans browse, eliminating the need for separate AI-optimized endpoints. The open-source tool uses a background crawler to extract and cache Markdown in KV storage, returning it on subsequent agent requests without adding latency to human visitors. AgentRail is a Cloudflare edge layer that gives known AI agents deterministic Markdown responses from the same URLs humans already visit. php Browser or search crawler - /pricing - origin HTML Known AI agent - /pricing - generated Markdown if ready Known AI agent - /pricing - origin HTML if Markdown is unavailable The crawler runs in the background. Request handling never waits for extraction, so cache misses fall through to the original site without adding generation latency. When a known AI agent requests a page that is not in KV yet, AgentRail returns the origin page and uses ctx.waitUntil to warm KV from that same origin response. A later AI-agent request can then receive the prepared Markdown. php flowchart TD browser "Human browser" -- worker "Cloudflare Worker route" search "Search crawler" -- worker ai "Known AI agent" -- worker worker -- classify{"Classify request"} classify -- |"Browser, search crawler, unknown bot, asset, or non-GET/HEAD"| origin "Origin website HTML" classify -- |"Known AI agent"| kvcheck{"KV record exists?"} kvcheck -- |"ready or fresh stale"| markdown "Return deterministic Markdown" markdown -- headers "text/markdown + x-ai-response-layer" kvcheck -- |"missing"| originfetch "Fetch origin HTML" originfetch -- firstbot "Return origin HTML to first bot" originfetch -- waituntil "ctx.waitUntil warmup" waituntil -- extract "Extract deterministic Markdown" extract -- store "Store page: