@qihoo/tuitui-openclaw-channel 1.0.26 → 1.0.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +89 -89
- package/index.ts +21 -21
- package/openclaw.plugin.json +194 -194
- package/package.json +37 -37
- package/skills/tuitui-im-read/SKILL.md +135 -143
- package/src/accounts.ts +56 -49
- package/src/channel.ts +296 -295
- package/src/chat_base.ts +50 -0
- package/src/chat_record.ts +458 -0
- package/src/const.ts +2 -2
- package/src/deduplicator.ts +120 -120
- package/src/env.ts +15 -15
- package/src/filespace.ts +227 -226
- package/src/histories.ts +130 -130
- package/src/inbound.ts +522 -524
- package/src/inbound_body_parse.ts +100 -100
- package/src/monitor.ts +331 -331
- package/src/outbound.ts +236 -447
- package/src/robot_api.ts +252 -270
- package/src/tools.ts +164 -164
- package/src/types.ts +158 -158
- package/src/utils.ts +10 -10
- package/src/websocket.ts +106 -106
package/README.md
CHANGED
|
@@ -1,89 +1,89 @@
|
|
|
1
|
-
<p align="center">
|
|
2
|
-
<img src="https://tuitui.cn/static/img/logo.6449dfbe.svg" alt="TuiTui Logo" width="360">
|
|
3
|
-
</p>
|
|
4
|
-
|
|
5
|
-
# TuiTui Channel for OpenClaw
|
|
6
|
-
|
|
7
|
-
<p class="repo-badges">
|
|
8
|
-
<a href="https://www.npmjs.com/package/@qihoo/tuitui-openclaw-channel"><img alt="npm version" src="https://img.shields.io/npm/v/%40qihoo%2Ftuitui-openclaw-channel"></a>
|
|
9
|
-
<a href="https://www.npmjs.com/package/@qihoo/tuitui-openclaw-channel"><img alt="npm downloads" src="https://img.shields.io/npm/dm/%40qihoo%2Ftuitui-openclaw-channel"></a>
|
|
10
|
-
<a href="https://github.com/openclaw/openclaw"><img alt="OpenClaw" src="https://img.shields.io/badge/OpenClaw-%3E%3D2026.3.13-0A7CFF"></a>
|
|
11
|
-
</p>
|
|
12
|
-
|
|
13
|
-
针对 OpenClaw 的推推机器人 Channel 渠道插件,基于 WebSocket 订阅模式接收消息、基于 HTTP API 发送消息,无需公网 IP。
|
|
14
|
-
|
|
15
|
-
## 功能特性
|
|
16
|
-
|
|
17
|
-
- WebSocket 订阅模式,无需 Webhook 和公网环境依赖
|
|
18
|
-
- 支持私聊、群聊和 @机器人、团队帖子等
|
|
19
|
-
- 支持文本、图片、语音、视频、文件、帖子
|
|
20
|
-
- 支持多 Agent、多机器人绑定、状态检测同步
|
|
21
|
-
|
|
22
|
-
## 文档入口
|
|
23
|
-
|
|
24
|
-
- 推推的公开网站:<https://tuitui.cn>
|
|
25
|
-
- 了解推推机器人:<https://easydoc.soft.360.cn/doc?project=38ed795130e25371ef319aeb60d5b4fa&doc=d1f11ba4cac8886301ede97079df824e&config=menu_toc>
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
## 安装与配置指南
|
|
29
|
-
|
|
30
|
-
> 最小兼容版本为 `OpenClaw 2026.3.13
|
|
31
|
-
|
|
32
|
-
龙虾+推推插件配置指南
|
|
33
|
-
|
|
34
|
-
### 什么是龙虾推推channel插件
|
|
35
|
-
在openclaw上安装推推插件后,可以通过推推与你的openclaw聊天。无需公网ip个人电脑也可以用。
|
|
36
|
-
|
|
37
|
-
### 第一步、创建你的专属推推机器人
|
|
38
|
-
推推搜索 推推机器人助手,和它私聊。使用 /创建 可自助创建一个机器人,得到appid和secret后用。
|
|
39
|
-
另外你也可以对它使用 /改头像 指令。
|
|
40
|
-
|
|
41
|
-
### 第二步、安装openclaw 推推插件
|
|
42
|
-
`openclaw plugins install @qihoo/tuitui-openclaw-channel`
|
|
43
|
-
(如果以前你装过推推插件zip包内测版,需要先把原来的目录删了,不然装不上)
|
|
44
|
-
|
|
45
|
-
有可能会遇到 clawHub 429 报错、npm install failed Error: package.json missing openclaw.hooks 等。
|
|
46
|
-
均为下载环节不稳定导致,可以多试几次或参考下文的“本地源码链接安装”。
|
|
47
|
-
|
|
48
|
-
### 第三步、配置插件。
|
|
49
|
-
打开龙虾dashboard页面,频道->Tuitui,在appid和secret填入第一步获取的,并找到 Enabled 开启,下方点保存。
|
|
50
|
-
|
|
51
|
-
### 第四步、与你的机器人聊天
|
|
52
|
-
|
|
53
|
-
私聊你的龙虾机器人,会提示配对。复制提示消息末尾的那行指令,龙虾主人在终端执行你复制的那行命令,然后就能聊了。
|
|
54
|
-
|
|
55
|
-
群聊的话,你把机器人拉到群能力。需要@机器人触发。第一次会提示主人配置群白名单,主人复制群id在dashboard上配置白名单以后就能聊了。
|
|
56
|
-
|
|
57
|
-
## 插件升级
|
|
58
|
-
后续如果更新,可以用下述命令升级
|
|
59
|
-
`openclaw plugins update tuitui-openclaw-channel`
|
|
60
|
-
|
|
61
|
-
## 安全备忘
|
|
62
|
-
|
|
63
|
-
私聊安全:默认设置下,你的申请的推推机器人是你个人专属机器人,权限只能与你私聊,其他人私聊这个机器人无效;另外推推插件默认模式为配对,即只有配对成功的人才能聊(包括你自己)
|
|
64
|
-
|
|
65
|
-
群聊安全:默认配置下,插件群聊策略为白名单,即只有白名单的群ID才能聊,不在白名单机器人会提示你加白名单
|
|
66
|
-
|
|
67
|
-
## 本地源码链接安装
|
|
68
|
-
|
|
69
|
-
如需本地开发、调试或联调,可使用源码链接安装:
|
|
70
|
-
|
|
71
|
-
```bash
|
|
72
|
-
下载并解压 @qihoo/tuitui-openclaw-channel 到 ./tuitui 目录。
|
|
73
|
-
cd ./tuitui
|
|
74
|
-
npm install
|
|
75
|
-
openclaw plugins install -l .
|
|
76
|
-
```
|
|
77
|
-
## 小建议
|
|
78
|
-
|
|
79
|
-
安装后建议显式配置 `plugins.allow`:
|
|
80
|
-
|
|
81
|
-
```json5
|
|
82
|
-
{
|
|
83
|
-
"plugins": {
|
|
84
|
-
"enabled": true,
|
|
85
|
-
"allow": ["tuitui"]
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
```
|
|
89
|
-
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="https://tuitui.cn/static/img/logo.6449dfbe.svg" alt="TuiTui Logo" width="360">
|
|
3
|
+
</p>
|
|
4
|
+
|
|
5
|
+
# TuiTui Channel for OpenClaw
|
|
6
|
+
|
|
7
|
+
<p class="repo-badges">
|
|
8
|
+
<a href="https://www.npmjs.com/package/@qihoo/tuitui-openclaw-channel"><img alt="npm version" src="https://img.shields.io/npm/v/%40qihoo%2Ftuitui-openclaw-channel"></a>
|
|
9
|
+
<a href="https://www.npmjs.com/package/@qihoo/tuitui-openclaw-channel"><img alt="npm downloads" src="https://img.shields.io/npm/dm/%40qihoo%2Ftuitui-openclaw-channel"></a>
|
|
10
|
+
<a href="https://github.com/openclaw/openclaw"><img alt="OpenClaw" src="https://img.shields.io/badge/OpenClaw-%3E%3D2026.3.13-0A7CFF"></a>
|
|
11
|
+
</p>
|
|
12
|
+
|
|
13
|
+
针对 OpenClaw 的推推机器人 Channel 渠道插件,基于 WebSocket 订阅模式接收消息、基于 HTTP API 发送消息,无需公网 IP。
|
|
14
|
+
|
|
15
|
+
## 功能特性
|
|
16
|
+
|
|
17
|
+
- WebSocket 订阅模式,无需 Webhook 和公网环境依赖
|
|
18
|
+
- 支持私聊、群聊和 @机器人、团队帖子等
|
|
19
|
+
- 支持文本、图片、语音、视频、文件、帖子
|
|
20
|
+
- 支持多 Agent、多机器人绑定、状态检测同步
|
|
21
|
+
|
|
22
|
+
## 文档入口
|
|
23
|
+
|
|
24
|
+
- 推推的公开网站:<https://tuitui.cn>
|
|
25
|
+
- 了解推推机器人:<https://easydoc.soft.360.cn/doc?project=38ed795130e25371ef319aeb60d5b4fa&doc=d1f11ba4cac8886301ede97079df824e&config=menu_toc>
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
## 安装与配置指南
|
|
29
|
+
|
|
30
|
+
> 最小兼容版本为 `OpenClaw 2026.3.13`。
|
|
31
|
+
|
|
32
|
+
龙虾+推推插件配置指南
|
|
33
|
+
|
|
34
|
+
### 什么是龙虾推推channel插件
|
|
35
|
+
在openclaw上安装推推插件后,可以通过推推与你的openclaw聊天。无需公网ip个人电脑也可以用。
|
|
36
|
+
|
|
37
|
+
### 第一步、创建你的专属推推机器人
|
|
38
|
+
推推搜索 推推机器人助手,和它私聊。使用 /创建 可自助创建一个机器人,得到appid和secret后用。
|
|
39
|
+
另外你也可以对它使用 /改头像 指令。
|
|
40
|
+
|
|
41
|
+
### 第二步、安装openclaw 推推插件
|
|
42
|
+
`openclaw plugins install @qihoo/tuitui-openclaw-channel`
|
|
43
|
+
(如果以前你装过推推插件zip包内测版,需要先把原来的目录删了,不然装不上)
|
|
44
|
+
|
|
45
|
+
有可能会遇到 clawHub 429 报错、npm install failed Error: package.json missing openclaw.hooks 等。
|
|
46
|
+
均为下载环节不稳定导致,可以多试几次或参考下文的“本地源码链接安装”。
|
|
47
|
+
|
|
48
|
+
### 第三步、配置插件。
|
|
49
|
+
打开龙虾dashboard页面,频道->Tuitui,在appid和secret填入第一步获取的,并找到 Enabled 开启,下方点保存。
|
|
50
|
+
|
|
51
|
+
### 第四步、与你的机器人聊天
|
|
52
|
+
|
|
53
|
+
私聊你的龙虾机器人,会提示配对。复制提示消息末尾的那行指令,龙虾主人在终端执行你复制的那行命令,然后就能聊了。
|
|
54
|
+
|
|
55
|
+
群聊的话,你把机器人拉到群能力。需要@机器人触发。第一次会提示主人配置群白名单,主人复制群id在dashboard上配置白名单以后就能聊了。
|
|
56
|
+
|
|
57
|
+
## 插件升级
|
|
58
|
+
后续如果更新,可以用下述命令升级
|
|
59
|
+
`openclaw plugins update tuitui-openclaw-channel`
|
|
60
|
+
|
|
61
|
+
## 安全备忘
|
|
62
|
+
|
|
63
|
+
私聊安全:默认设置下,你的申请的推推机器人是你个人专属机器人,权限只能与你私聊,其他人私聊这个机器人无效;另外推推插件默认模式为配对,即只有配对成功的人才能聊(包括你自己)
|
|
64
|
+
|
|
65
|
+
群聊安全:默认配置下,插件群聊策略为白名单,即只有白名单的群ID才能聊,不在白名单机器人会提示你加白名单
|
|
66
|
+
|
|
67
|
+
## 本地源码链接安装
|
|
68
|
+
|
|
69
|
+
如需本地开发、调试或联调,可使用源码链接安装:
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
下载并解压 @qihoo/tuitui-openclaw-channel 到 ./tuitui 目录。
|
|
73
|
+
cd ./tuitui
|
|
74
|
+
npm install
|
|
75
|
+
openclaw plugins install -l .
|
|
76
|
+
```
|
|
77
|
+
## 小建议
|
|
78
|
+
|
|
79
|
+
安装后建议显式配置 `plugins.allow`:
|
|
80
|
+
|
|
81
|
+
```json5
|
|
82
|
+
{
|
|
83
|
+
"plugins": {
|
|
84
|
+
"enabled": true,
|
|
85
|
+
"allow": ["tuitui"]
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
```
|
|
89
|
+
|
package/index.ts
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import type { OpenClawPluginApi } from 'openclaw/plugin-sdk';
|
|
2
|
-
import { emptyPluginConfigSchema } from 'openclaw/plugin-sdk/core';
|
|
3
|
-
import { registerTuiTuiChannel } from './src/channel';
|
|
4
|
-
import { registerTuituiTools } from './src/tools';
|
|
5
|
-
import { registerMonitorHooks } from './src/monitor';
|
|
6
|
-
import { CHANNEL_ID, CHANNEL_NAME } from './src/const';
|
|
7
|
-
import { id } from './openclaw.plugin.json';
|
|
8
|
-
|
|
9
|
-
const plugin = {
|
|
10
|
-
id, // plugin id not is CHANNEL_ID
|
|
11
|
-
name: CHANNEL_NAME,
|
|
12
|
-
description: `${CHANNEL_NAME} chat integration for OpenClaw via WebSocket`,
|
|
13
|
-
configSchema: emptyPluginConfigSchema(),
|
|
14
|
-
register(api: OpenClawPluginApi) {
|
|
15
|
-
registerTuiTuiChannel(api);
|
|
16
|
-
registerTuituiTools(api);
|
|
17
|
-
registerMonitorHooks(api);
|
|
18
|
-
},
|
|
19
|
-
};
|
|
20
|
-
console.log(`[${CHANNEL_ID}] Tuitui Extension Loaded!`);
|
|
21
|
-
export default plugin;
|
|
1
|
+
import type { OpenClawPluginApi } from 'openclaw/plugin-sdk';
|
|
2
|
+
import { emptyPluginConfigSchema } from 'openclaw/plugin-sdk/core';
|
|
3
|
+
import { registerTuiTuiChannel } from './src/channel';
|
|
4
|
+
import { registerTuituiTools } from './src/tools';
|
|
5
|
+
import { registerMonitorHooks } from './src/monitor';
|
|
6
|
+
import { CHANNEL_ID, CHANNEL_NAME } from './src/const';
|
|
7
|
+
import { id } from './openclaw.plugin.json';
|
|
8
|
+
|
|
9
|
+
const plugin = {
|
|
10
|
+
id, // plugin id not is CHANNEL_ID
|
|
11
|
+
name: CHANNEL_NAME,
|
|
12
|
+
description: `${CHANNEL_NAME} chat integration for OpenClaw via WebSocket`,
|
|
13
|
+
configSchema: emptyPluginConfigSchema(),
|
|
14
|
+
register(api: OpenClawPluginApi) {
|
|
15
|
+
registerTuiTuiChannel(api);
|
|
16
|
+
registerTuituiTools(api);
|
|
17
|
+
registerMonitorHooks(api);
|
|
18
|
+
},
|
|
19
|
+
};
|
|
20
|
+
console.log(`[${CHANNEL_ID}] Tuitui Extension Loaded!`);
|
|
21
|
+
export default plugin;
|
package/openclaw.plugin.json
CHANGED
|
@@ -1,195 +1,195 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "tuitui-openclaw-channel",
|
|
3
|
-
"channels": ["tuitui"],
|
|
4
|
-
"skills": ["./skills"],
|
|
5
|
-
"configSchema": {
|
|
6
|
-
"type": "object",
|
|
7
|
-
"additionalProperties": false,
|
|
8
|
-
"properties": {}
|
|
9
|
-
},
|
|
10
|
-
"channelConfigs": {
|
|
11
|
-
"tuitui": {
|
|
12
|
-
"schema": {
|
|
13
|
-
"type": "object",
|
|
14
|
-
"additionalProperties": false,
|
|
15
|
-
"properties": {
|
|
16
|
-
"enabled": { "type": "boolean", "default": true },
|
|
17
|
-
"appId": { "type": "string", "default": "" },
|
|
18
|
-
"appSecret": { "type": "string" },
|
|
19
|
-
"dmPolicy": {
|
|
20
|
-
"type": "string",
|
|
21
|
-
"default": "pairing",
|
|
22
|
-
"enum": ["pairing", "allowlist", "open", "disabled"]
|
|
23
|
-
},
|
|
24
|
-
"allowFrom": {
|
|
25
|
-
"type": "array",
|
|
26
|
-
"default": [],
|
|
27
|
-
"items": { "type": "string" }
|
|
28
|
-
},
|
|
29
|
-
"groupPolicy": {
|
|
30
|
-
"type": "string",
|
|
31
|
-
"default": "allowlist",
|
|
32
|
-
"enum": ["allowlist", "disabled"]
|
|
33
|
-
},
|
|
34
|
-
"requireMention": { "type": "boolean", "default": true },
|
|
35
|
-
"groupAllowFrom": {
|
|
36
|
-
"type": "array",
|
|
37
|
-
"default": [],
|
|
38
|
-
"items": { "type": "string" }
|
|
39
|
-
},
|
|
40
|
-
"channelContext": {
|
|
41
|
-
"type": "string",
|
|
42
|
-
"default": "thread",
|
|
43
|
-
"enum": ["channel", "thread"]
|
|
44
|
-
},
|
|
45
|
-
"emojiReaction": { "type": "boolean", "default": true },
|
|
46
|
-
"monitorEnabled": { "type": "boolean", "default": false },
|
|
47
|
-
"accounts": {
|
|
48
|
-
"type": "object",
|
|
49
|
-
"additionalProperties": {
|
|
50
|
-
"type": "object",
|
|
51
|
-
"additionalProperties": false,
|
|
52
|
-
"properties": {
|
|
53
|
-
"enabled": { "type": "boolean", "default": true },
|
|
54
|
-
"appId": { "type": "string", "default": "" },
|
|
55
|
-
"appSecret": { "type": "string" },
|
|
56
|
-
"dmPolicy": {
|
|
57
|
-
"type": "string",
|
|
58
|
-
"default": "pairing",
|
|
59
|
-
"enum": ["pairing", "allowlist", "open", "disabled"]
|
|
60
|
-
},
|
|
61
|
-
"allowFrom": {
|
|
62
|
-
"type": "array",
|
|
63
|
-
"default": [],
|
|
64
|
-
"items": { "type": "string" }
|
|
65
|
-
},
|
|
66
|
-
"groupPolicy": {
|
|
67
|
-
"type": "string",
|
|
68
|
-
"default": "allowlist",
|
|
69
|
-
"enum": ["allowlist", "disabled"]
|
|
70
|
-
},
|
|
71
|
-
"requireMention": { "type": "boolean", "default": true },
|
|
72
|
-
"groupAllowFrom": {
|
|
73
|
-
"type": "array",
|
|
74
|
-
"items": { "type": "string" }
|
|
75
|
-
},
|
|
76
|
-
"channelContext": {
|
|
77
|
-
"type": "string",
|
|
78
|
-
"default": "thread",
|
|
79
|
-
"enum": ["channel", "thread"]
|
|
80
|
-
},
|
|
81
|
-
"emojiReaction": { "type": "boolean", "default": true },
|
|
82
|
-
"monitorEnabled": { "type": "boolean", "default": false }
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
},
|
|
88
|
-
"uiHints": {
|
|
89
|
-
"enabled": { "order": 1, "help": "开启或关闭" },
|
|
90
|
-
"appId": {
|
|
91
|
-
"help": "推推机器人身份 AppId(你可以推推搜索【推推机器人助手】,和它聊天自助申请推推机器人)",
|
|
92
|
-
"order": 2
|
|
93
|
-
},
|
|
94
|
-
"appSecret": {
|
|
95
|
-
"help": "推推机器人密钥 Secret(推推机器人的 App Secret)",
|
|
96
|
-
"order": 3
|
|
97
|
-
},
|
|
98
|
-
"dmPolicy": {
|
|
99
|
-
"help": "私聊策略(pairing=配对(默认);allowlist=白名单;open=允许所有(不安全);disabled=禁用私聊)",
|
|
100
|
-
"order": 10,
|
|
101
|
-
"advanced": true
|
|
102
|
-
},
|
|
103
|
-
"allowFrom": {
|
|
104
|
-
"help": "私聊白名单-域账号(dmPolicy=allowlist 时生效;pairing 下可用于显式放行用户)。对群聊/团队也能生效",
|
|
105
|
-
"order": 11,
|
|
106
|
-
"advanced": true
|
|
107
|
-
},
|
|
108
|
-
"groupPolicy": {
|
|
109
|
-
"help": "群聊/团队策略(allowlist=白名单;disabled=禁用)",
|
|
110
|
-
"order": 12,
|
|
111
|
-
"advanced": true
|
|
112
|
-
},
|
|
113
|
-
"requireMention": {
|
|
114
|
-
"help": "群组/团队是否需要 @ 机器人才触发 Agent(默认 true)。注意:如果你关闭了这个开关,且有多个龙虾机器人在同一个群里,他们会聊的停不下来",
|
|
115
|
-
"order": 13,
|
|
116
|
-
"advanced": true
|
|
117
|
-
},
|
|
118
|
-
"groupAllowFrom": {
|
|
119
|
-
"help": "群组/团队白名单-包含群ID、团队ID或频道ID(仅在 groupPolicy=allowlist 生效)",
|
|
120
|
-
"order": 14,
|
|
121
|
-
"advanced": true
|
|
122
|
-
},
|
|
123
|
-
"channelContext": {
|
|
124
|
-
"help": "团队-频道上下文(选项已废弃)",
|
|
125
|
-
"order": 15,
|
|
126
|
-
"advanced": true
|
|
127
|
-
},
|
|
128
|
-
"emojiReaction": {
|
|
129
|
-
"help": "在收到消息后,大模型给出反应结果前,先对原消息发送一个\"收到\"的表情回复。",
|
|
130
|
-
"order": 16,
|
|
131
|
-
"advanced": true
|
|
132
|
-
},
|
|
133
|
-
"monitorEnabled": {
|
|
134
|
-
"help": "
|
|
135
|
-
"order": 17,
|
|
136
|
-
"advanced": true
|
|
137
|
-
},
|
|
138
|
-
"accounts": {
|
|
139
|
-
"help": "Accounts(多账户配置)",
|
|
140
|
-
"order": 30,
|
|
141
|
-
"advanced": true
|
|
142
|
-
},
|
|
143
|
-
"accounts.*.enabled": { "order": 301, "help": "开启或关闭" },
|
|
144
|
-
"accounts.*.appId": {
|
|
145
|
-
"help": "推推机器人身份 AppId(你可以推推搜索【推推机器人助手】,和它聊天自助申请推推机器人)",
|
|
146
|
-
"order": 302
|
|
147
|
-
},
|
|
148
|
-
"accounts.*.appSecret": {
|
|
149
|
-
"help": "推推机器人密钥 Secret(推推机器人的 App Secret)",
|
|
150
|
-
"order": 303
|
|
151
|
-
},
|
|
152
|
-
"accounts.*.dmPolicy": {
|
|
153
|
-
"help": "私聊策略(pairing=配对(默认);allowlist=白名单;open=允许所有(不安全);disabled=禁用私聊)",
|
|
154
|
-
"order": 304,
|
|
155
|
-
"advanced": true
|
|
156
|
-
},
|
|
157
|
-
"accounts.*.allowFrom": {
|
|
158
|
-
"help": "私聊白名单-推推域账号(dmPolicy=allowlist 时生效;pairing 下可用于显式放行用户);对群、团队也生效",
|
|
159
|
-
"order": 305,
|
|
160
|
-
"advanced": true
|
|
161
|
-
},
|
|
162
|
-
"accounts.*.groupPolicy": {
|
|
163
|
-
"help": "群聊/团队策略(allowlist=白名单;disabled=禁用)",
|
|
164
|
-
"order": 306,
|
|
165
|
-
"advanced": true
|
|
166
|
-
},
|
|
167
|
-
"accounts.*.requireMention": {
|
|
168
|
-
"help": "群组/团队是否需要 @ 机器人才触发 Agent(默认 true)",
|
|
169
|
-
"order": 307,
|
|
170
|
-
"advanced": true
|
|
171
|
-
},
|
|
172
|
-
"accounts.*.groupAllowFrom": {
|
|
173
|
-
"help": "群组/团队白名单-包含群ID、团队ID或频道ID(仅在 groupPolicy=allowlist 生效)。如果不想所有人使用,可以配置私聊白名单,私聊白名单对群/团队仍然有效",
|
|
174
|
-
"order": 308,
|
|
175
|
-
"advanced": true
|
|
176
|
-
},
|
|
177
|
-
"accounts.*.channelContext": {
|
|
178
|
-
"help": "团队-频道上下文(选项已废弃)",
|
|
179
|
-
"order": 309,
|
|
180
|
-
"advanced": true
|
|
181
|
-
},
|
|
182
|
-
"accounts.*.emojiReaction": {
|
|
183
|
-
"help": "在收到消息后,大模型给出反应结果前,先对原消息发送一个\"收到\"的表情回复。",
|
|
184
|
-
"order": 310,
|
|
185
|
-
"advanced": true
|
|
186
|
-
},
|
|
187
|
-
"accounts.*.monitorEnabled": {
|
|
188
|
-
"help": "
|
|
189
|
-
"order": 311,
|
|
190
|
-
"advanced": true
|
|
191
|
-
}
|
|
192
|
-
}
|
|
193
|
-
}
|
|
194
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"id": "tuitui-openclaw-channel",
|
|
3
|
+
"channels": ["tuitui"],
|
|
4
|
+
"skills": ["./skills"],
|
|
5
|
+
"configSchema": {
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"properties": {}
|
|
9
|
+
},
|
|
10
|
+
"channelConfigs": {
|
|
11
|
+
"tuitui": {
|
|
12
|
+
"schema": {
|
|
13
|
+
"type": "object",
|
|
14
|
+
"additionalProperties": false,
|
|
15
|
+
"properties": {
|
|
16
|
+
"enabled": { "type": "boolean", "default": true },
|
|
17
|
+
"appId": { "type": "string", "default": "" },
|
|
18
|
+
"appSecret": { "type": "string" },
|
|
19
|
+
"dmPolicy": {
|
|
20
|
+
"type": "string",
|
|
21
|
+
"default": "pairing",
|
|
22
|
+
"enum": ["pairing", "allowlist", "open", "disabled"]
|
|
23
|
+
},
|
|
24
|
+
"allowFrom": {
|
|
25
|
+
"type": "array",
|
|
26
|
+
"default": [],
|
|
27
|
+
"items": { "type": "string" }
|
|
28
|
+
},
|
|
29
|
+
"groupPolicy": {
|
|
30
|
+
"type": "string",
|
|
31
|
+
"default": "allowlist",
|
|
32
|
+
"enum": ["allowlist", "disabled"]
|
|
33
|
+
},
|
|
34
|
+
"requireMention": { "type": "boolean", "default": true },
|
|
35
|
+
"groupAllowFrom": {
|
|
36
|
+
"type": "array",
|
|
37
|
+
"default": [],
|
|
38
|
+
"items": { "type": "string" }
|
|
39
|
+
},
|
|
40
|
+
"channelContext": {
|
|
41
|
+
"type": "string",
|
|
42
|
+
"default": "thread",
|
|
43
|
+
"enum": ["channel", "thread"]
|
|
44
|
+
},
|
|
45
|
+
"emojiReaction": { "type": "boolean", "default": true },
|
|
46
|
+
"monitorEnabled": { "type": "boolean", "default": false },
|
|
47
|
+
"accounts": {
|
|
48
|
+
"type": "object",
|
|
49
|
+
"additionalProperties": {
|
|
50
|
+
"type": "object",
|
|
51
|
+
"additionalProperties": false,
|
|
52
|
+
"properties": {
|
|
53
|
+
"enabled": { "type": "boolean", "default": true },
|
|
54
|
+
"appId": { "type": "string", "default": "" },
|
|
55
|
+
"appSecret": { "type": "string" },
|
|
56
|
+
"dmPolicy": {
|
|
57
|
+
"type": "string",
|
|
58
|
+
"default": "pairing",
|
|
59
|
+
"enum": ["pairing", "allowlist", "open", "disabled"]
|
|
60
|
+
},
|
|
61
|
+
"allowFrom": {
|
|
62
|
+
"type": "array",
|
|
63
|
+
"default": [],
|
|
64
|
+
"items": { "type": "string" }
|
|
65
|
+
},
|
|
66
|
+
"groupPolicy": {
|
|
67
|
+
"type": "string",
|
|
68
|
+
"default": "allowlist",
|
|
69
|
+
"enum": ["allowlist", "disabled"]
|
|
70
|
+
},
|
|
71
|
+
"requireMention": { "type": "boolean", "default": true },
|
|
72
|
+
"groupAllowFrom": {
|
|
73
|
+
"type": "array",
|
|
74
|
+
"items": { "type": "string" }
|
|
75
|
+
},
|
|
76
|
+
"channelContext": {
|
|
77
|
+
"type": "string",
|
|
78
|
+
"default": "thread",
|
|
79
|
+
"enum": ["channel", "thread"]
|
|
80
|
+
},
|
|
81
|
+
"emojiReaction": { "type": "boolean", "default": true },
|
|
82
|
+
"monitorEnabled": { "type": "boolean", "default": false }
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
"uiHints": {
|
|
89
|
+
"enabled": { "order": 1, "help": "开启或关闭" },
|
|
90
|
+
"appId": {
|
|
91
|
+
"help": "推推机器人身份 AppId(你可以推推搜索【推推机器人助手】,和它聊天自助申请推推机器人)",
|
|
92
|
+
"order": 2
|
|
93
|
+
},
|
|
94
|
+
"appSecret": {
|
|
95
|
+
"help": "推推机器人密钥 Secret(推推机器人的 App Secret)",
|
|
96
|
+
"order": 3
|
|
97
|
+
},
|
|
98
|
+
"dmPolicy": {
|
|
99
|
+
"help": "私聊策略(pairing=配对(默认);allowlist=白名单;open=允许所有(不安全);disabled=禁用私聊)",
|
|
100
|
+
"order": 10,
|
|
101
|
+
"advanced": true
|
|
102
|
+
},
|
|
103
|
+
"allowFrom": {
|
|
104
|
+
"help": "私聊白名单-域账号(dmPolicy=allowlist 时生效;pairing 下可用于显式放行用户)。对群聊/团队也能生效",
|
|
105
|
+
"order": 11,
|
|
106
|
+
"advanced": true
|
|
107
|
+
},
|
|
108
|
+
"groupPolicy": {
|
|
109
|
+
"help": "群聊/团队策略(allowlist=白名单;disabled=禁用)",
|
|
110
|
+
"order": 12,
|
|
111
|
+
"advanced": true
|
|
112
|
+
},
|
|
113
|
+
"requireMention": {
|
|
114
|
+
"help": "群组/团队是否需要 @ 机器人才触发 Agent(默认 true)。注意:如果你关闭了这个开关,且有多个龙虾机器人在同一个群里,他们会聊的停不下来",
|
|
115
|
+
"order": 13,
|
|
116
|
+
"advanced": true
|
|
117
|
+
},
|
|
118
|
+
"groupAllowFrom": {
|
|
119
|
+
"help": "群组/团队白名单-包含群ID、团队ID或频道ID(仅在 groupPolicy=allowlist 生效)",
|
|
120
|
+
"order": 14,
|
|
121
|
+
"advanced": true
|
|
122
|
+
},
|
|
123
|
+
"channelContext": {
|
|
124
|
+
"help": "团队-频道上下文(选项已废弃)",
|
|
125
|
+
"order": 15,
|
|
126
|
+
"advanced": true
|
|
127
|
+
},
|
|
128
|
+
"emojiReaction": {
|
|
129
|
+
"help": "在收到消息后,大模型给出反应结果前,先对原消息发送一个\"收到\"的表情回复。",
|
|
130
|
+
"order": 16,
|
|
131
|
+
"advanced": true
|
|
132
|
+
},
|
|
133
|
+
"monitorEnabled": {
|
|
134
|
+
"help": "是否开启agent事件信息上报(默认 false)。修改后必须重启网关才能生效。",
|
|
135
|
+
"order": 17,
|
|
136
|
+
"advanced": true
|
|
137
|
+
},
|
|
138
|
+
"accounts": {
|
|
139
|
+
"help": "Accounts(多账户配置)",
|
|
140
|
+
"order": 30,
|
|
141
|
+
"advanced": true
|
|
142
|
+
},
|
|
143
|
+
"accounts.*.enabled": { "order": 301, "help": "开启或关闭" },
|
|
144
|
+
"accounts.*.appId": {
|
|
145
|
+
"help": "推推机器人身份 AppId(你可以推推搜索【推推机器人助手】,和它聊天自助申请推推机器人)",
|
|
146
|
+
"order": 302
|
|
147
|
+
},
|
|
148
|
+
"accounts.*.appSecret": {
|
|
149
|
+
"help": "推推机器人密钥 Secret(推推机器人的 App Secret)",
|
|
150
|
+
"order": 303
|
|
151
|
+
},
|
|
152
|
+
"accounts.*.dmPolicy": {
|
|
153
|
+
"help": "私聊策略(pairing=配对(默认);allowlist=白名单;open=允许所有(不安全);disabled=禁用私聊)",
|
|
154
|
+
"order": 304,
|
|
155
|
+
"advanced": true
|
|
156
|
+
},
|
|
157
|
+
"accounts.*.allowFrom": {
|
|
158
|
+
"help": "私聊白名单-推推域账号(dmPolicy=allowlist 时生效;pairing 下可用于显式放行用户);对群、团队也生效",
|
|
159
|
+
"order": 305,
|
|
160
|
+
"advanced": true
|
|
161
|
+
},
|
|
162
|
+
"accounts.*.groupPolicy": {
|
|
163
|
+
"help": "群聊/团队策略(allowlist=白名单;disabled=禁用)",
|
|
164
|
+
"order": 306,
|
|
165
|
+
"advanced": true
|
|
166
|
+
},
|
|
167
|
+
"accounts.*.requireMention": {
|
|
168
|
+
"help": "群组/团队是否需要 @ 机器人才触发 Agent(默认 true)",
|
|
169
|
+
"order": 307,
|
|
170
|
+
"advanced": true
|
|
171
|
+
},
|
|
172
|
+
"accounts.*.groupAllowFrom": {
|
|
173
|
+
"help": "群组/团队白名单-包含群ID、团队ID或频道ID(仅在 groupPolicy=allowlist 生效)。如果不想所有人使用,可以配置私聊白名单,私聊白名单对群/团队仍然有效",
|
|
174
|
+
"order": 308,
|
|
175
|
+
"advanced": true
|
|
176
|
+
},
|
|
177
|
+
"accounts.*.channelContext": {
|
|
178
|
+
"help": "团队-频道上下文(选项已废弃)",
|
|
179
|
+
"order": 309,
|
|
180
|
+
"advanced": true
|
|
181
|
+
},
|
|
182
|
+
"accounts.*.emojiReaction": {
|
|
183
|
+
"help": "在收到消息后,大模型给出反应结果前,先对原消息发送一个\"收到\"的表情回复。",
|
|
184
|
+
"order": 310,
|
|
185
|
+
"advanced": true
|
|
186
|
+
},
|
|
187
|
+
"accounts.*.monitorEnabled": {
|
|
188
|
+
"help": "是否开启agent事件信息上报(默认 false)。修改后必须重启网关才能生效。",
|
|
189
|
+
"order": 311,
|
|
190
|
+
"advanced": true
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
195
|
}
|