独立运营 · 不出售排名位置  · 我们怎么评估工具 →
Anclum 提交收录
S

swtormy/tgbot-cli

Unofficial single-binary CLI for the Telegram Bot API (JSON in/out)

装之前:没有可直接复制的命令 · 许可证 MIT · 链接可访问

第一步:go install github.com/swtormy/tgbot-cli/cmd/tgbot@latest

在 GitHub 查看 ↗链接已于 2026-11-12 核查 · HTTP 200 · 打开的是厂商自己的官网
安装与配置
取自该仓库的安装命令
go install github.com/swtormy/tgbot-cli/cmd/tgbot@latest

解析自我们于 2026-11-10 抓取的该仓库 README;我们未执行过。

这条是仓库自己写的安装方式,不是 MCP 客户端配置,所以不生成 JSON。
配置项的键名以你的客户端为准:客户端与 CLI
★ 数取值
0 ★ · swtormy/tgbot-cli · 取自 GitHub 搜索 API · (2026-11-13 20:00:50 核对)
来源明细
从该仓库的 GitHub 页面直接读取 · 条目类型:开源项目
收录与活跃
收录于 2026-11-11 · 最近见到 2026-11-14 · 共见到 4 次 · 被 2 个来源列出
评分构成
综合分 203 · 2 个来源 · repo
安装
go install github.com/swtormy/tgbot-cli/cmd/tgbot@latest
常见问题(答案都来自我们的记录)
怎么安装?
该仓库给出的安装命令是 go install github.com/swtormy/tgbot-cli/cmd/tgbot@latest。我们的记录里它是仓库自己提供的;不保证在你的客户端上直接可用。
它适合谁 / 用来做什么?
我们把它归在这些标签下: Agent 技能。标签来自条目自身,不是我们强加的分类。
谁维护它、还在更新吗?
仓库 swtormy/tgbot-cli;我们收录于 2026-11-11;最近见到 2026-11-14。这里没有"官方认证"或"质量评级"——我们只记录来源与时间。

# tgbot

以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →

A command-line tool for the Telegram Bot API and your own Telegram account (MTProto), built for AI agents. One binary, no server, JSON in and out.
tgbot is an unofficial, independent project and is not affiliated with, endorsed by, or sponsored by Telegram.
Inspired by Google's Gemini API CLI.
bash
export TELEGRAM_BOT_TOKEN="123456:ABC..." # from @BotFather
tgbot send 123456789 "build finished"
An agent with a shell (Claude Code, Cursor, Grok Build, Codex, and others) can call every Bot API method with it. There is no MCP server to run and no tool schemas sitting in the agent's context. The agent learns the commands from the binary itself, only when it needs them.
Two modes in one binary:
| | Bot mode (tgbot send ...) | User mode (tgbot user ...) |
| Acts as | a bot from @BotFather | your own Telegram account |
| Login | a token in an environment variable | once, with a code from your Telegram app |
| Good for | notifications, bot workflows | reading and searching your chats, replying as you, watching for messages |
| Docs | this page | docs/USER_MODE.md |
## Install
macOS and Linux:
bash
curl -fsSL https://raw.githubusercontent.com/swtormy/tgbot-cli/main/scripts/install.sh | bash
Or with Go:
bash
go install github.com/swtormy/tgbot-cli/cmd/tgbot@latest
Prebuilt binaries for macOS, Linux and Windows are on the releases page.
### Download a release binary
Pick the archive for your OS and CPU from a GitHub release (draft releases are visible to repo collaborators until published):
| Platform | Archive |
| Linux x86_64 | tgbot_linux_amd64.tar.gz |
| Linux arm64 | tgbot_linux_arm64.tar.gz |
| macOS Intel | tgbot_darwin_amd64.tar.gz |
| macOS Apple Silicon | tgbot_darwin_arm64.tar.gz |
| Windows x86_64 | tgbot_windows_amd64.zip |
| Windows arm64 | tgbot_windows_arm64.zip |
Each archive contains the tgbot binary (.exe on Windows), LICENSE, NOTICE, THIRD_PARTY_NOTICES, and full dependency license texts under third_party_licenses/. Verify the download against checksums.txt from the same release:
bash
curl -fsSLO https://github.com/swtormy/tgbot-cli/releases/download/vX.Y.Z/checksums.txt
curl -fsSLO https://github.com/swtormy/tgbot-cli/releases/download/vX.Y.Z/tgbot_linux_amd64.tar.gz
grep ' tgbot_linux_amd64.tar.gz$' checksums.txt | sha256sum -c -
tar -xzf tgbot_linux_amd64.tar.gz
./tgbot_linux_amd64/tgbot --version
Replace vX.Y.Z with the tag you downloaded. On macOS without GNU sha256sum, use shasum -a 256 -c the same way.
## Quick start
1. Create a bot with @BotFather and export its token as TELEGRAM_BOT_TOKEN.
2. Send the bot a message so it can write to you back, then read your chat id:
bash
tgbot updates --jq '.updates[].message.chat.id'
3. Send something:
bash
tgbot send 123456789 "hello from tgbot"
tgbot sendPhoto --chat_id 123456789 --photo @cat.jpg --caption "meow"
Every call can be previewed first with --dry-run. It needs no token and prints the request that would be sent.
## Give it to your agent
The skill is built into the binary, so one command installs it:
bash
tgbot skill install # ./.claude/skills/tgbot/SKILL.md (Claude Code)
tgbot skill install --agent cursor --global
tgbot skill install --agent grok
tgbot skill install --agent agents # shared .agents/skills folder
收录徽章(可选)
想把收录标记放进 README 就复制这行,可选,不影响收录。
[![Listed on Anclum](https://anclum.com/badge/listed.svg)](https://anclum.com/zh/s/swtormy-tgbot-cli/)
来源
github · https://github.com/swtormy/tgbot-cli
按领域浏览
Agent 技能
收录来源
2 个独立来源
收录于
今天

同类推荐

全部 420 →

所属领域与标签

每个标签都能点进去看同类的全部条目。数字是当前库里的真实条数。

浏览全部领域 →

← 返回索引