telegram-mcp
Allows interacting with Telegram as a user account, reading private chats, sending messages and files, searching messages and public channels, managing contacts, and drafting replies in the user's style.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@telegram-mcplist my recent unread chats"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
telegram-mcp
Your Telegram account in an MCP client. Signs in as you, not as a bot: it reads your private chats, and anything it sends comes from you.
Install
Node 22+.
Get API keys: my.telegram.org → API development tools → create an app (platform
Other, rest blank) → copy api_id and api_hash.Sign in — once, in a terminal:
TELEGRAM_API_ID=... TELEGRAM_API_HASH=... npx @vkruglikov/telegram-mcp loginIt asks for your phone, the code Telegram sends, and your 2FA password if you have one. This is a terminal command and not a tool on purpose — as a tool, the code and the password would pass through the model's context and land in chat logs.
Register the server:
claude mcp add telegram \ --env TELEGRAM_API_ID=... \ --env TELEGRAM_API_HASH=... \ -- npx -y @vkruglikov/telegram-mcpClients that read a JSON config instead:
{ "mcpServers": { "telegram": { "command": "npx", "args": ["-y", "@vkruglikov/telegram-mcp"], "env": { "TELEGRAM_API_ID": "...", "TELEGRAM_API_HASH": "..." } } } }Check:
npx @vkruglikov/telegram-mcp status.
logout revokes the session server-side and deletes it locally.
Related MCP server: Telegram MCP Server
Features
Your account:
| Dialogs, newest first, or only unread |
| Find a dialog by name — |
| Read a chat. Does not mark it read |
| Full-text, one chat or the whole account |
| Delivered immediately, no undo |
| Save an attachment |
| The only tool that marks anything read — the other side sees it |
| Saved contacts |
All of Telegram, not just your chats:
| Channels, groups and people you have never opened |
| Text of every public channel. A few free searches a day; the result says how many are left |
Prompts, shown as slash commands: personalize, draft_reply, catch_up.
Drafting in your voice
Run
/personalize. It callssample_my_messagesto collect messages you sent in recent private chats, then describes the patterns: languages and how you mix them, message length, greetings and sign-offs, punctuation you skip, which emoji and where, recurring phrasings, how formality shifts, and what you never do.It shows the profile before saving. Edit or reject it.
Saved to
~/.telegram-mcp/style.md. Reconnect the server to load it./draft_reply <chat> [intent]writes in that voice and shows the draft. It never sends.
get_style_profile prints the profile, forget_style_profile deletes it.
The profile covers how you write, not what you think. Facts, opinions and commitments stay yours to supply.
Everything stays on your machine
Local process, straight to Telegram, no service in between. Everything lives in
~/.telegram-mcp:
session.db— your login sessionstyle.md— your style profile, if you made onedownloads/— downloaded attachments
No telemetry, no account of ours, no third party. Credentials, session and messages go nowhere else.
Treat session.db like a password. It grants full access to your account without the
password and without 2FA. Never copy it to another machine or into a repo. If it leaks,
revoke it in Telegram → Settings → Devices. Deleting the folder by hand revokes nothing —
use logout.
License
MIT
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/vkruglikov/telegram-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server