@openclaw/matrix 2026.10.10 → 2026.11.1

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 (59) hide show
  1. package/dist/.setup/{account-selection-Co94mKNj.mjs → account-selection-BPFpdMIw.mjs} +1 -1
  2. package/dist/.setup/{approval-handler.runtime-DtNvJpfB.mjs → approval-handler.runtime-BvuXpzus.mjs} +4 -4
  3. package/dist/.setup/{channel-CNjJyBS_.mjs → channel-DYRabwmj.mjs} +11 -10
  4. package/dist/.setup/{channel.runtime-DaGbm27q.mjs → channel.runtime-C0VWk0Ch.mjs} +6 -6
  5. package/dist/.setup/{channel.setup-IjRB0ymg.mjs → channel.setup-Dp7V9AgV.mjs} +2 -2
  6. package/dist/.setup/{cli-metadata-rWmD_rzx.mjs → cli-metadata-DemZndyG.mjs} +1 -1
  7. package/dist/.setup/{cli-CuEJNM3c.mjs → cli-umlumhB6.mjs} +11 -11
  8. package/dist/.setup/{client-7eyTX0cu.mjs → client-BIsYqIzM.mjs} +8 -8
  9. package/dist/.setup/{client-CV0MkCZG.mjs → client-DL_aELCJ.mjs} +3 -3
  10. package/dist/.setup/{client-bootstrap-BjcmTmyR.mjs → client-bootstrap-kdsygurH.mjs} +1 -1
  11. package/dist/.setup/{create-client-C4Lnqs2C.mjs → create-client-BFkMM7SP.mjs} +5 -5
  12. package/dist/.setup/{credentials-B0vpXvcB.mjs → credentials-B3MlOOom.mjs} +1 -1
  13. package/dist/.setup/{credentials-read-WCQSEvI8.mjs → credentials-read-BOuCoy-p.mjs} +1 -1
  14. package/dist/.setup/{crypto-runtime-Crp1is7m.mjs → crypto-runtime-s3ogwLRO.mjs} +1 -1
  15. package/dist/.setup/{crypto-unsafe-state-doctor-Brv4bIyx.mjs → crypto-unsafe-state-doctor-ClzRgr8z.mjs} +1 -1
  16. package/dist/.setup/{device-health-DnKAXW1v.mjs → device-health-CmvwmCHB.mjs} +1 -1
  17. package/dist/.setup/{direct-management-DDaWVbQI.mjs → direct-management-BOYMqZJQ.mjs} +1 -1
  18. package/dist/.setup/{directory-live-B-csizuK.mjs → directory-live-tItssg9q.mjs} +2 -2
  19. package/dist/.setup/doctor-contract-GiXgCj7k.mjs +37 -0
  20. package/dist/.setup/{draft-stream-dmhBHufd.mjs → draft-stream-Buru5huX.mjs} +2 -2
  21. package/dist/.setup/{encryption-guidance-Cn6-Tlx0.mjs → encryption-guidance-CLloQ6H7.mjs} +1 -1
  22. package/dist/.setup/{exec-approvals-D7vv3AZS.mjs → exec-approvals-CWeSpE6V.mjs} +2 -2
  23. package/dist/.setup/{file-sync-store-q5KCV2Lp.mjs → file-sync-store-D1sEtAap.mjs} +2 -2
  24. package/dist/.setup/{logging-BLcaOSRD.mjs → logging-BWPjyW9s.mjs} +1 -1
  25. package/dist/.setup/{messages-BiHM0DM3.mjs → messages-Dt51OgyD.mjs} +2 -2
  26. package/dist/.setup/{monitor-CPwDgRFY.mjs → monitor-BrBbFO8h.mjs} +20 -20
  27. package/dist/.setup/{onboarding-DiVtpjNu.mjs → onboarding-QfFvgZ85.mjs} +5 -5
  28. package/dist/.setup/{outbound-DwP97VpQ.mjs → outbound-B8h2BwR2.mjs} +2 -2
  29. package/dist/.setup/{profile-update-DnNA9mEa.mjs → profile-update-DiXtw0NM.mjs} +2 -2
  30. package/dist/.setup/{reaction-events-ClY9h_FC.mjs → reaction-events-xTg2_wZJ.mjs} +4 -4
  31. package/dist/.setup/{resolve-targets-B8PAwHVS.mjs → resolve-targets-vlr765on.mjs} +2 -2
  32. package/dist/.setup/{room-info-T_PR_liR.mjs → room-info-BSvDbUmt.mjs} +3 -3
  33. package/dist/.setup/{doctor-contract-DybEjJcd.mjs → runtime-doctor-migrations-CSvRANPN.mjs} +12 -47
  34. package/dist/.setup/{sdk-Cj3ggJHG.mjs → sdk-BYR5_wri.mjs} +4 -4
  35. package/dist/.setup/{send-C1qeMQAy.mjs → send-BMe_VcxP.mjs} +3 -3
  36. package/dist/.setup/{setup-bootstrap-DDhwWvDs.mjs → setup-bootstrap-Ch6r7Szn.mjs} +2 -2
  37. package/dist/.setup/{setup-core-D2r4BivQ.mjs → setup-core-CRUekZa3.mjs} +4 -4
  38. package/dist/.setup/setup-plugin-api-BZPY4Dt2.mjs +2 -0
  39. package/dist/.setup/{startup-verification-B3LEbW33.mjs → startup-verification-Cv_NoW_O.mjs} +1 -1
  40. package/dist/.setup/{storage-CxN4jqKI.mjs → storage-B94yQdJy.mjs} +11 -4
  41. package/dist/.setup/{sync-cache-state-qYrd2EEh.mjs → sync-cache-state-B-FayxeA.mjs} +5 -3
  42. package/dist/.setup/{thread-bindings-D2ZR6mEZ.mjs → thread-bindings-CB-jqrf4.mjs} +2 -2
  43. package/dist/.setup/{tool-actions-CdKa0DC4.mjs → tool-actions-DjPJ6tpr.mjs} +9 -9
  44. package/dist/.setup/{verification-jP3tm-xD.mjs → verification-BqjyjLoq.mjs} +3 -3
  45. package/dist/.source-module-urls/1cd4d4ff8d44e1c8b830932b44d7cf8a7f3350e09e169910e1d7a85e131b7bea.json +1 -1
  46. package/dist/api.js +5 -5
  47. package/dist/channel-plugin-api.js +1 -1
  48. package/dist/cli-metadata.js +1 -1
  49. package/dist/contract-api.js +2 -2
  50. package/dist/doctor-contract-api.js +43 -12
  51. package/dist/helper-api.js +1 -1
  52. package/dist/index.js +1 -1
  53. package/dist/plugin-entry.handlers.runtime.js +2 -2
  54. package/dist/runtime-api.js +1 -1
  55. package/dist/session-binding-contract-api.js +1 -1
  56. package/dist/setup-entry.js +1 -1
  57. package/dist/setup-plugin-api.js +1 -1
  58. package/package.json +4 -4
  59. package/dist/.setup/setup-plugin-api-SO1hdrsT.mjs +0 -2
@@ -1,9 +1,10 @@
1
- import { n as normalizeCompatibilityConfig, r as runtime_doctor_migrations_exports, t as legacyConfigRules } from "./.setup/doctor-contract-DybEjJcd.mjs";
1
+ import { t as runtime_doctor_migrations_exports } from "./.setup/runtime-doctor-migrations-CSvRANPN.mjs";
2
2
  import { i as normalizeMatrixStoredCredentials, n as isMatrixCredentialRevocation, r as matrixCredentialsStoreKey, t as MATRIX_CREDENTIALS_NAMESPACE } from "./.setup/credentials-state-jxq29yQw.mjs";
3
3
  import { i as resolveMatrixCredentialsDir } from "./.setup/storage-paths-e_Vq6cvw.mjs";
4
+ import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./.setup/doctor-contract-GiXgCj7k.mjs";
4
5
  import { a as describeRetiredMatrixState, o as resolveMatrixSqliteStateEnv, t as RETIRED_MATRIX_STATE_FILENAMES } from "./.setup/retired-state-vIr2IB90.mjs";
5
6
  import { t as walkMatrixStateFiles } from "./.setup/state-layout-walk-BqCZTHpp.mjs";
6
- import { i as readLegacyMatrixSyncCacheState, n as hasMatrixSyncCacheStateInStore, r as openMatrixSyncCacheStoreOptions, s as writeMatrixSyncCacheStateToStore } from "./.setup/sync-cache-state-qYrd2EEh.mjs";
7
+ import { i as readLegacyMatrixSyncCacheState, n as hasMatrixSyncCacheStateInStore, r as openMatrixSyncCacheStoreOptions, s as writeMatrixSyncCacheStateToStore } from "./.setup/sync-cache-state-B-FayxeA.mjs";
7
8
  import { normalizeAccountId } from "openclaw/plugin-sdk/account-id";
8
9
  import { isRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
9
10
  import { createHash } from "node:crypto";
@@ -295,7 +296,7 @@ async function collectLegacyMatrixCredentialSources(params) {
295
296
  return left.name.localeCompare(right.name);
296
297
  });
297
298
  if (files.length === 0) return [];
298
- const { requiresExplicitMatrixDefaultAccount, resolveMatrixDefaultOrOnlyAccountId } = await import("./.setup/account-selection-Co94mKNj.mjs").then((n) => n.t);
299
+ const { requiresExplicitMatrixDefaultAccount, resolveMatrixDefaultOrOnlyAccountId } = await import("./.setup/account-selection-BPFpdMIw.mjs").then((n) => n.t);
299
300
  return files.map((entry) => {
300
301
  const namedAccount = /^credentials(?:-([a-z0-9._-]+))?\.json$/iu.exec(entry.name)?.[1];
301
302
  return {
@@ -307,23 +308,36 @@ async function collectLegacyMatrixCredentialSources(params) {
307
308
  async function readLegacyMatrixCredentials(source) {
308
309
  if (!source.accountId) return null;
309
310
  try {
310
- const raw = JSON.parse(await fs.readFile(source.filePath, "utf8"));
311
+ const raw = JSON.parse((0, runtime_doctor_migrations_exports.decodeUtf8Input)(await fs.readFile(source.filePath), "Legacy Matrix credentials"));
311
312
  const createdAt = isRecord(raw) && typeof raw.createdAt === "string" && raw.createdAt ? raw.createdAt : (await fs.stat(source.filePath)).mtime.toISOString();
312
313
  return normalizeMatrixStoredCredentials(isRecord(raw) ? {
313
314
  ...raw,
314
315
  createdAt
315
316
  } : raw, source.accountId);
316
- } catch {
317
+ } catch (error) {
318
+ if (error instanceof runtime_doctor_migrations_exports.Utf8InputError) throw error;
317
319
  return null;
318
320
  }
319
321
  }
320
322
  async function* readLegacyMatrixSyncCacheSources(stateDir) {
321
323
  const { entries } = await walkMatrixStateFiles(stateDir, (name, depth) => name === MATRIX_SYNC_CACHE_FILENAME && (depth === 2 || depth === 4));
322
324
  for (const storageRootDir of entries.map((entry) => path.dirname(entry.path)).toSorted()) {
323
- const payload = await readLegacyMatrixSyncCacheState(storageRootDir);
325
+ let payload;
326
+ try {
327
+ payload = await readLegacyMatrixSyncCacheState(storageRootDir);
328
+ } catch (error) {
329
+ if (!(error instanceof runtime_doctor_migrations_exports.Utf8InputError)) throw error;
330
+ yield {
331
+ storageRootDir,
332
+ payload: null,
333
+ error
334
+ };
335
+ continue;
336
+ }
324
337
  if (payload) yield {
325
338
  storageRootDir,
326
- payload
339
+ payload,
340
+ error: void 0
327
341
  };
328
342
  }
329
343
  }
@@ -332,12 +346,12 @@ const stateMigrations = [
332
346
  id: "matrix-crypto-unsafe-state",
333
347
  label: "Matrix crypto unsafe final state",
334
348
  async detectLegacyState(params) {
335
- const { listMatrixCryptoUnsafeState } = await import("./.setup/crypto-unsafe-state-doctor-Brv4bIyx.mjs").then((n) => n.t);
349
+ const { listMatrixCryptoUnsafeState } = await import("./.setup/crypto-unsafe-state-doctor-ClzRgr8z.mjs").then((n) => n.t);
336
350
  const roots = await listMatrixCryptoUnsafeState(params.stateDir, { openKeyedStoreV2: params.context.openPluginStateKeyedStore });
337
351
  return roots.length > 0 ? { preview: roots.map((root) => `Matrix crypto store is blocked after unsafe final save: ${root}. Run openclaw matrix doctor inspect; recovery is never automatic.`) } : null;
338
352
  },
339
353
  async migrateLegacyState(params) {
340
- const { listMatrixCryptoUnsafeState } = await import("./.setup/crypto-unsafe-state-doctor-Brv4bIyx.mjs").then((n) => n.t);
354
+ const { listMatrixCryptoUnsafeState } = await import("./.setup/crypto-unsafe-state-doctor-ClzRgr8z.mjs").then((n) => n.t);
341
355
  return {
342
356
  changes: [],
343
357
  warnings: (await listMatrixCryptoUnsafeState(params.stateDir, { openKeyedStoreV2: params.context.openPluginStateKeyedStore })).map((root) => `Matrix crypto store remains blocked: ${root}. Inspect with openclaw matrix doctor inspect; explicit recovery may roll back keys.`)
@@ -356,6 +370,7 @@ const stateMigrations = [
356
370
  const changes = [];
357
371
  const warnings = [];
358
372
  const sources = await collectLegacyMatrixCredentialSources(params);
373
+ let utf8Warnings = 0;
359
374
  const store = params.context.openPluginStateKeyedStore({
360
375
  namespace: MATRIX_CREDENTIALS_NAMESPACE,
361
376
  maxEntries: 256,
@@ -366,7 +381,15 @@ const stateMigrations = [
366
381
  warnings.push(`Left ambiguous Matrix credential legacy source in place because no default account is selected: ${source.filePath}`);
367
382
  continue;
368
383
  }
369
- const credentials = await readLegacyMatrixCredentials(source);
384
+ let credentials;
385
+ try {
386
+ credentials = await readLegacyMatrixCredentials(source);
387
+ } catch (error) {
388
+ if (!(error instanceof runtime_doctor_migrations_exports.Utf8InputError)) throw error;
389
+ warnings.push(`${error.message} Left legacy source in place: ${source.filePath}`);
390
+ utf8Warnings++;
391
+ continue;
392
+ }
370
393
  if (!credentials) {
371
394
  warnings.push(`Left invalid Matrix credential legacy source in place: ${source.filePath}`);
372
395
  continue;
@@ -406,7 +429,8 @@ const stateMigrations = [
406
429
  }
407
430
  return {
408
431
  changes,
409
- warnings
432
+ warnings,
433
+ ...utf8Warnings > 0 && utf8Warnings === warnings.length ? { warningDisposition: "recoverable" } : {}
410
434
  };
411
435
  }
412
436
  },
@@ -508,7 +532,13 @@ const stateMigrations = [
508
532
  const changes = [];
509
533
  const warnings = [];
510
534
  const notices = [];
535
+ let utf8Warnings = 0;
511
536
  for await (const source of readLegacyMatrixSyncCacheSources(params.stateDir)) {
537
+ if (source.error) {
538
+ warnings.push(`${source.error.message} Left legacy source in place: ${source.storageRootDir}`);
539
+ utf8Warnings++;
540
+ continue;
541
+ }
512
542
  const store = params.context.openPluginStateKeyedStore(openMatrixSyncCacheStoreOptions(source.storageRootDir));
513
543
  const existing = await hasMatrixSyncCacheStateInStore({
514
544
  ...source,
@@ -533,7 +563,8 @@ const stateMigrations = [
533
563
  return {
534
564
  changes,
535
565
  warnings,
536
- ...notices.length > 0 ? { notices } : {}
566
+ ...notices.length > 0 ? { notices } : {},
567
+ ...utf8Warnings > 0 && utf8Warnings === warnings.length ? { warningDisposition: "recoverable" } : {}
537
568
  };
538
569
  }
539
570
  }
@@ -1,4 +1,4 @@
1
- import { a as resolveConfiguredMatrixAccountIds, i as requiresExplicitMatrixDefaultAccount, n as findMatrixAccountEntry, o as resolveMatrixChannelConfig, r as hasImplicitMatrixAccountConfig, s as resolveMatrixDefaultOrOnlyAccountId } from "./.setup/account-selection-Co94mKNj.mjs";
1
+ import { a as resolveConfiguredMatrixAccountIds, i as requiresExplicitMatrixDefaultAccount, n as findMatrixAccountEntry, o as resolveMatrixChannelConfig, r as hasImplicitMatrixAccountConfig, s as resolveMatrixDefaultOrOnlyAccountId } from "./.setup/account-selection-BPFpdMIw.mjs";
2
2
  import { n as listMatrixEnvAccountIds, r as resolveMatrixEnvAccountToken, t as getMatrixScopedEnvVarNames } from "./.setup/env-vars-Bh1iOXJ1.mjs";
3
3
  import { a as resolveMatrixCredentialsFilename, c as resolveMatrixStateLayoutChildDepth, i as resolveMatrixCredentialsDir, l as sanitizeMatrixPathSegment, n as isMatrixActiveTokenRootDirectory, o as resolveMatrixCredentialsPath, r as resolveMatrixAccountStorageRoot, s as resolveMatrixHomeserverKey, t as hashMatrixAccessToken } from "./.setup/storage-paths-e_Vq6cvw.mjs";
4
4
  export { findMatrixAccountEntry, getMatrixScopedEnvVarNames, hasImplicitMatrixAccountConfig, hashMatrixAccessToken, isMatrixActiveTokenRootDirectory, listMatrixEnvAccountIds, requiresExplicitMatrixDefaultAccount, resolveConfiguredMatrixAccountIds, resolveMatrixAccountStorageRoot, resolveMatrixChannelConfig, resolveMatrixCredentialsDir, resolveMatrixCredentialsFilename, resolveMatrixCredentialsPath, resolveMatrixDefaultOrOnlyAccountId, resolveMatrixEnvAccountToken, resolveMatrixHomeserverKey, resolveMatrixStateLayoutChildDepth, sanitizeMatrixPathSegment };
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { n as registerMatrixCliMetadata } from "./.setup/cli-metadata-rWmD_rzx.mjs";
1
+ import { n as registerMatrixCliMetadata } from "./.setup/cli-metadata-DemZndyG.mjs";
2
2
  import { a as setMatrixRuntimeLifecycle } from "./.setup/runtime-Ck8TjD7L.mjs";
3
3
  import "./runtime-setter-api.js";
4
4
  import { registerMatrixSubagentHooks } from "./subagent-hooks-api.js";
@@ -1,9 +1,9 @@
1
- import { d as resolveMatrixAuthContext } from "./.setup/client-7eyTX0cu.mjs";
1
+ import { d as resolveMatrixAuthContext } from "./.setup/client-BIsYqIzM.mjs";
2
2
  import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
3
3
  import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
4
4
  import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
5
5
  // extensions/matrix/src/plugin-entry.runtime.ts
6
- const loadMatrixVerificationRuntime = createLazyRuntimeModule(() => import("./.setup/verification-jP3tm-xD.mjs").then((n) => n.y));
6
+ const loadMatrixVerificationRuntime = createLazyRuntimeModule(() => import("./.setup/verification-BqjyjLoq.mjs").then((n) => n.y));
7
7
  function sendError(respond, err) {
8
8
  respond(false, { error: formatErrorMessage(err) });
9
9
  }
@@ -1,5 +1,5 @@
1
1
  import { i as setMatrixRuntime } from "./.setup/runtime-Ck8TjD7L.mjs";
2
- import { a as resolveConfiguredMatrixAccountIds, f as resolveMatrixAccountStringValues, i as requiresExplicitMatrixDefaultAccount, n as findMatrixAccountEntry, o as resolveMatrixChannelConfig, s as resolveMatrixDefaultOrOnlyAccountId } from "./.setup/account-selection-Co94mKNj.mjs";
2
+ import { a as resolveConfiguredMatrixAccountIds, f as resolveMatrixAccountStringValues, i as requiresExplicitMatrixDefaultAccount, n as findMatrixAccountEntry, o as resolveMatrixChannelConfig, s as resolveMatrixDefaultOrOnlyAccountId } from "./.setup/account-selection-BPFpdMIw.mjs";
3
3
  import { n as listMatrixEnvAccountIds, r as resolveMatrixEnvAccountToken, t as getMatrixScopedEnvVarNames } from "./.setup/env-vars-Bh1iOXJ1.mjs";
4
4
  import { a as resolveMatrixCredentialsFilename, i as resolveMatrixCredentialsDir, l as sanitizeMatrixPathSegment, o as resolveMatrixCredentialsPath, r as resolveMatrixAccountStorageRoot, s as resolveMatrixHomeserverKey, t as hashMatrixAccessToken } from "./.setup/storage-paths-e_Vq6cvw.mjs";
5
5
  import { f as setMatrixThreadBindingMaxAgeBySessionKey, l as setMatrixThreadBindingIdleTimeoutBySessionKey, p as setMatrixThreadBindingMaxAgeBySessionKeyAsync, u as setMatrixThreadBindingIdleTimeoutBySessionKeyAsync } from "./.setup/thread-bindings-shared-FMu_szTm.mjs";
@@ -1,3 +1,3 @@
1
1
  import { i as setMatrixRuntime } from "./.setup/runtime-Ck8TjD7L.mjs";
2
- import { t as createMatrixThreadBindingManager } from "./.setup/thread-bindings-D2ZR6mEZ.mjs";
2
+ import { t as createMatrixThreadBindingManager } from "./.setup/thread-bindings-CB-jqrf4.mjs";
3
3
  export { createMatrixThreadBindingManager, setMatrixRuntime };
@@ -4,7 +4,7 @@ import { fileURLToPath } from "node:url";
4
4
  var setup_entry_default = defineBundledChannelSetupEntry({
5
5
  importMetaUrl: import.meta.url,
6
6
  plugin: {
7
- specifier: fileURLToPath(new URL(".setup/setup-plugin-api-SO1hdrsT.mjs", import.meta.url).href),
7
+ specifier: fileURLToPath(new URL(".setup/setup-plugin-api-BZPY4Dt2.mjs", import.meta.url).href),
8
8
  exportName: "matrixSetupPlugin"
9
9
  },
10
10
  secrets: {
@@ -1 +1 @@
1
- export { n as matrixSetupPlugin } from "./.setup/channel.setup-IjRB0ymg.mjs";
1
+ export { n as matrixSetupPlugin } from "./.setup/channel.setup-Dp7V9AgV.mjs";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/matrix",
3
- "version": "2026.10.10",
3
+ "version": "2026.11.1",
4
4
  "description": "OpenClaw Matrix channel plugin for rooms and direct messages.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -19,7 +19,7 @@
19
19
  "zod": "4.6.5"
20
20
  },
21
21
  "peerDependencies": {
22
- "openclaw": ">=2026.10.10"
22
+ "openclaw": ">=2026.11.1"
23
23
  },
24
24
  "peerDependenciesMeta": {
25
25
  "openclaw": {
@@ -170,11 +170,11 @@
170
170
  "allowInvalidConfigRecovery": true
171
171
  },
172
172
  "compat": {
173
- "pluginApi": ">=2026.10.10"
173
+ "pluginApi": ">=2026.11.1"
174
174
  },
175
175
  "build": {
176
176
  "bundledDist": false,
177
- "openclawVersion": "2026.10.10"
177
+ "openclawVersion": "2026.11.1"
178
178
  },
179
179
  "release": {
180
180
  "publishToClawHub": true,
@@ -1,2 +0,0 @@
1
- export { n as matrixSetupPlugin } from "./channel.setup-IjRB0ymg.mjs";
2
- import "../setup-plugin-api.js";