
popstas/telegram-download-chat 是从 https://github.com/popstas/telegram-download-chat. 导入的一个 MCP 服务器候选。
概览
popstas/telegram-download-chat 是从 https://github.com/popstas/telegram-download-chat. 导入的一个 MCP 服务器候选。
概述(AI 翻译)
一个强大的命令行、图形界面和网页界面工具,可下载和分析多种格式的Telegram聊天历史。
需要发送或管理消息? 该工具仅限下载。发送 消息,创建组/主题,管理成员和文件夹,看看 popstas/电报助理。
需要实时监控而不是一次性导出? 观看聊天和频道 和文件夹,实时转发匹配消息,详见 popstas/电报转发器。
特色
- 下载任何Telegram聊天、群组、超级群组、频道或Telegram导出档案的完整聊天历史
- 下载聊天文件夹
- 从消息线程中提取子对话
- 以JSON格式保存消息,包含完整的消息元数据
- 生成可读的人类和大型语言模型(LLM)可读TXT导出,显示名称友好
- 下载媒体附件(照片、视频、文档、音频等)
- 使用 Telegram Premium 语音转文本(
--stt)转录语音消息,缓存以便不会重复转录 - 通过
--preset使用常见选项集的预设。 - 跨平台支持(Windows、macOS、Linux)
- CLI 优先,可选图形用户界面和网页界面
过滤
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
Telegram Chat Downloader
A powerful command-line, GUI and web interface utility to download and analyze Telegram chat history in multiple formats.
Need to send or manage messages? This tool is download-only. To send messages, create groups/topics, manage members and folders, see popstas/telegram-assistant.
Need live monitoring instead of a one-off export? To watch chats, channels and folders and forward matching messages in real time, see popstas/telegram-resender.
Features
- Download complete chat history from any Telegram chat, group, supergroup, channel or Telegram export archive
- Download chats folder
- Extract sub-conversations from message threads
- Save messages in JSON format with full message metadata
- Generate human and LLM readable TXT exports with user-friendly display names
- Download media attachments (photos, videos, documents, audio, etc.)
- Transcribe voice messages with Telegram Premium speech-to-text (
--stt), cached so nothing is transcribed twice - Use presets for common option sets via
--preset - Cross-platform support (Windows, macOS, Linux)
- CLI-first, optional graphical user interface and web interface
Filtering
- Filter messages by date range
- Filter messages by specific users
- Filter saved messages by keywords
- Filter messages by sub-conversations from message threads
- Download only the unread messages of a chat (
--unread)
Usage
Login
Log in once before the first download. In a terminal, a download without a
session offers to log you in right there; everywhere else — the GUI, a cron job,
the console-less Windows build — it never prompts and tells you to run login
instead, so an unattended run fails with a message rather than waiting forever
for an answer nobody can type.
# Log in with a code from Telegram
telegram-download-chat login
# Log in by scanning a QR code with an app you are already logged into
telegram-download-chat login --qr
The login code is delivered by Telegram, and for third-party clients it usually
arrives in the Telegram app, in the chat named “Telegram” rather than by
SMS. If no code arrives at all, use login --qr: the code is confirmed from a
device where you are already logged in, so it does not depend on SMS. Add
--debug to see how Telegram chose to deliver the code.
Since September 2026 Telegram sometimes reports the code as sent to the app
(--debug shows SentCodeTypeApp with next_type=None) and then never
delivers it, on any device (#91).
The app cannot change how Telegram delivers codes, so QR login is the
way in for such accounts.
In the GUI, the same two options live on the Settings tab: fill in the phone and code, or press “Log in with QR code”. For accounts with two-step verification, fill the Password field before scanning.
安装
uvx --from telegram-download-chat[mcp配置
{
"mcpServers": {
"telegram": {
"command": "python",
"args": ["-m", "telegram_download_chat.mcp"]
}
}
}