Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add instructions/fastly/mcp/agents-mdgit clone --depth 1 https://github.com/fastly/mcpWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00801 | $0.00801 |
| Opus 5 | $0.00400 | $0.00400 |
| Sonnet 5 | $0.00160 | $0.00160 |
| Haiku 4.5 | $0.00080 | $0.00080 |
Grade A, and why
mcp AGENTS.md scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
- debug: `FASTLY_API_TOKEN=your-token bun run start`; `FASTLY_API_TOKEN=your-token bun run start:node`; `FASTLY_API_TOKEN=your-token bun run start:http`; `FASTLY_API_TOKEN=your-token FASTLY_MCP_HTTP_AUTH_TOKEN=dev-token How it starts
The opening of the file, as written. The whole thing — 31 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Workflow
- install:
bun install - test all:
bun test - test file:
bun test <test-file> - test case:
bun test <test-file> -t "<test-name>" - lint:
bun run lint - format:
bun run format - after every edit:
bun test && bun run lint - debug:
FASTLY_API_TOKEN=your-token bun run start;FASTLY_API_TOKEN=your-token bun run start:node;FASTLY_API_TOKEN=your-token bun run start:http;FASTLY_API_TOKEN=your-token FASTLY_MCP_HTTP_AUTH_TOKEN=dev-token bun run src/index.js --transport http;curl http://127.0.0.1:8231/healthz
Conventions
- Keep the public MCP surface to
search,inspect, andexecute; do not add one tool per Fastly API endpoint. The expected assistant flow is search first, inspect for call details, then execute focused JavaScript. executesnippets must usereturn; console output is captured separately and is not the result. Fastly client methods return values directly, not inside.result.- Prefer sandbox globals like
serviceApi,statsApi,purgeApi, andtlsCertificatesApiovernew Fastly.ServiceApi()in examples and generated usage. searchresults stay compact: discovery fields only, with fulldescription,params,returnType, andexamplereserved forinspect.searchandinspectmust work withoutFASTLY_API_TOKEN; real API calls throughexecuteneed it.- Everything thrown inside the sandbox, on either side of the host bridge, goes through
describeThrowninsrc/errors.js. The Fastly client rejects with a plain object rather than anError, soString(err)or a bareerr.messagesilently turns a 401 into[object Object]. Failures reach the model as{error, status, statusText, body, hint}. - When secret encryption is enabled, decrypt input strings before handlers and re-encrypt text output before returning it.
- HTTP defaults are loopback
127.0.0.1, port8231, path/mcp, andautoresponse framing;--http-jsonand--http-ssepin the framing and are mutually exclusive, and non-loopback/network binds require auth. Both flags reach the 2026 leg only — the 2025 fallback always answers with SSE. - The server speaks the
2026-07-28revision plus the 2025 family. There are no sessions in either era:createMcpHandlerserves the modern path and falls back to per-request stateless serving for 2025 clients, both off the samecreateMcpServerfactory. - Modern requests must carry
Mcp-Method(andMcp-Nameontools/call); the server rejects a request whose headers and body disagree. Keep those two on the CORS allow-headers list. docs/*Api.mdare generated inputs to the runtime index. Regenerate withbun run update-docsrather than hand-editing generated API docs.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 31 lines · 801 tokens per session scan A e9d13f183589
mcp AGENTS.md is an instructions file published in the GitHub repository fastly/mcp (39 stars, last pushed 14d ago), licensed MIT. It adds 801 tokens to every session, about $0.0040 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other instructions, from other repositories
inspector copilot-instructions.md
Copilot instructions for modelcontextprotocol/inspector, covering copilot review instructions — mcp inspector, typescript, react and ui (web client), the .withprops() rule and state and effects.
imageflow CLAUDE.md
Claude Code instructions for imazen/imageflow, covering imageflow project instructions, simd & dispatch crates, f32/f64 clamping, git workflow and test commands.
inspector CLAUDE.md
Claude Code instructions for modelcontextprotocol/inspector, a project described as: Visual testing tool for MCP servers.
mcp-logic GEMINI.md
Instructions for angrysky56/mcp-logic, covering mcp-logic — project guide (gemini/antigravity), project summary, active milestone, gsd workflow and architecture quick reference.
sleek-ui AGENTS.md
AGENTS.md instructions for luongnv89/sleek-ui, covering agents.md, critical commands, architecture map, hard rules and workflow preferences.
sleek-ui CLAUDE.md
Claude Code instructions for luongnv89/sleek-ui, covering sleek-ui, tech stack, critical commands, architecture map and hard rules.