Skip to main content
Glama
draiqw
by draiqw

tg_export

Idempotent

Export full Telegram conversations to JSON, Markdown, or text files, with optional media downloads, for backup or offline analysis.

Instructions

Dump whole conversations to files (max 5000 messages per chat).

With media=true every attachment is downloaded next to the transcript and each message carries the local file path, its links, and a t.me link to the message itself where one exists. That is the tool for "give me the full conversation with everything in it", and it pairs with tg_activity: take the chat ids from there, feed them in as chats.

Args: chat: one chat to export. chats: several chats at once, up to 25. One failure does not stop the rest. limit: how many recent messages per chat, written oldest first. format: json for analysis, markdown or text for reading. dest: target directory. Defaults to the project's data/downloads. since: only messages from this point — "today" or an ISO datetime. until: upper bound, ISO datetime. media: also download every attachment. media_max_mb: skip attachments larger than this (they are listed as skipped).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
chatNo
destNo
chatsNo
limitNo
mediaNo
sinceNo
untilNo
formatNojson
media_max_mbNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

The description adds substantial behavioral detail beyond the annotations: media downloading, local file paths in transcripts, t.me message links, per-chat failure isolation ('One failure does not stop the rest'), skipped-attachment behavior, and a message cap. These side effects matter for a tool with readOnlyHint=false, and they are clearly disclosed.

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?

The core purpose is front-loaded in the first sentence, followed by a short behavior summary and then a compact Arg list. Every line adds information; there is no filler. The length is justified by the 9 parameters and the need to explain batch behavior and media handling.

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

Completeness5/5

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

Despite having no output schema and 9 parameters, the description is complete for invocation: it explains limits, defaults, batch semantics, date constraints, media handling, and destination defaults. It also gives the recommended workflow with tg_activity. An agent has enough context to call this tool correctly without external documentation.

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

Parameters5/5

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

Schema description coverage is 0%, so the description carries full responsibility for explaining the 9 parameters. It delivers: chat vs chats, limit semantics ('most recent, written oldest first'), format guidance ('json for analysis, markdown or text for reading'), dest default, since/until bounds, and media_max_mb behavior. Every parameter in the schema is explained.

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

Purpose5/5

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

Description opens with a specific verb and resource: 'Dump whole conversations to files', and adds a concrete cap (max 5000 messages per chat). It explicitly frames itself as the tool for 'give me the full conversation with everything in it', which distinguishes it from narrower history/search siblings like tg_history or tg_search.

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

Usage Guidelines4/5

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

Provides clear usage context both by naming the exact user request it satisfies ('give me the full conversation with everything in it') and by instructing the agent to pair it with tg_activity: 'take the chat ids from there, feed them in as chats'. It doesn't explicitly name tools not to use, but the guidance is strong enough for an agent to select it appropriately.

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