@zytrux/daoyu
v0.1.17
Published
Daoyu 3D AI conversation channel plugin for OpenClaw.
Downloads
36
Maintainers
Readme
daoyu
Daoyu channel plugin for OpenClaw.
Daoyu is a 3D chat software product focused on AI-powered conversational experiences.
- Product website: aidaoyu.cn
- Company website: zytrux.com
Repository / 仓库地址: zytrux-tech/openclaw-daoyu
Issue Reporting / 问题反馈: Please open an Issue in the repository if installation, connection, or signing fails.
如遇安装、连接、签名校验问题,请在仓库中提交 Issue。Production Only / 仅支持正式环境: This plugin is designed for production deployment only. Use
https:///wss://only.
本插件仅面向正式环境发布与使用,只支持https:///wss://。
English
Features
appId/appSecretbot authentication- persistent WebSocket connection to Daoyu server
- signed inbound and outbound frames
- multi-account support
- isolated session context per
accountId - runtime token cache with persisted
deviceId
Installation
Install from npm:
openclaw plugins install @zytrux/daoyuInstall from a local archive:
openclaw plugins install ./zytrux-daoyu-0.1.17.tgzUpgrade
Repack and reinstall the plugin after code changes:
pnpm pack
openclaw plugins install ./zytrux-daoyu-0.1.17.tgzThen restart the gateway:
openclaw gateway --port 18789 --verboseCompatibility
This plugin follows the OpenClaw SDK migration guidance and uses scoped plugin SDK subpath imports.
Requirements:
- use a recent OpenClaw version that supports scoped plugin SDK imports
- do not use deprecated
openclaw/plugin-sdk/compat - reinstall the plugin package after upgrading plugin code
Minimal Config
{
"channels": {
"daoyu": {
"enabled": true,
"accounts": {
"bota": {
"enabled": true,
"auth": {
"appId": "bot_xxx",
"appSecret": "sec_xxx"
}
}
}
}
}
}Default values:
serverUrl = https://api.aidaoyu.cnwsPath = /openclaw/wsoauth.tokenPath = /openclaw/oauth/tokenauth.requiredSignatures = trueauth.signatureDebug = false
Runtime behavior:
deviceIdmay be written back to config for stable device identityaccessTokenis cached in memory and is not written back toopenclaw.json
Multi-Account Example
{
"agents": {
"list": [
{
"id": "daoyu-bota",
"workspace": "/root/.openclaw/workspace/daoyu-bota",
"agentDir": "/root/.openclaw/agents/daoyu-bota/agent"
},
{
"id": "daoyu-botb",
"workspace": "/root/.openclaw/workspace/daoyu-botb",
"agentDir": "/root/.openclaw/agents/daoyu-botb/agent"
}
]
},
"bindings": [
{
"agentId": "daoyu-bota",
"match": {
"channel": "daoyu",
"accountId": "bota"
}
},
{
"agentId": "daoyu-botb",
"match": {
"channel": "daoyu",
"accountId": "botb"
}
}
],
"channels": {
"daoyu": {
"enabled": true,
"defaultAccount": "bota",
"accounts": {
"bota": {
"enabled": true,
"auth": {
"appId": "bot_xxx_a",
"appSecret": "sec_xxx_a"
}
},
"botb": {
"enabled": true,
"auth": {
"appId": "bot_xxx_b",
"appSecret": "sec_xxx_b"
}
}
}
}
}
}Server Requirements
Your Daoyu server should provide:
POST /openclaw/oauth/tokenGET /openclaw/wsAuthorization: Bearer <accessToken>for WebSocket handshake- frame signing compatible with the Daoyu plugin protocol
Recommended production behavior:
- bind
requestIdto the originaluid + appId - rate limit token requests and failed WS handshakes
- keep token TTL short enough for rotation
- avoid logging raw business payloads in production
Security
Production deployment requirements:
- use
https://andwss://only - keep
requiredSignatures = true - keep
signatureDebug = false - do not commit
appSecret,accessToken, or localopenclaw.json - rotate bot secrets when credentials are exposed
Notes
- each account keeps its own runtime token cache,
deviceId, and session context - session isolation key includes
accountId - different accounts can stay online at the same time on one gateway
中文
Daoyu 是一款面向 AI 对话体验的 3D Chat 软件。
- 产品官网:aidaoyu.cn
- 公司官网:zytrux.com
功能特性
- 支持
appId/appSecretBOT 鉴权 - 支持与 Daoyu 服务端保持持久 WebSocket 长连接
- 支持消息帧签名
- 支持多账户同时在线
- 按
accountId隔离上下文 accessToken运行时缓存,deviceId持久化
安装
从 npm 安装:
openclaw plugins install @zytrux/daoyu从本地压缩包安装:
openclaw plugins install ./zytrux-daoyu-0.1.17.tgz升级
代码更新后,重新打包并重新安装:
pnpm pack
openclaw plugins install ./zytrux-daoyu-0.1.17.tgz然后重启网关:
openclaw gateway --port 18789 --verbose兼容性
本插件已按 OpenClaw 官方 SDK migration 方案切换为 scoped plugin SDK subpath import。
要求:
- 使用支持 scoped plugin SDK import 的较新版本 OpenClaw
- 不再使用已废弃的
openclaw/plugin-sdk/compat - 插件升级后需要重新安装插件包
最小配置
{
"channels": {
"daoyu": {
"enabled": true,
"accounts": {
"bota": {
"enabled": true,
"auth": {
"appId": "bot_xxx",
"appSecret": "sec_xxx"
}
}
}
}
}
}默认值:
serverUrl = https://api.aidaoyu.cnwsPath = /openclaw/wsoauth.tokenPath = /openclaw/oauth/tokenauth.requiredSignatures = trueauth.signatureDebug = false
运行时行为:
deviceId可能会回写到配置,用于保持设备身份稳定accessToken仅在运行时内存缓存,不会回写到openclaw.json
多账户配置示例
{
"agents": {
"list": [
{
"id": "daoyu-bota",
"workspace": "/root/.openclaw/workspace/daoyu-bota",
"agentDir": "/root/.openclaw/agents/daoyu-bota/agent"
},
{
"id": "daoyu-botb",
"workspace": "/root/.openclaw/workspace/daoyu-botb",
"agentDir": "/root/.openclaw/agents/daoyu-botb/agent"
}
]
},
"bindings": [
{
"agentId": "daoyu-bota",
"match": {
"channel": "daoyu",
"accountId": "bota"
}
},
{
"agentId": "daoyu-botb",
"match": {
"channel": "daoyu",
"accountId": "botb"
}
}
],
"channels": {
"daoyu": {
"enabled": true,
"defaultAccount": "bota",
"accounts": {
"bota": {
"enabled": true,
"auth": {
"appId": "bot_xxx_a",
"appSecret": "sec_xxx_a"
}
},
"botb": {
"enabled": true,
"auth": {
"appId": "bot_xxx_b",
"appSecret": "sec_xxx_b"
}
}
}
}
}
}服务端要求
Daoyu 服务端至少需要提供:
POST /openclaw/oauth/tokenGET /openclaw/ws- WebSocket 握手时使用
Authorization: Bearer <accessToken> - 与插件一致的消息帧签名协议
正式环境建议:
- 将
requestId与原始uid + appId做强绑定 - 对 token 获取和 WS 握手失败做限流
- 缩短 token TTL,便于密钥轮换
- 生产环境避免记录原始业务正文
安全要求
正式环境请遵循:
- 只使用
https://和wss:// - 保持
requiredSignatures = true - 保持
signatureDebug = false - 不要提交
appSecret、accessToken、本地openclaw.json - 凭据泄露后及时轮换 BOT 密钥
说明
- 每个账户都有自己的 token 缓存、
deviceId和会话上下文 - 会话隔离键中包含
accountId - 不同账户可以同时连接到同一个 OpenClaw gateway
