Skip to main content
Glama
Telegram MCP

Telegram MCP

Get bounded Telegram media

telegram_get_media
Read-onlyIdempotent

Fetches one anchored photo, PDF, audio item, or video thumbnail from a Telegram chat by chat_id and message_id, with preview and full size limits.

Instructions

Fetch one explicitly anchored photo, PDF document, audio item, or video thumbnail.

Preview transfers are capped at 2 MiB and full transfers at 12 MiB. Protected, self-destructing, secret, unsupported, and oversized media are rejected.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "chat_id": "<chat_id>",
      "message_id": "<message_id>"
    },
    "name": "telegram_get_media"
  }
}

Input Schema

NameRequiredDescriptionDefault
chat_idYesExact native chat_id returned by telegram_list_chats or message/search results. Keep its sign; pass the ID, not a title, @username or Telegram link.
qualityNopreview returns media up to 2 MiB; full returns supported full media up to 12 MiB. Video is thumbnail-only here; use telegram_download_file to save full video.preview
message_idYesExact positive native TDLib message_id from a Telegram MCP result in the specified chat. Reuse the chat/message pair unchanged; do not convert Bot API IDs or IDs from Telegram URLs.

Output Schema

NameRequiredDescriptionDefault
widthNo
heightNo
chat_idYes
qualityYes
file_nameNo
mime_typeYes
is_previewNo
media_kindYes
message_idYes
size_bytesYes
content_typeYes
trust_boundaryNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.14.0
    • addedInput schema / properties / chat_id / description
      Added value: +"Exact native chat_id returned by telegram_list_chats or message/search results. Keep its sign; pass the ID, not a title, @username or Telegram link."
    • addedInput schema / properties / message_id / description
      Added value: +"Exact positive native TDLib message_id from a Telegram MCP result in the specified chat. Reuse the chat/message pair unchanged; do not convert Bot API IDs or IDs from Telegram URLs."
    • addedInput schema / properties / quality / description
      Added value: +"preview returns media up to 2 MiB; full returns supported full media up to 12 MiB. Video is thumbnail-only here; use telegram_download_file to save full video."
  2. First observedv0.5.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already establish readOnly, idempotent, non-destructive behavior, so the description's added value is in the limits: 2 MiB preview and 12 MiB full caps plus the rejection classes (protected, self-destructing, secret, unsupported, oversized). Those failure modes are exactly the kind of context annotations cannot carry. It stops short of describing what the response object contains, but an output schema exists to cover that.

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?

Three short lines, purpose front-loaded, then constraints in descending order of importance, with no filler. The phrase "explicitly anchored" is left undefined and the trailing rejection list is unconnected prose, which keeps it just short of ideal.

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?

For a read-only fetch with a rich output schema and complete parameter documentation, the description supplies the two things structured fields cannot: transfer ceilings and rejection conditions. It omits any pointer to the full-video sibling tool, which is the one thing an agent could still get wrong.

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

Parameters3/5

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

Schema coverage is 100%, so chat_id, message_id and the quality enum are fully documented structurally. The description's size caps loosely correspond to the quality parameter but add no new syntax, formats, or ID-reuse guidance beyond the schema. Baseline 3 applies.

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 pairs a specific verb ("Fetch") with a bounded resource and enumerates the supported media types (photo, PDF, audio, video thumbnail), so the agent knows exactly what comes back. Sibling differentiation is only implicit, however: the video-thumbnail restriction hints that telegram_download_file is the alternative for full video, but the description never names it.

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?

Usage context is implied by the media-type list and the size ceilings rather than stated. There is no explicit when-to-use/when-not clause and no named alternative tool, so the agent must infer that full-video retrieval belongs to telegram_download_file.

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