@openclaw/msteams 2026.11.1 → 2026.11.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.
- package/dist/.setup/{adapter.runtime-BMvpm7sS.cjs → adapter.runtime-B-6Q3nMI.cjs} +5 -3
- package/dist/.setup/{approval-card-Bo8kHYbj.cjs → approval-card-DWPDItvq.cjs} +4 -2
- package/dist/.setup/{approval-handler.runtime-BS3avHFu.cjs → approval-handler.runtime-CJtz8aNI.cjs} +6 -5
- package/dist/.setup/{bot-framework-service-url-CgVuKiIR.cjs → bot-framework-service-url-B3FWn2SV.cjs} +4 -2
- package/dist/.setup/{channel-CdCSk3Rg.cjs → channel-DMWQSTtQ.cjs} +75 -38
- package/dist/.setup/{channel.runtime--ZjTYgkY.cjs → channel.runtime-CthqKb5j.cjs} +26 -17
- package/dist/.setup/{channel.setup-nSTtK77J.cjs → channel.setup-BN3uhq3r.cjs} +17 -11
- package/dist/.setup/{config-schema-Bm15lF-j.cjs → config-schema-CkKdphSp.cjs} +8 -5
- package/dist/.setup/{conversation-store-state-NJU9osd-.cjs → conversation-store-state-B-4g4uq5.cjs} +40 -23
- package/dist/.setup/{delegated-state-CbMd3rIh.cjs → delegated-state-Bv5cWuec.cjs} +6 -4
- package/dist/.setup/{monitor-BxLDs5fk.cjs → monitor-CNa939Lg.cjs} +101 -49
- package/dist/.setup/{oauth-B-Y5pNM4.cjs → oauth-BBUQCwmq.cjs} +5 -3
- package/dist/.setup/{reaction-types-BaL1EVBS.cjs → reaction-types-CwP5RVQB.cjs} +5 -3
- package/dist/.setup/{resolve-allowlist-CqNzS9bZ.cjs → resolve-allowlist-gI34MnpE.cjs} +34 -19
- package/dist/.setup/{rolldown-runtime-CiKaZLfC.cjs → rolldown-runtime-BloeesfJ.cjs} +2 -1
- package/dist/.setup/{runtime-CbKazLGv.cjs → runtime-gZTAuFux.cjs} +2 -1
- package/dist/.setup/{secret-contract-api-5aH1Fl_c.cjs → secret-contract-api-YY3v6MP8.cjs} +1 -1
- package/dist/.setup/{secret-contract-api-BOzdWSn9.cjs → secret-contract-api-wAyY5UHv.cjs} +2 -1
- package/dist/.setup/{send-BXjI3ufq.cjs → send-D48Qmug3.cjs} +11 -9
- package/dist/.setup/{setup-plugin-api-lPpin6Gg.cjs → setup-plugin-api-B-NYBLkF.cjs} +1 -1
- package/dist/.setup/{thread-session-DZMoCsSR.cjs → thread-session-BWVCoYza.cjs} +5 -3
- package/dist/.setup/{token-config-DTZ00Ibq.cjs → token-config-bEpua_Q7.cjs} +2 -1
- package/dist/api.cjs +2 -2
- package/dist/channel-config-api.cjs +1 -1
- package/dist/channel-plugin-api.cjs +1 -1
- package/dist/configured-state.cjs +2 -1
- package/dist/directory-contract-api.cjs +2 -1
- package/dist/doctor-backup-resources.cjs +3 -2
- package/dist/doctor-contract-api.cjs +15 -9
- package/dist/index.cjs +2 -1
- package/dist/qa-runner-api.cjs +5 -3
- package/dist/runtime-api.cjs +1 -1
- package/dist/secret-contract-api.cjs +1 -1
- package/dist/setup-entry.cjs +4 -3
- package/dist/setup-plugin-api.cjs +1 -1
- package/package.json +4 -4
- package/dist/.source-module-urls/7e43ee3ae4faab430a47269c8217f8d99ec60ecd85233f40e81d03efeb543068.json +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_rolldown_runtime = require("./rolldown-runtime-
|
|
1
|
+
const require_rolldown_runtime = require("./rolldown-runtime-BloeesfJ.cjs");
|
|
2
2
|
let node_url = require("node:url");
|
|
3
3
|
let openclaw_plugin_sdk_ssrf_runtime = require("openclaw/plugin-sdk/ssrf-runtime");
|
|
4
4
|
let openclaw_plugin_sdk_error_runtime = require("openclaw/plugin-sdk/error-runtime");
|
|
@@ -10,7 +10,7 @@ node_fs_promises = require_rolldown_runtime.__toESM(node_fs_promises, 1);
|
|
|
10
10
|
let node_timers_promises = require("node:timers/promises");
|
|
11
11
|
let node_events = require("node:events");
|
|
12
12
|
let node_http = require("node:http");
|
|
13
|
-
|
|
13
|
+
//#region extensions/msteams/src/qa/bot-framework-server.ts
|
|
14
14
|
const AMBIGUOUS_GATEWAY_TIMEOUT_MARKER = "QA-MSTEAMS-AMBIGUOUS-504";
|
|
15
15
|
async function readJson(request) {
|
|
16
16
|
const chunks = [];
|
|
@@ -71,7 +71,8 @@ async function startMSTeamsQaBotFrameworkServer(options) {
|
|
|
71
71
|
}
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
|
-
|
|
74
|
+
//#endregion
|
|
75
|
+
//#region extensions/msteams/src/qa/adapter.runtime.ts
|
|
75
76
|
const SERVICE_URL = "https://smba.trafficmanager.net/qa";
|
|
76
77
|
const APP_ID = "qa-msteams-app";
|
|
77
78
|
const TENANT_ID = "qa-msteams-tenant";
|
|
@@ -304,4 +305,5 @@ async function createMSTeamsQaTransportAdapter(context) {
|
|
|
304
305
|
}
|
|
305
306
|
};
|
|
306
307
|
}
|
|
308
|
+
//#endregion
|
|
307
309
|
exports.createMSTeamsQaTransportAdapter = createMSTeamsQaTransportAdapter;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
let openclaw_plugin_sdk_string_coerce_runtime = require("openclaw/plugin-sdk/string-coerce-runtime");
|
|
2
2
|
let openclaw_plugin_sdk_approval_runtime = require("openclaw/plugin-sdk/approval-runtime");
|
|
3
|
-
|
|
3
|
+
//#region extensions/msteams/src/approval-card-actions.ts
|
|
4
4
|
const msTeamsApprovalControls = (0, openclaw_plugin_sdk_approval_runtime.createNativeApprovalControlRegistry)({ releaseClaimOnLookupExpiry: true });
|
|
5
5
|
function readMSTeamsApprovalActionToken(value) {
|
|
6
6
|
if (!(0, openclaw_plugin_sdk_string_coerce_runtime.isRecord)(value)) return null;
|
|
@@ -9,7 +9,8 @@ function readMSTeamsApprovalActionToken(value) {
|
|
|
9
9
|
if (submitted.openclawAction !== "approval") return null;
|
|
10
10
|
return (0, openclaw_plugin_sdk_string_coerce_runtime.normalizeOptionalString)(submitted.token) ?? null;
|
|
11
11
|
}
|
|
12
|
-
|
|
12
|
+
//#endregion
|
|
13
|
+
//#region extensions/msteams/src/approval-card.ts
|
|
13
14
|
function formatMSTeamsApprovalKind(kind) {
|
|
14
15
|
return kind === "plugin" ? "Plugin" : kind === "system-agent" ? "OpenClaw Change" : "Exec";
|
|
15
16
|
}
|
|
@@ -198,6 +199,7 @@ function buildMSTeamsCanonicalApprovalTerminalCard(result) {
|
|
|
198
199
|
buildApprovalMetadata(approval.id, metadata)
|
|
199
200
|
]);
|
|
200
201
|
}
|
|
202
|
+
//#endregion
|
|
201
203
|
Object.defineProperty(exports, "buildMSTeamsCanonicalApprovalTerminalCard", {
|
|
202
204
|
enumerable: true,
|
|
203
205
|
get: function() {
|
package/dist/.setup/{approval-handler.runtime-BS3avHFu.cjs → approval-handler.runtime-CJtz8aNI.cjs}
RENAMED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
const require_resolve_allowlist = require("./resolve-allowlist-
|
|
2
|
-
const require_channel = require("./channel-
|
|
3
|
-
const require_approval_card = require("./approval-card-
|
|
4
|
-
const require_send = require("./send-
|
|
1
|
+
const require_resolve_allowlist = require("./resolve-allowlist-gI34MnpE.cjs");
|
|
2
|
+
const require_channel = require("./channel-DMWQSTtQ.cjs");
|
|
3
|
+
const require_approval_card = require("./approval-card-DWPDItvq.cjs");
|
|
4
|
+
const require_send = require("./send-D48Qmug3.cjs");
|
|
5
5
|
let openclaw_plugin_sdk_account_id = require("openclaw/plugin-sdk/account-id");
|
|
6
6
|
let openclaw_plugin_sdk_approval_native_runtime = require("openclaw/plugin-sdk/approval-native-runtime");
|
|
7
7
|
let openclaw_plugin_sdk_approval_handler_runtime = require("openclaw/plugin-sdk/approval-handler-runtime");
|
|
8
|
-
|
|
8
|
+
//#region extensions/msteams/src/approval-handler.runtime.ts
|
|
9
9
|
const log = (0, require("openclaw/plugin-sdk/runtime-env").createSubsystemLogger)("msteams/approvals");
|
|
10
10
|
const msTeamsApprovalNativeRuntime = (0, openclaw_plugin_sdk_approval_handler_runtime.createChannelApprovalNativeRuntimeAdapterAsync)({
|
|
11
11
|
eventKinds: [
|
|
@@ -117,4 +117,5 @@ const msTeamsApprovalNativeRuntime = (0, openclaw_plugin_sdk_approval_handler_ru
|
|
|
117
117
|
});
|
|
118
118
|
} }
|
|
119
119
|
});
|
|
120
|
+
//#endregion
|
|
120
121
|
exports.msTeamsApprovalNativeRuntime = msTeamsApprovalNativeRuntime;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
let openclaw_plugin_sdk_account_id = require("openclaw/plugin-sdk/account-id");
|
|
2
2
|
let openclaw_plugin_sdk_ssrf_policy = require("openclaw/plugin-sdk/ssrf-policy");
|
|
3
|
-
|
|
3
|
+
//#region extensions/msteams/src/accounts-webhook.ts
|
|
4
4
|
function resolveMSTeamsWebhookPath(channelConfig, accountId, account) {
|
|
5
5
|
const rootPath = channelConfig?.webhook?.path?.trim() || "/api/messages";
|
|
6
6
|
return account?.webhook?.path?.trim() || (accountId === openclaw_plugin_sdk_account_id.DEFAULT_ACCOUNT_ID ? rootPath : `${rootPath.replace(/\/+$/u, "")}/${accountId}`);
|
|
7
7
|
}
|
|
8
|
-
|
|
8
|
+
//#endregion
|
|
9
|
+
//#region extensions/msteams/src/bot-framework-service-url.ts
|
|
9
10
|
const BOT_FRAMEWORK_SERVICE_URL_HOST_ALLOWLIST = (0, openclaw_plugin_sdk_ssrf_policy.normalizeHostnameSuffixAllowlist)([
|
|
10
11
|
"smba.trafficmanager.net",
|
|
11
12
|
"smba.infra.gcc.teams.microsoft.com",
|
|
@@ -30,6 +31,7 @@ function normalizeBotFrameworkServiceUrl(serviceUrl) {
|
|
|
30
31
|
if (normalized) return normalized;
|
|
31
32
|
throw new Error(`Blocked Microsoft Teams serviceUrl host: ${describeBotFrameworkServiceUrlHost(serviceUrl)}`);
|
|
32
33
|
}
|
|
34
|
+
//#endregion
|
|
33
35
|
Object.defineProperty(exports, "describeBotFrameworkServiceUrlHost", {
|
|
34
36
|
enumerable: true,
|
|
35
37
|
get: function() {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
const require_rolldown_runtime = require("./rolldown-runtime-
|
|
2
|
-
const require_resolve_allowlist = require("./resolve-allowlist-
|
|
1
|
+
const require_rolldown_runtime = require("./rolldown-runtime-BloeesfJ.cjs");
|
|
2
|
+
const require_resolve_allowlist = require("./resolve-allowlist-gI34MnpE.cjs");
|
|
3
3
|
require("../runtime-api.cjs");
|
|
4
4
|
const require_directory_contract_api = require("../directory-contract-api.cjs");
|
|
5
|
-
const require_thread_session = require("./thread-session-
|
|
6
|
-
const require_channel_setup = require("./channel.setup-
|
|
5
|
+
const require_thread_session = require("./thread-session-BWVCoYza.cjs");
|
|
6
|
+
const require_channel_setup = require("./channel.setup-BN3uhq3r.cjs");
|
|
7
7
|
let openclaw_plugin_sdk_approval_handler_adapter_runtime = require("openclaw/plugin-sdk/approval-handler-adapter-runtime");
|
|
8
8
|
let openclaw_plugin_sdk_channel_actions = require("openclaw/plugin-sdk/channel-actions");
|
|
9
9
|
let openclaw_plugin_sdk_channel_core = require("openclaw/plugin-sdk/channel-core");
|
|
@@ -27,7 +27,7 @@ let openclaw_plugin_sdk_channel_targets = require("openclaw/plugin-sdk/channel-t
|
|
|
27
27
|
let openclaw_plugin_sdk_dangerous_name_runtime = require("openclaw/plugin-sdk/dangerous-name-runtime");
|
|
28
28
|
let openclaw_plugin_sdk_runtime_group_policy = require("openclaw/plugin-sdk/runtime-group-policy");
|
|
29
29
|
let openclaw_plugin_sdk_channel_status = require("openclaw/plugin-sdk/channel-status");
|
|
30
|
-
|
|
30
|
+
//#region extensions/msteams/src/action-params.ts
|
|
31
31
|
/** Text and upload-source aliases shared by Teams message actions. */
|
|
32
32
|
function resolveActionContent(params) {
|
|
33
33
|
return typeof params.text === "string" ? params.text : typeof params.content === "string" ? params.content : typeof params.message === "string" ? params.message : "";
|
|
@@ -42,7 +42,8 @@ function resolveActionUploadFilePath(params) {
|
|
|
42
42
|
if (value.trim()) return value;
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
|
-
|
|
45
|
+
//#endregion
|
|
46
|
+
//#region extensions/msteams/src/action-results.ts
|
|
46
47
|
function jsonActionResult(data, details = data) {
|
|
47
48
|
return (0, openclaw_plugin_sdk_tool_results.textResult)(JSON.stringify(data), details);
|
|
48
49
|
}
|
|
@@ -77,7 +78,8 @@ function actionError(message) {
|
|
|
77
78
|
...(0, openclaw_plugin_sdk_tool_results.textResult)(message, { error: message })
|
|
78
79
|
};
|
|
79
80
|
}
|
|
80
|
-
|
|
81
|
+
//#endregion
|
|
82
|
+
//#region extensions/msteams/src/policy.ts
|
|
81
83
|
function matchMSTeamsPolicyEntry(entries, ...keys) {
|
|
82
84
|
return (0, openclaw_plugin_sdk_channel_targets.resolveChannelEntryMatchWithFallback)({
|
|
83
85
|
entries,
|
|
@@ -158,7 +160,8 @@ function resolveMSTeamsReplyPolicy(params) {
|
|
|
158
160
|
...requireMentionInBotThreads === void 0 ? {} : { requireMentionInBotThreads }
|
|
159
161
|
};
|
|
160
162
|
}
|
|
161
|
-
|
|
163
|
+
//#endregion
|
|
164
|
+
//#region extensions/msteams/src/action-threading.ts
|
|
162
165
|
/** Normalize Teams conversation targets for equality (strips `conversation:` and `;messageid=`). */
|
|
163
166
|
function normalizeMSTeamsThreadingTarget(raw) {
|
|
164
167
|
const value = (0, openclaw_plugin_sdk_string_coerce_runtime.normalizeOptionalString)(raw);
|
|
@@ -223,7 +226,8 @@ function resolveMSTeamsAutoThreadId(params) {
|
|
|
223
226
|
if ((0, openclaw_plugin_sdk_reply_reference.isSingleUseReplyToMode)(context.replyToMode ?? "off") && context.hasRepliedRef?.value) return;
|
|
224
227
|
return context.currentThreadTs;
|
|
225
228
|
}
|
|
226
|
-
|
|
229
|
+
//#endregion
|
|
230
|
+
//#region extensions/msteams/src/approval-native.ts
|
|
227
231
|
function isMSTeamsApprovalTransportEnabled(params) {
|
|
228
232
|
const account = require_resolve_allowlist.resolveMSTeamsAccount(params);
|
|
229
233
|
return account.enabled && account.configured && account.tokenStatus === "available";
|
|
@@ -298,7 +302,7 @@ const msTeamsLazyApprovalNativeRuntime = (0, openclaw_plugin_sdk_approval_handle
|
|
|
298
302
|
request
|
|
299
303
|
}),
|
|
300
304
|
load: async () => {
|
|
301
|
-
const { msTeamsApprovalNativeRuntime } = await Promise.resolve().then(() => require("./approval-handler.runtime-
|
|
305
|
+
const { msTeamsApprovalNativeRuntime } = await Promise.resolve().then(() => require("./approval-handler.runtime-CJtz8aNI.cjs"));
|
|
302
306
|
return msTeamsApprovalNativeRuntime;
|
|
303
307
|
}
|
|
304
308
|
});
|
|
@@ -344,7 +348,8 @@ const msTeamsApprovalCapability = {
|
|
|
344
348
|
}),
|
|
345
349
|
authorizeActorActionAsync: async (params) => require_thread_session.msTeamsApprovalAuth.authorizeActorAction?.(params)
|
|
346
350
|
};
|
|
347
|
-
|
|
351
|
+
//#endregion
|
|
352
|
+
//#region extensions/msteams/src/channel-message-tool.ts
|
|
348
353
|
function describeMSTeamsMessageTool({ cfg, accountId }) {
|
|
349
354
|
const account = require_resolve_allowlist.resolveMSTeamsAccount({
|
|
350
355
|
cfg,
|
|
@@ -378,7 +383,8 @@ function describeMSTeamsMessageTool({ cfg, accountId }) {
|
|
|
378
383
|
} : null
|
|
379
384
|
};
|
|
380
385
|
}
|
|
381
|
-
|
|
386
|
+
//#endregion
|
|
387
|
+
//#region src/gateway/gateway-http-route-contracts.ts
|
|
382
388
|
const GATEWAY_PROBE_ROUTES = /* @__PURE__ */ new Map([
|
|
383
389
|
["/health", "live"],
|
|
384
390
|
["/healthz", "live"],
|
|
@@ -394,7 +400,8 @@ function classifyGatewayProbePath(pathname) {
|
|
|
394
400
|
}
|
|
395
401
|
return "outside";
|
|
396
402
|
}
|
|
397
|
-
|
|
403
|
+
//#endregion
|
|
404
|
+
//#region packages/normalization-core/src/string-coerce.ts
|
|
398
405
|
/** Trims string input and returns null for non-strings or empty strings. */
|
|
399
406
|
function normalizeNullableString(value) {
|
|
400
407
|
if (typeof value !== "string") return null;
|
|
@@ -413,11 +420,13 @@ function normalizeOptionalLowercaseString(value) {
|
|
|
413
420
|
function normalizeLowercaseStringOrEmpty$1(value) {
|
|
414
421
|
return normalizeOptionalLowercaseString(value) ?? "";
|
|
415
422
|
}
|
|
416
|
-
|
|
423
|
+
//#endregion
|
|
424
|
+
//#region src/plugins/http-path-prefix.ts
|
|
417
425
|
function prefixMatchPath(pathname, prefix) {
|
|
418
426
|
return pathname === prefix || pathname.startsWith(`${prefix}/`) || pathname.startsWith(`${prefix}%`);
|
|
419
427
|
}
|
|
420
|
-
|
|
428
|
+
//#endregion
|
|
429
|
+
//#region src/gateway/security-path.ts
|
|
421
430
|
const MAX_PATH_DECODE_PASSES = 32;
|
|
422
431
|
function normalizePathSeparators(pathname) {
|
|
423
432
|
const collapsed = pathname.replace(/\/{2,}/g, "/");
|
|
@@ -470,7 +479,8 @@ function canonicalizePathForSecurity(pathname) {
|
|
|
470
479
|
};
|
|
471
480
|
}
|
|
472
481
|
const PROTECTED_PLUGIN_ROUTE_PREFIXES = ["/api/channels"];
|
|
473
|
-
|
|
482
|
+
//#endregion
|
|
483
|
+
//#region src/gateway/server/plugins-http/path-context.ts
|
|
474
484
|
function normalizeProtectedPrefix(prefix) {
|
|
475
485
|
const collapsed = normalizeLowercaseStringOrEmpty$1(prefix).replace(/\/{2,}/g, "/");
|
|
476
486
|
if (collapsed.length <= 1) return collapsed || "/";
|
|
@@ -496,27 +506,40 @@ function resolvePluginRoutePathContext(pathname) {
|
|
|
496
506
|
rawNormalizedPath: canonical.rawNormalizedPath
|
|
497
507
|
};
|
|
498
508
|
}
|
|
499
|
-
|
|
509
|
+
//#endregion
|
|
510
|
+
//#region \0openclaw:bundled-sdk:openclaw/plugin-sdk/gateway-config-runtime
|
|
500
511
|
var gateway_config_runtime_exports = /* @__PURE__ */ require_rolldown_runtime.__exportAll({
|
|
501
512
|
classifyGatewayProbePath: () => classifyGatewayProbePath,
|
|
502
513
|
isProtectedPluginRoutePathFromContext: () => isProtectedPluginRoutePathFromContext,
|
|
503
514
|
resolvePluginRoutePathContext: () => resolvePluginRoutePathContext
|
|
504
515
|
});
|
|
505
516
|
require_rolldown_runtime.__reExport(gateway_config_runtime_exports, require("openclaw/plugin-sdk/gateway-config-runtime"));
|
|
506
|
-
|
|
517
|
+
//#endregion
|
|
518
|
+
//#region extensions/msteams/src/webhook-route.ts
|
|
519
|
+
const LEGACY_MESSAGES_PATH = "/api/messages";
|
|
520
|
+
function listEnabledMSTeamsWebhookPaths(cfg) {
|
|
521
|
+
return require_resolve_allowlist.listMSTeamsAccountIds(cfg).flatMap((accountId) => {
|
|
522
|
+
const account = require_resolve_allowlist.resolveMSTeamsAccountConfig(cfg, accountId);
|
|
523
|
+
if (account.enabled === false) return [];
|
|
524
|
+
const path = account.webhook?.path || LEGACY_MESSAGES_PATH;
|
|
525
|
+
return [{
|
|
526
|
+
accountId,
|
|
527
|
+
path,
|
|
528
|
+
canonical: resolvePluginRoutePathContext(path).canonicalPath
|
|
529
|
+
}];
|
|
530
|
+
});
|
|
531
|
+
}
|
|
532
|
+
/** Enabled account whose configured webhook path is /api/messages, if any. */
|
|
533
|
+
function resolveMSTeamsLegacyMessagesOwner(cfg) {
|
|
534
|
+
const legacy = resolvePluginRoutePathContext(LEGACY_MESSAGES_PATH).canonicalPath;
|
|
535
|
+
return listEnabledMSTeamsWebhookPaths(cfg).find(({ canonical }) => canonical === legacy)?.accountId;
|
|
536
|
+
}
|
|
507
537
|
function resolveMSTeamsWebhookCollisionIssue(cfg) {
|
|
508
538
|
const owners = /* @__PURE__ */ new Map();
|
|
509
|
-
for (const accountId of
|
|
510
|
-
const
|
|
511
|
-
if (
|
|
512
|
-
|
|
513
|
-
const paths = accountId === openclaw_plugin_sdk_account_id.DEFAULT_ACCOUNT_ID && path !== "/api/messages" ? [path, "/api/messages"] : [path];
|
|
514
|
-
for (const routePath of paths) {
|
|
515
|
-
const canonical = resolvePluginRoutePathContext(routePath).canonicalPath;
|
|
516
|
-
const owner = owners.get(canonical);
|
|
517
|
-
if (owner && owner !== accountId) return "Microsoft Teams webhook path " + routePath + " is shared by accounts " + owner + " and " + accountId + ". Configure distinct webhook.path values.";
|
|
518
|
-
owners.set(canonical, accountId);
|
|
519
|
-
}
|
|
539
|
+
for (const { accountId, path, canonical } of listEnabledMSTeamsWebhookPaths(cfg)) {
|
|
540
|
+
const owner = owners.get(canonical);
|
|
541
|
+
if (owner && owner !== accountId) return "Microsoft Teams webhook path " + path + " is shared by accounts " + owner + " and " + accountId + ". Configure distinct webhook.path values.";
|
|
542
|
+
owners.set(canonical, accountId);
|
|
520
543
|
}
|
|
521
544
|
}
|
|
522
545
|
function resolveMSTeamsLegacyWebhook(config) {
|
|
@@ -538,7 +561,8 @@ function resolveMSTeamsWebhookPathIssue({ cfg, env, accountId = openclaw_plugin_
|
|
|
538
561
|
const recoveryPath = accountId === openclaw_plugin_sdk_account_id.DEFAULT_ACCOUNT_ID ? "/api/messages" : `/api/messages/${accountId}`;
|
|
539
562
|
return `Microsoft Teams webhook path ${path} ${reason}. Set ${configPath}.webhook.path to ${recoveryPath} and update the Azure Bot messaging endpoint or reverse-proxy upstream to Gateway port ${(0, gateway_config_runtime_exports.resolveGatewayPort)(cfg, env)}${recoveryPath}.` + (legacy ? ` Compatibility port ${legacy.port} continues serving the current path; verify delivery before removing ${resolveMSTeamsLegacyWebhookConfigPath(cfg, accountId)}.` : " The compatibility listener is disabled, so this path cannot receive Teams callbacks.");
|
|
540
563
|
}
|
|
541
|
-
|
|
564
|
+
//#endregion
|
|
565
|
+
//#region extensions/msteams/src/doctor.ts
|
|
542
566
|
const isMSTeamsMutableAllowEntry = (0, openclaw_plugin_sdk_channel_policy.buildMutableAllowEntryDetector)({
|
|
543
567
|
prefixes: ["msteams:", "user:"],
|
|
544
568
|
stableIdPattern: /^[^\s@]+$/
|
|
@@ -590,7 +614,8 @@ const msteamsDoctor = {
|
|
|
590
614
|
collectMutableAllowlistWarnings: collectMSTeamsMutableAllowlistWarnings,
|
|
591
615
|
runConfigSequence: runMSTeamsWebhookDoctorSequence
|
|
592
616
|
};
|
|
593
|
-
|
|
617
|
+
//#endregion
|
|
618
|
+
//#region extensions/msteams/src/graph-action-context.ts
|
|
594
619
|
const MSTEAMS_GROUP_MANAGEMENT_ACTIONS = /* @__PURE__ */ new Set([
|
|
595
620
|
"addParticipant",
|
|
596
621
|
"removeParticipant",
|
|
@@ -602,7 +627,8 @@ function withMSTeamsGraphMutationCurrentness(handleAction) {
|
|
|
602
627
|
return handleAction(ctx);
|
|
603
628
|
};
|
|
604
629
|
}
|
|
605
|
-
|
|
630
|
+
//#endregion
|
|
631
|
+
//#region extensions/msteams/src/presentation.ts
|
|
606
632
|
const MSTEAMS_PRESENTATION_CAPABILITIES = {
|
|
607
633
|
supported: true,
|
|
608
634
|
buttons: true,
|
|
@@ -696,7 +722,8 @@ function buildMSTeamsPresentationCard(params) {
|
|
|
696
722
|
...actions.length ? { actions } : {}
|
|
697
723
|
};
|
|
698
724
|
}
|
|
699
|
-
|
|
725
|
+
//#endregion
|
|
726
|
+
//#region extensions/msteams/src/outbound-config.ts
|
|
700
727
|
const MSTEAMS_TEXT_CHUNK_LIMIT = 4e3;
|
|
701
728
|
function resolveMSTeamsEffectiveTextChunkLimit(configuredLimit) {
|
|
702
729
|
return typeof configuredLimit === "number" && configuredLimit > 0 ? Math.min(configuredLimit, MSTEAMS_TEXT_CHUNK_LIMIT) : MSTEAMS_TEXT_CHUNK_LIMIT;
|
|
@@ -716,7 +743,8 @@ const msteamsOutboundConfig = {
|
|
|
716
743
|
} },
|
|
717
744
|
presentationCapabilities: MSTEAMS_PRESENTATION_CAPABILITIES
|
|
718
745
|
};
|
|
719
|
-
|
|
746
|
+
//#endregion
|
|
747
|
+
//#region extensions/msteams/src/read-policy.ts
|
|
720
748
|
function normalizeTarget(raw) {
|
|
721
749
|
return raw ? require_resolve_allowlist.normalizeMSTeamsMessagingTarget(raw) ?? "" : "";
|
|
722
750
|
}
|
|
@@ -919,7 +947,8 @@ async function assertMSTeamsTeamEnumerationAllowed(params) {
|
|
|
919
947
|
if (!((directRoute.allowlistConfigured ? directRoute.allowed : groupPolicy === "open") || await isMappedChannelAllowed(cfg, accountId, stableTeamId, "__openclaw_all_channels__"))) throw new openclaw_plugin_sdk_channel_actions.ToolAuthorizationError("Microsoft Teams channel list requires access to every channel in the team.");
|
|
920
948
|
return stableTeamId;
|
|
921
949
|
}
|
|
922
|
-
|
|
950
|
+
//#endregion
|
|
951
|
+
//#region extensions/msteams/src/session-route.ts
|
|
923
952
|
function inferMSTeamsTargetChatType(raw) {
|
|
924
953
|
const target = (0, openclaw_plugin_sdk_channel_core.stripChannelTargetPrefix)(raw, "msteams", "teams");
|
|
925
954
|
if (!target) return;
|
|
@@ -970,7 +999,8 @@ function resolveMSTeamsOutboundSessionRoute(params) {
|
|
|
970
999
|
...channelThreadId !== void 0 ? { threadId: channelThreadId } : {}
|
|
971
1000
|
} : route;
|
|
972
1001
|
}
|
|
973
|
-
|
|
1002
|
+
//#endregion
|
|
1003
|
+
//#region extensions/msteams/src/channel.ts
|
|
974
1004
|
const TEAMS_GRAPH_PERMISSION_HINTS = {
|
|
975
1005
|
"ChannelMessage.Read.All": "channel history",
|
|
976
1006
|
"Chat.Read.All": "chat history",
|
|
@@ -986,7 +1016,7 @@ const collectMSTeamsSecurityFindings = openclaw_plugin_sdk_channel_policy.create
|
|
|
986
1016
|
severity: "warn",
|
|
987
1017
|
title: "MS Teams security warning"
|
|
988
1018
|
});
|
|
989
|
-
const loadMSTeamsChannelRuntime = (0, openclaw_plugin_sdk_lazy_runtime.createLazyRuntimeNamedExport)(() => Promise.resolve().then(() => require("./channel.runtime
|
|
1019
|
+
const loadMSTeamsChannelRuntime = (0, openclaw_plugin_sdk_lazy_runtime.createLazyRuntimeNamedExport)(() => Promise.resolve().then(() => require("./channel.runtime-CthqKb5j.cjs")), "msTeamsChannelRuntime");
|
|
990
1020
|
const MSTEAMS_REACTION_TYPES = [
|
|
991
1021
|
"like",
|
|
992
1022
|
"heart",
|
|
@@ -1495,7 +1525,7 @@ const msteamsPlugin = (0, openclaw_plugin_sdk_channel_core.createChatChannelPlug
|
|
|
1495
1525
|
})
|
|
1496
1526
|
}),
|
|
1497
1527
|
gateway: { startAccount: async (ctx) => {
|
|
1498
|
-
const { monitorMSTeamsProvider } = await Promise.resolve().then(() => require("./monitor-
|
|
1528
|
+
const { monitorMSTeamsProvider } = await Promise.resolve().then(() => require("./monitor-CNa939Lg.cjs"));
|
|
1499
1529
|
const account = require_resolve_allowlist.resolveMSTeamsAccount({
|
|
1500
1530
|
cfg: ctx.cfg,
|
|
1501
1531
|
accountId: ctx.accountId
|
|
@@ -1571,6 +1601,7 @@ const msteamsPlugin = (0, openclaw_plugin_sdk_channel_core.createChatChannelPlug
|
|
|
1571
1601
|
},
|
|
1572
1602
|
outbound: msteamsChannelOutbound
|
|
1573
1603
|
});
|
|
1604
|
+
//#endregion
|
|
1574
1605
|
Object.defineProperty(exports, "buildMSTeamsPresentationCard", {
|
|
1575
1606
|
enumerable: true,
|
|
1576
1607
|
get: function() {
|
|
@@ -1607,6 +1638,12 @@ Object.defineProperty(exports, "resolveMSTeamsEffectiveTextChunkLimit", {
|
|
|
1607
1638
|
return resolveMSTeamsEffectiveTextChunkLimit;
|
|
1608
1639
|
}
|
|
1609
1640
|
});
|
|
1641
|
+
Object.defineProperty(exports, "resolveMSTeamsLegacyMessagesOwner", {
|
|
1642
|
+
enumerable: true,
|
|
1643
|
+
get: function() {
|
|
1644
|
+
return resolveMSTeamsLegacyMessagesOwner;
|
|
1645
|
+
}
|
|
1646
|
+
});
|
|
1610
1647
|
Object.defineProperty(exports, "resolveMSTeamsLegacyWebhook", {
|
|
1611
1648
|
enumerable: true,
|
|
1612
1649
|
get: function() {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
const require_token_config = require("./token-config-
|
|
2
|
-
const require_resolve_allowlist = require("./resolve-allowlist-
|
|
1
|
+
const require_token_config = require("./token-config-bEpua_Q7.cjs");
|
|
2
|
+
const require_resolve_allowlist = require("./resolve-allowlist-gI34MnpE.cjs");
|
|
3
3
|
require("../runtime-api.cjs");
|
|
4
|
-
const require_delegated_state = require("./delegated-state-
|
|
5
|
-
const require_channel = require("./channel-
|
|
6
|
-
const require_channel_setup = require("./channel.setup-
|
|
7
|
-
const require_conversation_store_state = require("./conversation-store-state-
|
|
8
|
-
const require_send = require("./send-
|
|
9
|
-
const require_reaction_types = require("./reaction-types-
|
|
4
|
+
const require_delegated_state = require("./delegated-state-Bv5cWuec.cjs");
|
|
5
|
+
const require_channel = require("./channel-DMWQSTtQ.cjs");
|
|
6
|
+
const require_channel_setup = require("./channel.setup-BN3uhq3r.cjs");
|
|
7
|
+
const require_conversation_store_state = require("./conversation-store-state-B-4g4uq5.cjs");
|
|
8
|
+
const require_send = require("./send-D48Qmug3.cjs");
|
|
9
|
+
const require_reaction_types = require("./reaction-types-CwP5RVQB.cjs");
|
|
10
10
|
let openclaw_plugin_sdk_channel_outbound = require("openclaw/plugin-sdk/channel-outbound");
|
|
11
11
|
let openclaw_plugin_sdk_string_coerce_runtime = require("openclaw/plugin-sdk/string-coerce-runtime");
|
|
12
12
|
let openclaw_plugin_sdk_account_id = require("openclaw/plugin-sdk/account-id");
|
|
@@ -16,7 +16,7 @@ let openclaw_plugin_sdk_channel_inbound = require("openclaw/plugin-sdk/channel-i
|
|
|
16
16
|
let openclaw_plugin_sdk_channel_send_result = require("openclaw/plugin-sdk/channel-send-result");
|
|
17
17
|
let openclaw_plugin_sdk_string_normalization_runtime = require("openclaw/plugin-sdk/string-normalization-runtime");
|
|
18
18
|
let openclaw_plugin_sdk_text_chunking = require("openclaw/plugin-sdk/text-chunking");
|
|
19
|
-
|
|
19
|
+
//#region extensions/msteams/src/directory-live.ts
|
|
20
20
|
async function listMSTeamsDirectoryPeersLive(params) {
|
|
21
21
|
const query = require_resolve_allowlist.normalizeQuery(params.query);
|
|
22
22
|
if (!query) return [];
|
|
@@ -81,7 +81,8 @@ async function listMSTeamsDirectoryGroupsLive(params) {
|
|
|
81
81
|
}
|
|
82
82
|
return results;
|
|
83
83
|
}
|
|
84
|
-
|
|
84
|
+
//#endregion
|
|
85
|
+
//#region extensions/msteams/src/graph-messages.ts
|
|
85
86
|
function stripTargetPrefix(raw) {
|
|
86
87
|
return raw.trim().replace(/^(conversation|user):/i, "").trim();
|
|
87
88
|
}
|
|
@@ -323,7 +324,8 @@ async function searchMessagesMSTeams(params) {
|
|
|
323
324
|
truncated
|
|
324
325
|
};
|
|
325
326
|
}
|
|
326
|
-
|
|
327
|
+
//#endregion
|
|
328
|
+
//#region extensions/msteams/src/graph-conversation-members.ts
|
|
327
329
|
const MAX_CONVERSATION_MEMBER_PAGES = 100;
|
|
328
330
|
async function findMSTeamsConversationMember(params) {
|
|
329
331
|
const conversationId = await resolveGraphConversationId(params.to, {
|
|
@@ -345,7 +347,8 @@ async function findMSTeamsConversationMember(params) {
|
|
|
345
347
|
member: result.found
|
|
346
348
|
};
|
|
347
349
|
}
|
|
348
|
-
|
|
350
|
+
//#endregion
|
|
351
|
+
//#region extensions/msteams/src/graph-group-management.ts
|
|
349
352
|
function resolveConversationMemberRoles(role, kind) {
|
|
350
353
|
const normalized = role?.trim().toLowerCase() || "member";
|
|
351
354
|
if (normalized !== "member" && normalized !== "owner") throw new Error("MS Teams participant role must be \"member\" or \"owner\".");
|
|
@@ -408,7 +411,8 @@ async function renameGroupMSTeams(params) {
|
|
|
408
411
|
newName: params.name
|
|
409
412
|
} };
|
|
410
413
|
}
|
|
411
|
-
|
|
414
|
+
//#endregion
|
|
415
|
+
//#region extensions/msteams/src/graph-members.ts
|
|
412
416
|
const MAX_TEAM_MEMBER_PAGES = 100;
|
|
413
417
|
function normalizeUserId(value) {
|
|
414
418
|
return value?.replace(/^(msteams|teams|user):/i, "").trim().toLowerCase() ?? "";
|
|
@@ -461,7 +465,8 @@ async function getMemberInfoMSTeams(params) {
|
|
|
461
465
|
roles: member.roles ?? []
|
|
462
466
|
} };
|
|
463
467
|
}
|
|
464
|
-
|
|
468
|
+
//#endregion
|
|
469
|
+
//#region extensions/msteams/src/graph-teams.ts
|
|
465
470
|
async function listChannelsMSTeams(params) {
|
|
466
471
|
const token = await require_resolve_allowlist.resolveGraphToken(params.cfg, { accountId: params.accountId });
|
|
467
472
|
const result = await require_resolve_allowlist.fetchAllGraphPages({
|
|
@@ -495,7 +500,8 @@ async function getChannelInfoMSTeams(params) {
|
|
|
495
500
|
createdDateTime: ch.createdDateTime
|
|
496
501
|
} };
|
|
497
502
|
}
|
|
498
|
-
|
|
503
|
+
//#endregion
|
|
504
|
+
//#region extensions/msteams/src/outbound.ts
|
|
499
505
|
function toMSTeamsOutboundResult(result) {
|
|
500
506
|
const { conversationId, ...delivery } = result;
|
|
501
507
|
return {
|
|
@@ -684,7 +690,8 @@ const msteamsOutbound = {
|
|
|
684
690
|
}
|
|
685
691
|
})
|
|
686
692
|
};
|
|
687
|
-
|
|
693
|
+
//#endregion
|
|
694
|
+
//#region extensions/msteams/src/probe.ts
|
|
688
695
|
function decodeJwtPayload(token) {
|
|
689
696
|
const parts = token.split(".");
|
|
690
697
|
if (parts.length < 2) return null;
|
|
@@ -776,7 +783,8 @@ async function probeMSTeams(cfg, params) {
|
|
|
776
783
|
};
|
|
777
784
|
}
|
|
778
785
|
}
|
|
779
|
-
|
|
786
|
+
//#endregion
|
|
787
|
+
//#region extensions/msteams/src/channel.runtime.ts
|
|
780
788
|
const msTeamsChannelRuntime = {
|
|
781
789
|
addParticipantMSTeams,
|
|
782
790
|
deleteMessageMSTeams: require_send.deleteMessageMSTeams,
|
|
@@ -801,4 +809,5 @@ const msTeamsChannelRuntime = {
|
|
|
801
809
|
sendAdaptiveCardMSTeams: require_send.sendAdaptiveCardMSTeams,
|
|
802
810
|
sendMessageMSTeams: require_send.sendMessageMSTeams
|
|
803
811
|
};
|
|
812
|
+
//#endregion
|
|
804
813
|
exports.msTeamsChannelRuntime = msTeamsChannelRuntime;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const require_token_config = require("./token-config-
|
|
2
|
-
const require_resolve_allowlist = require("./resolve-allowlist-
|
|
1
|
+
const require_token_config = require("./token-config-bEpua_Q7.cjs");
|
|
2
|
+
const require_resolve_allowlist = require("./resolve-allowlist-gI34MnpE.cjs");
|
|
3
3
|
require("../runtime-api.cjs");
|
|
4
|
-
const require_delegated_state = require("./delegated-state-
|
|
5
|
-
const require_config_schema = require("./config-schema-
|
|
4
|
+
const require_delegated_state = require("./delegated-state-Bv5cWuec.cjs");
|
|
5
|
+
const require_config_schema = require("./config-schema-CkKdphSp.cjs");
|
|
6
6
|
let openclaw_plugin_sdk_channel_policy = require("openclaw/plugin-sdk/channel-policy");
|
|
7
7
|
let openclaw_plugin_sdk_string_coerce_runtime = require("openclaw/plugin-sdk/string-coerce-runtime");
|
|
8
8
|
let openclaw_plugin_sdk_account_helpers = require("openclaw/plugin-sdk/account-helpers");
|
|
@@ -16,7 +16,7 @@ let openclaw_plugin_sdk_setup_tools = require("openclaw/plugin-sdk/setup-tools")
|
|
|
16
16
|
let openclaw_plugin_sdk_channel_dm_policy = require("openclaw/plugin-sdk/channel-dm-policy");
|
|
17
17
|
let openclaw_plugin_sdk_setup_runtime = require("openclaw/plugin-sdk/setup-runtime");
|
|
18
18
|
let openclaw_plugin_sdk_retry_runtime = require("openclaw/plugin-sdk/retry-runtime");
|
|
19
|
-
|
|
19
|
+
//#region extensions/msteams/src/accounts-mutations.ts
|
|
20
20
|
function splitRootIdentity(msteams) {
|
|
21
21
|
const { appId, appPassword, ...root } = msteams;
|
|
22
22
|
return {
|
|
@@ -82,7 +82,8 @@ function patchMSTeamsAccountConfig(params) {
|
|
|
82
82
|
}
|
|
83
83
|
};
|
|
84
84
|
}
|
|
85
|
-
|
|
85
|
+
//#endregion
|
|
86
|
+
//#region extensions/msteams/src/channel-config.ts
|
|
86
87
|
const msteamsMeta = {
|
|
87
88
|
id: "msteams",
|
|
88
89
|
label: "Microsoft Teams",
|
|
@@ -182,7 +183,8 @@ const msteamsConfigAdapter = {
|
|
|
182
183
|
accountId: params.accountId
|
|
183
184
|
}) ?? msteamsBaseConfigAdapter.deleteAccount(params)
|
|
184
185
|
};
|
|
185
|
-
|
|
186
|
+
//#endregion
|
|
187
|
+
//#region extensions/msteams/src/setup-core.ts
|
|
186
188
|
const t$1 = (0, openclaw_plugin_sdk_setup.createSetupTranslator)();
|
|
187
189
|
const channel$1 = "msteams";
|
|
188
190
|
function applySecretAuthCredentials(patch, existing) {
|
|
@@ -440,7 +442,8 @@ function createMSTeamsSetupWizardBase() {
|
|
|
440
442
|
}
|
|
441
443
|
};
|
|
442
444
|
}
|
|
443
|
-
|
|
445
|
+
//#endregion
|
|
446
|
+
//#region extensions/msteams/src/errors.ts
|
|
444
447
|
const MAX_SAFE_RETRY_AFTER_SECONDS = Number.MAX_SAFE_INTEGER / 1e3;
|
|
445
448
|
function formatUnknownError(err) {
|
|
446
449
|
if (err instanceof Error) return err.message;
|
|
@@ -611,7 +614,8 @@ function formatMSTeamsDeliveryFailureGuidance(classification) {
|
|
|
611
614
|
if (classification.kind === "replay-safe") return "The request was rate-limited before delivery; retrying later may succeed.";
|
|
612
615
|
if (classification.kind === "ambiguous") return "Delivery may already have succeeded; do not send the same content again without checking the conversation.";
|
|
613
616
|
}
|
|
614
|
-
|
|
617
|
+
//#endregion
|
|
618
|
+
//#region extensions/msteams/src/setup-surface.ts
|
|
615
619
|
const t = (0, openclaw_plugin_sdk_setup.createSetupTranslator)();
|
|
616
620
|
const channel = "msteams";
|
|
617
621
|
function openDelegatedOAuthUrl(url) {
|
|
@@ -823,7 +827,7 @@ const msteamsSetupWizard = {
|
|
|
823
827
|
};
|
|
824
828
|
let oauthModule;
|
|
825
829
|
try {
|
|
826
|
-
oauthModule = await Promise.resolve().then(() => require("./oauth-
|
|
830
|
+
oauthModule = await Promise.resolve().then(() => require("./oauth-BBUQCwmq.cjs"));
|
|
827
831
|
} catch (err) {
|
|
828
832
|
await noteDelegatedAuthFailure(err);
|
|
829
833
|
return {
|
|
@@ -874,7 +878,8 @@ const msteamsSetupWizard = {
|
|
|
874
878
|
groupAccess: msteamsGroupAccess,
|
|
875
879
|
disable: (cfg) => (0, openclaw_plugin_sdk_setup.setSetupChannelEnabled)(cfg, channel, false)
|
|
876
880
|
};
|
|
877
|
-
|
|
881
|
+
//#endregion
|
|
882
|
+
//#region extensions/msteams/src/channel.setup.ts
|
|
878
883
|
const msteamsSetupPlugin = {
|
|
879
884
|
id: "msteams",
|
|
880
885
|
meta: {
|
|
@@ -910,6 +915,7 @@ const msteamsSetupPlugin = {
|
|
|
910
915
|
setupWizard: msteamsSetupWizard,
|
|
911
916
|
setupContract: msteamsSetupContract
|
|
912
917
|
};
|
|
918
|
+
//#endregion
|
|
913
919
|
Object.defineProperty(exports, "classifyMSTeamsSendError", {
|
|
914
920
|
enumerable: true,
|
|
915
921
|
get: function() {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const require_bot_framework_service_url = require("./bot-framework-service-url-
|
|
2
|
-
const require_token_config = require("./token-config-
|
|
1
|
+
const require_bot_framework_service_url = require("./bot-framework-service-url-B3FWn2SV.cjs");
|
|
2
|
+
const require_token_config = require("./token-config-bEpua_Q7.cjs");
|
|
3
3
|
let openclaw_plugin_sdk_channel_core = require("openclaw/plugin-sdk/channel-core");
|
|
4
4
|
let openclaw_plugin_sdk_account_id = require("openclaw/plugin-sdk/account-id");
|
|
5
5
|
let openclaw_plugin_sdk_secret_input = require("openclaw/plugin-sdk/secret-input");
|
|
@@ -7,7 +7,7 @@ let openclaw_plugin_sdk_ssrf_policy = require("openclaw/plugin-sdk/ssrf-policy")
|
|
|
7
7
|
let openclaw_plugin_sdk_channel_config_schema = require("openclaw/plugin-sdk/channel-config-schema");
|
|
8
8
|
let zod = require("zod");
|
|
9
9
|
let openclaw_plugin_sdk_webhook_targets = require("openclaw/plugin-sdk/webhook-targets");
|
|
10
|
-
|
|
10
|
+
//#region extensions/msteams/src/config-schema-refinement.ts
|
|
11
11
|
function hasConfiguredValue(value) {
|
|
12
12
|
return typeof value === "string" ? value.trim().length > 0 : value !== void 0 && value !== null;
|
|
13
13
|
}
|
|
@@ -161,7 +161,8 @@ function refineMSTeamsConfig(value, ctx) {
|
|
|
161
161
|
]);
|
|
162
162
|
}
|
|
163
163
|
}
|
|
164
|
-
|
|
164
|
+
//#endregion
|
|
165
|
+
//#region extensions/msteams/src/config-ui-hints.ts
|
|
165
166
|
const msTeamsChannelConfigUiHints = {
|
|
166
167
|
"": {
|
|
167
168
|
label: "MS Teams",
|
|
@@ -207,7 +208,8 @@ const msTeamsChannelConfigUiHints = {
|
|
|
207
208
|
}
|
|
208
209
|
})
|
|
209
210
|
};
|
|
210
|
-
|
|
211
|
+
//#endregion
|
|
212
|
+
//#region extensions/msteams/src/config-schema.ts
|
|
211
213
|
const SecretInputSchema = (0, openclaw_plugin_sdk_secret_input.buildSecretInputSchema)();
|
|
212
214
|
const ToolPolicyBySenderSchema = zod.z.record(zod.z.string(), openclaw_plugin_sdk_channel_config_schema.ToolPolicySchema).optional();
|
|
213
215
|
const MSTeamsChannelSchema = zod.z.object({
|
|
@@ -282,6 +284,7 @@ const MSTeamsConfigSchema = MSTeamsAccountConfigBaseSchema.extend({
|
|
|
282
284
|
defaultAccount: zod.z.string().optional()
|
|
283
285
|
}).strict().superRefine(refineMSTeamsConfig);
|
|
284
286
|
const MSTeamsChannelConfigSchema = (0, openclaw_plugin_sdk_channel_config_schema.buildChannelConfigSchema)(MSTeamsConfigSchema, { uiHints: msTeamsChannelConfigUiHints });
|
|
287
|
+
//#endregion
|
|
285
288
|
Object.defineProperty(exports, "MSTeamsChannelConfigSchema", {
|
|
286
289
|
enumerable: true,
|
|
287
290
|
get: function() {
|