telegram-mcp
Verified Safeby Sarang-Nambiar
Overview
Enables AI assistants to programmatically interact with Telegram chats for message reading, sending, and management.
Installation
uv run main.pyEnvironment Variables
- TELE_APP_ID
- TELE_HASH
Security Notes
The server loads Telegram API credentials from environment variables, which is good practice. It utilizes the Telethon library for API interaction. There are no explicit uses of `eval`, `exec`, or `os.system` for arbitrary code execution from user input found in the provided code. A critical security aspect is the `anon.session` file created locally, which stores session data; its compromise would grant access to the Telegram account. The `message` parameter in `send_message` is sent directly to Telegram, so an AI generating malicious markdown could potentially create annoying messages, but not execute code on the server itself. Overall, the direct code appears reasonably safe, but relies heavily on the security of the Telethon library and proper protection of the session file.
Similar Servers
better-chatbot
An advanced open-source AI chatbot supporting multiple LLMs, extensive tools (web search, code execution, data visualization, MCP protocol), image generation, and workflow automation for individuals and teams.
line-bot-mcp-server
Integrates AI agents with LINE Messaging API for automated communication and management of LINE Official Accounts.
whatsapp-mcp-ts
Connects a personal WhatsApp account to an AI agent, enabling the agent to search messages and contacts, list chats, retrieve message history, and send messages via WhatsApp.
fast-mcp-telegram
Enables AI assistants to interact with Telegram for messaging, search, and contact management via a standardized MCP interface.