@efengx/openclaw-channel-dragon 0.5.1 → 0.5.2

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.
@@ -86,9 +86,9 @@ export class SseComponent {
86
86
  return;
87
87
  // 2. Handle specific types
88
88
  if (data.type === 'WORKBENCH_MESSAGE') {
89
- const { content, sessionId, attachments, id } = data.payload || {};
89
+ const { content, sessionId, attachments, id, msgId } = data.payload || {};
90
90
  logger?.info?.(`[Dragon Plugin] [SSE] Received from Workbench: "${content?.substring(0, 50)}${content?.length > 50 ? '...' : ''}" [Session: ${sessionId}]`);
91
- this.channel.deliverToOpenClaw(content, sessionId, undefined, attachments, id);
91
+ this.channel.deliverToOpenClaw(content, sessionId, undefined, attachments, msgId || id);
92
92
  }
93
93
  else if (data.type === 'FETCH_HISTORY') {
94
94
  const { sessionId } = data.payload || {};
@@ -9,10 +9,11 @@ export class TelemetryComponent {
9
9
  async stop() { }
10
10
  async reportReply(payload) {
11
11
  try {
12
+ const msgId = crypto.randomUUID();
12
13
  await this.http.fetch(`/api/agents/${this.agentId}/messages/reply`, {
13
14
  method: "POST",
14
15
  headers: { "Content-Type": "application/json" },
15
- body: JSON.stringify(payload),
16
+ body: JSON.stringify({ ...payload, msgId }),
16
17
  });
17
18
  }
18
19
  catch (e) {
@@ -41,10 +42,11 @@ export class TelemetryComponent {
41
42
  };
42
43
  }
43
44
  if (telemetryPayload) {
45
+ const msgId = crypto.randomUUID();
44
46
  this.http.fetch(`/api/agents/${this.agentId}/messages/reply`, {
45
47
  method: "POST",
46
48
  headers: { "Content-Type": "application/json" },
47
- body: JSON.stringify(telemetryPayload),
49
+ body: JSON.stringify({ ...telemetryPayload, msgId }),
48
50
  }).catch(() => { });
49
51
  }
50
52
  }
@@ -2,7 +2,7 @@
2
2
  "id": "dragon",
3
3
  "name": "Dragon Workbench Channel",
4
4
  "description": "Connect OpenClaw to the Dragon agent-client workbench chat.",
5
- "version": "0.5.1",
5
+ "version": "0.5.2",
6
6
  "enabledByDefault": true,
7
7
  "activation": {
8
8
  "onCapabilities": ["hook"]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@efengx/openclaw-channel-dragon",
3
- "version": "0.5.1",
3
+ "version": "0.5.2",
4
4
  "description": "Dragon workbench channel for OpenClaw",
5
5
  "author": "feng xiang <ofengx@gmail.com>",
6
6
  "type": "module",