Telegram MCP Server
Provides tools for interacting with the Telegram Bot API, enabling sending text messages, files, and photos, retrieving recent chat messages, and pinning messages in a configured Telegram chat.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Telegram MCP Server
A Model Context Protocol (MCP) server that exposes Telegram Bot API operations as tools for AI assistants like Claude. Send messages, files, photos, read chat history, and pin messages — all through a standardized MCP interface.
Features
Tool | Description |
send_telegram_message | Send text messages with Markdown formatting and optional silent mode |
send_telegram_file | Send a local file as a document |
send_telegram_file_direct | Send a file from in-memory content (UTF-8 or Base64) without writing to disk |
send_telegram_photo | Send a local image as a photo |
send_telegram_photo_direct | Send a photo from Base64-encoded content without writing to disk |
get_telegram_messages | Retrieve the latest messages from the configured chat |
pin_telegram_message | Pin a message to the top of the chat |
Related MCP server: Telegram MCP Server
Architecture
┌──────────────────────┐
│ Claude / AI │
└──────────┬───────────┘
│ stdio (MCP)
┌──────────▼───────────┐
│ MCP Server │
│ (index.ts) │
│ │
│ 7 tool handlers │
└──────────┬───────────┘
│ HTTPS
┌──────────▼───────────┐
│ Telegram Bot API │
└──────────────────────┘The server communicates with the MCP client (e.g. Claude) over stdio and makes HTTPS calls to the Telegram Bot API. It is a single-file, stateless TypeScript application executed on-the-fly with tsx.
Prerequisites
Node.js >= 18
npm
A Telegram Bot Token (create one via @BotFather)
The Chat ID of the conversation the bot should interact with
Setup
1. Clone the repository
git clone https://github.com/GeorgBreithaupt/ChlodwigTelegramMCP.git
cd ChlodwigTelegramMCP2. Install dependencies
npm install3. Configure environment variables
Create a .env file in the project root:
TELEGRAM_BOT_TOKEN=your-bot-token-here
TELEGRAM_CHAT_ID=your-chat-id-hereVariable | Required | Description |
| Yes | Bot API token from @BotFather (format: |
| Yes | Numeric ID of the target chat / user |
Tip: To find your Chat ID, send a message to your bot and visit
https://api.telegram.org/bot<YOUR_TOKEN>/getUpdates— thechat.idfield contains the value you need.
4. Run the server (standalone)
npx tsx index.tsThe server starts listening on stdio for MCP requests. In practice it is launched automatically by the MCP client.
MCP Client Configuration
Add the following to your MCP client config to register this server.
Claude Code (.mcp.json)
{
"mcpServers": {
"telegram": {
"command": "npx",
"args": ["--quiet", "tsx", "/absolute/path/to/ChlodwigTelegramMCP/index.ts"]
}
}
}Claude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"telegram": {
"command": "npx",
"args": ["--quiet", "tsx", "/absolute/path/to/ChlodwigTelegramMCP/index.ts"]
}
}
}Config file location:
Windows:
%APPDATA%\Claude\claude_desktop_config.jsonmacOS:
~/Library/Application Support/Claude/claude_desktop_config.json
Tool Reference
send_telegram_message
Send a text message with optional Markdown formatting.
Parameter | Type | Required | Description |
| string | Yes | Message text (supports Markdown) |
| boolean | No | Send without notification sound |
send_telegram_file
Send a file from the local filesystem as a document.
Parameter | Type | Required | Description |
| string | Yes | Absolute path to the file |
| string | No | Caption for the document |
send_telegram_file_direct
Send a file from in-memory content — no disk write required.
Parameter | Type | Required | Description |
| string | Yes | Name for the file (e.g. |
| string | Yes | File content as a string |
| string | No |
|
| string | No | Caption for the document |
send_telegram_photo
Send a local image file as a photo.
Parameter | Type | Required | Description |
| string | Yes | Absolute path to the image |
| string | No | Caption for the photo |
send_telegram_photo_direct
Send a photo from Base64-encoded content — no disk write required.
Parameter | Type | Required | Description |
| string | Yes | Base64-encoded image data |
| string | Yes | File name (e.g. |
| string | No | Caption for the photo |
get_telegram_messages
Retrieve the most recent messages from the configured chat.
Parameter | Type | Required | Description |
| number | No | Number of messages to return (default: 10) |
pin_telegram_message
Pin a message to the top of the chat.
Parameter | Type | Required | Description |
| number | Yes | ID of the message to pin |
Tech Stack
Component | Technology |
Language | TypeScript |
Runtime | Node.js (via tsx) |
MCP SDK | |
Transport | stdio |
Env management | |
HTTP client | Native |
License
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Let AI assistants post to your Telegram chats, groups and channels. Not affiliated with Telegram.
Read chats and members; send, edit and delete messages with a bot in Telegram.
WhatsApp and Telegram for AI agents, behind a policy gateway. OAuth or access key.
Publish and schedule Telegram channel posts from your AI assistant.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI agents to send and receive messages, media, and files on Telegram, and manage chats via a bot token.1755 PyPIMIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with the Telegram Bot API, allowing them to send messages, forward messages, get bot information, and receive updates.3MIT
- FlicenseNot gradedqualityDmaintenanceEnables LLM clients to send messages, read recent messages, and retrieve chat information through the Telegram Bot API.-
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants to read chats, Saved Messages, files and media, search history, and send messages through your personal Telegram account.3MIT