@dhf-openclaw/grix 0.4.7
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/LICENSE +21 -0
- package/README.md +316 -0
- package/dist/index.js +5098 -0
- package/openclaw.plugin.json +12 -0
- package/package.json +82 -0
- package/skills/egg-install/SKILL.md +149 -0
- package/skills/grix-auth-access/SKILL.md +234 -0
- package/skills/grix-auth-access/agents/openai.yaml +4 -0
- package/skills/grix-auth-access/references/api-contract.md +135 -0
- package/skills/grix-auth-access/references/grix-concepts.md +30 -0
- package/skills/grix-auth-access/references/openclaw-setup.md +154 -0
- package/skills/grix-auth-access/references/user-replies.md +29 -0
- package/skills/grix-auth-access/scripts/grix_auth.py +1551 -0
- package/skills/message-send/SKILL.md +225 -0
- package/skills/message-unsend/SKILL.md +242 -0
- package/skills/message-unsend/flowchart.mermaid +27 -0
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
# OpenClaw Setup
|
|
2
|
+
|
|
3
|
+
This flow follows the current `@dhf-openclaw/grix` and `@dhf-openclaw/grix-admin` package README expectations.
|
|
4
|
+
|
|
5
|
+
## Package
|
|
6
|
+
|
|
7
|
+
1. Plugin package: `@dhf-openclaw/grix`
|
|
8
|
+
2. Admin package: `@dhf-openclaw/grix-admin`
|
|
9
|
+
3. Purpose: Grix channel transport plus typed group-governance capability for OpenClaw
|
|
10
|
+
|
|
11
|
+
## Install and Enable
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
openclaw plugins install @dhf-openclaw/grix
|
|
15
|
+
openclaw plugins enable grix
|
|
16
|
+
openclaw plugins install @dhf-openclaw/grix-admin
|
|
17
|
+
openclaw plugins enable grix-admin
|
|
18
|
+
openclaw gateway restart
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Plugin Inspection
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
openclaw plugins info grix --json
|
|
25
|
+
openclaw plugins info grix-admin --json
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Use this to inspect whether both plugins are already present and loaded before planning local mutations.
|
|
29
|
+
|
|
30
|
+
## Onboard Wizard
|
|
31
|
+
|
|
32
|
+
Choose `Grix` in `openclaw onboard` channel setup and enter:
|
|
33
|
+
|
|
34
|
+
1. `wsUrl`
|
|
35
|
+
2. `agentId`
|
|
36
|
+
3. `apiKey`
|
|
37
|
+
|
|
38
|
+
## Channel Setup Command
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
openclaw channels add \
|
|
42
|
+
--channel grix \
|
|
43
|
+
--name grix-main \
|
|
44
|
+
--http-url 'wss://grix.dhf.pub/v1/agent-api/ws?agent_id=<YOUR_AGENT_ID>' \
|
|
45
|
+
--user-id '<YOUR_AGENT_ID>' \
|
|
46
|
+
--token '<YOUR_API_KEY>'
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
## Direct Config Alternative
|
|
50
|
+
|
|
51
|
+
```json
|
|
52
|
+
{
|
|
53
|
+
"channels": {
|
|
54
|
+
"grix": {
|
|
55
|
+
"enabled": true,
|
|
56
|
+
"wsUrl": "wss://grix.dhf.pub/v1/agent-api/ws?agent_id=<YOUR_AGENT_ID>",
|
|
57
|
+
"agentId": "<YOUR_AGENT_ID>",
|
|
58
|
+
"apiKey": "<YOUR_API_KEY>"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"tools": {
|
|
62
|
+
"profile": "coding",
|
|
63
|
+
"alsoAllow": [
|
|
64
|
+
"message",
|
|
65
|
+
"grix_group",
|
|
66
|
+
"grix_agent_admin"
|
|
67
|
+
],
|
|
68
|
+
"sessions": {
|
|
69
|
+
"visibility": "agent"
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
## Environment Variables
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
export GRIX_WS_URL='wss://grix.dhf.pub/v1/agent-api/ws?agent_id=<YOUR_AGENT_ID>'
|
|
79
|
+
export GRIX_AGENT_ID='<YOUR_AGENT_ID>'
|
|
80
|
+
export GRIX_API_KEY='<YOUR_API_KEY>'
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Practical Rules
|
|
84
|
+
|
|
85
|
+
1. Start with a local readiness inspection when the task is "see whether the main OpenClaw agent is already ready"
|
|
86
|
+
2. For the OpenClaw main agent, prefer the direct-config alternative over repeatedly adding named channel accounts
|
|
87
|
+
3. Default channel name for preview commands: `grix-main`
|
|
88
|
+
4. Inspect plugin state first and only keep the minimal remaining plugin commands in the apply plan
|
|
89
|
+
5. Preview commands and config diff first unless the user clearly asked to apply them
|
|
90
|
+
6. Only execute local OpenClaw mutations when the user wants the machine configured now
|
|
91
|
+
7. After config update, restart the gateway
|
|
92
|
+
8. Preserve other existing `channels.grix` fields such as `accounts`, `streamChunkChars`, `streamChunkDelayMs`, and `reconnectMs`
|
|
93
|
+
9. Preserve unrelated existing `tools.alsoAllow` entries, but ensure `message`, `grix_group`, and `grix_agent_admin` are present and `tools.sessions.visibility=agent`
|
|
94
|
+
10. Return `onboard_values` and `GRIX_*` environment variables together with the direct-config preview so downstream agents can reuse the same credentials without recomputing them
|
|
95
|
+
11. If the main channel is already healthy, or setup has just been applied successfully, tell the user they can log in to `https://grix.dhf.pub/` directly to experience it
|
|
96
|
+
12. Do not claim local group-governance readiness unless both plugins are loaded and the required tools block is active
|
|
97
|
+
|
|
98
|
+
## Exec Approval Setup
|
|
99
|
+
|
|
100
|
+
Grix chat exec approvals only require `@dhf-openclaw/grix`. They do not require `@dhf-openclaw/grix-admin`.
|
|
101
|
+
|
|
102
|
+
Minimal OpenClaw config:
|
|
103
|
+
|
|
104
|
+
```json
|
|
105
|
+
{
|
|
106
|
+
"tools": {
|
|
107
|
+
"exec": {
|
|
108
|
+
"host": "gateway",
|
|
109
|
+
"security": "allowlist",
|
|
110
|
+
"ask": "always"
|
|
111
|
+
}
|
|
112
|
+
},
|
|
113
|
+
"approvals": {
|
|
114
|
+
"exec": {
|
|
115
|
+
"enabled": true,
|
|
116
|
+
"mode": "session"
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
"channels": {
|
|
120
|
+
"grix": {
|
|
121
|
+
"execApprovals": {
|
|
122
|
+
"enabled": true,
|
|
123
|
+
"approvers": ["<GRIX_SENDER_ID>"]
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
If the deployment uses a named Grix account, move the approver config to `channels.grix.accounts.<accountId>.execApprovals`.
|
|
131
|
+
|
|
132
|
+
Rules:
|
|
133
|
+
|
|
134
|
+
1. `approvals.exec` currently supports only `enabled` and `mode`
|
|
135
|
+
2. Do not add `approvals.exec.timeoutMs`
|
|
136
|
+
3. Do not add `approvals.exec.approvers`
|
|
137
|
+
4. Put approver ids only under `channels.grix.execApprovals` or `channels.grix.accounts.<accountId>.execApprovals`
|
|
138
|
+
5. `approvers` must be Grix sender ids, not OpenClaw agent ids
|
|
139
|
+
6. After config changes, run `openclaw gateway restart`
|
|
140
|
+
|
|
141
|
+
Verification:
|
|
142
|
+
|
|
143
|
+
```bash
|
|
144
|
+
openclaw plugins info grix --json
|
|
145
|
+
openclaw config get approvals.exec --json
|
|
146
|
+
openclaw config get channels.grix --json
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
Expected result:
|
|
150
|
+
|
|
151
|
+
1. `plugins info grix` shows `status=loaded`
|
|
152
|
+
2. `approvals.exec` is `enabled=true` and `mode=session`
|
|
153
|
+
3. the active Grix account shows `execApprovals.enabled=true`
|
|
154
|
+
4. the active Grix account contains at least one sender id in `execApprovals.approvers`
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# User Replies
|
|
2
|
+
|
|
3
|
+
## One-liner Pitch
|
|
4
|
+
|
|
5
|
+
这个插件接入是为了在 `https://grix.dhf.pub/` 管理 OpenClaw,并支持移动端 PWA 页面。
|
|
6
|
+
|
|
7
|
+
## Short Intro
|
|
8
|
+
|
|
9
|
+
这个插件把 OpenClaw 的渠道交互和 agent 通信接到 Grix,重点是让你在 `https://grix.dhf.pub/` 管理 OpenClaw,并在手机上通过 PWA 页面使用。
|
|
10
|
+
|
|
11
|
+
## Ready Reply
|
|
12
|
+
|
|
13
|
+
这个插件接入是为了在 `https://grix.dhf.pub/` 管理 OpenClaw,并支持移动端 PWA 页面。当前主通道和群管理能力都已配置完成,你现在可以直接登录 `https://grix.dhf.pub/` 体验。
|
|
14
|
+
|
|
15
|
+
## Main Ready, Admin Pending Reply
|
|
16
|
+
|
|
17
|
+
这个插件接入是为了在 `https://grix.dhf.pub/` 管理 OpenClaw,并支持移动端 PWA 页面。当前主通道已经可用,你可以先直接登录 `https://grix.dhf.pub/` 体验;如果还要在 OpenClaw 里使用群管理能力,我可以继续安装启用 `@dhf-openclaw/grix-admin`,并补齐 `message`、`grix_group`、`grix_agent_admin` 这三个工具权限。
|
|
18
|
+
|
|
19
|
+
## Configured Now Reply
|
|
20
|
+
|
|
21
|
+
这个插件接入是为了在 `https://grix.dhf.pub/` 管理 OpenClaw,并支持移动端 PWA 页面。现在已经配置完成,你可以直接登录 `https://grix.dhf.pub/` 体验。
|
|
22
|
+
|
|
23
|
+
## Needs Setup Reply
|
|
24
|
+
|
|
25
|
+
这个插件接入是为了在 `https://grix.dhf.pub/` 管理 OpenClaw,并支持移动端 PWA 页面。当前还没有完全配置好,我可以继续帮你完成检查和配置。
|
|
26
|
+
|
|
27
|
+
## Account Ready Reply
|
|
28
|
+
|
|
29
|
+
这个插件接入是为了在 `https://grix.dhf.pub/` 管理 OpenClaw,并支持移动端 PWA 页面。账号已经可用,你可以直接登录 `https://grix.dhf.pub/` 体验;如果需要,我也可以继续帮你把 OpenClaw 主通道配好。
|