@openclaw/matrix 2026.7.2-beta.3 → 2026.7.2-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.
Files changed (73) hide show
  1. package/dist/api.js +4 -4
  2. package/dist/{approval-handler.runtime-BEa98wwG.js → approval-handler.runtime-AsawryfP.js} +4 -4
  3. package/dist/{approval-ids-Dfn7oQAm.js → approval-ids-XAMP8vN9.js} +1 -1
  4. package/dist/{approval-reaction-auth-kXkCJBGi.js → approval-reaction-auth-DButmM13.js} +2 -2
  5. package/dist/{channel-j331Xd7b.js → channel-MBtrY36B.js} +17 -11
  6. package/dist/channel-plugin-api.js +1 -1
  7. package/dist/{channel.runtime-BIwlVfQw.js → channel.runtime-Bi4Dgy2P.js} +6 -6
  8. package/dist/{cli-0EcKfqFw.js → cli-CcPuMyCk.js} +14 -18
  9. package/dist/{cli-metadata-Xq1Xb15R.js → cli-metadata-DAhDhbYX.js} +1 -1
  10. package/dist/cli-metadata.js +1 -1
  11. package/dist/{client-BtG4quUl.js → client-BwX6rURh.js} +2 -2
  12. package/dist/{client-CA0PULls.js → client-Dg8dk8NW.js} +2 -2
  13. package/dist/{client-bootstrap-Dk5EAn3n.js → client-bootstrap-ZAaO9fZ-.js} +1 -1
  14. package/dist/{config-schema-B5GRV8wL.js → config-schema-CggnuwnJ.js} +4 -5
  15. package/dist/contract-api.js +2 -2
  16. package/dist/{create-client-WQExaby_.js → create-client-Und1YmJ2.js} +3 -3
  17. package/dist/{crypto-runtime-CAff-n15.js → crypto-runtime-_j7TpS7k.js} +2 -2
  18. package/dist/{directory-live-DiC-0XBC.js → directory-live-B6fbX6jf.js} +3 -3
  19. package/dist/{doctor-DwUVm5Lw.js → doctor-C0LPJGTz.js} +1 -1
  20. package/dist/doctor-contract-CWVdlRQR.js +183 -0
  21. package/dist/doctor-contract-api.js +112 -71
  22. package/dist/{draft-stream-CTLKtJJ0.js → draft-stream-BfibauH1.js} +1 -1
  23. package/dist/{file-sync-store-CPkgnSXp.js → file-sync-store-DUEWCEjb.js} +1 -1
  24. package/dist/{http-client-BmrgOZTL.js → http-client-DOyTG9l2.js} +1 -1
  25. package/dist/{idb-persistence-Dyy6ipgU.js → idb-persistence-C6zQfW2w.js} +72 -63
  26. package/dist/index.js +1 -1
  27. package/dist/{media-text-BMXEXb1j.js → media-text-Cv1VIHXW.js} +1 -1
  28. package/dist/{messages-3UBHfZrN.js → messages-ClTgfFl6.js} +3 -3
  29. package/dist/{monitor-BtUIds8T.js → monitor-2BjKS9RV.js} +23 -20
  30. package/dist/plugin-entry.handlers.runtime.js +1 -1
  31. package/dist/probe.runtime-BWkgfbiE.js +3 -0
  32. package/dist/{profile-update-Bh2XtJwN.js → profile-update-C2My3TML.js} +2 -2
  33. package/dist/{reaction-events-BwAKtUyQ.js → reaction-events-Cj6thhmc.js} +2 -2
  34. package/dist/{recovery-key-store-CW6eePfp.js → recovery-key-store-0O8ARdT_.js} +1 -1
  35. package/dist/{resolve-targets-DVoj-YxB.js → resolve-targets-Dn11HT76.js} +1 -1
  36. package/dist/{resolver.runtime-CC0VVsAt.js → resolver.runtime-Zguh0hH9.js} +1 -1
  37. package/dist/{sdk-CIDZXWpZ.js → sdk-DiRXiRRf.js} +5 -5
  38. package/dist/{send-BJbrdmNm.js → send-CZCmDQu8.js} +2 -2
  39. package/dist/session-binding-contract-api.js +1 -1
  40. package/dist/{setup-bootstrap-DGPOOdz-.js → setup-bootstrap-C9w01xQK.js} +2 -2
  41. package/dist/{setup-core-XCdAx1nY.js → setup-core-D6gyoyeg.js} +107 -19
  42. package/dist/setup-plugin-api.js +4 -3
  43. package/dist/{setup-surface-CzUiTe_k.js → setup-surface-DZIEWtQC.js} +6 -4
  44. package/dist/{shared-DquM1oz6.js → shared-C7Vm9RxI.js} +3 -3
  45. package/dist/{startup-verification-CA00kebL.js → startup-verification-D1nscMh8.js} +1 -1
  46. package/dist/{storage-CzHxeF5E.js → storage-BrkTJZov.js} +6 -39
  47. package/dist/{thread-bindings-Cw194yEn.js → thread-bindings-BcYBELC7.js} +2 -2
  48. package/dist/{tool-actions.runtime-C0jgWYhX.js → tool-actions.runtime-Dbco_Vwn.js} +7 -7
  49. package/dist/{verification-DjxyWTNP.js → verification-DhMBWxOJ.js} +1 -1
  50. package/node_modules/music-metadata/lib/common/Util.d.ts +1 -1
  51. package/node_modules/music-metadata/lib/common/Util.js +7 -1
  52. package/node_modules/music-metadata/lib/id3v2/FrameHeader.js +23 -3
  53. package/node_modules/music-metadata/lib/id3v2/FrameParser.js +2 -2
  54. package/node_modules/music-metadata/lib/id3v2/ID3v2Token.js +1 -1
  55. package/node_modules/music-metadata/lib/mp4/AtomToken.js +38 -13
  56. package/node_modules/music-metadata/lib/mpeg/MpegParser.js +1 -1
  57. package/node_modules/music-metadata/package.json +6 -6
  58. package/node_modules/typebox/build/compile/validator.d.mts +1 -4
  59. package/node_modules/typebox/build/guard/guard.d.mts +1 -1
  60. package/node_modules/typebox/build/guard/guard.mjs +5 -2
  61. package/node_modules/typebox/build/guard/string.mjs +16 -4
  62. package/node_modules/typebox/build/schema/engine/_functions.mjs +34 -15
  63. package/node_modules/typebox/build/type/action/readonly_object.d.mts +5 -0
  64. package/node_modules/typebox/build/type/action/readonly_object.mjs +8 -0
  65. package/node_modules/typebox/build/typebox.d.mts +1 -1
  66. package/node_modules/typebox/build/typebox.mjs +1 -1
  67. package/node_modules/typebox/package.json +1 -1
  68. package/node_modules/typebox/readme.md +29 -32
  69. package/npm-shrinkwrap.json +11 -11
  70. package/openclaw.plugin.json +7 -20
  71. package/package.json +111 -28
  72. package/dist/doctor-contract-BA2Y6Crx.js +0 -312
  73. package/dist/probe.runtime-sBV-Govx.js +0 -3
package/dist/api.js CHANGED
@@ -1,11 +1,11 @@
1
1
  import { a as resolveMatrixDefaultOrOnlyAccountId, i as resolveMatrixChannelConfig, n as requiresExplicitMatrixDefaultAccount, r as resolveConfiguredMatrixAccountIds, t as findMatrixAccountEntry } from "./account-selection-kqquRzCf.js";
2
2
  import { n as listMatrixEnvAccountIds, r as resolveMatrixEnvAccountToken, t as getMatrixScopedEnvVarNames } from "./env-vars-B0NxQnPk.js";
3
3
  import { a as resolveMatrixCredentialsPath, i as resolveMatrixCredentialsFilename, n as resolveMatrixAccountStorageRoot, o as resolveMatrixHomeserverKey, r as resolveMatrixCredentialsDir, s as sanitizeMatrixPathSegment, t as hashMatrixAccessToken } from "./storage-paths-gUmSydsW.js";
4
- import { n as matrixSetupAdapter, t as createMatrixSetupWizardProxy } from "./setup-core-XCdAx1nY.js";
5
- import { t as matrixPlugin } from "./channel-j331Xd7b.js";
4
+ import { n as matrixSetupAdapter, t as createMatrixSetupWizardProxy } from "./setup-core-D6gyoyeg.js";
5
+ import { t as matrixPlugin } from "./channel-MBtrY36B.js";
6
6
  import { d as setMatrixThreadBindingIdleTimeoutBySessionKey, n as getMatrixThreadBindingManager, p as setMatrixThreadBindingMaxAgeBySessionKey, s as resetMatrixThreadBindingsForTests } from "./thread-bindings-shared-CKnY4LSd.js";
7
- import { n as matrixOnboardingAdapter } from "./setup-surface-CzUiTe_k.js";
8
- import { t as createMatrixThreadBindingManager } from "./thread-bindings-Cw194yEn.js";
7
+ import { n as matrixOnboardingAdapter } from "./setup-surface-DZIEWtQC.js";
8
+ import { t as createMatrixThreadBindingManager } from "./thread-bindings-BcYBELC7.js";
9
9
  //#region extensions/matrix/api.ts
10
10
  const matrixSessionBindingAdapterChannels = ["matrix"];
11
11
  //#endregion
@@ -1,9 +1,9 @@
1
- import { g as resolveMatrixAccount } from "./setup-core-XCdAx1nY.js";
2
- import { _ as shouldHandleMatrixApprovalRequest, g as isMatrixAnyApprovalClientEnabled } from "./channel-j331Xd7b.js";
1
+ import { _ as resolveMatrixAccount } from "./setup-core-D6gyoyeg.js";
2
+ import { _ as shouldHandleMatrixApprovalRequest, g as isMatrixAnyApprovalClientEnabled } from "./channel-MBtrY36B.js";
3
3
  import { a as resolveMatrixTargetIdentity } from "./target-ids-B-5aQxwn.js";
4
- import { a as sendMessageMatrix, i as reactMatrixMessage, p as repairMatrixDirectRooms, s as sendSingleTextMessageMatrix } from "./send-BJbrdmNm.js";
4
+ import { a as sendMessageMatrix, i as reactMatrixMessage, p as repairMatrixDirectRooms, s as sendSingleTextMessageMatrix } from "./send-CZCmDQu8.js";
5
5
  import { a as unregisterMatrixApprovalReactionTarget, n as listMatrixApprovalReactionBindings, r as registerMatrixApprovalReactionTarget, t as buildMatrixApprovalReactionHint } from "./approval-reactions-D-BxBK_L.js";
6
- import { n as editMatrixMessage, t as deleteMatrixMessage } from "./messages-3UBHfZrN.js";
6
+ import { n as editMatrixMessage, t as deleteMatrixMessage } from "./messages-ClTgfFl6.js";
7
7
  import { listMessageReceiptPlatformIds, resolveMessageReceiptPrimaryId } from "openclaw/plugin-sdk/channel-outbound";
8
8
  import { normalizeUniqueStringEntries } from "openclaw/plugin-sdk/string-coerce-runtime";
9
9
  import { buildChannelApprovalNativeTargetKey } from "openclaw/plugin-sdk/approval-native-runtime";
@@ -1,4 +1,4 @@
1
- import { a as normalizeMatrixUserId } from "./config-schema-B5GRV8wL.js";
1
+ import { a as normalizeMatrixUserId } from "./config-schema-CggnuwnJ.js";
2
2
  //#region extensions/matrix/src/approval-ids.ts
3
3
  function normalizeMatrixApproverId(value) {
4
4
  return normalizeMatrixUserId(String(value)) || void 0;
@@ -1,5 +1,5 @@
1
- import { g as resolveMatrixAccount } from "./setup-core-XCdAx1nY.js";
2
- import { t as normalizeMatrixApproverId } from "./approval-ids-Dfn7oQAm.js";
1
+ import { _ as resolveMatrixAccount } from "./setup-core-D6gyoyeg.js";
2
+ import { t as normalizeMatrixApproverId } from "./approval-ids-XAMP8vN9.js";
3
3
  import { resolveApprovalApprovers } from "openclaw/plugin-sdk/approval-auth-runtime";
4
4
  //#region extensions/matrix/src/approval-reaction-auth.ts
5
5
  function normalizeMatrixExecApproverId(value) {
@@ -1,11 +1,11 @@
1
1
  import { n as requiresExplicitMatrixDefaultAccount } from "./account-selection-kqquRzCf.js";
2
2
  import { a as resolveMatrixAccountConfig } from "./account-config-BZWN9tGS.js";
3
- import { d as resolveSingleAccountPromotionTarget, f as singleAccountKeysToMove, g as resolveMatrixAccount, h as resolveDefaultMatrixAccountId, n as matrixSetupAdapter, p as listMatrixAccountIds, t as createMatrixSetupWizardProxy, u as namedAccountPromotionKeys } from "./setup-core-XCdAx1nY.js";
4
- import { a as normalizeMatrixUserId, n as DEFAULT_ACCOUNT_ID$2, r as matrixConfigAdapter, t as MatrixChannelConfigSchema } from "./config-schema-B5GRV8wL.js";
5
- import { t as normalizeMatrixApproverId } from "./approval-ids-Dfn7oQAm.js";
3
+ import { _ as resolveMatrixAccount, d as namedAccountPromotionKeys, f as resolveSingleAccountPromotionTarget, g as resolveDefaultMatrixAccountId, m as listMatrixAccountIds, n as matrixSetupAdapter, p as singleAccountKeysToMove, r as matrixSetupContract, t as createMatrixSetupWizardProxy } from "./setup-core-D6gyoyeg.js";
4
+ import { a as normalizeMatrixUserId, n as DEFAULT_ACCOUNT_ID$2, r as matrixConfigAdapter, t as MatrixChannelConfigSchema } from "./config-schema-CggnuwnJ.js";
5
+ import { t as normalizeMatrixApproverId } from "./approval-ids-XAMP8vN9.js";
6
6
  import { a as resolveMatrixTargetIdentity, i as resolveMatrixDirectUserId, n as normalizeMatrixMessagingTarget, r as normalizeMatrixResolvableTarget, t as isMatrixQualifiedUserId } from "./target-ids-B-5aQxwn.js";
7
7
  import { t as formatMatrixErrorMessage } from "./errors-C47hvAF8.js";
8
- import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-BA2Y6Crx.js";
8
+ import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-CWVdlRQR.js";
9
9
  import { d as setMatrixThreadBindingIdleTimeoutBySessionKey, p as setMatrixThreadBindingMaxAgeBySessionKey } from "./thread-bindings-shared-CKnY4LSd.js";
10
10
  import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries } from "./secret-contract-M3hRmGO-.js";
11
11
  import { n as resolveMatrixInboundConversation, t as defaultTopLevelPlacement } from "./thread-binding-api-DRbBZlhS.js";
@@ -127,7 +127,7 @@ const matrixMessageActions = {
127
127
  return extractToolSend(args, "sendMessage");
128
128
  },
129
129
  handleAction: async (ctx) => {
130
- const { handleMatrixAction } = await import("./tool-actions.runtime-C0jgWYhX.js");
130
+ const { handleMatrixAction } = await import("./tool-actions.runtime-Dbco_Vwn.js");
131
131
  const { action, params, cfg, accountId, mediaLocalRoots } = ctx;
132
132
  const dispatch = async (actionParams) => await handleMatrixAction({
133
133
  ...actionParams,
@@ -601,7 +601,7 @@ const matrixNativeApprovalCapability = createApproverRestrictedNativeApprovalCap
601
601
  approvalKind,
602
602
  request
603
603
  }),
604
- load: async () => (await import("./approval-handler.runtime-BEa98wwG.js")).matrixApprovalNativeRuntime
604
+ load: async () => (await import("./approval-handler.runtime-AsawryfP.js")).matrixApprovalNativeRuntime
605
605
  })
606
606
  });
607
607
  const splitMatrixApprovalCapability = splitChannelApprovalCapability(matrixNativeApprovalCapability);
@@ -780,7 +780,7 @@ function resolveMatrixGroupToolPolicy(params) {
780
780
  }
781
781
  //#endregion
782
782
  //#region extensions/matrix/src/resolver.ts
783
- const loadMatrixChannelRuntime$1 = createLazyRuntimeNamedExport(() => import("./resolver.runtime-CC0VVsAt.js"), "matrixResolverRuntime");
783
+ const loadMatrixChannelRuntime$1 = createLazyRuntimeNamedExport(() => import("./resolver.runtime-Zguh0hH9.js"), "matrixResolverRuntime");
784
784
  const matrixResolverAdapter = { resolveTargets: async ({ cfg, accountId, inputs, kind, runtime }) => (await loadMatrixChannelRuntime$1()).resolveMatrixTargets({
785
785
  cfg,
786
786
  accountId,
@@ -906,9 +906,9 @@ function resolveMatrixOutboundSessionRoute(params) {
906
906
  //#endregion
907
907
  //#region extensions/matrix/src/channel.ts
908
908
  let matrixStartupLock = Promise.resolve();
909
- const loadMatrixSetupWizard = createLazyRuntimeNamedExport(() => import("./setup-surface-CzUiTe_k.js").then((n) => n.t), "matrixSetupWizard");
910
- const loadMatrixChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-BIwlVfQw.js"), "matrixChannelRuntime");
911
- const loadMatrixDoctorModule = createLazyRuntimeModule(() => import("./doctor-DwUVm5Lw.js"));
909
+ const loadMatrixSetupWizard = createLazyRuntimeNamedExport(() => import("./setup-surface-DZIEWtQC.js").then((n) => n.t), "matrixSetupWizard");
910
+ const loadMatrixChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-Bi4Dgy2P.js"), "matrixChannelRuntime");
911
+ const loadMatrixDoctorModule = createLazyRuntimeModule(() => import("./doctor-C0LPJGTz.js"));
912
912
  const meta = {
913
913
  id: "matrix",
914
914
  label: "Matrix",
@@ -1225,6 +1225,12 @@ const matrixPlugin = createChatChannelPlugin({
1225
1225
  namedAccountPromotionKeys,
1226
1226
  resolveSingleAccountPromotionTarget
1227
1227
  },
1228
+ setupContract: {
1229
+ ...matrixSetupContract,
1230
+ singleAccountKeysToMove,
1231
+ namedAccountPromotionKeys,
1232
+ resolveSingleAccountPromotionTarget
1233
+ },
1228
1234
  bindings: {
1229
1235
  compileConfiguredBinding: ({ conversationId }) => normalizeMatrixAcpConversationId(conversationId),
1230
1236
  matchInboundConversation: ({ compiledBinding, conversationId, parentConversationId }) => matchMatrixAcpConversation({
@@ -1281,7 +1287,7 @@ const matrixPlugin = createChatChannelPlugin({
1281
1287
  await previousLock;
1282
1288
  let monitorMatrixProvider;
1283
1289
  try {
1284
- monitorMatrixProvider = (await import("./monitor-BtUIds8T.js")).monitorMatrixProvider;
1290
+ monitorMatrixProvider = (await import("./monitor-2BjKS9RV.js")).monitorMatrixProvider;
1285
1291
  } finally {
1286
1292
  releaseLock();
1287
1293
  }
@@ -1,2 +1,2 @@
1
- import { t as matrixPlugin } from "./channel-j331Xd7b.js";
1
+ import { t as matrixPlugin } from "./channel-MBtrY36B.js";
2
2
  export { matrixPlugin };
@@ -1,10 +1,10 @@
1
- import { a as sendMessageMatrix, c as sendTypingMatrix, o as sendPollMatrix } from "./send-BJbrdmNm.js";
1
+ import { a as sendMessageMatrix, c as sendTypingMatrix, o as sendPollMatrix } from "./send-CZCmDQu8.js";
2
2
  import { t as isBunRuntime } from "./runtime-BefyhPWv.js";
3
- import { f as resolveMatrixAuth } from "./shared-DquM1oz6.js";
4
- import "./client-CA0PULls.js";
5
- import { n as listMatrixDirectoryGroupsLive, r as listMatrixDirectoryPeersLive } from "./directory-live-DiC-0XBC.js";
3
+ import { f as resolveMatrixAuth } from "./shared-C7Vm9RxI.js";
4
+ import "./client-Dg8dk8NW.js";
5
+ import { n as listMatrixDirectoryGroupsLive, r as listMatrixDirectoryPeersLive } from "./directory-live-B6fbX6jf.js";
6
6
  import { p as resolveOutboundSendDep, r as chunkTextForOutbound } from "./runtime-api-D1xI_cvh.js";
7
- import { t as resolveMatrixTargets } from "./resolve-targets-DVoj-YxB.js";
7
+ import { t as resolveMatrixTargets } from "./resolve-targets-Dn11HT76.js";
8
8
  import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
9
9
  import { createReplyToFanout } from "openclaw/plugin-sdk/channel-outbound";
10
10
  import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
@@ -12,7 +12,7 @@ import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
12
12
  import { renderMessagePresentationFallbackText } from "openclaw/plugin-sdk/interactive-runtime";
13
13
  import { resolvePayloadMediaUrls, sendPayloadMediaSequence } from "openclaw/plugin-sdk/reply-payload";
14
14
  //#region extensions/matrix/src/matrix/probe.ts
15
- const loadMatrixProbeRuntimeDeps = createLazyRuntimeModule(() => import("./probe.runtime-sBV-Govx.js").then((runtimeModule) => ({ createMatrixClient: runtimeModule.createMatrixClient })));
15
+ const loadMatrixProbeRuntimeDeps = createLazyRuntimeModule(() => import("./probe.runtime-BWkgfbiE.js").then((runtimeModule) => ({ createMatrixClient: runtimeModule.createMatrixClient })));
16
16
  async function probeMatrix(params) {
17
17
  const started = Date.now();
18
18
  const result = {
@@ -1,19 +1,20 @@
1
1
  import { a as resolveMatrixAccountConfig } from "./account-config-BZWN9tGS.js";
2
2
  import { t as getMatrixRuntime } from "./runtime-6S3DNFNv.js";
3
- import { c as resolveMatrixConfigPath, g as resolveMatrixAccount, l as updateMatrixAccountConfig, n as matrixSetupAdapter } from "./setup-core-XCdAx1nY.js";
3
+ import { _ as resolveMatrixAccount, l as resolveMatrixConfigPath, n as matrixSetupAdapter, u as updateMatrixAccountConfig } from "./setup-core-D6gyoyeg.js";
4
4
  import { t as formatMatrixErrorMessage } from "./errors-C47hvAF8.js";
5
- import { n as withResolvedActionClient } from "./client-BtG4quUl.js";
6
- import { p as resolveMatrixAuthContext } from "./shared-DquM1oz6.js";
7
- import "./client-CA0PULls.js";
5
+ import { n as withResolvedActionClient } from "./client-BwX6rURh.js";
6
+ import { p as resolveMatrixAuthContext } from "./shared-C7Vm9RxI.js";
7
+ import "./client-Dg8dk8NW.js";
8
8
  import { a as formatZonedTimestamp } from "./runtime-api-D1xI_cvh.js";
9
9
  import { isOpenClawManagedMatrixDevice, summarizeMatrixDeviceHealth } from "./device-health-D4LBxuPq.js";
10
- import { n as updateMatrixOwnProfile, t as applyMatrixProfileUpdate } from "./profile-update-Bh2XtJwN.js";
11
- import { a as confirmMatrixVerificationSas, b as verifyMatrixRecoveryKey, c as getMatrixRoomKeyBackupStatus, d as listMatrixVerifications, f as mismatchMatrixVerificationSas, g as runMatrixSelfVerification, h as restoreMatrixRoomKeyBackup, l as getMatrixVerificationSas, m as resetMatrixRoomKeyBackup, n as bootstrapMatrixVerification, p as requestMatrixVerification, r as cancelMatrixVerification, t as acceptMatrixVerification, u as getMatrixVerificationStatus, v as startMatrixVerification } from "./verification-DjxyWTNP.js";
10
+ import { n as updateMatrixOwnProfile, t as applyMatrixProfileUpdate } from "./profile-update-C2My3TML.js";
11
+ import { a as confirmMatrixVerificationSas, b as verifyMatrixRecoveryKey, c as getMatrixRoomKeyBackupStatus, d as listMatrixVerifications, f as mismatchMatrixVerificationSas, g as runMatrixSelfVerification, h as restoreMatrixRoomKeyBackup, l as getMatrixVerificationSas, m as resetMatrixRoomKeyBackup, n as bootstrapMatrixVerification, p as requestMatrixVerification, r as cancelMatrixVerification, t as acceptMatrixVerification, u as getMatrixVerificationStatus, v as startMatrixVerification } from "./verification-DhMBWxOJ.js";
12
12
  import { t as resolveMatrixRoomKeyBackupIssue } from "./backup-health-Dm_YMVFT.js";
13
13
  import { setMatrixSdkConsoleLogging, setMatrixSdkLogMode } from "./logging-QH-48Gr6.js";
14
14
  import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
15
15
  import { normalizeAccountId } from "openclaw/plugin-sdk/account-id";
16
16
  import { parseStrictInteger, timestampMsToIsoString } from "openclaw/plugin-sdk/number-runtime";
17
+ import { readByteStreamWithLimit } from "openclaw/plugin-sdk/response-limit-runtime";
17
18
  //#region extensions/matrix/src/matrix/actions/devices.ts
18
19
  async function listMatrixOwnDevices(opts = {}) {
19
20
  return await withResolvedActionClient(opts, async (client) => await client.listOwnDevices());
@@ -37,8 +38,8 @@ async function pruneMatrixStaleGatewayDevices(opts = {}) {
37
38
  //#region extensions/matrix/src/cli.ts
38
39
  let matrixCliExitScheduled = false;
39
40
  const MATRIX_CLI_RECOVERY_KEY_STDIN_MAX_BYTES = 1024 * 1024;
40
- const loadMatrixActionClientModule = createLazyRuntimeModule(() => import("./client-BtG4quUl.js").then((n) => n.t));
41
- const loadMatrixDirectManagementModule = createLazyRuntimeModule(() => import("./send-BJbrdmNm.js").then((n) => n.d));
41
+ const loadMatrixActionClientModule = createLazyRuntimeModule(() => import("./client-BwX6rURh.js").then((n) => n.t));
42
+ const loadMatrixDirectManagementModule = createLazyRuntimeModule(() => import("./send-CZCmDQu8.js").then((n) => n.d));
42
43
  function scheduleMatrixCliExit() {
43
44
  if (matrixCliExitScheduled || process.env.VITEST) return;
44
45
  matrixCliExitScheduled = true;
@@ -54,15 +55,10 @@ function markCliFailure() {
54
55
  process.exitCode = 1;
55
56
  }
56
57
  async function readMatrixCliRecoveryKeyFromStdin() {
57
- const chunks = [];
58
- let totalBytes = 0;
59
- for await (const chunk of process.stdin) {
60
- const buffer = Buffer.isBuffer(chunk) ? chunk : Buffer.from(String(chunk));
61
- totalBytes += buffer.byteLength;
62
- if (totalBytes > MATRIX_CLI_RECOVERY_KEY_STDIN_MAX_BYTES) throw new Error(`Matrix recovery key stdin exceeds ${MATRIX_CLI_RECOVERY_KEY_STDIN_MAX_BYTES} bytes.`);
63
- chunks.push(buffer);
64
- }
65
- const recoveryKey = Buffer.concat(chunks, totalBytes).toString("utf8").trim();
58
+ const recoveryKey = (await readByteStreamWithLimit(process.stdin, {
59
+ maxBytes: MATRIX_CLI_RECOVERY_KEY_STDIN_MAX_BYTES,
60
+ onOverflow: ({ maxBytes }) => /* @__PURE__ */ new Error(`Matrix recovery key stdin exceeds ${maxBytes} bytes.`)
61
+ })).toString("utf8").trim();
66
62
  if (!recoveryKey) throw new Error("Matrix recovery key was requested from stdin, but stdin was empty.");
67
63
  return recoveryKey;
68
64
  }
@@ -212,7 +208,7 @@ async function addMatrixAccount(params) {
212
208
  backupVersion: null
213
209
  };
214
210
  if (accountConfig.encryption === true) {
215
- const { maybeBootstrapNewEncryptedMatrixAccount } = await import("./setup-bootstrap-DGPOOdz-.js");
211
+ const { maybeBootstrapNewEncryptedMatrixAccount } = await import("./setup-bootstrap-C9w01xQK.js");
216
212
  verificationBootstrap = await maybeBootstrapNewEncryptedMatrixAccount({
217
213
  previousCfg: cfg,
218
214
  cfg: updated,
@@ -2,7 +2,7 @@ import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
2
2
  //#region extensions/matrix/src/cli-metadata.ts
3
3
  function registerMatrixCliMetadata(api) {
4
4
  api.registerCli(async ({ program }) => {
5
- const { registerMatrixCli } = await import("./cli-0EcKfqFw.js");
5
+ const { registerMatrixCli } = await import("./cli-CcPuMyCk.js");
6
6
  registerMatrixCli({ program });
7
7
  }, { descriptors: [{
8
8
  name: "matrix",
@@ -1,2 +1,2 @@
1
- import { n as registerMatrixCliMetadata, t as cli_metadata_default } from "./cli-metadata-Xq1Xb15R.js";
1
+ import { n as registerMatrixCliMetadata, t as cli_metadata_default } from "./cli-metadata-DAhDhbYX.js";
2
2
  export { cli_metadata_default as default, registerMatrixCliMetadata };
@@ -1,6 +1,6 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-8H4AJuhK.js";
2
- import { u as resolveMatrixRoomId } from "./send-BJbrdmNm.js";
3
- import { n as withResolvedRuntimeMatrixClient } from "./client-bootstrap-Dk5EAn3n.js";
2
+ import { u as resolveMatrixRoomId } from "./send-CZCmDQu8.js";
3
+ import { n as withResolvedRuntimeMatrixClient } from "./client-bootstrap-ZAaO9fZ-.js";
4
4
  //#region extensions/matrix/src/matrix/actions/client.ts
5
5
  var client_exports = /* @__PURE__ */ __exportAll({
6
6
  withResolvedActionClient: () => withResolvedActionClient,
@@ -3,8 +3,8 @@ import { t as getMatrixScopedEnvVarNames } from "./env-vars-B0NxQnPk.js";
3
3
  import { i as resolveScopedMatrixEnvConfig, r as resolveMatrixEnvAuthReadiness, t as hasReadyMatrixEnvAuth } from "./env-auth-CQsYbz-p.js";
4
4
  import { n as validateMatrixHomeserverUrl, t as resolveValidatedMatrixHomeserverUrl } from "./url-validation-GRHde6lq.js";
5
5
  import { t as isBunRuntime } from "./runtime-BefyhPWv.js";
6
- import { d as backfillMatrixAuthDeviceIdAfterStartup, f as resolveMatrixAuth, i as resolveSharedMatrixClient, m as resolveMatrixConfigForAccount, n as releaseSharedClientInstance, o as stopSharedClientForAccount, p as resolveMatrixAuthContext, r as removeSharedClientInstance, s as stopSharedClientInstance, t as acquireSharedMatrixClient } from "./shared-DquM1oz6.js";
7
- import { t as createMatrixClient } from "./create-client-WQExaby_.js";
6
+ import { d as backfillMatrixAuthDeviceIdAfterStartup, f as resolveMatrixAuth, i as resolveSharedMatrixClient, m as resolveMatrixConfigForAccount, n as releaseSharedClientInstance, o as stopSharedClientForAccount, p as resolveMatrixAuthContext, r as removeSharedClientInstance, s as stopSharedClientInstance, t as acquireSharedMatrixClient } from "./shared-C7Vm9RxI.js";
7
+ import { t as createMatrixClient } from "./create-client-Und1YmJ2.js";
8
8
  //#region extensions/matrix/src/matrix/client.ts
9
9
  var client_exports = /* @__PURE__ */ __exportAll({
10
10
  acquireSharedMatrixClient: () => acquireSharedMatrixClient,
@@ -8,7 +8,7 @@ var client_bootstrap_exports = /* @__PURE__ */ __exportAll({
8
8
  resolveRuntimeMatrixClientWithReadiness: () => resolveRuntimeMatrixClientWithReadiness,
9
9
  withResolvedRuntimeMatrixClient: () => withResolvedRuntimeMatrixClient
10
10
  });
11
- const loadMatrixSharedClientRuntimeDeps = createLazyRuntimeModule(() => Promise.all([import("./client-CA0PULls.js").then((n) => n.t), import("./shared-DquM1oz6.js").then((n) => n.a)]).then(([clientModule, sharedModule]) => ({
11
+ const loadMatrixSharedClientRuntimeDeps = createLazyRuntimeModule(() => Promise.all([import("./client-Dg8dk8NW.js").then((n) => n.t), import("./shared-C7Vm9RxI.js").then((n) => n.a)]).then(([clientModule, sharedModule]) => ({
12
12
  acquireSharedMatrixClient: clientModule.acquireSharedMatrixClient,
13
13
  resolveMatrixAuthContext: clientModule.resolveMatrixAuthContext,
14
14
  releaseSharedClientInstance: sharedModule.releaseSharedClientInstance
@@ -1,5 +1,5 @@
1
1
  import { a as resolveMatrixAccountConfig } from "./account-config-BZWN9tGS.js";
2
- import { g as resolveMatrixAccount, h as resolveDefaultMatrixAccountId, p as listMatrixAccountIds } from "./setup-core-XCdAx1nY.js";
2
+ import { _ as resolveMatrixAccount, g as resolveDefaultMatrixAccountId, m as listMatrixAccountIds } from "./setup-core-D6gyoyeg.js";
3
3
  import { adaptScopedAccountAccessor, createScopedChannelConfigAdapter } from "openclaw/plugin-sdk/channel-config-helpers";
4
4
  import { createChannelConfigUiHints } from "openclaw/plugin-sdk/channel-core";
5
5
  import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/string-coerce-runtime";
@@ -159,9 +159,7 @@ const matrixThreadBindingsSchema = z.object({
159
159
  idleHours: z.number().nonnegative().optional(),
160
160
  maxAgeHours: z.number().nonnegative().optional(),
161
161
  spawnSessions: z.boolean().optional(),
162
- defaultSpawnContext: z.enum(["isolated", "fork"]).optional(),
163
- spawnSubagentSessions: z.boolean().optional(),
164
- spawnAcpSessions: z.boolean().optional()
162
+ defaultSpawnContext: z.enum(["isolated", "fork"]).optional()
165
163
  }).optional();
166
164
  const matrixExecApprovalsSchema = z.object({
167
165
  enabled: z.boolean().optional(),
@@ -208,7 +206,8 @@ const matrixStreamingSchema = z.object({
208
206
  labels: z.array(z.string()).optional(),
209
207
  maxLines: z.number().int().positive().optional(),
210
208
  maxLineChars: z.number().int().positive().optional(),
211
- toolProgress: z.boolean().optional()
209
+ toolProgress: z.boolean().optional(),
210
+ commandText: z.enum(["raw", "status"]).optional()
212
211
  }).strict().optional(),
213
212
  preview: z.object({ toolProgress: z.boolean().optional() }).strict().optional()
214
213
  }).strict();
@@ -1,3 +1,3 @@
1
- import { d as resolveSingleAccountPromotionTarget, f as singleAccountKeysToMove, n as matrixSetupAdapter, u as namedAccountPromotionKeys } from "./setup-core-XCdAx1nY.js";
2
- import { n as matrixOnboardingAdapter } from "./setup-surface-CzUiTe_k.js";
1
+ import { d as namedAccountPromotionKeys, f as resolveSingleAccountPromotionTarget, n as matrixSetupAdapter, p as singleAccountKeysToMove } from "./setup-core-D6gyoyeg.js";
2
+ import { n as matrixOnboardingAdapter } from "./setup-surface-DZIEWtQC.js";
3
3
  export { matrixSetupAdapter, matrixOnboardingAdapter as matrixSetupWizard, namedAccountPromotionKeys, resolveSingleAccountPromotionTarget, singleAccountKeysToMove };
@@ -1,14 +1,14 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-8H4AJuhK.js";
2
2
  import { t as resolveValidatedMatrixHomeserverUrl } from "./url-validation-GRHde6lq.js";
3
- import { d as writeStorageMeta, l as resolveMatrixStoragePaths, r as maybeMigrateLegacyStorage } from "./storage-CzHxeF5E.js";
4
- import "./shared-DquM1oz6.js";
3
+ import { d as writeStorageMeta, l as resolveMatrixStoragePaths, r as maybeMigrateLegacyStorage } from "./storage-BrkTJZov.js";
4
+ import "./shared-C7Vm9RxI.js";
5
5
  import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
6
6
  import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
7
7
  import { ssrfPolicyFromDangerouslyAllowPrivateNetwork } from "openclaw/plugin-sdk/ssrf-runtime";
8
8
  import fs from "node:fs";
9
9
  //#region extensions/matrix/src/matrix/client/create-client.ts
10
10
  var create_client_exports = /* @__PURE__ */ __exportAll({ createMatrixClient: () => createMatrixClient });
11
- const loadMatrixCreateClientRuntimeDeps = createLazyRuntimeModule(() => Promise.all([import("./sdk-CIDZXWpZ.js"), import("./logging-QH-48Gr6.js")]).then(([sdkModule, loggingModule]) => ({
11
+ const loadMatrixCreateClientRuntimeDeps = createLazyRuntimeModule(() => Promise.all([import("./sdk-DiRXiRRf.js"), import("./logging-QH-48Gr6.js")]).then(([sdkModule, loggingModule]) => ({
12
12
  MatrixClient: sdkModule.MatrixClient,
13
13
  ensureMatrixSdkLoggingConfigured: loggingModule.ensureMatrixSdkLoggingConfigured
14
14
  })));
@@ -1,8 +1,8 @@
1
1
  import { t as formatMatrixErrorMessage } from "./errors-C47hvAF8.js";
2
2
  import { t as ensureMatrixCryptoRuntime } from "./deps-CcVJfvRM.js";
3
3
  import { n as LogService, r as noop } from "./logger-D0GCSDQq.js";
4
- import { i as restoreIdbFromDisk, n as persistIdbToDisk } from "./idb-persistence-Dyy6ipgU.js";
5
- import { n as isRepairableSecretStorageAccessError } from "./recovery-key-store-CW6eePfp.js";
4
+ import { i as restoreIdbFromDisk, n as persistIdbToDisk } from "./idb-persistence-C6zQfW2w.js";
5
+ import { n as isRepairableSecretStorageAccessError } from "./recovery-key-store-0O8ARdT_.js";
6
6
  import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
7
7
  import { resolveDateTimestampMs, resolveTimestampMsToIsoString } from "openclaw/plugin-sdk/number-runtime";
8
8
  import { MatrixEventEvent } from "matrix-js-sdk/lib/matrix.js";
@@ -1,8 +1,8 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-8H4AJuhK.js";
2
2
  import { n as normalizeMatrixMessagingTarget, t as isMatrixQualifiedUserId } from "./target-ids-B-5aQxwn.js";
3
- import { f as resolveMatrixAuth } from "./shared-DquM1oz6.js";
4
- import "./client-CA0PULls.js";
5
- import { t as MatrixAuthedHttpClient } from "./http-client-BmrgOZTL.js";
3
+ import { f as resolveMatrixAuth } from "./shared-C7Vm9RxI.js";
4
+ import "./client-Dg8dk8NW.js";
5
+ import { t as MatrixAuthedHttpClient } from "./http-client-DOyTG9l2.js";
6
6
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
7
7
  //#region extensions/matrix/src/directory-live.ts
8
8
  var directory_live_exports = /* @__PURE__ */ __exportAll({
@@ -1,4 +1,4 @@
1
- import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-BA2Y6Crx.js";
1
+ import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-CWVdlRQR.js";
2
2
  import { detectPluginInstallPathIssue, formatPluginInstallPathIssue, removePluginFromConfig } from "openclaw/plugin-sdk/runtime-doctor";
3
3
  //#region extensions/matrix/src/doctor.ts
4
4
  async function collectMatrixInstallPathWarnings(cfg) {
@@ -0,0 +1,183 @@
1
+ import { t as isRecord } from "./record-shared-CWWx6fvI.js";
2
+ import { defineChannelAliasMigration, hasLegacyAccountStreamingAliases, normalizeChannelConfigEntries, stripRetiredChannelKeys } from "openclaw/plugin-sdk/runtime-doctor";
3
+ import { hasLegacyFlatAllowPrivateNetworkAlias, migrateLegacyFlatAllowPrivateNetworkAlias } from "openclaw/plugin-sdk/ssrf-runtime";
4
+ //#region extensions/matrix/src/doctor-contract.ts
5
+ function parseMatrixStreamingMode(value) {
6
+ if (typeof value !== "string") return null;
7
+ const normalized = value.trim().toLowerCase();
8
+ return normalized === "partial" || normalized === "quiet" || normalized === "progress" || normalized === "off" ? normalized : null;
9
+ }
10
+ const streamingAliasMigration = defineChannelAliasMigration({
11
+ channelId: "matrix",
12
+ streaming: {
13
+ defaultMode: "off",
14
+ resolveMode: (entry) => {
15
+ const streaming = isRecord(entry.streaming) ? entry.streaming : null;
16
+ const parsed = parseMatrixStreamingMode(streaming ? streaming.mode : entry.streaming);
17
+ if (parsed) return parsed;
18
+ return entry.streaming === true ? "partial" : "off";
19
+ }
20
+ },
21
+ accountStreamingReplacesRoot: true
22
+ });
23
+ function hasLegacyMatrixRoomAllowAlias(value) {
24
+ const room = isRecord(value) ? value : null;
25
+ return Boolean(room && typeof room.allow === "boolean");
26
+ }
27
+ function hasLegacyMatrixRoomMapAllowAliases(value) {
28
+ const rooms = isRecord(value) ? value : null;
29
+ return Boolean(rooms && Object.values(rooms).some((room) => hasLegacyMatrixRoomAllowAlias(room)));
30
+ }
31
+ function hasLegacyTrustedDmPolicy(value) {
32
+ const root = isRecord(value) ? value : null;
33
+ if (!root) return false;
34
+ return (isRecord(root.dm) ? root.dm : null)?.policy === "trusted";
35
+ }
36
+ function migrateLegacyTrustedDmPolicy(params) {
37
+ const dm = isRecord(params.entry.dm) ? params.entry.dm : null;
38
+ if (!dm || dm.policy !== "trusted") return {
39
+ entry: params.entry,
40
+ changed: false
41
+ };
42
+ const allowFromRaw = dm.allowFrom;
43
+ const allowFromEntries = Array.isArray(allowFromRaw) ? allowFromRaw.filter((entry) => typeof entry === "string" && entry.trim().length > 0).length : 0;
44
+ const nextPolicy = allowFromEntries > 0 ? "allowlist" : "pairing";
45
+ const nextDm = {
46
+ ...dm,
47
+ policy: nextPolicy
48
+ };
49
+ params.changes.push(`Migrated ${params.pathPrefix}.dm.policy "trusted" → "${nextPolicy}" (legacy alias removed; ${allowFromEntries > 0 ? `preserved ${allowFromEntries} ${params.pathPrefix}.dm.allowFrom ${allowFromEntries === 1 ? "entry" : "entries"}` : "no allowFrom entries present, defaulting to pairing for safety"}).`);
50
+ return {
51
+ entry: {
52
+ ...params.entry,
53
+ dm: nextDm
54
+ },
55
+ changed: true
56
+ };
57
+ }
58
+ function normalizeMatrixRoomAllowAliases(params) {
59
+ let changed = false;
60
+ const nextRooms = { ...params.rooms };
61
+ for (const [roomId, roomValue] of Object.entries(params.rooms)) {
62
+ const room = isRecord(roomValue) ? roomValue : null;
63
+ if (!room || typeof room.allow !== "boolean") continue;
64
+ const nextRoom = { ...room };
65
+ if (typeof nextRoom.enabled !== "boolean") nextRoom.enabled = room.allow;
66
+ delete nextRoom.allow;
67
+ nextRooms[roomId] = nextRoom;
68
+ changed = true;
69
+ params.changes.push(`Moved ${params.pathPrefix}.${roomId}.allow → ${params.pathPrefix}.${roomId}.enabled (${String(nextRoom.enabled)}).`);
70
+ }
71
+ return {
72
+ rooms: nextRooms,
73
+ changed
74
+ };
75
+ }
76
+ const legacyConfigRules = [
77
+ ...streamingAliasMigration.legacyConfigRules,
78
+ {
79
+ path: ["channels", "matrix"],
80
+ message: "channels.matrix.allowPrivateNetwork is legacy; use channels.matrix.network.dangerouslyAllowPrivateNetwork instead. Run \"openclaw doctor --fix\".",
81
+ match: (value) => hasLegacyFlatAllowPrivateNetworkAlias(isRecord(value) ? value : {})
82
+ },
83
+ {
84
+ path: [
85
+ "channels",
86
+ "matrix",
87
+ "accounts"
88
+ ],
89
+ message: "channels.matrix.accounts.<id>.allowPrivateNetwork is legacy; use channels.matrix.accounts.<id>.network.dangerouslyAllowPrivateNetwork instead. Run \"openclaw doctor --fix\".",
90
+ match: (value) => hasLegacyAccountStreamingAliases(value, (account) => hasLegacyFlatAllowPrivateNetworkAlias(isRecord(account) ? account : {}))
91
+ },
92
+ {
93
+ path: [
94
+ "channels",
95
+ "matrix",
96
+ "groups"
97
+ ],
98
+ message: "channels.matrix.groups.<room>.allow is legacy; use channels.matrix.groups.<room>.enabled instead. Run \"openclaw doctor --fix\".",
99
+ match: hasLegacyMatrixRoomMapAllowAliases
100
+ },
101
+ {
102
+ path: [
103
+ "channels",
104
+ "matrix",
105
+ "rooms"
106
+ ],
107
+ message: "channels.matrix.rooms.<room>.allow is legacy; use channels.matrix.rooms.<room>.enabled instead. Run \"openclaw doctor --fix\".",
108
+ match: hasLegacyMatrixRoomMapAllowAliases
109
+ },
110
+ {
111
+ path: [
112
+ "channels",
113
+ "matrix",
114
+ "accounts"
115
+ ],
116
+ message: "channels.matrix.accounts.<id>.{groups,rooms}.<room>.allow is legacy; use channels.matrix.accounts.<id>.{groups,rooms}.<room>.enabled instead. Run \"openclaw doctor --fix\".",
117
+ match: (value) => hasLegacyAccountStreamingAliases(value, (account) => {
118
+ if (!isRecord(account)) return false;
119
+ return hasLegacyMatrixRoomMapAllowAliases(account.groups) || hasLegacyMatrixRoomMapAllowAliases(account.rooms);
120
+ })
121
+ },
122
+ {
123
+ path: ["channels", "matrix"],
124
+ message: "channels.matrix.dm.policy \"trusted\" is legacy; use \"allowlist\" (with allowFrom entries) or \"pairing\" instead. Run \"openclaw doctor --fix\".",
125
+ match: hasLegacyTrustedDmPolicy
126
+ },
127
+ {
128
+ path: [
129
+ "channels",
130
+ "matrix",
131
+ "accounts"
132
+ ],
133
+ message: "channels.matrix.accounts.<id>.dm.policy \"trusted\" is legacy; use \"allowlist\" (with allowFrom entries) or \"pairing\" instead. Run \"openclaw doctor --fix\".",
134
+ match: (value) => hasLegacyAccountStreamingAliases(value, hasLegacyTrustedDmPolicy)
135
+ }
136
+ ];
137
+ function normalizeMatrixEntry(params) {
138
+ const network = migrateLegacyFlatAllowPrivateNetworkAlias(params);
139
+ const dmPolicy = migrateLegacyTrustedDmPolicy({
140
+ ...params,
141
+ entry: network.entry
142
+ });
143
+ let entry = dmPolicy.entry;
144
+ let changed = network.changed || dmPolicy.changed;
145
+ for (const key of ["groups", "rooms"]) {
146
+ const rooms = isRecord(entry[key]) ? entry[key] : null;
147
+ if (!rooms) continue;
148
+ const normalized = normalizeMatrixRoomAllowAliases({
149
+ rooms,
150
+ pathPrefix: `${params.pathPrefix}.${key}`,
151
+ changes: params.changes
152
+ });
153
+ if (normalized.changed) {
154
+ entry = Object.assign({}, entry, { [key]: normalized.rooms });
155
+ changed = true;
156
+ }
157
+ }
158
+ return {
159
+ entry,
160
+ changed
161
+ };
162
+ }
163
+ function normalizeCompatibilityConfig({ cfg }) {
164
+ const changes = [];
165
+ const withoutJunkStreamMode = stripRetiredChannelKeys({
166
+ cfg,
167
+ channelId: "matrix",
168
+ keys: /* @__PURE__ */ new Set(["streamMode"]),
169
+ scope: "root-and-accounts",
170
+ onRemove: ({ key, pathPrefix }) => changes.push(`Removed ${pathPrefix}.${key} (never read by the Matrix runtime).`)
171
+ }).config;
172
+ return normalizeChannelConfigEntries({
173
+ cfg: streamingAliasMigration.normalizeChannelConfig({
174
+ cfg: withoutJunkStreamMode,
175
+ changes
176
+ }).config,
177
+ channelId: "matrix",
178
+ changes,
179
+ normalizeEntry: normalizeMatrixEntry
180
+ });
181
+ }
182
+ //#endregion
183
+ export { normalizeCompatibilityConfig as n, legacyConfigRules as t };