@openclaw/synology-chat 2026.7.1-beta.2 → 2026.7.1-beta.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/dist/api.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as setSynologyRuntime, t as synologyChatPlugin } from "./channel-
|
|
1
|
+
import { n as setSynologyRuntime, t as synologyChatPlugin } from "./channel-C6bhvNZi.js";
|
|
2
2
|
import { t as collectSynologyChatSecurityAuditFindings } from "./security-audit-DIsaxIaB.js";
|
|
3
3
|
export { collectSynologyChatSecurityAuditFindings, setSynologyRuntime, synologyChatPlugin };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as resolveAccount, n as synologyChatSetupWizard, r as listAccountIds, t as synologyChatSetupAdapter } from "./setup-surface-
|
|
1
|
+
import { i as resolveAccount, n as synologyChatSetupWizard, r as listAccountIds, t as synologyChatSetupAdapter } from "./setup-surface-pMbKFqU5.js";
|
|
2
2
|
import { t as collectSynologyChatSecurityAuditFindings } from "./security-audit-DIsaxIaB.js";
|
|
3
3
|
import { DEFAULT_ACCOUNT_ID } from "openclaw/plugin-sdk/account-id";
|
|
4
4
|
import { createHybridChannelConfigAdapter, createScopedDmSecurityResolver } from "openclaw/plugin-sdk/channel-config-helpers";
|
|
@@ -6,9 +6,9 @@ import { createChatChannelPlugin } from "openclaw/plugin-sdk/channel-core";
|
|
|
6
6
|
import { createMessageReceiptFromOutboundResults, defineChannelMessageAdapter, waitUntilAbort } from "openclaw/plugin-sdk/channel-outbound";
|
|
7
7
|
import { composeWarningCollectors, createConditionalWarningCollector, projectAccountConfigWarningCollector, projectAccountWarningCollector } from "openclaw/plugin-sdk/channel-policy";
|
|
8
8
|
import { createEmptyChannelDirectoryAdapter } from "openclaw/plugin-sdk/directory-runtime";
|
|
9
|
+
import { finiteSecondsToTimerSafeMilliseconds, parseStrictNonNegativeInteger } from "openclaw/plugin-sdk/number-runtime";
|
|
9
10
|
import { normalizeLowercaseStringOrEmpty, normalizeStringEntriesLower } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
10
11
|
import { DEFAULT_ACCOUNT_ID as DEFAULT_ACCOUNT_ID$1 } from "openclaw/plugin-sdk/account-resolution";
|
|
11
|
-
import { finiteSecondsToTimerSafeMilliseconds, parseStrictNonNegativeInteger } from "openclaw/plugin-sdk/number-runtime";
|
|
12
12
|
import { createResolvedApproverActionAuthAdapter, resolveApprovalApprovers } from "openclaw/plugin-sdk/approval-auth-runtime";
|
|
13
13
|
import * as http from "node:http";
|
|
14
14
|
import * as https from "node:https";
|
|
@@ -273,6 +273,18 @@ function buildSynologyChatInboundSessionKey(params) {
|
|
|
273
273
|
identityLinks: params.identityLinks
|
|
274
274
|
});
|
|
275
275
|
}
|
|
276
|
+
function buildSynologyChatOutboundSessionKey(params) {
|
|
277
|
+
return buildAgentSessionKey({
|
|
278
|
+
agentId: params.agentId,
|
|
279
|
+
channel: CHANNEL_ID$3,
|
|
280
|
+
accountId: params.accountId,
|
|
281
|
+
peer: {
|
|
282
|
+
kind: "direct",
|
|
283
|
+
id: `chat-api-${params.chatUserId}`
|
|
284
|
+
},
|
|
285
|
+
dmScope: "per-account-channel-peer"
|
|
286
|
+
});
|
|
287
|
+
}
|
|
276
288
|
//#endregion
|
|
277
289
|
//#region extensions/synology-chat/src/inbound-event.ts
|
|
278
290
|
const CHANNEL_ID$2 = "synology-chat";
|
|
@@ -1057,6 +1069,12 @@ function requireIncomingUrl(account) {
|
|
|
1057
1069
|
if (!account.incomingUrl) throw new Error("Synology Chat incoming URL not configured");
|
|
1058
1070
|
return account.incomingUrl;
|
|
1059
1071
|
}
|
|
1072
|
+
function normalizeSynologyChatTarget(target) {
|
|
1073
|
+
const trimmed = target.trim();
|
|
1074
|
+
if (!trimmed) return;
|
|
1075
|
+
const chatUserId = parseStrictNonNegativeInteger(trimmed.replace(/^synology(?:[-_]?chat)?:/i, "").trim());
|
|
1076
|
+
return chatUserId === void 0 ? void 0 : String(chatUserId);
|
|
1077
|
+
}
|
|
1060
1078
|
function createSynologyChatSendResult(params) {
|
|
1061
1079
|
return {
|
|
1062
1080
|
channel: CHANNEL_ID,
|
|
@@ -1140,17 +1158,30 @@ function createSynologyChatPlugin() {
|
|
|
1140
1158
|
"synology_chat",
|
|
1141
1159
|
"synology"
|
|
1142
1160
|
],
|
|
1143
|
-
normalizeTarget:
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1161
|
+
normalizeTarget: normalizeSynologyChatTarget,
|
|
1162
|
+
resolveOutboundSessionRoute: ({ agentId, accountId, target }) => {
|
|
1163
|
+
const chatUserId = normalizeSynologyChatTarget(target);
|
|
1164
|
+
if (!chatUserId) return null;
|
|
1165
|
+
const sessionKey = buildSynologyChatOutboundSessionKey({
|
|
1166
|
+
agentId,
|
|
1167
|
+
accountId: accountId?.trim() || DEFAULT_ACCOUNT_ID,
|
|
1168
|
+
chatUserId
|
|
1169
|
+
});
|
|
1170
|
+
return {
|
|
1171
|
+
sessionKey,
|
|
1172
|
+
baseSessionKey: sessionKey,
|
|
1173
|
+
recipientSessionExact: "delivery-identity",
|
|
1174
|
+
peer: {
|
|
1175
|
+
kind: "direct",
|
|
1176
|
+
id: `chat-api-${chatUserId}`
|
|
1177
|
+
},
|
|
1178
|
+
chatType: "direct",
|
|
1179
|
+
from: `synology-chat:chat-api:${chatUserId}`,
|
|
1180
|
+
to: chatUserId
|
|
1181
|
+
};
|
|
1147
1182
|
},
|
|
1148
1183
|
targetResolver: {
|
|
1149
|
-
looksLikeId: (id) =>
|
|
1150
|
-
const trimmed = id?.trim();
|
|
1151
|
-
if (!trimmed) return false;
|
|
1152
|
-
return /^\d+$/.test(trimmed) || /^synology(?:[-_]?chat)?:/i.test(trimmed);
|
|
1153
|
-
},
|
|
1184
|
+
looksLikeId: (id) => normalizeSynologyChatTarget(id) !== void 0,
|
|
1154
1185
|
hint: "<userId>"
|
|
1155
1186
|
}
|
|
1156
1187
|
},
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as synologyChatPlugin } from "./channel-
|
|
1
|
+
import { t as synologyChatPlugin } from "./channel-C6bhvNZi.js";
|
|
2
2
|
export { synologyChatPlugin };
|
package/dist/setup-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as synologyChatSetupWizard, t as synologyChatSetupAdapter } from "./setup-surface-
|
|
1
|
+
import { n as synologyChatSetupWizard, t as synologyChatSetupAdapter } from "./setup-surface-pMbKFqU5.js";
|
|
2
2
|
export { synologyChatSetupAdapter, synologyChatSetupWizard };
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/synology-chat",
|
|
3
|
-
"version": "2026.7.1-beta.
|
|
3
|
+
"version": "2026.7.1-beta.4",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@openclaw/synology-chat",
|
|
9
|
-
"version": "2026.7.1-beta.
|
|
9
|
+
"version": "2026.7.1-beta.4",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"zod": "4.4.3"
|
|
12
12
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/synology-chat",
|
|
3
|
-
"version": "2026.7.1-beta.
|
|
3
|
+
"version": "2026.7.1-beta.4",
|
|
4
4
|
"description": "Synology Chat channel plugin for OpenClaw channels and direct messages.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
"minHostVersion": ">=2026.4.10"
|
|
28
28
|
},
|
|
29
29
|
"compat": {
|
|
30
|
-
"pluginApi": ">=2026.7.1-beta.
|
|
30
|
+
"pluginApi": ">=2026.7.1-beta.4"
|
|
31
31
|
},
|
|
32
32
|
"build": {
|
|
33
|
-
"openclawVersion": "2026.7.1-beta.
|
|
33
|
+
"openclawVersion": "2026.7.1-beta.4"
|
|
34
34
|
},
|
|
35
35
|
"release": {
|
|
36
36
|
"publishToClawHub": true,
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"README.md"
|
|
52
52
|
],
|
|
53
53
|
"peerDependencies": {
|
|
54
|
-
"openclaw": ">=2026.7.1-beta.
|
|
54
|
+
"openclaw": ">=2026.7.1-beta.4"
|
|
55
55
|
},
|
|
56
56
|
"peerDependenciesMeta": {
|
|
57
57
|
"openclaw": {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
import { parseStrictInteger } from "openclaw/plugin-sdk/number-runtime";
|
|
1
2
|
import { normalizeOptionalString, normalizeStringEntries } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
2
3
|
import { DEFAULT_ACCOUNT_ID, listCombinedAccountIds, resolveMergedAccountConfig } from "openclaw/plugin-sdk/account-resolution";
|
|
3
4
|
import { resolveDangerousNameMatchingEnabled } from "openclaw/plugin-sdk/dangerous-name-runtime";
|
|
4
|
-
import { parseStrictInteger } from "openclaw/plugin-sdk/number-runtime";
|
|
5
5
|
import { DEFAULT_ACCOUNT_ID as DEFAULT_ACCOUNT_ID$1, createAllowFromSection, createSetupTranslator, createStandardChannelSetupStatus, formatDocsLink, mergeAllowFromEntries, normalizeAccountId, setSetupChannelEnabled, splitSetupEntries } from "openclaw/plugin-sdk/setup";
|
|
6
6
|
//#region extensions/synology-chat/src/accounts.ts
|
|
7
7
|
/**
|