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/22syn/telegram-user-mcp/claude-mdgit clone --depth 1 https://github.com/22syn/telegram-user-mcpWrote 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/22syn/telegram-user-mcp/claude-md)<a href="https://agentmods.dev/instructions/22syn/telegram-user-mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/22syn/telegram-user-mcp/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.00648 | $0.00648 |
| Opus 5 | $0.00324 | $0.00324 |
| Sonnet 5 | $0.00130 | $0.00130 |
| Haiku 4.5 | $0.00065 | $0.00065 |
Grade A, and why
telegram-user-mcp CLAUDE.md scanned grade A with 0 findings 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 4d 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.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
CLAUDE.md — telegram-mcp
📋 Active plan (2026-07-23): docs/plans/2026-07-23-graph-audit-followup.md — graph-audit follow-up; review before structural changes. 📋 Improvement plan (2026-07-23): docs/plans/2026-07-23-improvement-plan.md — the PRD's own prompt-injection safeguard was never implemented, add before any write capability.
Purpose An MCP (Model Context Protocol) server that connects to Telegram as a real user account (MTProto via GramJS), exposing read-only tools to MCP clients (Claude Desktop, Cursor, etc.): read & search messages, list chats/folders, inspect group info, get pinned messages, and download media. Because it authenticates as the user, it can see everything the account can — private channels, groups, and DMs a bot cannot.
Stack
- Node.js ≥18, CommonJS (plain JS, no build step)
@modelcontextprotocol/sdk— MCP server frameworktelegram(GramJS) — MTProto clientinput— interactive CLI prompts during setup
Structure
server.js— the MCP server; implements all tools (main entry,mainfield)setup.js— one-time interactive login (api_id,api_hash, phone, 2FA)cli.js—binentry (telegram-user-mcp), dispatches setup vs. serverdocs/— additional documentationLICENSE(MIT),README.md
Run / dev
npm run setup(ornpx telegram-user-mcp setup) — one-time loginnpm start— run the MCP server (node server.js)- Register in an MCP client via
command: npx,args: ["-y", "telegram-user-mcp"]
Conventions / notes
- All tools are read-only (reading, search, discovery, media info/download). No sending/posting.
groupUrlargs accept ahttps://t.me/...link,@username, or numeric id (fromlist_dialogs).- Config in
~/.telegram-mcp-config.json(apiId,apiHash,phoneNumber, optionaldownloadDir,maxDownloadMB). Login session in~/.telegram-mcp-session— grants full account access; treat as a password, never commit/share. Media downloads land in~/.telegram-mcp-downloads/. download_mediarefuses files overmaxDownloadMB(default 200) unlessmaxMBoverrides; useget_thumbnailto preview heavy videos cheaply.- Get
api_id/api_hashfrom https://my.telegram.org → API development tools.
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.
- 4d ago First seen · 33 lines · 648 tokens per session scan A d505aeaefa39
telegram-user-mcp CLAUDE.md is an instructions file published in the GitHub repository 22syn/telegram-user-mcp (0 stars, last pushed 12d ago), licensed MIT. It adds 648 tokens to every session, about $0.0032 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).