telegram-mcp
Provides read-only access to Telegram messaging data, including ability to fetch unread messages, search chats, and retrieve message history for a given chat.
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-mcpshow my recent unread messages"
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 (движок)
Read-only MCP-читалка своей Telegram (self-host, Telethon). Открытый движок — актив бренда aiaiai. Session живёт на устройстве (keychain), наружу не уходит. v1 = читалка; write-методы не выставлены.
Дизайн и решения — в umbrella-репо telegram-mcp-hosted (docs/decisions.md, architecture.md, build-plan.md).
Раскладка
telegram_mcp/
server.py # entrypoint: FastMCP + авто-дискавери tools/
_app.py # единый FastMCP-инстанс (mcp)
config.py # app-креды (BYO env/.env; broker позже)
qr_render.py # ASCII-QR полублоками (обкатан в спайке) ✅
session_store.py # SessionStore: keychain+Fernet — интерфейс (impl = T2)
client.py # get_client() -> авторизованный TelegramClient — интерфейс (impl = T3)
auth.py # QR-login + 2FA — интерфейс (impl = T4)
tools/
_base.py # mcp, get_client, общие хелперы — единая точка импорта
*.py # по тулу на файл, саморегистрация через @mcp.tool (стабы T5–T12)Related MCP server: telemcp
Контракт для авторов тулзов (Wave 1, T5–T12)
Файл тула начинается с
from telegram_mcp.tools._base import mcp, get_client.Регистрация —
@mcp.tool(FastMCP берёт сигнатуру+докстринг в схему). Центрального списка НЕТ — добавил файл, тул появился (авто-дискавери).В Telegram — только через
await get_client().read-only: только
get_*/iter_*/download_*. Ни одного write-вызова.Возвращай JSON-сериализуемое (dict/list), не объекты Telethon.
Трогаешь только свой файл. Не редактируешь
pyproject,server.py,_base.py,_app.py(нужна общая утилита/зависимость → флаг в интеграцию T16). Свой git worktree.
Установка (self-host)
# 1. поставить как CLI (uv сам тянет нужный python ≥3.10)
uv tool install git+https://github.com/expremiental/telegram-mcp
# 2. залогиниться — отсканировать QR своим Telegram
# (app-креды берутся с брокера автоматически, ничего на my.telegram.org создавать не надо)
telegram-mcp login
# 3. подключить в Claude Code / Cursor
claude mcp add -s user telegram-mcp -- telegram-mcp serveПерезапусти хост → спрашивай обычным языком: «сделай дайджест непрочитанного», «найди чат с …», «что писали в … за сегодня».
read-only — выставлены только read-тулзы; ничего не отправляет/не меняет.
session шифрованная в keychain, машину не покидает. Сброс:
telegram-mcp logout.BYO-креды (advanced):
TELEGRAM_API_ID/TELEGRAM_API_HASHв окружении переопределяют брокер.
Dev
uv venv --python 3.12 .venv && uv pip install -e . --python .venv
.venv/bin/telegram-mcp serve # сервер (stdio) · login / logout — онбордингТребует Python ≥3.10 (FastMCP).
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityCmaintenanceA read-only MCP server that lets AI agents read personal Telegram chats from an allowlist of folders, with no send/edit/delete capability.Last updated27MIT
- Alicense-qualityAmaintenanceAn MCP server that gives AI assistants read-only access to your personal Telegram account via MTProto, enforcing a whitelist of allowed chats and never marking messages as read.Last updatedMIT
- Alicense-qualityBmaintenanceAn MCP server that connects to Telegram as your real user account and exposes read-only tools to read and search messages, list chats and folders, inspect group info, and download media.Last updated20MIT
- Alicense-qualityAmaintenanceRead-only MCP server for Telegram that enables reading messages and transcribing voice, audio, and video notes via the Telegram API for use with Codex and Claude Code.Last updatedApache 2.0
Related MCP Connectors
Read-only MCP server for ClassQuill, a tutoring-business-management platform.
Read-only MCP server for Robinhood Chain token discovery, research, and due diligence via GMGN.
Agent-native MCP server over the public saagarpatel.dev corpus. Read-only, stateless.
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/expremiental/telegram-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server