Skip to main content
Glama
iamalexzatcepin

Telegram MCP

Telegram MCP — local read-only access for AI agents

The local MCP server gives Codex, Claude, and other MCP clients three tools:

Tool

Purpose

list_chats(limit, account)

List chats and unread counts

read_chat(chat, limit, account)

Latest messages of the selected chat

search_chat(chat, query, limit, account)

Search text in the selected chat

The server is read-only. There are no tools for sending, editing, or deleting messages in the code. The server runs locally via STDIO and intentionally does not provide network HTTP/SSE access.

Supported clients

  • ChatGPT/Codex Desktop;

  • Codex CLI and IDE extension;

  • Claude Code;

  • Claude Desktop;

  • any local MCP client with STDIO support.

The local server does not work directly in chatgpt.com, claude.ai, on a phone, or on another computer: these environments cannot run a process on your machine.

Related MCP server: telegram-mcp-server

What you'll need

  • Windows 10/11, macOS, or Linux;

  • Git;

  • Python 3.10+;

  • at least one supported MCP client.

Installation for beginners

1. Open a terminal

  • macOS: Command + Space → type Terminal → Enter.

  • Windows: Start menu → type PowerShell → open PowerShell.

  • Linux: press Ctrl + Alt + T or open the Terminal app.

2. Download the project

macOS/Linux:

git clone https://github.com/iamalexzatcepin/telegram-mcp-template.git ~/telegram-mcp
cd ~/telegram-mcp

Windows PowerShell:

git clone https://github.com/iamalexzatcepin/telegram-mcp-template.git "$env:USERPROFILE\telegram-mcp"
cd "$env:USERPROFILE\telegram-mcp"

If GitHub reports that the repository is not found, your account does not yet have access to the private repository.

3. Get your Telegram API ID and API Hash

  1. Open my.telegram.org.

  2. Sign in with your phone number.

  3. Open API development tools.

  4. Create an app, e.g. Local Telegram MCP.

  5. Save api_id and api_hash.

Do not send api_hash, the login code, or the cloud password to an AI chat.

Create a local .env.

macOS/Linux:

cp .env.example .env
nano .env

Saving in Nano: Ctrl + O → Enter → Ctrl + X.

Windows PowerShell:

Copy-Item .env.example .env
notepad .env

Fill in the file locally:

TELEGRAM_API_ID=ваш_api_id
TELEGRAM_API_HASH=ваш_api_hash

4. Install dependencies and sign in to Telegram

macOS/Linux:

bash setup.sh

Windows PowerShell:

powershell -ExecutionPolicy Bypass -File setup.ps1

The script will find Python 3.10+ itself, create .venv, install dependencies, and ask for your phone number, the code from Telegram, and, if enabled, the cloud password. Enter them only in your own terminal.

Connecting to an agent

In all examples, use the absolute paths printed by the setup script. The command is Python inside .venv, the argument is telegram_mcp_server.py.

Codex CLI and ChatGPT/Codex Desktop

macOS/Linux:

codex mcp add telegram -- "$HOME/telegram-mcp/.venv/bin/python" "$HOME/telegram-mcp/telegram_mcp_server.py"
codex mcp get telegram

Windows PowerShell:

codex mcp add telegram -- "$env:USERPROFILE\telegram-mcp\.venv\Scripts\python.exe" "$env:USERPROFILE\telegram-mcp\telegram_mcp_server.py"
codex mcp get telegram

In ChatGPT/Codex Desktop you can also open Settings → MCP servers → Add server, select STDIO, and specify the same Command and Arguments. After saving, click Restart. Local clients of the same Codex host share the ~/.codex/config.toml configuration.

Claude Code

macOS/Linux:

claude mcp add --transport stdio --scope user telegram -- "$HOME/telegram-mcp/.venv/bin/python" "$HOME/telegram-mcp/telegram_mcp_server.py"
claude mcp get telegram

Windows PowerShell:

claude mcp add --transport stdio --scope user telegram -- "$env:USERPROFILE\telegram-mcp\.venv\Scripts\python.exe" "$env:USERPROFILE\telegram-mcp\telegram_mcp_server.py"
claude mcp get telegram

Start a new Claude Code session and type /mcp. The user scope makes the server available across different local projects of this user.

Claude Desktop

Open the Developer/MCP settings and add a local STDIO server. If your Claude Desktop version uses a JSON configuration, add the object while keeping the other servers:

{
  "mcpServers": {
    "telegram": {
      "command": "/absolute/path/to/telegram-mcp/.venv/bin/python",
      "args": ["/absolute/path/to/telegram-mcp/telegram_mcp_server.py"]
    }
  }
}

Typical file locations:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json;

  • Windows: %APPDATA%\Claude\claude_desktop_config.json.

Fully restart Claude Desktop and open a new chat.

Another STDIO MCP client

Use an equivalent configuration:

{
  "mcpServers": {
    "telegram": {
      "command": "/absolute/path/to/.venv/bin/python",
      "args": ["/absolute/path/to/telegram_mcp_server.py"]
    }
  }
}

Final check

Ask the agent:

Use telegram list_chats with limit=10 and show the name, type, and number of unread messages.

Do not consider the installation complete until the agent has actually returned the list of your chats.

Multiple accounts

The server supports separate local sessions default, work, personal, and others. Instructions are in docs/MULTI_ACCOUNT.md.

Instructions for AI agents

If Codex, Claude, or another agent is performing the installation, ask it to fully read docs/AGENT_SETUP.md and follow it step by step. This file contains security rules and branches for different OSes.

Security and limitations

  • .env and sessions/ are excluded from Git;

  • the .session file grants access to the account — do not copy or publish it;

  • media files are not downloaded, only the has_media flag is returned;

  • requests to Telegram are executed on behalf of your account and obey Telegram's limits;

  • do not run two operations with the same .session at the same time;

  • do not expose this server to the internet.

More: SECURITY.md.

If something doesn't work

See docs/TROUBLESHOOTING.md.

Development

.venv/bin/python -m unittest discover -s tests -v

Project structure:

File

Purpose

telegram_mcp_server.py

Three read-only MCP tools, STDIO only

telegram_ro_common.py

Loading settings and local Telethon sessions

login.py

Sign in and create a named session

setup.sh

Installation on macOS/Linux

setup.ps1

Installation on Windows

docs/AGENT_SETUP.md

Step-by-step protocol for AI agents

docs/MULTI_ACCOUNT.md

Connecting multiple accounts

docs/TROUBLESHOOTING.md

Diagnosing common issues

License

MIT — the project can be used, modified, and distributed with the copyright notice and the license text preserved.

Available Tools

14 tools
analyze_chat_activityC

Compute deterministic activity statistics; the calling agent writes narrative analysis.

ParametersJSON Schema
NameRequiredDescriptionDefault
chatYes
limitNo
accountNo
topic_idNo

TDQS

C2.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden. It discloses that the computation is deterministic and that narrative analysis is left to the agent, but it says nothing about permissions, rate limits, what statistics are produced, or whether it is a safe read operation. This is too little for a tool with zero annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single efficiently structured sentence with the core action front-loaded. The semicolon clause adds useful scope, and there is no wasted text, though the overall brevity leaves it under-informative rather than optimally concise.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given four undocumented parameters, no annotations, and no output schema, the description is far too sparse to tell an agent how to call the tool correctly or what to expect back. It conveys only the highest-level idea and omits necessary operational and return-value context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across four parameters (chat, limit, account, topic_id), and the description does not mention or explain any of them. It fails to compensate for the complete lack of schema-level parameter documentation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb (Compute) and resource (deterministic activity statistics), which clearly separates it from the read/search/list siblings. It does not explicitly name any alternative tool, so it falls short of full sibling differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains that the calling agent writes narrative analysis, which clarifies a division of labor, but it gives no guidance on when to use this tool versus alternatives like search_chat or read_chat, nor any prerequisite conditions. The agent is left to infer the use case.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_message_contextC

Read one message and bounded surrounding context.

ParametersJSON Schema
NameRequiredDescriptionDefault
chatYes
afterNo
beforeNo
accountNo
message_idYes

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. 'Read' implies a safe read, but it never explains what 'bounded' means (the schema defaults of before=5/after=5 are never surfaced) or what happens at message boundaries.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single efficient sentence with the core action front-loaded. No filler, though the extreme brevity is itself a source of underspecification.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 5-parameter tool with no annotations and no output schema, the description is too thin. The meaning of required 'chat', optional 'account', and the default window sizes are all left to inference.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across 5 parameters, so the description must compensate and does not. It hints at message_id and before/after via 'message and bounded surrounding context', but leaves chat, account, and the integer window sizes entirely unexplained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource: reading one message plus bounded surrounding context. This is clearer than a generic 'get', but it does not distinguish itself from siblings like read_chat or read_forum_topic, which presumably also surface messages.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No when-to-use guidance and no alternatives named. The agent cannot tell from the description when to reach for this versus read_chat, get_unread, or search_chat.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_unreadA

Return unread messages grouped by chat without marking them read.

ParametersJSON Schema
NameRequiredDescriptionDefault
accountNo
limit_chatsNo
limit_per_chatNo

TDQS

A3.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations, so description carries full burden. It discloses the critical side-effect: messages are NOT marked read, which is essential for a fetcher. Safe-read behavior is clear. Missing: pagination semantics for limit_per_chat across chats, and whether it includes archived/muted chats.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence, front-loaded, no waste, with the key non-mutating behavior embedded naturally.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 3-param tool with no annotations and no output schema, the description states the core non-side-effect but omits parameter meaning and pagination. Adequate but with clear gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage 0% with 3 parameters. Description doesn't mention any of them (account, limit_chats, limit_per_chat). No defaults or format info added. The description names 'grouped by chat' which loosely maps to limit_per_chat but not explicitly.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clear verb+resource: returns unread messages grouped by chat. Distinguishable from read_chat and search_chat by the unread scope, though it doesn't explicitly name alternatives.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Implied usage from 'unread messages' but no explicit when-to-use vs read_chat or search_chat, nor when-not. A helpful behavior note (no marking read) hints at use cases but not selection guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

inspect_permissionsA

Show the active profile, allowed capabilities, and physically exposed tools.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

TDQS

A3.5/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It discloses what is returned but not that this is read-only, side-effect free, or requires no special auth. For a zero-parameter introspection call the risk is low, so partial disclosure is tolerable, but the safety profile is left implicit.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence that enumerates the three outputs with no filler. Nothing could be cut without losing information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, so the description must convey return content, which it does by listing the three information categories. For a no-argument tool this is close to sufficient; it could clarify auth/permission prerequisites, but the core is covered.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

There are zero parameters and 100% schema coverage, so the baseline of 4 applies. The description correctly adds no redundant parameter detail.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a clear verb ('Show') and three specific resources it returns: the active profile, allowed capabilities, and exposed tools. This makes it readily distinguishable from all the search/list/read chat siblings. 'Physically exposed tools' is slightly opaque jargon, but the intent is legible.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description offers no when-to-use guidance, no prerequisites, and no alternatives. The sibling telegram_diagnostics plausibly overlaps, yet nothing routes the agent between them. Usage is only weakly inferable from the verb.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_chat_foldersC

List Telegram chat folders without changing their configuration.

ParametersJSON Schema
NameRequiredDescriptionDefault
accountNo

TDQS

C2.8/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden, and it discloses only one trait: the call does not alter folder configuration. It says nothing about pagination, return shape, ordering, or account requirements for a listing operation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

One compact sentence with the non-mutating guarantee front-loaded and no filler. It is lean, though some of that leanness is under-specification rather than economy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple read-only listing with one optional parameter and no output schema, the description is minimally adequate. It omits return contents and the account parameter's role, which a caller would still have to guess.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% and the single 'account' parameter has no title-level documentation beyond a default of empty string. The description adds no meaning about what account means or how it affects the listing.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (List) and resource (Telegram chat folders), so the agent knows exactly what the tool returns at a high level. It does not explicitly contrast with the nearby list_folder_chats or list_chats, but the resource is distinct enough to stand on its own.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to use this versus list_folder_chats (chats inside a folder) or list_chats, nor any mention of prerequisites. Usage can only be inferred from the resource name.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_chatsC

List chats, stable references, unread counts, and pinned state.

ParametersJSON Schema
NameRequiredDescriptionDefault
limitNo
accountNo

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden. It discloses what is returned but says nothing about read-only safety, pagination behavior tied to 'limit', auth needs for 'account', or ordering. That is a significant gap for a tool with zero annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with no filler; the key verb and resource lead. It is efficient, though its brevity is partly the cause of the usage and parameter gaps.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-parameter list tool with no output schema and no annotations, the description should at minimum explain limit/account and pagination. It discloses the return shape but leaves parameter behavior and operational context undocumented.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Two parameters exist ('limit', 'account') with 0% schema description coverage, so the description must compensate and instead mentions neither. The default of 50 for limit and the meaning of an empty account string are left entirely unexplained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb ('List') and resource ('chats'), and goes further by naming the payload fields (stable references, unread counts, pinned state). This distinguishes it from search_chat's query semantics, though it never explicitly names a sibling.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no statement of when to use this versus search_chat, get_unread, or list_chat_folders, all of which sit adjacent in the sibling list. The agent must infer usage from the name alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_folder_chatsC

List chats visible in one Telegram folder by its numeric folder id.

ParametersJSON Schema
NameRequiredDescriptionDefault
limitNo
accountNo
folder_idYes

TDQS

C2.8/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden and does not meet it. It says nothing about the limit/pagination behavior, the account parameter's effect, whether chats are returned in a stable order, or how unread/archived chats are treated.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with no filler; the key identifying detail (numeric folder id) comes before any trailing clauses.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 3-parameter tool with no annotations and no output schema, the definition is too thin. An agent can identify the tool but lacks the pagination, account-selection, and return-shape context needed to call and interpret it reliably.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It clarifies only folder_id (numeric id), leaving 'limit' (default 50) and 'account' (default empty string) entirely undefined in both the schema and the description.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (List), resource (chats), and scope (visible in one Telegram folder, keyed by numeric folder id). This distinguishes it from list_chats and list_chat_folders in spirit, though it never names those siblings to make the boundary explicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no when-to-use guidance and no mention of alternatives. The phrase 'by its numeric folder id' hints that an id must be obtained elsewhere (e.g. list_chat_folders), but this prerequisite is left for the agent to infer.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_forum_topicsC

List topics in a Telegram forum chat, including unread state.

ParametersJSON Schema
NameRequiredDescriptionDefault
chatYes
limitNo
queryNo
accountNo

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so the description carries the full burden. It mentions unread state but doesn't disclose pagination, ordering, authentication needs, or rate limits. For a read-only listing tool with no annotations, this is a significant gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence, front-loaded with the action and resource, no wasted words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with 4 undocumented parameters, no annotations, and no output schema, the description is insufficient. It doesn't describe return format, pagination, or parameter meaning, leaving critical gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, with 4 parameters (chat, limit, query, account) completely undocumented in both schema and description. The description mentions no parameters, leaving the agent unable to interpret limit, query, or account semantics.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (list) and resource (forum topics in a Telegram forum chat), including the scope (unread state). It distinguishes from read_forum_topic and search_forum_topic by being a listing operation, but doesn't explicitly name the alternatives.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this versus search_forum_topic, read_forum_topic, or other listing tools. It implies listing but provides no conditions or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

read_chatC

Read recent messages from a chat, returned oldest-first.

ParametersJSON Schema
NameRequiredDescriptionDefault
chatYes
limitNo
accountNo

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full behavioral burden. It usefully discloses that results are recent and returned oldest-first, but it omits whether the operation is read-only, authentication/permission requirements, pagination behavior, or how the limit default interacts with 'recent'.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The definition is a single, front-loaded sentence with no wasted words. It is concise and easy to parse, though it achieves brevity by omitting details an agent would benefit from.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a three-parameter tool with no annotations and no output schema, the description is too thin. It should at least explain the required chat identifier, the limit default, and the account parameter, but it covers none of those.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% for three parameters. The description only loosely implies the 'chat' parameter and the 'limit' via 'recent messages', while 'account' and all default values are completely unaddressed, so it does little to compensate for the schema gap.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (read) and resource (messages from a chat), plus a useful ordering detail (oldest-first). It is clear what the tool does, but it does not differentiate itself from siblings like search_chat or get_unread.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no explicit when-to-use guidance, no when-not-to-use guidance, and no named alternatives. 'Recent messages' implies a use case, but the agent receives no routing information among the many sibling read/search/list tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

read_forum_topicB

Read recent messages from one forum topic without marking it read.

ParametersJSON Schema
NameRequiredDescriptionDefault
chatYes
limitNo
accountNo
topic_idYes

TDQS

B3.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden, and it does disclose one genuinely useful behavioral trait: the topic is not marked read, making this non-mutating. It says nothing about pagination, ordering, return shape, or required permissions, which are material for a 4-parameter read tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with no wasted words; the non-marking-read constraint is placed where it matters. It is efficient, though the terseness contributes to the coverage gaps noted elsewhere.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No annotations, no output schema, and 0% schema description coverage on 4 parameters means the description is the only channel for behavioral and parameter detail — and it provides almost none. For a tool with this structured-data vacuum it should say considerably more.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate for all four parameters. It only loosely gestures at 'chat' and 'topic' via 'one forum topic' and never mentions limit, account, or the defaults, so the agent gets no syntax or format guidance from it.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a clear verb (Read) plus resource (recent messages from one forum topic) with a scoping qualifier (one forum topic). It distinguishes itself from read_chat and search_forum_topic implicitly, though it never names those siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase 'without marking it read' implies a peek-style use case, hinting when to prefer this over a read-that-consumes operation like get_unread. However, it never explicitly says when to use this versus search_forum_topic, read_chat, or get_message_context, leaving the agent to infer.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

search_chatC

Search message text within one chat.

ParametersJSON Schema
NameRequiredDescriptionDefault
chatYes
limitNo
queryYes
accountNo

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full behavioral burden but delivers almost nothing: no mention of whether search is case-sensitive, substring vs token matching, pagination via limit, or what results look like. Only the scope constraint is disclosed.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single efficient sentence with the scope constraint front-loaded and no wasted words. It is terse to the point of under-specification, but the structure itself is clean.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

A 4-parameter search tool with no annotations, no output schema, and 0% schema coverage needs the description to do much more. It omits result format, pagination behavior, account scoping, and the chat identifier format.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across 4 parameters, and the description only loosely gestures at two of them ('chat', 'message text' for query). The limit and account parameters are undocumented in both schema and description, leaving real ambiguity.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (Search) and resource (message text) with an explicit scope constraint (within one chat). The scope phrasing implicitly distinguishes it from search_global, though it never names the sibling directly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No when-to-use guidance, no prerequisites, and no alternatives named despite siblings like search_global and read_chat being obvious candidates. The 'within one chat' scope is the only signal an agent gets for when this tool applies.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

search_forum_topicC

Search message text inside one forum topic.

ParametersJSON Schema
NameRequiredDescriptionDefault
chatYes
limitNo
queryYes
accountNo
topic_idYes

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It does not state that the operation is read-only, whether results are paginated, permission requirements, or how results are ordered, leaving key behavioral traits unspecified.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single sentence with no filler, and the core scope is front-loaded. It is appropriately brief for a simple search tool, though the brevity borders on under-specification given the missing parameter details.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 5-parameter search tool with no annotations and no output schema, the description is far too thin. It omits parameter meanings and behavioral context that an agent needs to invoke the tool correctly, making it incomplete for the tool's complexity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% and there are 5 parameters. The description only loosely hints at 'query' and 'topic_id' through 'message text' and 'forum topic'; parameters like limit, account, and the chat format receive no explanation, so the description fails to compensate for the coverage gap.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb ('Search') and a scoped resource ('message text inside one forum topic'), which distinguishes it from search_global. However, it does not differentiate from the sibling search_chat, which likely searches across a whole chat, leaving some ambiguity about when to prefer this tool.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no explicit guidance on when to use this tool versus search_chat or search_global, no prerequisites, and no mention of when not to use it. Usage is only implicitly suggested by the scope phrase 'inside one forum topic'.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

search_globalC

Search message text across all dialogs.

ParametersJSON Schema
NameRequiredDescriptionDefault
limitNo
queryYes
accountNo

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full behavioral burden, yet it says nothing about read-only semantics, result ordering, pagination behavior, or rate limits. For a search tool with zero annotation coverage, this is a significant gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with no waste. It is appropriately terse, though the brevity reflects under-specification rather than disciplined editing.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no annotations, no output schema, and 0% parameter coverage across three parameters, an agent lacks the return format, scoping rules, and parameter meanings needed to invoke the tool confidently.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% and there are three parameters, so the description must compensate. It only hints that 'message text' maps to the query parameter and never explains limit, account, or default values, leaving most parameters undocumented.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb (search) and resource (message text) and states the scope ('across all dialogs'), which implicitly separates it from search_chat and search_forum_topic. It is clear but never names or contrasts with the sibling tools explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase 'across all dialogs' implies this is the tool to use when the dialog is unknown, but there is no explicit when-to-use statement, no exclusions (e.g., prefer search_chat when the chat is known), and no mention of alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

telegram_diagnosticsA

Inspect local runtime/config/storage state without returning secrets or messages.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full disclosure burden, and it does add one genuinely useful trait: output is sanitized of secrets and messages. It does not state that the operation is read-only, describe the shape or contents of the returned state, or mention any side effects, so behavioral coverage is partial.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with no filler; the action, the target, and the key output constraint are all packed into one clause. Nothing in it is redundant.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema and no annotations, the description should ideally say what the diagnostic actually returns and confirm it is a safe read. It only states what it does not return, leaving the output shape and read-only nature for the agent to assume, which is adequate but not fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool takes zero parameters, so there is nothing for the description to clarify; the baseline for a parameterless tool is 4. No parameter-level detail could be added beyond what the schema already conveys.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb ('Inspect') and a concrete resource ('local runtime/config/storage state'), which clearly separates it from the chat-oriented siblings like search_chat and read_chat. It does not explicitly name or contrast with any sibling, but the domain difference is discernible from the wording.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no explicit when-to-use or when-not-to-use statement, and no alternatives are named. The diagnostic framing implies it is used for troubleshooting rather than normal chat retrieval, but the agent must infer this from the resource noun alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 14 tool updatesv2.3.0
    • First observedanalyze_chat_activity
    • First observedget_message_context
    • First observedget_unread
    • First observedinspect_permissions
    • First observedlist_chat_folders
    • First observedlist_chats
    • First observedlist_folder_chats
    • First observedlist_forum_topics
    • First observedread_chat
    • First observedread_forum_topic
    • First observedsearch_chat
    • First observedsearch_forum_topic
    • First observedsearch_global
    • First observedtelegram_diagnostics

TDQS

B3.3/5.0

Scored across 14 tools

Disambiguation5/5

Each tool targets a distinct scope or operation: search by chat/global/forum topic, list chats/folders/topics, read chat/topic/unread/context, plus analysis and diagnostics. Overlaps are minimal and descriptions clearly differentiate boundaries (e.g., read_chat vs read_forum_topic).

Naming Consistency4/5

Most tools follow a consistent verb_noun snake_case pattern (search_chat, list_chats, get_unread). One outlier is telegram_diagnostics, which lacks a verb and slightly breaks the pattern, but overall naming is predictable.

Tool Count5/5

14 tools is well-scoped for a read-only Telegram client surface, covering search, read, list, and diagnostic needs without redundant or excessive operations.

Completeness4/5

The read-only surface is quite complete for searching, reading, listing, and analyzing chats, including unread and forum topic support. Minor gaps remain in exposing detailed chat metadata (e.g., profile info) or any write operations, though the latter may be intentional.

Maintenance

ActivityMaintained
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    D
    maintenance
    Read-only Telegram access for Claude and other MCP hosts. Provides tools to list chats, read recent messages, and download media from your own Telegram account without needing an api_id/api_hash.
    5
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    A read-only MCP server that lets AI agents read personal Telegram chats from an allowlist of folders, with no send/edit/delete capability.
    32 npm
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Enables reading Telegram chats and searching messages through natural language, connecting to MCP clients like Claude Code, Codex, and Cursor.
    4 npm
    1
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Enables reading Telegram channels, groups, and direct messages through an MCP interface, with enforced read-only access so the agent cannot write to them.
    MIT