configure-channel
它能做什么
它为 AI 智能体提供分步命令,用于将聊天频道接入 OpenClaw 并确认其正常工作。它适合希望 OpenClaw 通过通讯应用与人交流的人。
适用场景
- ✓想把 OpenClaw 接入 Telegram 等聊天应用的时候。
- ✓需要检查 OpenClaw 聊天频道当前状态的时候。
- ✓想更改谁可以给你的 OpenClaw 机器人发消息,同时避免无意中开放访问权限的时候。
技能链接
https://github.com/openclaw/openclaw/blob/main/custodian-skills/configure-channel/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请帮我把 OpenClaw 机器人接入 Telegram,并检查它是否会回复我。”
每周 5 个新技能,1 分钟读完。
工作原理
技能先检查哪些频道已经设置好,然后把机器人令牌以安全引用的形式添加,而不是明文。最后通过一条真实消息确认该频道可以正常工作。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Configure a channel
Never print or persist secret values; channel tokens enter config only as SecretRefs, or through the in-session connect_channel flow where the operator types the secret into a masked prompt. Never hand-edit config files on disk. Every run ends with the observable Prove result or an exact explanation of why it could not be proven.
Gather
openclaw channels list --all
openclaw channels status
openclaw config get channels --json # "Config path not found" is normal before first setup
Confirm the exact config path before writing — key names differ per channel (channels.telegram.botToken, channels.discord.token, ...):
openclaw config schema --json | jq '.properties.channels.properties.telegram'
Mutate
Confirm the intended account and access changes with the operator before writing. Preserve existing approved allowlist entries, dmPolicy, and groupPolicy unless their replacement or change is explicitly approved; never broaden access to make a check pass.
Preferred shell path — token staged as an env var on the gateway process or in a 0600 file, wired as a SecretRef (Telegram example):
openclaw config set channels.telegram.botToken --ref-provider default --ref-source env --ref-id TELEGRAM_BOT_TOKEN
With the bot connected and DM policy pairing, ask the operator to DM it. Read Your Telegram user id in the pairing reply, or run openclaw logs --follow and read senderUserId in that sender's telegram pairing request entry. Stop following once captured; keep unrelated logs private. If the current policy prevents this flow, use an already verified ID or report the discovery blocker; do not broaden access.
Use the numeric Telegram user ID, not a phone number, username, chat/group ID, or bot ID. In this single-user example, 123456789 is a placeholder: replace it with the verified, approved user ID and retain any other approved entries.
openclaw config set channels.telegram.allowFrom '["123456789"]' --strict-json
Multi-field changes in one validated write:
openclaw config patch --stdin <<'JSON'
{ channels: { telegram: { enabled: true, groupPolicy: "allowlist" } } }
JSON
In-session alternative: call the connect_channel tool action with the channel id — the operator enters the token in a masked prompt, never in chat. Avoid openclaw channels add --token <value>: it puts the secret in argv and process listings.
Repair
openclaw doctor --lint
openclaw channels status --probe
doctor --lint can exit 1 for findings: read the report and continue the remaining checks. Ordinary doctor and doctor --non-interactive can write config/state; do not use them for diagnosis before approval. Apply openclaw doctor --fix --non-interactive only after explicit approval, then re-check status.
Prove
Send one real, clearly labeled test message and confirm delivery from the command result (use --dry-run first to inspect the payload):
openclaw message send --channel telegram --target <chatId> --message "OpenClaw channel test — please ignore" --dry-run
openclaw message send --channel telegram --target <chatId> --message "OpenClaw channel test — please ignore"
If sending fails, report the exact account, permission, destination, or network blocker without exposing credentials.
Report
State the channel and account changed, the exact config paths written (never values), the test destination, and the observed delivery result. List any remaining operator action.
Further reference: https://docs.openclaw.ai/channels/telegram (and the matching page for other channels)
常见问题
我的机器人令牌会以明文保存吗?
不会。令牌以对环境变量或安全文件的引用形式保存,因此配置中不会写入密钥本身。
它能更改谁被允许给机器人发消息吗?
除非你同意更改,否则它会保留现有的已批准访问设置;它不会为了通过检查而扩大访问范围。
它支持哪些聊天应用?
它支持多个聊天应用,包括 Telegram 和 Discord,每个应用都有各自的设置。
详情
作者的原始描述
Configure and prove a chat channel with non-interactive one-liners; secrets only as SecretRefs.
repo: openclaw/openclaw
热度
- GitHub 星标
- 394k
- 排名
- #11
- 许可证
- MIT
- 更新时间
- 2026/11/2
评论
- …
同一仓库的更多技能
discord-user-post
394k让你的智能体通过 Discord 桌面应用,以你的身份发送你已批准的消息,并在发送前确认具体频道。
discrawl
394k让你的智能体搜索和总结本地保存的 Discord 消息档案,查看档案的新旧程度,并阅读私信。
gitcrawl
394k让你的智能体搜索已保存的 GitHub 议题和拉取请求档案,将重复内容归类,并在 GitHub 上核实它们的当前状态。
graincrawl
394k让你的智能体搜索已保存的 Granola 会议记录和转写稿,查看它们的新旧程度,并统计某段时间内的数量。