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/dotneteeer/simpletgchatmcp/claude-mdgit clone --depth 1 https://github.com/dotneteeer/SimpleTgChatMcpWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/dotneteeer/simpletgchatmcp/claude-md)<a href="https://agentmods.dev/instructions/dotneteeer/simpletgchatmcp/claude-md"><img src="https://agentmods.dev/badge/instructions/dotneteeer/simpletgchatmcp/claude-md.svg" alt="Measured on agentmods" height="20"></a>What 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.01969 | $0.01969 |
| Opus 5 | $0.00984 | $0.00984 |
| Sonnet 5 | $0.00394 | $0.00394 |
| Haiku 4.5 | $0.00197 | $0.00197 |
Grade A, and why
SimpleTgChatMcp CLAUDE.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 3d 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.
`curl -F file=@<path> .../api/upload` to move bytes straight from disk, How it starts
The opening of the file, as written. The whole thing — 129 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
What this is
Remote MCP server (Next.js App Router, mcp-handler) exposing Telegram Bot
API methods for a single chat. Stateless multi-tenant: bot token and chat ID
come from the connector's URL query params (token, chat), not from env
vars or storage. See README.md for user-facing setup.
Hosted on Render as a persistent Node server (next start), not serverless - deliberately, since serverless hosts like Vercel cap
request bodies at ~4.5 MB, which truncates (corrupts) large file uploads to
/api/upload above that size. Render's free tier has no such cap and
auto-deploys from GitHub on push (render.yaml). app/api/health/route.ts
exists for Render's health check and for an external keep-alive cron (avoids
the free tier's ~15-min idle spin-down). export const maxDuration = 60 in
route.ts is a leftover Vercel-ism; Render ignores it, harmless to keep.
Architecture
app/api/[transport]/route.ts- the only route. Parsestoken/chat/keyfrom the request URL, optionally gates onMCP_ACCESS_KEY(env), then builds a freshcreateMcpHandlerper request withtoken/chatcaptured in tool closures.lib/telegram.ts- Bot API client.callApifor JSON calls,callApiWithMediafor methods that send a file by URL/file_id(thin wrapper aroundcallApi),callApiWithMediaBytesfor sending file bytes directly as multipart instead of a URL. All three auto-retry once as plain text if Telegram rejects the message due to badparse_modeentities.lib/mdv2.ts-escapeMarkdownV2()helper (not used by tools directly, but exported for callers who want to send literal text safely).lib/upload.ts+app/api/upload/route.ts+app/api/file/[id]/route.ts+app/api/file/[id]/[filename]/route.ts- out-of-band file upload, deliberately plain HTTP, not an MCP tool, and the only way to send a local file - inline base64 was removed from the media schema entirely (it costs output tokens regardless of file size, since the model has to generate the whole file as text; a hypothetical "upload" MCP tool would have the same problem, since the bytes still have to enter the model's output). The upload URL includes the filename (/api/file/<id>/<name>; the bare/api/file/<id>route still works for back-compat) and the response carries aContent-Dispositionheader (lib/serveUpload.ts, shared by both routes) - both needed because Telegram's sendDocument/sendPhoto URL-fetch path rejects some Content-Types (application/octet-stream,application/x-msdownload,text/plain, and others) outright with "failed to get HTTP URL content", confirmed by testing arbitrary extension-less/generic-mime URLs, not just ours - fatal for arbitrary binaries like.bin/.exe/.dll. Because of that,route.ts's media tools (ownUploadIdinlib/upload.ts) detect whenmedia.urlis one of our own upload URLs and, if the entry hasn't expired, send the bytes straight to Telegram viacallApiWithMediaBytesinstead of handing Telegram a URL to fetch - sidesteps the Content-Type gate entirely. Only our own uploads get this treatment; other public URLs still go through Telegram's URL fetch as before. A shell-capable client (Claude Code) runscurl -F file=@<path> .../api/uploadto move bytes straight from disk, gets back a URL, and passes that to the existingmedia.urlfield. Storage is an in-memoryMap(5-min TTL, 200 MB total cap) since files only need to survive until Telegram fetches them; not persisted, no external object store. Upload auth is an HMAC-SHA256(MCP_ACCESS_KEY, "upload-v1") token (?u=), nottoken/chat, because the model never sees those - they live in the connector URL, hidden from the model. The upload URL+token reaches the model via the MCPinstructionsfield (set fromuploadInstructions()inroute.ts,serverOptions.instructions-mcp-handlerpasses it through to the SDK). Only works in shell-capable clients; shell-less ones (Claude.ai web/Desktop) can only send files via a publicurlor an existingfile_id- a client-capability limit, not fixable server-side. Telegram's send cap (any method) is 50 MB./api/file/[id]supports HTTP Range requests (206/Content-Range/416) - needed because Telegram's media fetcher (and others) can probe with a Range request before downloading in full.
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.
- 3d ago First seen · 129 lines · 1,969 tokens per session scan A a434c56cc6b0
SimpleTgChatMcp CLAUDE.md is an instructions file published in the GitHub repository dotneteeer/SimpleTgChatMcp (0 stars, last pushed 7d ago), licensed MIT. It adds 1,969 tokens to every session, about $0.0098 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-31.
Other instructions, from other repositories
Alita_Robot AGENTS.md
AGENTS.md instructions for Divkix/Alita_Robot, covering repository guidelines, 0. maintaining this file, 1. mental model, 2. project structure and 3. build, test, lint.
telegram-search copilot-instructions.md
Copilot instructions for groupultra/telegram-search, covering copilot instructions for telegram-search, architecture essentials, dev workflows, conventions and patterns and where to look for examples.
telegram-search AGENTS.md
AGENTS.md instructions for groupultra/telegram-search, covering project coded agent guide, tech stack (by surface), structure & responsibilities, key path index (what lives where) and commands (pnpm with filters).
telegram-bot AGENTS.md
Instructions for vendelieu/telegram-bot, covering agents.md, dev environment, testing, project structure and key conventions.
telegram-search CLAUDE.md
Claude Code instructions for groupultra/telegram-search, a project described as: 🔍 导出并模糊搜索 Telegram 聊天记录 | Export and fuzzy search your Telegram chat history.
gsd-task-manager copilot-instructions.md
Copilot instructions for vscarpenter/gsd-task-manager, covering copilot instructions for gsd task manager, architecture overview, core stack, database schema (v13) and key architectural decisions.