@eclaw/openclaw-channel 1.1.3 → 1.1.4
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 +15 -2
- package/dist/onboarding.js +1 -10
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,6 +6,16 @@ This plugin enables OpenClaw bots to communicate with E-Claw users as a native c
|
|
|
6
6
|
|
|
7
7
|
## Installation
|
|
8
8
|
|
|
9
|
+
**In OpenClaw terminal (Zeabur / Railway SSH):**
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
openclaw plugins install @eclaw/openclaw-channel
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
> ⚠️ Do **not** use `npm install` directly — OpenClaw uses pnpm internally, and mixing package managers will cause a crash (`Cannot read properties of null`).
|
|
16
|
+
|
|
17
|
+
**In a standalone Node.js project:**
|
|
18
|
+
|
|
9
19
|
```bash
|
|
10
20
|
npm install @eclaw/openclaw-channel
|
|
11
21
|
```
|
|
@@ -207,8 +217,11 @@ fs.writeFileSync(p, JSON.stringify(cfg, null, 2));
|
|
|
207
217
|
// 3. Remove old plugin files
|
|
208
218
|
execSync('rm -rf /home/node/.openclaw/extensions/openclaw-channel');
|
|
209
219
|
|
|
210
|
-
// 4.
|
|
211
|
-
var
|
|
220
|
+
// 4. Fetch latest version from GitHub and install
|
|
221
|
+
var pkgJson = execSync('curl -sf https://raw.githubusercontent.com/HankHuang0516/openclaw-channel-eclaw/main/package.json', { encoding: 'utf8' });
|
|
222
|
+
var latestVersion = JSON.parse(pkgJson).version;
|
|
223
|
+
console.log('Installing @eclaw/openclaw-channel@' + latestVersion + ' ...');
|
|
224
|
+
var out = execSync('openclaw plugins install @eclaw/openclaw-channel@' + latestVersion + ' 2>&1', { encoding: 'utf8' });
|
|
212
225
|
console.log(out);
|
|
213
226
|
|
|
214
227
|
// 5. Restore channel config
|
package/dist/onboarding.js
CHANGED
|
@@ -33,15 +33,6 @@ export const eclawOnboardingAdapter = {
|
|
|
33
33
|
initialValue: resolved.apiKey || '',
|
|
34
34
|
validate: (v) => (String(v ?? '').trim() ? undefined : 'Required'),
|
|
35
35
|
});
|
|
36
|
-
const entityIdStr = await prompter.text({
|
|
37
|
-
message: 'Entity ID (0–3)',
|
|
38
|
-
placeholder: '0',
|
|
39
|
-
initialValue: String(resolved.entityId ?? 0),
|
|
40
|
-
validate: (v) => {
|
|
41
|
-
const n = Number(v);
|
|
42
|
-
return Number.isInteger(n) && n >= 0 && n <= 3 ? undefined : 'Must be 0–3';
|
|
43
|
-
},
|
|
44
|
-
});
|
|
45
36
|
const botName = await prompter.text({
|
|
46
37
|
message: 'Bot display name (optional)',
|
|
47
38
|
placeholder: 'My Bot',
|
|
@@ -63,7 +54,7 @@ export const eclawOnboardingAdapter = {
|
|
|
63
54
|
[accountId]: {
|
|
64
55
|
apiKey: String(apiKey).trim(),
|
|
65
56
|
apiBase: resolved.apiBase || 'https://eclawbot.com',
|
|
66
|
-
entityId:
|
|
57
|
+
entityId: resolved.entityId, // keep existing if re-configuring, else undefined = auto-assign
|
|
67
58
|
botName: String(botName).trim() || undefined,
|
|
68
59
|
webhookUrl: String(webhookUrl).trim() || undefined,
|
|
69
60
|
enabled: true,
|