@efengx/openclaw-channel-dragon 0.5.7 → 0.5.8
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/dist/index.js +5 -5
- package/openclaw.plugin.json +1 -1
- package/package.json +6 -6
package/dist/index.js
CHANGED
|
@@ -57,10 +57,10 @@ const base = createChannelPluginBase({
|
|
|
57
57
|
},
|
|
58
58
|
config: {
|
|
59
59
|
listAccountIds: (cfg) => {
|
|
60
|
-
return Object.keys(cfg
|
|
60
|
+
return Object.keys(cfg?.channels?.[channelId]?.accounts || { "default": {} });
|
|
61
61
|
},
|
|
62
62
|
resolveAccount: (cfg, accountId = "default") => {
|
|
63
|
-
const accountConfig = cfg
|
|
63
|
+
const accountConfig = cfg?.channels?.[channelId]?.accounts?.[accountId] || {};
|
|
64
64
|
return {
|
|
65
65
|
accountId,
|
|
66
66
|
agentId: accountConfig.agentId || accountId,
|
|
@@ -113,11 +113,11 @@ const entry = defineChannelPluginEntry({
|
|
|
113
113
|
if (!sessionKey || !sessionKey.startsWith(`${channelId}:`))
|
|
114
114
|
return;
|
|
115
115
|
const accountId = sessionKey.split(':')[2] || "default";
|
|
116
|
-
const account = base.config.resolveAccount(api
|
|
116
|
+
const account = base.config.resolveAccount(api?.runtime?.cfg, accountId);
|
|
117
117
|
const container = await getOrCreateContainer(account, {
|
|
118
|
-
cfg: api
|
|
118
|
+
cfg: api?.runtime?.cfg,
|
|
119
119
|
abortSignal: new AbortController().signal,
|
|
120
|
-
channelRuntime: api
|
|
120
|
+
channelRuntime: api?.runtime?.channelRuntime // Ensure runtime is passed
|
|
121
121
|
});
|
|
122
122
|
const channel = container.get('channel');
|
|
123
123
|
await channel.handleAgentEvent(evt);
|
package/openclaw.plugin.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@efengx/openclaw-channel-dragon",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.8",
|
|
4
4
|
"description": "Dragon workbench channel for OpenClaw",
|
|
5
5
|
"author": "feng xiang <ofengx@gmail.com>",
|
|
6
6
|
"type": "module",
|
|
@@ -11,10 +11,6 @@
|
|
|
11
11
|
"openclaw.plugin.json",
|
|
12
12
|
"README.md"
|
|
13
13
|
],
|
|
14
|
-
"scripts": {
|
|
15
|
-
"build": "tsc -p tsconfig.json",
|
|
16
|
-
"lint": "echo \"(skip)\""
|
|
17
|
-
},
|
|
18
14
|
"dependencies": {
|
|
19
15
|
"openclaw": "^2026.4.12"
|
|
20
16
|
},
|
|
@@ -36,5 +32,9 @@
|
|
|
36
32
|
},
|
|
37
33
|
"publishConfig": {
|
|
38
34
|
"access": "public"
|
|
35
|
+
},
|
|
36
|
+
"scripts": {
|
|
37
|
+
"build": "tsc -p tsconfig.json",
|
|
38
|
+
"lint": "echo \"(skip)\""
|
|
39
39
|
}
|
|
40
|
-
}
|
|
40
|
+
}
|