@openclaw/matrix 2026.11.5-beta.1 → 2026.11.5-beta.3

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 (102) hide show
  1. package/dist/.setup/{account-config-CVM2a28p.mjs → account-config-CRsKoMqJ.mjs} +2 -1
  2. package/dist/.setup/{account-selection-Cow3TMFO.mjs → account-selection-UUPhMBmu.mjs} +8 -5
  3. package/dist/.setup/{approval-handler.runtime-_0gqiVgR.mjs → approval-handler.runtime-Ca12_7Qa.mjs} +9 -8
  4. package/dist/.setup/{approval-reactions-Bz_8XB01.mjs → approval-reactions-BazmsDbe.mjs} +3 -2
  5. package/dist/.setup/{backup-health-BxH69np2.mjs → backup-health-Dm_YMVFT.mjs} +2 -1
  6. package/dist/.setup/{channel-ByHcZU28.mjs → channel-CX7k81dL.mjs} +38 -27
  7. package/dist/.setup/{channel.runtime-sNicWjmD.mjs → channel.runtime-K_hHX-9W.mjs} +12 -10
  8. package/dist/.setup/{channel.setup-Bmba21y9.mjs → channel.setup-B00zzOOL.mjs} +7 -5
  9. package/dist/.setup/{cli-B26pps0Q.mjs → cli-dz9hd2dR.mjs} +34 -25
  10. package/dist/.setup/{cli-metadata-CKGwVfmT.mjs → cli-metadata-CwUhA9CY.mjs} +5 -3
  11. package/dist/.setup/{client-N8TEwtmk.mjs → client-CFPYqaYK.mjs} +5 -4
  12. package/dist/.setup/{client-Bqu801rH.mjs → client-D1bsidwU.mjs} +26 -21
  13. package/dist/.setup/{client-bootstrap-k6Zm1M8Y.mjs → client-bootstrap-CTT0VF6v.mjs} +3 -2
  14. package/dist/.setup/{client-support-CqXAOZp3.mjs → client-support-B_Mp4Qk9.mjs} +3 -2
  15. package/dist/.setup/{config-paths-DBpHxDyc.mjs → config-paths-CnREYb1Y.mjs} +2 -1
  16. package/dist/.setup/{create-client-DaGljdrk.mjs → create-client-Ccf5wyS3.mjs} +9 -8
  17. package/dist/.setup/{credentials-DVmY0miU.mjs → credentials-kT20jk_u.mjs} +6 -5
  18. package/dist/.setup/{credentials-read-rPqEpuxv.mjs → credentials-read-CM6wXUjL.mjs} +6 -5
  19. package/dist/.setup/{credentials-state-jxq29yQw.mjs → credentials-state-B3cuUFwZ.mjs} +2 -1
  20. package/dist/.setup/{crypto-node.runtime-E_hqXGxm.mjs → crypto-node.runtime-6Aj_ltHQ.mjs} +2 -1
  21. package/dist/.setup/{crypto-runtime-KQupbxSM.mjs → crypto-runtime-DZNytKX5.mjs} +15 -10
  22. package/dist/.setup/{crypto-state-store-p1mdYTWH.mjs → crypto-state-store-BZLlwkv_.mjs} +4 -3
  23. package/dist/.setup/{crypto-store-ownership-7lVHeXWL.mjs → crypto-store-ownership-CiQ1l_O7.mjs} +4 -3
  24. package/dist/.setup/{crypto-unsafe-state-doctor-CG2nJk8P.mjs → crypto-unsafe-state-doctor-Dh1dtuSz.mjs} +8 -7
  25. package/dist/.setup/{deps-CVPT2Ros.mjs → deps-D-W_QQjz.mjs} +2 -1
  26. package/dist/.setup/{device-health-D7n-lPeb.mjs → device-health-Ck2YpEVN.mjs} +3 -2
  27. package/dist/.setup/{direct-management-D59C1WO-.mjs → direct-management-Dp1giZ34.mjs} +11 -7
  28. package/dist/.setup/{directory-live-YixmpyLW.mjs → directory-live-ufzRheWx.mjs} +6 -5
  29. package/dist/.setup/{doctor-contract-GiXgCj7k.mjs → doctor-contract-BANpMUbP.mjs} +3 -2
  30. package/dist/.setup/{draft-stream-C09OtoJZ.mjs → draft-stream-BPjjKSoI.mjs} +4 -3
  31. package/dist/.setup/{encryption-guidance-DfbEaKct.mjs → encryption-guidance-Br3Lv9Hm.mjs} +4 -3
  32. package/dist/.setup/{env-vars-Bh1iOXJ1.mjs → env-vars-aEBngJPa.mjs} +2 -1
  33. package/dist/.setup/{errors-CL3YJV8U.mjs → errors-Bw4EHwKX.mjs} +2 -1
  34. package/dist/.setup/{event-helpers-DDUjVVf7.mjs → event-helpers-CxNgMQqH.mjs} +2 -1
  35. package/dist/.setup/{exec-approvals-C3rCm0Sn.mjs → exec-approvals-BwEOyI1-.mjs} +9 -6
  36. package/dist/.setup/{file-sync-store-NW6eDuai.mjs → file-sync-store-BpS12yaK.mjs} +36 -6
  37. package/dist/.setup/{http-client-CqnKFKUH.mjs → http-client-B_ohXrBm.mjs} +8 -5
  38. package/dist/.setup/{idb-persistence-CmoPtwDD.mjs → idb-persistence-BTOsltD9.mjs} +7 -6
  39. package/dist/.setup/{idb-persistence-lock-CH2K6d_3.mjs → idb-persistence-lock-Bh3ZLIsE.mjs} +2 -1
  40. package/dist/.setup/{joined-room-encryption-9sJK1kM-.mjs → joined-room-encryption-C0gHa2DG.mjs} +3 -2
  41. package/dist/.setup/{logger-B9TwnY6C.mjs → logger-CuAzdD8Q.mjs} +3 -2
  42. package/dist/.setup/{logging-Bnsn7s4r.mjs → logging-CoaEyRtA.mjs} +4 -3
  43. package/dist/.setup/{messages-BjzsVgS6.mjs → messages-DpJ9naJa.mjs} +14 -9
  44. package/dist/.setup/{monitor-D4vhbNUM.mjs → monitor-Rzl3naSn.mjs} +157 -63
  45. package/dist/.setup/{onboarding-DKmt3jpW.mjs → onboarding-BK-V2ZLT.mjs} +11 -10
  46. package/dist/.setup/{outbound-wsXTF0z_.mjs → outbound-DMMVmZjV.mjs} +4 -3
  47. package/dist/.setup/{profile-update-DX060MnL.mjs → profile-update-RLsY-gu6.mjs} +9 -7
  48. package/dist/.setup/{reaction-events-BMsatzs4.mjs → reaction-events-UA_g6jEX.mjs} +9 -8
  49. package/dist/.setup/{resolve-targets-Yz_3aN_2.mjs → resolve-targets-DYW8ULZS.mjs} +5 -4
  50. package/dist/.setup/{retired-state-Bs3Gqkge.mjs → retired-state-JGUEBE72.mjs} +7 -4
  51. package/dist/.setup/{room-info-OGKjk422.mjs → room-info-Dhc4efkA.mjs} +8 -6
  52. package/dist/.setup/{runtime-Ck8TjD7L.mjs → runtime-1kn1P6io.mjs} +2 -1
  53. package/dist/.setup/{runtime-doctor-migrations-CSvRANPN.mjs → runtime-doctor-migrations-hxP-CXX7.mjs} +10 -5
  54. package/dist/.setup/{runtime-setter-api-CpwhcBQK.mjs → runtime-setter-api-i2MOXoT3.mjs} +1 -1
  55. package/dist/.setup/{sdk-BXcIyN-I.mjs → sdk-DPXiQ3jr.mjs} +46 -32
  56. package/dist/.setup/{secret-contract-AKnr45nw.mjs → secret-contract-DxyzKSzf.mjs} +3 -2
  57. package/dist/.setup/{secret-contract-api-DMSwMIxd.mjs → secret-contract-api-Dukgvike.mjs} +1 -1
  58. package/dist/.setup/{send-CWjH-l-T.mjs → send-HHAbKARg.mjs} +41 -25
  59. package/dist/.setup/{send-currentness-D1x6YP9O.mjs → send-currentness-DGxiiBn9.mjs} +4 -2
  60. package/dist/.setup/{setup-bootstrap-yKeGh4Iy.mjs → setup-bootstrap-DaT2j28V.mjs} +5 -4
  61. package/dist/.setup/{setup-core-BaKffgBi.mjs → setup-core-DcqQbLZv.mjs} +20 -13
  62. package/dist/.setup/setup-plugin-api-Cg4TelGZ.mjs +2 -0
  63. package/dist/.setup/{startup-verification-C-lhD0gk.mjs → startup-verification-UkaoSldm.mjs} +5 -4
  64. package/dist/.setup/{state-layout-walk-BqCZTHpp.mjs → state-layout-walk-BQMgMykU.mjs} +3 -2
  65. package/dist/.setup/{storage-BLLN9jYG.mjs → storage-C3N6YZIn.mjs} +10 -8
  66. package/dist/.setup/{storage-paths-e_Vq6cvw.mjs → storage-paths-B51JM-pC.mjs} +2 -1
  67. package/dist/.setup/{subagent-hooks-D-lCcLGQ.mjs → subagent-hooks-CfGAysJi.mjs} +3 -2
  68. package/dist/.setup/{sync-cache-state-B4hJFIPw.mjs → sync-cache-state-BKVaKRzQ.mjs} +5 -4
  69. package/dist/.setup/{sync-state-Cu1nagBV.mjs → sync-state-CWbp0QSY.mjs} +2 -1
  70. package/dist/.setup/{target-ids-DltG_ZHJ.mjs → target-ids-HhcaKX1n.mjs} +2 -1
  71. package/dist/.setup/{task-runner-CYyGHdNW.mjs → task-runner-DY3aKiQa.mjs} +2 -1
  72. package/dist/.setup/{thread-binding-api-OtSciHmZ.mjs → thread-binding-api-BvuaKpd0.mjs} +3 -2
  73. package/dist/.setup/{thread-bindings-BA2xESjV.mjs → thread-bindings-891JsKXF.mjs} +9 -7
  74. package/dist/.setup/{thread-bindings-shared-CBlJu3Wz.mjs → thread-bindings-shared-QmZOfX9Q.mjs} +2 -1
  75. package/dist/.setup/{tool-actions-CRuiVbqj.mjs → tool-actions-yFZH_7mC.mjs} +24 -19
  76. package/dist/.setup/{url-validation-DesoKUns.mjs → url-validation-By_2hsXr.mjs} +2 -1
  77. package/dist/.setup/{verification-C5x4Hy5Y.mjs → verification-CcZIVL8P.mjs} +5 -4
  78. package/dist/.source-module-urls/1cd4d4ff8d44e1c8b830932b44d7cf8a7f3350e09e169910e1d7a85e131b7bea.json +1 -1
  79. package/dist/api.js +8 -8
  80. package/dist/auth-presence.js +3 -2
  81. package/dist/channel-plugin-api.js +1 -1
  82. package/dist/cli-metadata.js +1 -1
  83. package/dist/contract-api.js +2 -2
  84. package/dist/doctor-contract-api.js +16 -13
  85. package/dist/helper-api.js +3 -3
  86. package/dist/index.js +4 -3
  87. package/dist/plugin-entry.handlers.runtime.js +4 -3
  88. package/dist/runtime-api.js +8 -7
  89. package/dist/runtime-setter-api.js +1 -1
  90. package/dist/secret-contract-api.js +1 -1
  91. package/dist/session-binding-contract-api.js +2 -2
  92. package/dist/setup-entry.js +5 -4
  93. package/dist/setup-plugin-api.js +1 -1
  94. package/dist/subagent-hooks-api.js +3 -2
  95. package/dist/thread-binding-api.js +1 -1
  96. package/dist/thread-bindings-runtime.js +1 -1
  97. package/node_modules/matrix-js-sdk/lib/http-api/utils.js +3 -1
  98. package/node_modules/matrix-js-sdk/lib/rust-crypto/rust-crypto.js +7 -1
  99. package/node_modules/matrix-js-sdk/src/http-api/utils.ts +5 -1
  100. package/node_modules/matrix-js-sdk/src/rust-crypto/rust-crypto.ts +7 -1
  101. package/package.json +4 -4
  102. package/dist/.setup/setup-plugin-api-B_t4waBw.mjs +0 -2
@@ -1,14 +1,15 @@
1
- import { a as resolveMatrixAccountConfig } from "./account-config-CVM2a28p.mjs";
2
- import { g as resolveDefaultMatrixAccountId, v as resolveMatrixAccountAsync } from "./setup-core-BaKffgBi.mjs";
3
- import { i as normalizeMatrixUserId } from "./channel.setup-Bmba21y9.mjs";
1
+ import { a as resolveMatrixAccountConfig } from "./account-config-CRsKoMqJ.mjs";
2
+ import { g as resolveDefaultMatrixAccountId, v as resolveMatrixAccountAsync } from "./setup-core-DcqQbLZv.mjs";
3
+ import { i as normalizeMatrixUserId } from "./channel.setup-B00zzOOL.mjs";
4
4
  import { doesApprovalRequestSelectChannelAccountAsync } from "openclaw/plugin-sdk/approval-native-runtime";
5
5
  import { createChannelApprovalAuth, resolveApprovalApprovers } from "openclaw/plugin-sdk/approval-auth-runtime";
6
6
  import { createChannelExecApprovalProfileAsync, getExecApprovalReplyMetadata, isChannelExecApprovalClientEnabledFromConfig, isChannelExecApprovalTargetRecipient, matchesApprovalRequestFilters } from "openclaw/plugin-sdk/approval-client-runtime";
7
- // extensions/matrix/src/approval-ids.ts
7
+ //#region extensions/matrix/src/approval-ids.ts
8
8
  function normalizeMatrixApproverId(value) {
9
9
  return normalizeMatrixUserId(String(value)) || void 0;
10
10
  }
11
- // extensions/matrix/src/approval-auth.ts
11
+ //#endregion
12
+ //#region extensions/matrix/src/approval-auth.ts
12
13
  const matrixApproval = createChannelApprovalAuth({
13
14
  channelLabel: "Matrix",
14
15
  resolveInputs: ({ cfg, accountId }) => {
@@ -21,7 +22,8 @@ const matrixApproval = createChannelApprovalAuth({
21
22
  });
22
23
  const getMatrixApprovalAuthApprovers = matrixApproval.resolveApprovers;
23
24
  const matrixApprovalAuth = matrixApproval.approvalAuth;
24
- // extensions/matrix/src/exec-approvals.ts
25
+ //#endregion
26
+ //#region extensions/matrix/src/exec-approvals.ts
25
27
  function normalizeMatrixExecApproverId(value) {
26
28
  const normalized = normalizeMatrixApproverId(value);
27
29
  return normalized === "*" ? void 0 : normalized;
@@ -141,4 +143,5 @@ async function shouldSuppressLocalMatrixExecApprovalPrompt(params) {
141
143
  request
142
144
  });
143
145
  }
146
+ //#endregion
144
147
  export { isMatrixExecApprovalAuthorizedSender as a, shouldSuppressLocalMatrixExecApprovalPrompt as c, normalizeMatrixApproverId as d, isMatrixApprovalClientEnabled as i, getMatrixApprovalAuthApprovers as l, getMatrixExecApprovalApprovers as n, resolveMatrixExecApprovalTarget as o, isMatrixAnyApprovalClientEnabled as r, shouldHandleMatrixApprovalRequest as s, getMatrixApprovalApprovers as t, matrixApprovalAuth as u };
@@ -1,11 +1,12 @@
1
- import { t as getMatrixRuntime } from "./runtime-Ck8TjD7L.mjs";
2
- import { t as claimCurrentTokenStorageState } from "./storage-BLLN9jYG.mjs";
3
- import { a as readPersistedStoreFromStore, r as openMatrixSyncCacheStoreOptions, s as writeMatrixSyncCacheStateToStore, t as deleteMatrixSyncCacheStateFromStore } from "./sync-cache-state-B4hJFIPw.mjs";
4
- import { t as LogService } from "./logger-B9TwnY6C.mjs";
1
+ import { t as getMatrixRuntime } from "./runtime-1kn1P6io.mjs";
2
+ import { t as claimCurrentTokenStorageState } from "./storage-C3N6YZIn.mjs";
3
+ import { a as readPersistedStoreFromStore, r as openMatrixSyncCacheStoreOptions, s as writeMatrixSyncCacheStateToStore, t as deleteMatrixSyncCacheStateFromStore } from "./sync-cache-state-BKVaKRzQ.mjs";
4
+ import { n as emitMatrixLog, t as LogService } from "./logger-CuAzdD8Q.mjs";
5
5
  import { materializeErrorStack } from "openclaw/plugin-sdk/error-runtime";
6
+ import { randomUUID } from "node:crypto";
6
7
  import { MemoryStore, SyncAccumulator } from "matrix-js-sdk/lib/matrix.js";
7
8
  import { createAsyncLock } from "openclaw/plugin-sdk/async-lock-runtime";
8
- // extensions/matrix/src/matrix/client/file-sync-store.ts
9
+ //#region extensions/matrix/src/matrix/client/file-sync-store.ts
9
10
  const PERSIST_DEBOUNCE_MS = 250;
10
11
  function syncDataToSyncResponse(syncData) {
11
12
  return {
@@ -15,6 +16,22 @@ function syncDataToSyncResponse(syncData) {
15
16
  };
16
17
  }
17
18
  var SqliteBackedMatrixSyncStore = class SqliteBackedMatrixSyncStore extends MemoryStore {
19
+ observe(phase, facts = {}) {
20
+ if (this.diagnosticCount >= 48) return;
21
+ this.diagnosticCount += 1;
22
+ try {
23
+ emitMatrixLog("debug", "MatrixSyncIngress", [JSON.stringify({
24
+ store: this.diagnosticId,
25
+ sequence: this.diagnosticCount,
26
+ phase,
27
+ bound: Boolean(this.syncIngressHandler),
28
+ frozen: this.frozen,
29
+ admissionPending: this.syncIngressAdmission !== null,
30
+ ...facts,
31
+ exhausted: this.diagnosticCount === 48
32
+ })]);
33
+ } catch {}
34
+ }
18
35
  static async create(storageRootDir) {
19
36
  let store;
20
37
  let persisted = null;
@@ -37,6 +54,8 @@ var SqliteBackedMatrixSyncStore = class SqliteBackedMatrixSyncStore extends Memo
37
54
  this.storageRootDir = storageRootDir;
38
55
  this.store = store;
39
56
  this.storeUnavailableError = storeUnavailableError;
57
+ this.diagnosticId = randomUUID();
58
+ this.diagnosticCount = 0;
40
59
  this.persistLock = createAsyncLock();
41
60
  this.accumulator = new SyncAccumulator();
42
61
  this.savedSync = null;
@@ -69,8 +88,12 @@ var SqliteBackedMatrixSyncStore = class SqliteBackedMatrixSyncStore extends Memo
69
88
  async bindSyncIngress(handler) {
70
89
  if (this.frozen || this.syncIngressHandler) throw new Error("Matrix sync ingress is already bound or the sync store is frozen");
71
90
  this.syncIngressHandler = handler;
91
+ this.observe("bound", { savedSync: this.savedSync !== null });
72
92
  const dispose = () => {
73
- if (this.syncIngressHandler === handler) this.syncIngressHandler = void 0;
93
+ if (this.syncIngressHandler === handler) {
94
+ this.observe("unbound");
95
+ this.syncIngressHandler = void 0;
96
+ }
74
97
  };
75
98
  try {
76
99
  if (this.savedSync) {
@@ -93,19 +116,25 @@ var SqliteBackedMatrixSyncStore = class SqliteBackedMatrixSyncStore extends Memo
93
116
  return Promise.resolve(this.savedSync?.nextBatch ?? null);
94
117
  }
95
118
  async setSyncData(syncData) {
119
+ const eventCount = this.diagnosticCount < 48 ? [...Object.values(syncData.rooms?.join ?? {}), ...Object.values(syncData.rooms?.leave ?? {})].reduce((count, room) => count + (room.timeline?.events?.length ?? 0), 0) : 0;
120
+ if (eventCount > 0) this.observe("sync-received", { eventCount });
96
121
  if (this.frozen) return;
97
122
  const handler = this.syncIngressHandler;
98
123
  if (handler) {
99
124
  await this.runSyncIngress(async () => {
125
+ if (eventCount > 0) this.observe("handler-entered");
100
126
  await handler(syncData, { hasSavedSync: this.hadSavedSyncOnLoad });
127
+ if (eventCount > 0) this.observe("handler-returned");
101
128
  if (!this.frozen) {
102
129
  super.setSyncToken(syncData.next_batch);
103
130
  this.acceptSyncData(syncData);
131
+ if (eventCount > 0) this.observe("cursor-accepted");
104
132
  }
105
133
  });
106
134
  return;
107
135
  }
108
136
  this.acceptSyncData(syncData);
137
+ if (eventCount > 0) this.observe("cursor-accepted-unbound");
109
138
  }
110
139
  acceptSyncData(syncData) {
111
140
  this.accumulator.accumulate(syncData);
@@ -224,4 +253,5 @@ var SqliteBackedMatrixSyncStore = class SqliteBackedMatrixSyncStore extends Memo
224
253
  throw new Error("Matrix sync cache SQLite store is unavailable; cannot persist sync state", { cause: this.storeUnavailableError });
225
254
  }
226
255
  };
256
+ //#endregion
227
257
  export { SqliteBackedMatrixSyncStore };
@@ -1,5 +1,5 @@
1
- import { n as __exportAll } from "./runtime-doctor-migrations-CSvRANPN.mjs";
2
- import { t as buildHttpError } from "./event-helpers-DDUjVVf7.mjs";
1
+ import { n as __exportAll } from "./runtime-doctor-migrations-hxP-CXX7.mjs";
2
+ import { t as buildHttpError } from "./event-helpers-CxNgMQqH.mjs";
3
3
  import { PlatformMessageNotDispatchedError } from "openclaw/plugin-sdk/error-runtime";
4
4
  import { parseMediaContentLength } from "openclaw/plugin-sdk/media-runtime";
5
5
  import { buildTimeoutAbortSignal } from "openclaw/plugin-sdk/extension-shared";
@@ -7,7 +7,7 @@ import { captureChannelReadAuthority, captureEffectAuthority } from "openclaw/pl
7
7
  import { readResponseWithLimit } from "openclaw/plugin-sdk/response-limit-runtime";
8
8
  import { fetchWithRuntimeDispatcherOrMockedGlobal } from "openclaw/plugin-sdk/runtime-fetch";
9
9
  import { closeDispatcher, createPinnedDispatcher, resolvePinnedHostnameWithPolicy } from "openclaw/plugin-sdk/ssrf-dispatcher";
10
- // extensions/matrix/src/matrix/media-errors.ts
10
+ //#region extensions/matrix/src/matrix/media-errors.ts
11
11
  const MATRIX_MEDIA_SIZE_LIMIT_ERROR_MESSAGE = "Matrix media exceeds configured size limit";
12
12
  var MatrixMediaSizeLimitError = class extends Error {
13
13
  constructor(message = MATRIX_MEDIA_SIZE_LIMIT_ERROR_MESSAGE, options) {
@@ -21,7 +21,8 @@ function isMatrixMediaSizeLimitError(err) {
21
21
  if (!(err instanceof Error) || err.cause === void 0) return false;
22
22
  return isMatrixMediaSizeLimitError(err.cause);
23
23
  }
24
- // extensions/matrix/src/matrix/sdk/transport.ts
24
+ //#endregion
25
+ //#region extensions/matrix/src/matrix/sdk/transport.ts
25
26
  var MatrixSdkAuthorityError = class extends Error {
26
27
  constructor(cause) {
27
28
  super(cause instanceof Error ? cause.message : "Matrix request authority expired", { cause });
@@ -282,7 +283,8 @@ async function performMatrixRequest(params) {
282
283
  buffer
283
284
  }));
284
285
  }
285
- // extensions/matrix/src/matrix/sdk/http-client.ts
286
+ //#endregion
287
+ //#region extensions/matrix/src/matrix/sdk/http-client.ts
286
288
  var http_client_exports = /* @__PURE__ */ __exportAll({ MatrixAuthedHttpClient: () => MatrixAuthedHttpClient });
287
289
  var MatrixAuthedHttpClient = class {
288
290
  constructor(params) {
@@ -319,4 +321,5 @@ var MatrixAuthedHttpClient = class {
319
321
  return buffer;
320
322
  }
321
323
  };
324
+ //#endregion
322
325
  export { isMatrixMediaSizeLimitError as a, MatrixMediaSizeLimitError as i, http_client_exports as n, createMatrixGuardedFetch as r, MatrixAuthedHttpClient as t };
@@ -1,8 +1,8 @@
1
- import { t as getMatrixRuntime } from "./runtime-Ck8TjD7L.mjs";
2
- import { n as RETIRED_MATRIX_STATE_REMEDIATION } from "./retired-state-Bs3Gqkge.mjs";
3
- import { i as readMatrixIdbSnapshotJson, l as writeMatrixIdbSnapshotJson, r as pruneMatrixIdbSnapshotChunks } from "./crypto-state-store-p1mdYTWH.mjs";
4
- import { t as LogService } from "./logger-B9TwnY6C.mjs";
5
- import { n as MATRIX_IDB_SNAPSHOT_LOCK_OPTIONS } from "./idb-persistence-lock-CH2K6d_3.mjs";
1
+ import { t as getMatrixRuntime } from "./runtime-1kn1P6io.mjs";
2
+ import { n as RETIRED_MATRIX_STATE_REMEDIATION } from "./retired-state-JGUEBE72.mjs";
3
+ import { i as readMatrixIdbSnapshotJson, l as writeMatrixIdbSnapshotJson, r as pruneMatrixIdbSnapshotChunks } from "./crypto-state-store-BZLlwkv_.mjs";
4
+ import { t as LogService } from "./logger-CuAzdD8Q.mjs";
5
+ import { n as MATRIX_IDB_SNAPSHOT_LOCK_OPTIONS } from "./idb-persistence-lock-Bh3ZLIsE.mjs";
6
6
  import { toErrorObject } from "openclaw/plugin-sdk/error-runtime";
7
7
  import { asOptionalObjectRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
8
8
  import path from "node:path";
@@ -10,7 +10,7 @@ import fs from "node:fs";
10
10
  import { withFileLock } from "openclaw/plugin-sdk/file-lock";
11
11
  import { IDBFactory, indexedDB } from "fake-indexeddb";
12
12
  import { isStringArray } from "openclaw/plugin-sdk/collection-input-runtime";
13
- // extensions/matrix/src/matrix/sdk/idb-persistence.ts
13
+ //#region extensions/matrix/src/matrix/sdk/idb-persistence.ts
14
14
  const LEGACY_SNAPSHOT_DIAGNOSTIC = {
15
15
  code: "matrix-idb-snapshot-requires-doctor",
16
16
  message: "Matrix IndexedDB snapshot exists outside the current SQLite state",
@@ -236,4 +236,5 @@ function throwLegacySnapshotMigrationRequired() {
236
236
  LogService.warn("IdbPersistence", LEGACY_SNAPSHOT_DIAGNOSTIC);
237
237
  throw new MatrixIdbSnapshotMigrationRequiredError();
238
238
  }
239
+ //#endregion
239
240
  export { persistIdbToDisk, resolveDefaultIdbSnapshotPath, restoreIdbFromDisk, validateMatrixIdbSnapshotJson };
@@ -1,4 +1,4 @@
1
- // extensions/matrix/src/matrix/sdk/idb-persistence-lock.ts
1
+ //#region extensions/matrix/src/matrix/sdk/idb-persistence-lock.ts
2
2
  const MATRIX_IDB_PERSIST_INTERVAL_MS = 6e4;
3
3
  const MATRIX_IDB_SNAPSHOT_LOCK_OPTIONS = {
4
4
  retries: {
@@ -10,4 +10,5 @@ const MATRIX_IDB_SNAPSHOT_LOCK_OPTIONS = {
10
10
  },
11
11
  stale: 3e5
12
12
  };
13
+ //#endregion
13
14
  export { MATRIX_IDB_SNAPSHOT_LOCK_OPTIONS as n, MATRIX_IDB_PERSIST_INTERVAL_MS as t };
@@ -1,9 +1,9 @@
1
- import { t as LogService } from "./logger-B9TwnY6C.mjs";
1
+ import { t as LogService } from "./logger-CuAzdD8Q.mjs";
2
2
  import { ConnectionError, HTTPError, Method } from "matrix-js-sdk/lib/http-api/index.js";
3
3
  import { EventType, MatrixError, MatrixEvent } from "matrix-js-sdk/lib/matrix.js";
4
4
  import { isStringArray } from "openclaw/plugin-sdk/collection-input-runtime";
5
5
  import { RustCrypto } from "matrix-js-sdk/lib/rust-crypto/rust-crypto.js";
6
- // extensions/matrix/src/matrix/sdk/joined-room-encryption.ts
6
+ //#region extensions/matrix/src/matrix/sdk/joined-room-encryption.ts
7
7
  const ROOM_CONCURRENCY = 4;
8
8
  async function reconcileJoinedRoomEncryption(client, signal, assertCurrent) {
9
9
  const crypto = client.getCrypto();
@@ -64,4 +64,5 @@ async function reconcileJoinedRoomEncryption(client, signal, assertCurrent) {
64
64
  checkActive();
65
65
  for (const result of results) if (result.status === "rejected") throw result.reason;
66
66
  }
67
+ //#endregion
67
68
  export { reconcileJoinedRoomEncryption };
@@ -1,7 +1,7 @@
1
- import { t as getMatrixRuntime } from "./runtime-Ck8TjD7L.mjs";
1
+ import { t as getMatrixRuntime } from "./runtime-1kn1P6io.mjs";
2
2
  import { format } from "node:util";
3
3
  import { redactSensitiveText } from "openclaw/plugin-sdk/security-runtime";
4
- // extensions/matrix/src/matrix/sdk/logger.ts
4
+ //#region extensions/matrix/src/matrix/sdk/logger.ts
5
5
  function noop() {}
6
6
  let forceConsoleLogging = false;
7
7
  let serviceQuiet = false;
@@ -40,4 +40,5 @@ const LogService = {
40
40
  info: emitServiceLog.bind(null, "info"),
41
41
  warn: emitServiceLog.bind(null, "warn")
42
42
  };
43
+ //#endregion
43
44
  export { setMatrixLogServiceQuiet as a, setMatrixConsoleLogging as i, emitMatrixLog as n, noop as r, LogService as t };
@@ -1,7 +1,7 @@
1
- import { n as __exportAll } from "./runtime-doctor-migrations-CSvRANPN.mjs";
2
- import { a as setMatrixLogServiceQuiet, n as emitMatrixLog } from "./logger-B9TwnY6C.mjs";
1
+ import { n as __exportAll } from "./runtime-doctor-migrations-hxP-CXX7.mjs";
2
+ import { a as setMatrixLogServiceQuiet, n as emitMatrixLog } from "./logger-CuAzdD8Q.mjs";
3
3
  import { logger } from "matrix-js-sdk/lib/logger.js";
4
- // extensions/matrix/src/matrix/client/logging.ts
4
+ //#region extensions/matrix/src/matrix/client/logging.ts
5
5
  var logging_exports = /* @__PURE__ */ __exportAll({
6
6
  createMatrixJsSdkClientLogger: () => createMatrixJsSdkClientLogger,
7
7
  ensureMatrixSdkLoggingConfigured: () => ensureMatrixSdkLoggingConfigured,
@@ -73,4 +73,5 @@ function createMatrixJsSdkClientLogger(prefix = "matrix") {
73
73
  }
74
74
  };
75
75
  }
76
+ //#endregion
76
77
  export { logging_exports as n, setMatrixSdkLogMode as r, createMatrixJsSdkClientLogger as t };
@@ -1,11 +1,11 @@
1
- import { a as MATRIX_REACTION_EVENT_TYPE } from "./send-currentness-D1x6YP9O.mjs";
2
- import { _ as isPollEventType, b as resolvePollReferenceEventId, d as resolveMatrixReplacementContent, g as formatPollResultsAsText, m as buildPollResultsSummary, t as editMessageMatrix, u as resolveMatrixMessageAttachment, v as isPollStartType, y as parsePollStart } from "./send-CWjH-l-T.mjs";
3
- import { n as isMatrixNotFoundError } from "./errors-CL3YJV8U.mjs";
4
- import { r as withResolvedRoomAction } from "./client-N8TEwtmk.mjs";
1
+ import { a as MATRIX_REACTION_EVENT_TYPE } from "./send-currentness-DGxiiBn9.mjs";
2
+ import { _ as isPollEventType, b as resolvePollReferenceEventId, d as resolveMatrixReplacementContent, g as formatPollResultsAsText, m as buildPollResultsSummary, t as editMessageMatrix, u as resolveMatrixMessageAttachment, v as isPollStartType, y as parsePollStart } from "./send-HHAbKARg.mjs";
3
+ import { n as isMatrixNotFoundError } from "./errors-Bw4EHwKX.mjs";
4
+ import { r as withResolvedRoomAction } from "./client-CFPYqaYK.mjs";
5
5
  import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
6
6
  import { asNullableObjectRecord, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
7
7
  import { HTTPError } from "matrix-js-sdk/lib/http-api/index.js";
8
- // extensions/matrix/src/matrix/poll-summary.ts
8
+ //#region extensions/matrix/src/matrix/poll-summary.ts
9
9
  function resolveMatrixPollRootEventId(event) {
10
10
  if (isPollStartType(event.type)) {
11
11
  const eventId = event.event_id?.trim();
@@ -59,18 +59,21 @@ async function fetchMatrixPollMessageSummary(client, roomId, event) {
59
59
  timestamp: snapshot.triggerEvent.origin_server_ts || snapshot.rootEvent.origin_server_ts
60
60
  };
61
61
  }
62
- // extensions/matrix/src/matrix/actions/limits.ts
62
+ //#endregion
63
+ //#region extensions/matrix/src/matrix/actions/limits.ts
63
64
  function resolveMatrixActionLimit(raw, fallback) {
64
65
  return Math.max(1, Math.floor(raw !== void 0 && Number.isFinite(raw) ? raw : fallback));
65
66
  }
66
- // extensions/matrix/src/matrix/actions/types.ts
67
+ //#endregion
68
+ //#region extensions/matrix/src/matrix/actions/types.ts
67
69
  const EventType = {
68
70
  RoomMessage: "m.room.message",
69
71
  RoomPinnedEvents: "m.room.pinned_events",
70
72
  RoomTopic: "m.room.topic",
71
73
  Reaction: MATRIX_REACTION_EVENT_TYPE
72
74
  };
73
- // extensions/matrix/src/matrix/actions/summary.ts
75
+ //#endregion
76
+ //#region extensions/matrix/src/matrix/actions/summary.ts
74
77
  function parseMatrixRawEvent(value) {
75
78
  const event = asNullableObjectRecord(value);
76
79
  const content = asNullableObjectRecord(event?.content);
@@ -142,7 +145,8 @@ async function fetchEventSummary(client, roomId, eventId) {
142
145
  return null;
143
146
  }
144
147
  }
145
- // extensions/matrix/src/matrix/actions/messages.ts
148
+ //#endregion
149
+ //#region extensions/matrix/src/matrix/actions/messages.ts
146
150
  const MATRIX_THREAD_RELATIONS_START_CURSOR_PREFIX = "openclaw.matrix.thread-relations-start:";
147
151
  const MATRIX_READ_CURSOR_HINT = "Matrix read before/after take a pagination token from a previous read's nextBatch or prevBatch, not an event id; use messageId to read one event.";
148
152
  function resolveMatrixReplacementTarget(event) {
@@ -303,4 +307,5 @@ async function isMatrixPollRootThreaded(params) {
303
307
  const rootEvent = await params.client.getEvent(params.resolvedRoom, params.pollRootId).catch(() => null);
304
308
  return rootEvent ? isMatrixThreadEvent(rootEvent) : false;
305
309
  }
310
+ //#endregion
306
311
  export { fetchEventSummary as a, resolveMatrixActionLimit as c, readMatrixMessages as i, fetchMatrixPollSnapshot as l, editMatrixMessage as n, readPinnedEvents as o, readMatrixMessage as r, EventType as s, deleteMatrixMessage as t };