Better-TG-CLI (Telegram)
MCP server by TheVilfer Community
Better-TG-CLI is a Telegram CLI and MCP server that lets AI agents read, search and send messages on your own account. You approve every send, edit or delete in the chat before it happens.
Install Better-TG-CLI (Telegram)
Built from the published package, never by AI.
claude mcp add better-tg-cli-telegram -- npx -y better-tg-cliRun in your terminal. Add --scope user to use it in every project.
Step-by-step: install Better-TG-CLI (Telegram) in Claude Code
{
"mcpServers": {
"better-tg-cli-telegram": {
"args": [
"-y",
"better-tg-cli"
],
"command": "npx"
}
}
}Settings, Developer, Edit config. Paste into claude_desktop_config.json and restart.
Step-by-step: install Better-TG-CLI (Telegram) in Claude Desktop
{
"mcpServers": {
"better-tg-cli-telegram": {
"args": [
"-y",
"better-tg-cli"
],
"command": "npx"
}
}
}Add to ~/.cursor/mcp.json (all projects) or .cursor/mcp.json (this project).
{
"servers": {
"better-tg-cli-telegram": {
"args": [
"-y",
"better-tg-cli"
],
"command": "npx"
}
}
}Add to .vscode/mcp.json. VS Code uses "servers", not "mcpServers".
codex mcp add better-tg-cli-telegram -- npx -y better-tg-cli{
"mcpServers": {
"better-tg-cli-telegram": {
"args": [
"-y",
"better-tg-cli"
],
"command": "npx"
}
}
}Add to ~/.gemini/config/mcp_config.json (all projects) or .agents/mcp_config.json (this project).
Step-by-step: install Better-TG-CLI (Telegram) in Antigravity CLI
gemini mcp add better-tg-cli-telegram npx -y better-tg-cliGemini CLI was replaced by Antigravity CLI in June 2026 and remains only for enterprise licences and paid API keys.
Step-by-step: install Better-TG-CLI (Telegram) in Gemini CLI
MCP servers run with your permissions and can read what you give them access to. Some need an API key: check the README and add it under env in the better-tg-cli-telegram block.
About
Better-TG-CLI is a Telegram CLI and MCP server for AI agents such as Claude Code, Codex, Cursor and Claude Desktop. It works on your own Telegram account, so agents can read, search and send messages and press bot buttons. The command is `telegram`, with about 60 commands for reading, searching, writing, bots, groups and exports.
After login, the agent asks you in the chat before each send, edit or delete and shows the exact text. Writes are logged to a local audit file, and secrets are kept in the macOS Keychain, the Linux Secret Service or 1Password. It is an unofficial, open-source client built on teleproto, and it suits people who want an AI agent to work in their own Telegram account.
Written from the project's README and checked against it.
Tools it gives your assistant
inboxLists unread chats and recent activity on your Telegram account (CLI command).readReads messages from a chat, with JSON output for agents (CLI command).searchSearches messages with filters for type, sender or date (CLI command).sendSends messages only after you approve the exact text in the chat (CLI command).clickPresses bot buttons and walks through bot menus (CLI command).getFetches a single message by its ID (CLI command).mcpRuns the CLI as an MCP server with the `telegram mcp` command.skill installInstalls the agent skill for supported agents found on the machine.
What you need
- A Telegram account
- Telegram API keys from my.telegram.org, or a login key from better-tg-cli.com
- Node.js 20 or later for the npm install, or Homebrew for the standalone binary
- macOS, Linux, or Windows (experimental)
| Setting | Needed | What it is |
|---|---|---|
TG_Environment variable | Optional | Optional profile name, to keep this client on a separate Telegram session |
From the publisher's entry in the official MCP Registry. Required settings are already in the install config below as placeholders.
Try asking
- Show me my unread Telegram chats and the latest messages in each
- Search my Telegram for messages from Alice about the meeting last week
- Draft a reply to Bob in Telegram and ask me before you send it
Good to know
- Unofficial client: Telegram may limit or freeze accounts that behave like bots.
- Writes need your approval, and turning on unattended writes needs your own confirmation.
- Windows support is marked experimental.
- Without a working Linux Secret Service, the write mode is kept in a plain file and guards against mistakes only.
Security check
C- Asks for administrator rights (sudo)In
README.md:`sudo
Checked automatically: README.md, package.json. This looks for known risky patterns and is not a full audit. How grades work
Alternatives to Better-TG-CLI (Telegram)
All alternatives →Jitsu MCP server lets AI assistants configure and operate Jitsu data pipelines. It covers destinations, streams, connections and functions, plus Live Events and connector syncs. It is aimed at teams that run event data pipelines.
Vexa sends a bot into Google Meet, Microsoft Teams, Zoom and Jitsi calls to capture speaker-labelled transcripts live or after the call. It suits teams that want meeting transcripts they can self-host.
Gives Claude and other MCP-compatible AI agents access to LinkedIn through your own browser session. It reads profiles, researches companies, finds jobs, and manages messages and connection requests.
Runs a NetSapiens phone system from Claude, ChatGPT, or any MCP client. Each person signs in as themselves, and their assistant gets role-aware tools for calls, voicemail, queues, and provisioning.
Resend MCP Server connects AI assistants to the Resend email platform. It lets them send and receive emails and manage contacts, broadcasts, templates, and domains. It suits developers and teams who use MCP clients such as Claude or Cursor.
The source does not describe labelhead-artist-momentum. It is a README for Paperclip, an open-source orchestration app for teams of AI agents.
Compare with Jitsu, Vexa or Linkedin MCP server
Better-TG-CLI (Telegram): common questions
Is Better-TG-CLI an official Telegram client?
No. The project describes itself as an unofficial, open-source client that uses MTProto through the teleproto library.
Can the agent send messages without asking first?
By default the agent asks you in the chat before each send, edit or delete. Writing without asking requires `write-access on`, which you confirm in a terminal or a macOS dialog.
Does using it put my Telegram account at risk?
The README warns that Telegram may limit or freeze accounts that behave like bots. The risk is highest for new accounts, bulk messaging, mass joins or invites, and spam-like activity.
How do I install Better-TG-CLI (Telegram)?
In Claude Code run claude mcp add better-tg-cli-telegram -- npx -y better-tg-cli. For Claude Desktop, Cursor and VS Code, paste the config shown above and restart. See the install guides.
Is Better-TG-CLI (Telegram) the official server?
Better-TG-CLI (Telegram) is a community project by TheVilfer, not verified by a company domain.
Is Better-TG-CLI (Telegram) free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is Better-TG-CLI (Telegram) safe to use?
It scores 82 of 100. Grades: maintenance A, licence A, quality C. Security check: grade C (asks for administrator rights (sudo)). Review the code before you install. How grades work.
What are alternatives to Better-TG-CLI (Telegram)?
Similar MCP servers: Jitsu, Vexa, Linkedin MCP server, Netsapiens MCP.
Does Better-TG-CLI (Telegram) work with ChatGPT?
Not directly. It runs locally, and ChatGPT only connects to remote servers with a URL. Use it in Claude Code, Claude Desktop, Cursor, VS Code or Codex.
