Sponsored by Deepsite.site

Telegram MCP Server

Created By
NexusX-MCP8 months ago
An MCP server implementation that provides tools for interacting with the [Telegram Bot API](
Content

Telegram MCP Server

smithery badge

An MCP server implementation that provides tools for interacting with the Telegram Bot API. This service allows AI assistants to send messages and retrieve bot information programmatically.

Tools

The Telegram MCP Service provides the following tools for interacting with the Telegram Bot API:

get_bot_info

Retrieves basic information about the bot.

  • No parameters required
  • Returns a User object containing bot information

send_message

Sends a message to a specified chat.

  • chatId: Unique identifier for the target chat (can be string or number)
  • text: Text of the message to be sent
  • params (optional): Additional parameters for the message (e.g., parse_mode, reply_markup, etc.)

get_updates

Receives incoming updates using long polling.

  • params (optional): Object containing optional parameters:
    • offset (optional): Identifier of the first update to be returned
    • limit (optional): Limits the number of updates to be retrieved (1-100)
    • timeout (optional): Timeout in seconds for long polling
    • allowed_updates (optional): Array of update types to receive
  • Returns an array of Update objects containing various types of updates:
    • Messages and edited messages
    • Channel posts
    • Business messages
    • Inline queries
    • Callback queries
    • Shipping queries
    • Pre-checkout queries
    • Polls and poll answers
    • Chat member updates
    • Chat join requests
    • Chat boosts

forward_message

Forwards messages of any kind. Service messages and messages with protected content can't be forwarded.

  • chatId: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
  • fromChatId: Unique identifier for the chat where the original message was sent (or channel username in the format @channelusername)
  • messageId: Message identifier in the chat specified in from_chat_id
  • params (optional): Object containing optional parameters:
    • message_thread_id (optional): Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
    • video_start_timestamp (optional): New start timestamp for the forwarded video in the message
    • disable_notification (optional): Sends the message silently. Users will receive a notification with no sound.
    • protect_content (optional): Protects the contents of the forwarded message from forwarding and saving
  • Returns the sent Message object on success

Configuration

Environment Variables

You need to set up the following environment variable:

TELEGRAM_BOT_TOKEN=your_bot_token

You can get your bot token by talking to @BotFather on Telegram and creating a new bot.

Creating a new bot

Use the /newbot command to create a new bot. @BotFather will ask you for a name and username, then generate an authentication token for your new bot.

The name of your bot is displayed in contact details and elsewhere.

The username is a short name, used in search, mentions and t.me links. Usernames are 5-32 characters long and not case sensitive – but may only include Latin characters, numbers, and underscores. Your bot's username must end in 'bot', like 'tetris_bot' or 'TetrisBot'.

The token is a string, like 110201543:AAHdqTcvCH1vGWJxfSeofSAs0K5PALDsaw, which is required to authorize the bot and send requests to the Bot API. Keep your token secure and store it safely, it can be used by anyone to control your bot.

Unlike the bot's name, the username cannot be changed later – so choose it carefully. When sending a request to api.telegram.org, remember to prefix the word 'bot' to your token.

Development

npm install

npm run build

npx @modelcontextprotocol/inspector node dist/index.js

Open http://127.0.0.1:6274 to set up the environment and interact with the tools.

License

This MCP server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.

Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
DeepChatYour AI Partner on Desktop
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
WindsurfThe new purpose-built IDE to harness magic
Tavily Mcp
CursorThe AI Code Editor
Context7Context7 MCP Server -- Up-to-date code documentation for LLMs and AI code editors
Playwright McpPlaywright MCP server
ChatWiseThe second fastest AI chatbot™
Amap Maps高德地图官方 MCP Server
Serper MCP ServerA Serper MCP Server