OpenClaw 插件
为 OpenClaw 所有渠道接入 VoxFlow TTS — WeChat、Telegram、Discord、Slack、飞书、钉钉等。
94+ 中文音色,多语言自动检测,扫码登录,无需 API Key。
用 AI 助手安装
不想手动配置?把下面的安装说明复制给 Claude、ChatGPT 等 AI 编程助手,让 AI 帮你执行。
I want to install the VoxFlow TTS plugin for OpenClaw. Here are the steps — please run them for me:
1. Make sure OpenClaw is up to date (plugin requires v2026.3.22+):
openclaw update
2. Install the plugin from npm:
openclaw plugins install @voxflow/openclaw-tts
2. Restart the gateway:
openclaw gateway restart
3. Open my openclaw.json (find it with: openclaw config path) and merge in the following — do not overwrite existing keys:
{
"messages": {
"tts": {
"auto": "always",
"provider": "voxflow"
}
},
"plugins": {
"enabled": true,
"allow": ["openclaw-tts"],
"entries": {
"openclaw-tts": {
"config": {
"voice": "v-female-R2s4N9qJ",
"speed": 1.0
}
}
}
}
}
4. After saving the config, tell me which chat channel I'm using (WeChat / Telegram / Discord / Slack / other). Then I'll send a message there — if I'm not logged in, the bot will automatically reply with a login link from voxflow.studio. I'll open it in my browser to complete auth.
更喜欢手动操作?按下面步骤来:
手动安装步骤
三步完成配置,全程不需要手动填写 API Key:
更新 OpenClaw 并安装插件
插件需要 OpenClaw v2026.3.22+,先确认版本:
openclaw update
openclaw plugins install @voxflow/openclaw-tts
配置 openclaw.json
{
"messages": {
"tts": {
"auto": "always",
"provider": "voxflow"
}
},
"plugins": {
"enabled": true,
"entries": {
"openclaw-tts": {
"config": {
"voice": "v-female-R2s4N9qJ",
"speed": 1.0
}
}
}
}
}
重启 Gateway & 登录
openclaw gateway restart
重启后,在任意 OpenClaw 聊天渠道里发一条消息。如果未登录,Bot 会自动回复一个授权链接:
🔑 VoxFlow 未登录
点击登录:https://voxflow.studio/openclaw-auth?code=VF-XXXX
点击链接,Google 登录或邮箱 OTP,配对完成后之后每条回复都会附带语音 🎙️
登录 & 授权
VoxFlow 插件使用设备码授权流程(RFC 8628),全程在浏览器里完成,无需在配置文件里填写 Token:
/voxflow login → Bot 返回配对链接,例如:Token 保存在 ~/.config/voxflow/token.json,有效期约 1 小时。到期后重新发 /voxflow login 即可,无需重启 OpenClaw。
高级用法:设置环境变量 VOXFLOW_TOKEN=<jwt> 或 VOXFLOW_JWT=<jwt> 可跳过浏览器登录(适合服务器部署)。
TTS 自动语音模式
messages.tts.auto 控制何时触发语音回复:
| 模式 | 触发时机 | 适用场景 |
|---|---|---|
off |
从不 | 仅文字,默认值 |
always |
每条回复都发语音 | 语音助手场景,推荐 |
inbound |
收到消息时 AI 回复带语音,主动推送不带 | 混合文字/语音群组 |
tagged |
LLM 判断是否需要语音 | 智能选择,消耗更多推理 |
音色选择
在 openclaw.json 中设置 voice 字段指定音色 ID:
"plugins": {
"entries": {
"openclaw-tts": {
"config": {
"voice": "v-female-R2s4N9qJ", // 默认音色
"speed": 1.0 // 语速,0.5–2.0
}
}
}
}
部分推荐音色(更多音色在 VoxFlow 音色库 中查询):
| 音色 ID | 描述 | 语言 |
|---|---|---|
v-female-R2s4N9qJ |
自然女声,默认推荐 | 中文 / 多语言 |
通过 /voxflow voices 查询 |
94+ 中文音色 | zh / en / ja |
VoxFlow 支持多语言自动检测 — 中英日混合文本会自动选用对应口音合成。
登录触发方式
插件没有独立的命令界面。登录链接由插件在首次合成时自动触发:发任意一条消息,如果未登录,Bot 就会回复授权链接。
🔑 VoxFlow 未登录
点击登录:https://voxflow.studio/openclaw-auth?code=VF-XXXX
或运行:npx voxflow login
配对码有效期 5 分钟。
登录完成后无需重启,下一条消息即刻生效。
渠道支持
插件输出 MP3 音频,OpenClaw 框架负责将其转换为各渠道所需格式并发送。只要你的 OpenClaw 版本支持该渠道的语音消息,VoxFlow 就可以使用。
已验证可用:WeChat iLink、Telegram。其他渠道(Discord、Slack、飞书等)取决于 OpenClaw 对该渠道的语音支持情况。
完整配置示例
{
"messages": {
"tts": {
"auto": "always", // always | inbound | tagged | off
"provider": "voxflow" // 指定使用 VoxFlow TTS
}
},
"channels": {
"telegram": {
"enabled": true
// botToken 通过环境变量传入:export TELEGRAM_BOT_TOKEN=xxx
}
},
"plugins": {
"enabled": true,
"load": {
"paths": [] // 留空使用 npm 安装的包
},
"entries": {
"openclaw-tts": {
"config": {
"voice": "v-female-R2s4N9qJ", // 音色 ID
"speed": 1.0, // 语速 0.5–2.0
"apiBase": "https://api.voxflow.studio", // 可选,默认值
"timeoutMs": 30000 // 超时毫秒,默认 30s
}
}
}
}
}
配额 & 定价
每次 TTS 合成消耗 100 配额。查询音色列表不消耗配额。
| 套餐 | 月配额 | 约合 TTS 次数 | 价格 |
|---|---|---|---|
| Free | 10,000 | ~100 次 | $0 |
| Plus | 100,000 | ~1,000 次 | $9/mo |
| Pro | 250,000 | ~2,500 次 | $29/mo |
| Max | 600,000 | ~6,000 次 | $59/mo |
邀请好友各得 5,000 bonus 配额。配额不足时 Bot 会提示升级。 查看套餐详情 →
常见问题
▶ 插件加载失败:Cannot find module 'plugin-sdk/root-alias.cjs/plugin-entry'?
OpenClaw 版本过低,插件需要 v2026.3.22+。运行:
openclaw update
更新后重新安装插件即可。
▶ 发消息没有语音回复?
1. 确认 messages.tts.auto 不是 off,推荐设为 always
2. 发任意消息,如果未登录 Bot 会自动回复授权链接,按提示登录即可
3. 如果改过配置,确认已执行 openclaw gateway restart
▶ 登录链接打开报错?
配对码有效期 5 分钟。超时后重新发 /voxflow login 获取新链接。
▶ Token 过期了怎么办?
Supabase JWT 有效期约 1 小时。过期后发 /voxflow login 重新登录,无需重启 OpenClaw。
▶ 配额不够用了?
Free 套餐每月 10,000 配额(约 100 次 TTS)。配额耗尽后 Bot 会提示:
"VoxFlow quota exceeded — upgrade at https://voxflow.studio/pricing"
邀请好友可获得额外 5,000 bonus 配额。升级套餐 →
▶ 服务器部署,不方便用浏览器登录?
设置环境变量跳过浏览器授权:
export VOXFLOW_TOKEN=<your-jwt>
JWT 可通过 voxflow login(VoxFlow CLI)在本机登录后,从 ~/.config/voxflow/token.json 中读取 access_token 字段获得,然后复制到服务器环境变量。注意 JWT 有效期约 1 小时,到期后需重新获取。
如果使用 systemd 管理服务,还建议加上以下两个变量防止 mDNS 冲突导致频繁重启:
OPENCLAW_DISABLE_BONJOUR=1 OPENCLAW_ALLOW_MULTI_GATEWAY=1
长期 Token 支持正在开发中(#913),届时将支持不过期的 API Key,无需每小时刷新。
▶ 插件加载了但提示 "plugins.allow is empty"?
这是 OpenClaw 的安全提示,不影响功能。如果想消除警告,在 openclaw.json 里添加:
"plugins": {
"allow": ["openclaw-tts"]
}
⚠️ 注意:某些 OpenClaw 版本设置 allow 列表后渠道会无法启动。如遇此问题,删除 allow 字段即可恢复。
MCP Server → · CLI → · 所有文档 →