@camstack/addon-provider-onvif 1.2.128 → 1.2.130

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 (3) hide show
  1. package/dist/addon.js +1276 -61
  2. package/dist/addon.mjs +1276 -61
  3. package/package.json +1 -1
package/dist/addon.mjs CHANGED
@@ -3,7 +3,7 @@ import { createRequire } from "node:module";
3
3
  var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
4
4
  var __require = /* @__PURE__ */ createRequire(import.meta.url);
5
5
  //#endregion
6
- //#region ../types/dist/event-category-C4hVnRo8.mjs
6
+ //#region ../types/dist/event-category-BvOFi6PY.mjs
7
7
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
8
8
  EventCategory["SystemBoot"] = "system.boot";
9
9
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -67,6 +67,24 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
67
67
  * consumes this category and maps it to the `addon-crash-loop` kind.
68
68
  */
69
69
  EventCategory["AddonRunnerFailed"] = "addon.runner-failed";
70
+ /**
71
+ * A runner whose addon refused to start with a typed reason (D877) - parked
72
+ * in `refused`, never counted by the crash breaker, retried on operator
73
+ * action. One event per refusal.
74
+ */
75
+ EventCategory["AddonRunnerRefused"] = "addon.runner-refused";
76
+ /**
77
+ * A runner settled on a state (D877): `running` (READY), `crashed`, `failed` or
78
+ * `refused`. In-process telemetry for the boot check (re-evaluate while any
79
+ * runner is still pending) and the alert centre (close a recovered runner).
80
+ */
81
+ EventCategory["ProcessStateChanged"] = "process.state-changed";
82
+ /**
83
+ * The node's one-shot runner boot check (D877): planned runners against the
84
+ * process service, `degraded` when any is failed, refused or missing. The
85
+ * alert centre turns it into one alert and a direct critical push.
86
+ */
87
+ EventCategory["SystemRunnerCheck"] = "system.runner-check";
70
88
  EventCategory["AddonError"] = "addon.error";
71
89
  EventCategory["AddonPageReady"] = "addon.page-ready";
72
90
  EventCategory["AddonWidgetReady"] = "addon.widget-ready";
@@ -5391,7 +5409,7 @@ var ZodIssueCode = {
5391
5409
  var ZodFirstPartyTypeKind;
5392
5410
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5393
5411
  //#endregion
5394
- //#region ../types/dist/sleep-DRqxtc0C.mjs
5412
+ //#region ../types/dist/sleep-BegKjwUu.mjs
5395
5413
  /**
5396
5414
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5397
5415
  * window to float samples (D455).
@@ -5508,7 +5526,7 @@ function isKeychainStoredField(field) {
5508
5526
  var SECRET_CLEAR = { $secretClear: true };
5509
5527
  /** The `'***'` token D634 redaction writes for non-admins. */
5510
5528
  var LEGACY_DEVICE_REDACTION = "***";
5511
- function isRecord$2(value) {
5529
+ function isRecord$5(value) {
5512
5530
  return typeof value === "object" && value !== null && !Array.isArray(value);
5513
5531
  }
5514
5532
  function makeSecretMarker(ref) {
@@ -5519,12 +5537,12 @@ function makeSecretMarker(ref) {
5519
5537
  }
5520
5538
  /** A stored marker: an object whose `$secret` is a non-empty string. */
5521
5539
  function isSecretMarker(value) {
5522
- if (!isRecord$2(value)) return false;
5540
+ if (!isRecord$5(value)) return false;
5523
5541
  const ref = value["$secret"];
5524
5542
  return typeof ref === "string" && ref.length > 0;
5525
5543
  }
5526
5544
  function isSecretClear(value) {
5527
- return isRecord$2(value) && value["$secretClear"] === true;
5545
+ return isRecord$5(value) && value["$secretClear"] === true;
5528
5546
  }
5529
5547
  /**
5530
5548
  * The UI view of a stored secret field value: a marker becomes "set", inline
@@ -6134,7 +6152,7 @@ var KeychainWriteRefusedError = class extends Error {
6134
6152
  }
6135
6153
  };
6136
6154
  var KEEP = { kind: "keep" };
6137
- function isRecord$1(value) {
6155
+ function isRecord$4(value) {
6138
6156
  return typeof value === "object" && value !== null && !Array.isArray(value);
6139
6157
  }
6140
6158
  function defaultMintId() {
@@ -6147,7 +6165,7 @@ function collectSecretMarkerRefs(value, out = []) {
6147
6165
  return out;
6148
6166
  }
6149
6167
  if (Array.isArray(value)) for (const item of value) collectSecretMarkerRefs(item, out);
6150
- else if (isRecord$1(value)) for (const child of Object.values(value)) collectSecretMarkerRefs(child, out);
6168
+ else if (isRecord$4(value)) for (const child of Object.values(value)) collectSecretMarkerRefs(child, out);
6151
6169
  return out;
6152
6170
  }
6153
6171
  async function storedValueEquals(secrets, marker, candidate) {
@@ -6202,7 +6220,7 @@ function rowId(row, idKey) {
6202
6220
  return null;
6203
6221
  }
6204
6222
  async function writeArray(ctx, node, incoming, stored, fieldPath) {
6205
- const storedRows = Array.isArray(stored) ? stored.filter(isRecord$1) : [];
6223
+ const storedRows = Array.isArray(stored) ? stored.filter(isRecord$4) : [];
6206
6224
  if (!Array.isArray(incoming)) {
6207
6225
  ctx.deletes.push(...collectSecretMarkerRefs(storedRows));
6208
6226
  return {
@@ -6218,7 +6236,7 @@ async function writeArray(ctx, node, incoming, stored, fieldPath) {
6218
6236
  const kept = /* @__PURE__ */ new Set();
6219
6237
  const rows = [];
6220
6238
  for (const row of incoming) {
6221
- if (!isRecord$1(row)) {
6239
+ if (!isRecord$4(row)) {
6222
6240
  rows.push(row);
6223
6241
  continue;
6224
6242
  }
@@ -6243,7 +6261,7 @@ async function writeNode(ctx, node, incoming, stored, fieldPath) {
6243
6261
  case "leaf": return writeLeaf(ctx, incoming, stored, fieldPath);
6244
6262
  case "array": return writeArray(ctx, node, incoming, stored, fieldPath);
6245
6263
  case "object": {
6246
- if (!isRecord$1(incoming)) {
6264
+ if (!isRecord$4(incoming)) {
6247
6265
  if (incoming === void 0) return KEEP;
6248
6266
  ctx.deletes.push(...collectSecretMarkerRefs(stored));
6249
6267
  return {
@@ -6251,7 +6269,7 @@ async function writeNode(ctx, node, incoming, stored, fieldPath) {
6251
6269
  value: incoming
6252
6270
  };
6253
6271
  }
6254
- const storedObj = isRecord$1(stored) ? stored : {};
6272
+ const storedObj = isRecord$4(stored) ? stored : {};
6255
6273
  return {
6256
6274
  kind: "value",
6257
6275
  value: await writeMembers(ctx, node.children, incoming, storedObj, (m) => `${fieldPath}.${m}`)
@@ -6374,7 +6392,7 @@ async function resolveSecretMarkers(value, secrets, options = {}) {
6374
6392
  value: items
6375
6393
  };
6376
6394
  }
6377
- if (isRecord$1(v)) {
6395
+ if (isRecord$4(v)) {
6378
6396
  const out = {};
6379
6397
  for (const [k, child] of Object.entries(v)) {
6380
6398
  const s = substitute(child);
@@ -6406,7 +6424,7 @@ var SecretOverwriteRefusedError = class extends Error {
6406
6424
  this.name = "SecretOverwriteRefusedError";
6407
6425
  }
6408
6426
  };
6409
- function isRecord(value) {
6427
+ function isRecord$3(value) {
6410
6428
  return typeof value === "object" && value !== null && !Array.isArray(value);
6411
6429
  }
6412
6430
  function resolvedValue(pass, marker) {
@@ -6435,7 +6453,7 @@ function inArray(pass, incoming, stored) {
6435
6453
  return incoming.map((item, index) => {
6436
6454
  const twin = stored[index];
6437
6455
  if (isSecretMarker(twin)) return typeof item === "string" && item === resolvedValue(pass, twin) ? twin : item;
6438
- if (isRecord(item) && isRecord(twin)) return inArrayRow(pass, item, twin);
6456
+ if (isRecord$3(item) && isRecord$3(twin)) return inArrayRow(pass, item, twin);
6439
6457
  if (Array.isArray(item) && Array.isArray(twin)) return inArray(pass, item, twin);
6440
6458
  return item;
6441
6459
  });
@@ -6446,7 +6464,7 @@ function inArrayRow(pass, incoming, stored) {
6446
6464
  const twin = stored[key];
6447
6465
  if (isSecretMarker(twin)) {
6448
6466
  if (typeof value === "string" && value === resolvedValue(pass, twin)) out[key] = twin;
6449
- } else if (isRecord(value) && isRecord(twin)) out[key] = inArrayRow(pass, value, twin);
6467
+ } else if (isRecord$3(value) && isRecord$3(twin)) out[key] = inArrayRow(pass, value, twin);
6450
6468
  else if (Array.isArray(value) && Array.isArray(twin)) out[key] = inArray(pass, value, twin);
6451
6469
  }
6452
6470
  return out;
@@ -6454,7 +6472,7 @@ function inArrayRow(pass, incoming, stored) {
6454
6472
  async function walk(pass, incoming, stored) {
6455
6473
  if (isSecretMarker(stored)) return atMarker(pass, incoming, stored);
6456
6474
  if (Array.isArray(incoming) && Array.isArray(stored)) return inArray(pass, incoming, stored);
6457
- if (!isRecord(incoming) || !isRecord(stored)) return incoming;
6475
+ if (!isRecord$3(incoming) || !isRecord$3(stored)) return incoming;
6458
6476
  const out = { ...incoming };
6459
6477
  for (const [key, value] of Object.entries(incoming)) out[key] = await walk(pass, value, stored[key]);
6460
6478
  return out;
@@ -6485,7 +6503,7 @@ async function restoreUnchangedSecrets(input) {
6485
6503
  function isJsonEqual(a, b) {
6486
6504
  if (Object.is(a, b)) return true;
6487
6505
  if (Array.isArray(a)) return Array.isArray(b) && a.length === b.length && a.every((v, i) => isJsonEqual(v, b[i]));
6488
- if (isRecord(a) && isRecord(b)) {
6506
+ if (isRecord$3(a) && isRecord$3(b)) {
6489
6507
  const keys = Object.keys(a);
6490
6508
  if (keys.length !== Object.keys(b).length) return false;
6491
6509
  return keys.every((k) => Object.prototype.hasOwnProperty.call(b, k) && isJsonEqual(a[k], b[k]));
@@ -6509,7 +6527,7 @@ function markerKeysOf(blob, owner) {
6509
6527
  }
6510
6528
  function nodeFromStored(value, owner) {
6511
6529
  if (isSecretMarker(value)) return isSecretRefOwnedBy(value.$secret, owner) ? { kind: "leaf" } : null;
6512
- if (!isRecord(value)) return null;
6530
+ if (!isRecord$3(value)) return null;
6513
6531
  const children = /* @__PURE__ */ new Map();
6514
6532
  for (const [key, child] of Object.entries(value)) {
6515
6533
  const node = nodeFromStored(child, owner);
@@ -6642,7 +6660,6 @@ function createHandle(raw, opts) {
6642
6660
  const writeAddon = (patch) => write("addon", opts.addonTree(), void 0, patch, () => readStoredAddonBlob(raw), (p) => raw.writeAddonStore(p));
6643
6661
  const readAddonStoreResult = raw.readAddonStoreResult;
6644
6662
  const readAddonStoreKeyResult = raw.readAddonStoreKeyResult;
6645
- const readDeviceStoreBatch = raw.readDeviceStoreBatch;
6646
6663
  const overrides = {
6647
6664
  readAddonStore: async () => resolveRead("addon", await raw.readAddonStore()),
6648
6665
  ...readAddonStoreResult !== void 0 ? { readAddonStoreResult: async () => {
@@ -6666,12 +6683,12 @@ function createHandle(raw, opts) {
6666
6683
  };
6667
6684
  } } : {},
6668
6685
  readDeviceStore: async (deviceId) => resolveRead(`device:${deviceId}`, await raw.readDeviceStore(deviceId)),
6669
- ...readDeviceStoreBatch !== void 0 ? { readDeviceStoreBatch: async (deviceIds) => {
6670
- const rows = await readDeviceStoreBatch.call(raw, deviceIds);
6686
+ readDeviceStoreBatch: async (deviceIds) => {
6687
+ const rows = await raw.readDeviceStoreBatch(deviceIds);
6671
6688
  const out = /* @__PURE__ */ new Map();
6672
6689
  for (const [deviceId, blob] of rows) out.set(deviceId, await resolveRead(`device:${deviceId}`, blob));
6673
6690
  return out;
6674
- } } : {},
6691
+ },
6675
6692
  writeAddonStore: async (patch) => {
6676
6693
  await writeAddon(patch);
6677
6694
  },
@@ -7298,7 +7315,7 @@ var BaseAddon = class {
7298
7315
  if (!ctx) return;
7299
7316
  const addonId = ctx.id;
7300
7317
  setImmediate(() => {
7301
- ctx.api.addons?.restartAddon?.mutate({ addonId }).then(() => {
7318
+ ctx.api.addons.restartAddon.mutate({ addonId }).then(() => {
7302
7319
  ctx.logger.info("addon auto-restart triggered by restart-required setting change", { meta: { changedFields: patchKeys.filter((k) => restartKeys.has(k)) } });
7303
7320
  }).catch((err) => {
7304
7321
  ctx.logger.error("addon auto-restart failed", { meta: { error: err instanceof Error ? err.message : String(err) } });
@@ -7498,7 +7515,7 @@ var BaseAddon = class {
7498
7515
  return this._addonSecretTree;
7499
7516
  }
7500
7517
  deviceSecretTree() {
7501
- this._deviceSecretTree ??= secretTreeFromSchema(this.deviceSettingsSchema());
7518
+ this._deviceSecretTree ??= mergeSecretStatePaths(secretTreeFromSchema(this.deviceSettingsSchema()), this.secretStatePaths);
7502
7519
  return this._deviceSecretTree;
7503
7520
  }
7504
7521
  /**
@@ -7574,42 +7591,135 @@ var BaseAddon = class {
7574
7591
  this[timerOf] = timer;
7575
7592
  }
7576
7593
  /**
7577
- * Wrap `ctx.settings.readAddonStore()` with a short retry budget so a
7578
- * transient settings-store outage (mid-restart of sqlite-settings, tsx-watch
7579
- * swap, or any race where the SqliteSettingsBackend is between shutdown and
7580
- * re-initialize) doesn't propagate up into `initialize()` and leave the
7594
+ * Wrap `ctx.settings.readAddonStore()` with a retry budget so a transient
7595
+ * settings-store outage doesn't propagate up into `initialize()` and leave the
7581
7596
  * addon permanently broken.
7582
7597
  *
7583
- * Retry only the two known infra fingerprints. Anything else propagates so
7584
- * real bugs surface immediately. After the budget expires we fall back to
7585
- * `{}` (defaults) — the addon's first successful patch will rehydrate.
7598
+ * Two kinds of outage, two budgets:
7599
+ * - the store's own restart fingerprints (`SqliteSettingsBackend not
7600
+ * initialized`, `provider not available`): a short budget, then the addon
7601
+ * falls back to `{}` (defaults) - its first successful patch rehydrates;
7602
+ * - a TRANSPORT failure (the hub is restarting while this runner boots:
7603
+ * `discovery deadline exceeded`, `parent could not route`, a refused or
7604
+ * timed-out connection). Since D870 a runner's settings read THROWS instead
7605
+ * of answering `{}`, so without a budget a hub restart ends in a respawn
7606
+ * loop. A long, bounded budget; only after it the error propagates - the
7607
+ * addon never runs on defaults for a store it could not ask.
7608
+ * Anything else propagates immediately so real bugs surface.
7586
7609
  */
7587
7610
  async readAddonStoreWithRetry() {
7588
7611
  const settings = this.rawSettings();
7589
7612
  if (!settings) return {};
7590
- const delaysMs = [
7591
- 150,
7592
- 350,
7593
- 600,
7594
- 900
7595
- ];
7596
7613
  let lastErr;
7597
- for (let attempt = 0; attempt <= delaysMs.length; attempt++) try {
7614
+ for (let attempt = 0;; attempt++) try {
7598
7615
  const stored = await settings.readAddonStore() ?? {};
7599
7616
  this.settingsStoreReady = true;
7600
7617
  return stored;
7601
7618
  } catch (err) {
7602
7619
  lastErr = err;
7603
- const msg = err instanceof Error ? err.message : String(err);
7604
- if (!(msg.includes("SqliteSettingsBackend not initialized") || msg.includes("provider not available"))) throw err;
7605
- if (attempt === delaysMs.length) break;
7606
- await new Promise((r) => setTimeout(r, delaysMs[attempt]));
7620
+ const kind = classifyStoreError(err);
7621
+ if (kind === "permanent") throw err;
7622
+ const delay = (kind === "transport" ? TRANSPORT_RETRY_DELAYS_MS : RESTART_RETRY_DELAYS_MS)[attempt];
7623
+ if (delay === void 0) {
7624
+ if (kind === "transport") throw err;
7625
+ break;
7626
+ }
7627
+ await new Promise((r) => setTimeout(r, delay));
7607
7628
  }
7608
7629
  this.settingsStoreReady = false;
7609
7630
  this._ctx?.logger?.warn?.("readAddonStore: settings-store unavailable after retries — using defaults", { meta: { error: lastErr instanceof Error ? lastErr.message : String(lastErr) } });
7610
7631
  return {};
7611
7632
  }
7612
7633
  };
7634
+ /** The settings store's own restart fingerprints. */
7635
+ var RESTART_RETRY_DELAYS_MS = [
7636
+ 150,
7637
+ 350,
7638
+ 600,
7639
+ 900
7640
+ ];
7641
+ /** A hub restarting under a booting runner: ~100 s in total. */
7642
+ var TRANSPORT_RETRY_DELAYS_MS = [
7643
+ 150,
7644
+ 350,
7645
+ 600,
7646
+ 900,
7647
+ 2e3,
7648
+ 5e3,
7649
+ 1e4,
7650
+ 2e4,
7651
+ 3e4,
7652
+ 3e4
7653
+ ];
7654
+ var RESTART_FINGERPRINTS = ["SqliteSettingsBackend not initialized", "provider not available"];
7655
+ /** Node / socket error codes of a connection that did not happen or broke. */
7656
+ var TRANSPORT_CODES = new Set([
7657
+ "ECONNREFUSED",
7658
+ "ECONNRESET",
7659
+ "ETIMEDOUT",
7660
+ "EPIPE",
7661
+ "EHOSTUNREACH",
7662
+ "ENETUNREACH"
7663
+ ]);
7664
+ /** tRPC error codes that mean "the other side is not answering now", not "your call is wrong". */
7665
+ var UNAVAILABLE_TRPC_CODES = new Set([
7666
+ "TIMEOUT",
7667
+ "SERVICE_UNAVAILABLE",
7668
+ "BAD_GATEWAY",
7669
+ "GATEWAY_TIMEOUT"
7670
+ ]);
7671
+ /** The exact phrases OUR transport raises when it cannot reach the hub. */
7672
+ var TRANSPORT_PHRASES = [
7673
+ "discovery deadline exceeded",
7674
+ "parent could not route child unowned cap call",
7675
+ "UDS request timed out after",
7676
+ "channel closed"
7677
+ ];
7678
+ /** Moleculer error `type`s of a call that could not be served right now. */
7679
+ var MOLECULER_TRANSIENT_TYPES = new Set([
7680
+ "REQUEST_TIMEOUT",
7681
+ "SERVICE_NOT_FOUND",
7682
+ "SERVICE_NOT_AVAILABLE",
7683
+ "REQUEST_REJECTED",
7684
+ "BROKER_DISCONNECTED"
7685
+ ]);
7686
+ function stringProp(value, key) {
7687
+ if (typeof value !== "object" || value === null) return void 0;
7688
+ const found = Reflect.get(value, key);
7689
+ return typeof found === "string" ? found : void 0;
7690
+ }
7691
+ /** The code an error carries: its own, its cause's, or a tRPC `data.code`. */
7692
+ function errorCode(err) {
7693
+ const out = {};
7694
+ const cause = typeof err === "object" && err !== null ? Reflect.get(err, "cause") : void 0;
7695
+ const data = typeof err === "object" && err !== null ? Reflect.get(err, "data") : void 0;
7696
+ const node = stringProp(err, "code") ?? stringProp(cause, "code");
7697
+ if (node !== void 0) out.node = node;
7698
+ const trpc = stringProp(data, "code");
7699
+ if (trpc !== void 0) out.trpc = trpc;
7700
+ return out;
7701
+ }
7702
+ /**
7703
+ * Is a settings read failure worth retrying, and with which budget? Only
7704
+ * EXPLICIT signals count: a socket error code, a tRPC "unavailable" code, or
7705
+ * one of the exact phrases our own transport raises. A message that merely
7706
+ * contains "timed out" or "unreachable" is not evidence of anything, and
7707
+ * `settings store not wired` is a wiring bug that retrying cannot fix.
7708
+ */
7709
+ function classifyStoreError(err) {
7710
+ const message = err instanceof Error ? err.message : String(err);
7711
+ if (RESTART_FINGERPRINTS.some((f) => message.includes(f))) return "restart";
7712
+ const code = errorCode(err);
7713
+ if (code.node !== void 0 && TRANSPORT_CODES.has(code.node)) return "transport";
7714
+ if (code.trpc !== void 0 && UNAVAILABLE_TRPC_CODES.has(code.trpc)) return "transport";
7715
+ if (typeof err === "object" && err !== null) {
7716
+ if (Reflect.get(err, "retryable") === true) return "transport";
7717
+ const type = stringProp(err, "type");
7718
+ if (type !== void 0 && MOLECULER_TRANSIENT_TYPES.has(type)) return "transport";
7719
+ }
7720
+ if (TRANSPORT_PHRASES.some((f) => message.includes(f))) return "transport";
7721
+ return "permanent";
7722
+ }
7613
7723
  /**
7614
7724
  * Collect the keys of every field marked `perNode: true`, recursing into
7615
7725
  * layout containers (`group` fields and `sub-tabs` tabs) the same way
@@ -7699,6 +7809,89 @@ var PeerBytesTicketSchema = object({
7699
7809
  */
7700
7810
  declaredBytes: number().int().nonnegative().nullable()
7701
7811
  });
7812
+ /** Limits and names of `ctx.records` (D881). One authority; the engine and the facade read it. */
7813
+ /** The files a kind may live in. `history` is device-history's (D850), never records. */
7814
+ var RECORD_DATABASES = ["settings", "events"];
7815
+ /** The classes of a kind: the `@durable` vocabulary, one authority (replaces the annotation). */
7816
+ var RECORD_CLASSES = [
7817
+ "config",
7818
+ "ledger",
7819
+ "audit",
7820
+ "mirror",
7821
+ "ephemeral"
7822
+ ];
7823
+ var RECORD_DEFAULT_MAX_DATA_BYTES = 64 * 1024;
7824
+ var RECORD_MAX_DATA_BYTES = 1024 * 1024;
7825
+ var RECORD_BATCH_MAX = 1e3;
7826
+ var RECORD_QUERY_MAX = 1e3;
7827
+ /**
7828
+ * Record kinds (D881): the declaration an addon makes of one kind of fact, the
7829
+ * Zod row schema that describes it, and the helper that turns the two into the
7830
+ * JSON the engine stores.
7831
+ *
7832
+ * A kind is declared ONCE, next to the code that owns it, and the engine's
7833
+ * reconciler creates its indexes - nothing creates DDL at runtime from a write.
7834
+ * Everything the generic machinery needs (secret fields, the entry descriptor)
7835
+ * is DERIVED from the Zod schema: `.meta({ secret: true })` marks a credential,
7836
+ * never a field name (D879).
7837
+ */
7838
+ /** A JSON field path: `trackId`, `auth.accessToken`. Charset-restricted: it is rendered into DDL. */
7839
+ var RecordFieldPathSchema = string().regex(/^[A-Za-z_][A-Za-z0-9_]{0,63}(\.[A-Za-z_][A-Za-z0-9_]{0,63}){0,3}$/);
7840
+ var RecordIndexSchema = object({
7841
+ name: string().regex(/^[a-z][a-z0-9_]{0,31}$/),
7842
+ fields: array(RecordFieldPathSchema).min(1).max(4),
7843
+ unique: boolean().optional()
7844
+ }).strict();
7845
+ var RecordRetentionSchema = union([
7846
+ object({
7847
+ ttlMs: number().int().positive(),
7848
+ from: _enum(["at", "write"])
7849
+ }).strict(),
7850
+ object({
7851
+ maxRows: number().int().positive().optional(),
7852
+ maxRowsPerDevice: number().int().positive().optional()
7853
+ }).strict().refine((r) => r.maxRows !== void 0 || r.maxRowsPerDevice !== void 0, { message: "name maxRows, maxRowsPerDevice or both" }),
7854
+ object({
7855
+ owner: string().min(1),
7856
+ reason: string().min(1)
7857
+ }).strict(),
7858
+ object({ none: string().min(1) }).strict()
7859
+ ]);
7860
+ /** The descriptor a generic entries UI reads (D881 "generic entries"). */
7861
+ var EntryDescriptorSchema = object({
7862
+ title: string().min(1),
7863
+ /** The record body field shown as the entry's name. */
7864
+ nameField: string().min(1),
7865
+ /** JSON Schema of the entry body; `secret: true` marks a password field. */
7866
+ fields: record(string(), unknown())
7867
+ }).strict();
7868
+ /** What crosses the wire and sits in the engine's catalog: JSON only, no Zod. */
7869
+ var RecordKindDeclarationSchema = object({
7870
+ database: _enum(RECORD_DATABASES).default("settings"),
7871
+ class: _enum(RECORD_CLASSES),
7872
+ writeTrigger: string().min(1),
7873
+ device: _enum([
7874
+ "required",
7875
+ "optional",
7876
+ "none"
7877
+ ]).default("none"),
7878
+ at: _enum(["required", "none"]).default("none"),
7879
+ indexes: array(RecordIndexSchema).max(8).default([]),
7880
+ retention: RecordRetentionSchema,
7881
+ deviceRemoval: _enum(["delete", "none"]).default("none"),
7882
+ maxDataBytes: number().int().positive().max(RECORD_MAX_DATA_BYTES).default(RECORD_DEFAULT_MAX_DATA_BYTES),
7883
+ /** Derived from the Zod schema; never written by hand. */
7884
+ secretPaths: array(string().min(1)).default([]),
7885
+ /** The id key of each array that carries a secret (`{ headers: 'name' }`). */
7886
+ secretArrayKeys: record(string(), string()).default({}),
7887
+ /** The legacy table this kind adopts from; the boot guard reads it (D853: no migration code). */
7888
+ adoptsFrom: string().min(1).optional(),
7889
+ /** Kinds that must agree through `transact` sit in one file under one family name. */
7890
+ transactFamily: string().min(1).optional(),
7891
+ entry: EntryDescriptorSchema.optional()
7892
+ }).strict();
7893
+ /** The kind names: lower-case, dash separated, short enough for an index name. */
7894
+ var RecordKindNameSchema = string().regex(/^[a-z][a-z0-9-]{0,47}$/);
7702
7895
  /** Shared Zod schemas used across streaming capabilities. */
7703
7896
  var CamProfileSchema = _enum([
7704
7897
  "high",
@@ -8164,7 +8357,7 @@ object({
8164
8357
  params: record(string(), union([string(), number()])).optional()
8165
8358
  });
8166
8359
  //#endregion
8167
- //#region ../types/dist/err-msg-DLerKiVO.mjs
8360
+ //#region ../types/dist/err-msg-BXKzRBwg.mjs
8168
8361
  var DeviceType = /* @__PURE__ */ function(DeviceType) {
8169
8362
  DeviceType["Camera"] = "camera";
8170
8363
  DeviceType["Hub"] = "hub";
@@ -8256,6 +8449,10 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
8256
8449
  * native PetKit (`nodepetkit` `FeederDevice`), reusable by other feeder
8257
8450
  * integrations sharing the same food/desiccant/hopper surface. */
8258
8451
  DeviceType["PetFeeder"] = "pet-feeder";
8452
+ /** Built-in dishwasher — program lifecycle, door / remote-start gates,
8453
+ * salt and rinse-aid levels. Installed with the `dishwasher` cap.
8454
+ * Sources: native Bosch Home Connect, reusable by similar integrations. */
8455
+ DeviceType["Dishwasher"] = "dishwasher";
8259
8456
  return DeviceType;
8260
8457
  }({});
8261
8458
  var DeviceFeature = /* @__PURE__ */ function(DeviceFeature) {
@@ -8433,6 +8630,9 @@ var DeviceRole = /* @__PURE__ */ function(DeviceRole) {
8433
8630
  /** Virtual HA toggle (input_boolean.*) — distinguishable from a
8434
8631
  * real Switch device for UI rendering / export adapters. */
8435
8632
  DeviceRole["BinaryHelper"] = "binary-helper";
8633
+ /** A smart plug: a `switch` whose source says it is an outlet (HA
8634
+ * `device_class: outlet`). The Alexa export shows it as a SMARTPLUG. */
8635
+ DeviceRole["Outlet"] = "outlet";
8436
8636
  /** Generic motion / occupancy / moving event source. Distinct from
8437
8637
  * the camera accessory PirSensor role: that one is a camera child;
8438
8638
  * this is a standalone HA / 3rd-party motion sensor. */
@@ -8510,7 +8710,7 @@ function errMsg(err) {
8510
8710
  return String(err);
8511
8711
  }
8512
8712
  //#endregion
8513
- //#region ../types/dist/composition-EQ9Ok0Ee.mjs
8713
+ //#region ../types/dist/composition-CB6PMT9p.mjs
8514
8714
  /**
8515
8715
  * The ffmpeg build every CamStack node downloads, per platform and arch.
8516
8716
  *
@@ -11714,11 +11914,10 @@ var ClipModelMetaSchema = object({
11714
11914
  /**
11715
11915
  * The `vector-store` index this model's vectors live in. ONE feature space
11716
11916
  * per index: two models share an index only when their vectors are ranked
11717
- * against each other, which for CLIP means never across families. MobileCLIP
11718
- * S1 and S2 share `object-clip` for history (separated by the row's
11719
- * `modelId`); any other model gets its own.
11917
+ * against each other, which for CLIP means never across families. Every
11918
+ * model gets its own.
11720
11919
  */
11721
- vectorIndex: string().regex(/^object-clip(-[a-z0-9][a-z0-9-]*)?$/),
11920
+ vectorIndex: string().regex(/^object-clip-[a-z0-9][a-z0-9-]*$/),
11722
11921
  /**
11723
11922
  * The text encoder's tokenizer, a declared SIBLING file of its onnx. The name
11724
11923
  * must be unique per tokenizer: every model's siblings land in ONE flat
@@ -12897,8 +13096,13 @@ var AlertSeveritySchema = _enum([
12897
13096
  "info",
12898
13097
  "success",
12899
13098
  "warning",
12900
- "error"
13099
+ "error",
13100
+ "critical"
12901
13101
  ]);
13102
+ var AlertActionSchema = object({
13103
+ label: string(),
13104
+ href: string().optional()
13105
+ });
12902
13106
  var AlertStatusSchema = _enum([
12903
13107
  "active",
12904
13108
  "in-progress",
@@ -12916,6 +13120,7 @@ var AlertSchema = object({
12916
13120
  severity: AlertSeveritySchema,
12917
13121
  title: string(),
12918
13122
  message: string(),
13123
+ action: AlertActionSchema.optional(),
12919
13124
  status: AlertStatusSchema,
12920
13125
  progress: number().optional(),
12921
13126
  read: boolean(),
@@ -15345,6 +15550,41 @@ var ComposableCapabilitiesSchema = object({ caps: array(object({
15345
15550
  keyField: string()
15346
15551
  }).optional()
15347
15552
  })) });
15553
+ /**
15554
+ * The report of a one-shot "move this owner's plaintext secrets into the
15555
+ * keychain" run (D878). COUNTS only - never a value, never a ref.
15556
+ *
15557
+ * The owner runs it on its own rows, through its own write path; an operator
15558
+ * script (`scripts/hub/migrate-raw-secrets.ts`) calls the owner's cap method.
15559
+ * Dry run (`apply: false`) reports what WOULD move and changes nothing.
15560
+ */
15561
+ var RawSecretMigrationInputSchema = object({
15562
+ /** `false` (the default of the script) = report only. */
15563
+ apply: boolean() });
15564
+ var RawSecretMigrationReportSchema = object({
15565
+ apply: boolean(),
15566
+ /** Rows that can carry a secret (a profile, an enrolment). */
15567
+ rows: number().int(),
15568
+ /** Rows whose secret was plaintext when the run started. */
15569
+ raw: number().int(),
15570
+ /** Rows that already held a keychain marker when the run started. */
15571
+ markers: number().int(),
15572
+ /** Plaintext rows moved by THIS run (always 0 on a dry run). */
15573
+ migrated: number().int(),
15574
+ /** Plaintext rows left in place because the move or its read-back failed. */
15575
+ failed: number().int(),
15576
+ /** After the run: rows still holding plaintext. */
15577
+ remainingRaw: number().int(),
15578
+ /** After the run: markers the keychain could not resolve right now. */
15579
+ unresolvedMarkers: number().int(),
15580
+ /**
15581
+ * A second, redundant copy of the secrets' rows that the run found (and, on
15582
+ * `apply`, deleted after verifying the first). Owners with a single copy omit it.
15583
+ */
15584
+ redundantCopies: number().int().optional(),
15585
+ /** True when nothing is raw and every marker resolves. */
15586
+ verified: boolean()
15587
+ });
15348
15588
  /** Where a block runs. The operator chooses — a block driving a device on an
15349
15589
  * agent is the reason placement is not fixed to the hub. */
15350
15590
  var CoreBlockPlacementSchema = union([literal("hub"), string().min(1)]);
@@ -15571,6 +15811,9 @@ method(object({}), object({ blocks: array(CoreBlockSchema) }), { auth: "admin" }
15571
15811
  }), SettingsUpdateResultSchema, {
15572
15812
  kind: "mutation",
15573
15813
  auth: "admin"
15814
+ }), method(RawSecretMigrationInputSchema, RawSecretMigrationReportSchema, {
15815
+ kind: "mutation",
15816
+ auth: "admin"
15574
15817
  }), method(object({}), object({ libs: array(object({
15575
15818
  filePath: string(),
15576
15819
  content: string()
@@ -15834,6 +16077,347 @@ id: union([string(), number()]) }), {
15834
16077
  auth: "admin"
15835
16078
  });
15836
16079
  /**
16080
+ * records - an addon's own facts and documents (D881): ledgers, audit rows,
16081
+ * config documents, mirrors. The third storage API next to `ctx.settings`
16082
+ * (operator intent, D870) and device-history (numbers over time, D850).
16083
+ *
16084
+ * Who the OWNER is: `callerAddonId`, stamped by the transport on a call that
16085
+ * crossed a process and stated by a hub in-process caller (`ctx.records` does
16086
+ * that with the addon id closed over). It is deliberately NOT in any input
16087
+ * schema, so a session can never supply it, and a call with no stamp is refused
16088
+ * `records/no-caller`. A kind is readable and writable only by its owner; other
16089
+ * addons go through the owner's capability.
16090
+ *
16091
+ * Every read is three-way: a row, `null`, or the call THROWS. A failed read is
16092
+ * never `[]`. Secret fields are never on the wire: a read shows the
16093
+ * redaction token, `secretRefs` hands the owner's `ctx.secrets` the refs it
16094
+ * resolves itself, and a write may carry only a keychain marker bound to the
16095
+ * row's own ref.
16096
+ *
16097
+ * Internal: addons reach it through `ctx.records`, never directly.
16098
+ */
16099
+ var RecordIdSchema = string().min(1).max(256);
16100
+ /** A JSON object body. Size is the engine's check (`maxDataBytes`), not a schema's. */
16101
+ var RecordBodySchema = record(string(), unknown());
16102
+ var RecordInputSchema = object({
16103
+ id: RecordIdSchema,
16104
+ /** The device this row belongs to (D865 removal, per-device reads). */
16105
+ deviceId: number().int().optional(),
16106
+ /** The domain clock, ms: observed / created / opened. */
16107
+ at: number().int().optional(),
16108
+ /** Producer-set expiry, ms. Refused on a kind whose retention is an engine TTL. */
16109
+ expiresAt: number().int().optional(),
16110
+ data: RecordBodySchema
16111
+ });
16112
+ var RecordViewSchema = object({
16113
+ id: string(),
16114
+ deviceId: number().int().nullable(),
16115
+ at: number().nullable(),
16116
+ expiresAt: number().nullable(),
16117
+ rev: number().int(),
16118
+ updatedAt: number(),
16119
+ data: RecordBodySchema
16120
+ });
16121
+ /** Declared index fields only. Anything else does not compile, by design. */
16122
+ var RecordWhereSchema = record(RecordFieldPathSchema, union([
16123
+ string(),
16124
+ number(),
16125
+ boolean(),
16126
+ object({ in: array(union([
16127
+ string(),
16128
+ number(),
16129
+ boolean()
16130
+ ])).min(1).max(RECORD_BATCH_MAX) }),
16131
+ object({
16132
+ gt: union([string(), number()]).optional(),
16133
+ gte: union([string(), number()]).optional(),
16134
+ lt: union([string(), number()]).optional(),
16135
+ lte: union([string(), number()]).optional()
16136
+ }).refine((r) => Object.keys(r).length > 0, { message: "name at least one bound" })
16137
+ ]));
16138
+ var KindShape = { kind: RecordKindNameSchema };
16139
+ var TimeWindowShape = {
16140
+ deviceId: number().int().optional(),
16141
+ atFrom: number().optional(),
16142
+ atTo: number().optional()
16143
+ };
16144
+ var RecordQueryInputSchema = object({
16145
+ ...KindShape,
16146
+ ...TimeWindowShape,
16147
+ where: RecordWhereSchema.optional(),
16148
+ /** Without `where`: `at` (default for a kind with a clock) or `id`. With `where` the order is the index's. */
16149
+ order: _enum(["at", "id"]).optional(),
16150
+ desc: boolean().optional(),
16151
+ limit: number().int().min(1).max(RECORD_QUERY_MAX).default(100),
16152
+ /** Opaque keyset cursor from a previous answer. There is no offset. */
16153
+ cursor: string().min(1).optional()
16154
+ });
16155
+ var RecordQueryResultSchema = object({
16156
+ records: array(RecordViewSchema),
16157
+ nextCursor: string().nullable()
16158
+ });
16159
+ var RecordKindStateSchema = _enum([
16160
+ "created",
16161
+ "unchanged",
16162
+ "updated"
16163
+ ]);
16164
+ var DeclareKindResultSchema = object({
16165
+ kindId: number().int(),
16166
+ state: RecordKindStateSchema,
16167
+ createdIndexes: array(string()),
16168
+ /** The boot guard: the kind is empty while its legacy table still holds rows. */
16169
+ adoptionPending: object({
16170
+ legacyTable: string(),
16171
+ legacyRows: number().int()
16172
+ }).nullable()
16173
+ });
16174
+ /** Keychain refs a write released (the old marker is gone from the row): the owner deletes the values. */
16175
+ var SecretRefsList = array(string());
16176
+ var RecordSecretRefsSchema = record(string(), record(string(), string()));
16177
+ method(object({ kinds: record(RecordKindNameSchema, RecordKindDeclarationSchema) }), object({ kinds: record(string(), DeclareKindResultSchema) }), {
16178
+ kind: "mutation",
16179
+ auth: "admin"
16180
+ }), method(object({
16181
+ ...KindShape,
16182
+ id: RecordIdSchema
16183
+ }), RecordViewSchema.nullable(), { auth: "admin" }), method(object({
16184
+ ...KindShape,
16185
+ ids: array(RecordIdSchema).min(1).max(RECORD_BATCH_MAX)
16186
+ }), array(RecordViewSchema), { auth: "admin" }), method(object({
16187
+ ...KindShape,
16188
+ ids: array(RecordIdSchema).min(1).max(RECORD_BATCH_MAX)
16189
+ }), RecordSecretRefsSchema, { auth: "admin" }), method(object({
16190
+ ...KindShape,
16191
+ record: RecordInputSchema,
16192
+ /** Compare-and-set. `0` means "the row must not exist". */
16193
+ ifRev: number().int().min(0).optional()
16194
+ }), object({
16195
+ rev: number().int(),
16196
+ releasedRefs: SecretRefsList
16197
+ }), {
16198
+ kind: "mutation",
16199
+ auth: "admin"
16200
+ }), method(object({
16201
+ ...KindShape,
16202
+ records: array(RecordInputSchema).min(1).max(RECORD_BATCH_MAX)
16203
+ }), object({
16204
+ count: number().int(),
16205
+ releasedRefs: SecretRefsList
16206
+ }), {
16207
+ kind: "mutation",
16208
+ auth: "admin"
16209
+ }), method(object({
16210
+ ...KindShape,
16211
+ id: RecordIdSchema,
16212
+ data: RecordBodySchema,
16213
+ at: number().int().nullable().optional(),
16214
+ expiresAt: number().int().nullable().optional(),
16215
+ ifRev: number().int().min(1).optional()
16216
+ }), object({
16217
+ rev: number().int(),
16218
+ releasedRefs: SecretRefsList
16219
+ }), {
16220
+ kind: "mutation",
16221
+ auth: "admin"
16222
+ }), method(object({
16223
+ ...KindShape,
16224
+ id: RecordIdSchema
16225
+ }), object({
16226
+ deleted: boolean(),
16227
+ secretRefs: SecretRefsList
16228
+ }), {
16229
+ kind: "mutation",
16230
+ auth: "admin"
16231
+ }), method(object({
16232
+ ...KindShape,
16233
+ ids: array(RecordIdSchema).min(1).max(RECORD_BATCH_MAX)
16234
+ }), object({
16235
+ deleted: number().int(),
16236
+ secretRefs: SecretRefsList
16237
+ }), {
16238
+ kind: "mutation",
16239
+ auth: "admin"
16240
+ }), method(RecordQueryInputSchema, RecordQueryResultSchema, { auth: "admin" }), method(object({
16241
+ ...KindShape,
16242
+ ...TimeWindowShape,
16243
+ where: RecordWhereSchema.optional()
16244
+ }), object({ count: number().int() }), { auth: "admin" }), method(object({
16245
+ ...KindShape,
16246
+ deviceId: number().int().optional(),
16247
+ from: number(),
16248
+ to: number(),
16249
+ bucketMs: number().int().positive()
16250
+ }), object({ buckets: array(object({
16251
+ bucketStart: number(),
16252
+ count: number().int()
16253
+ })) }), { auth: "admin" }), method(object({
16254
+ ...KindShape,
16255
+ op: _enum([
16256
+ "sum",
16257
+ "min",
16258
+ "max",
16259
+ "count"
16260
+ ]),
16261
+ field: RecordFieldPathSchema.optional(),
16262
+ groupBy: RecordFieldPathSchema.optional(),
16263
+ where: RecordWhereSchema.optional()
16264
+ }), object({ rows: array(object({
16265
+ group: union([
16266
+ string(),
16267
+ number(),
16268
+ _null()
16269
+ ]),
16270
+ value: number().nullable()
16271
+ })) }), { auth: "admin" }), method(object({
16272
+ ...KindShape,
16273
+ deviceId: number().int().optional(),
16274
+ atBefore: number().optional(),
16275
+ where: RecordWhereSchema.optional()
16276
+ }), object({
16277
+ deleted: number().int(),
16278
+ secretRefs: SecretRefsList
16279
+ }), {
16280
+ kind: "mutation",
16281
+ auth: "admin"
16282
+ }), method(object({
16283
+ deviceId: number().int(),
16284
+ kinds: array(RecordKindNameSchema).optional()
16285
+ }), object({
16286
+ deleted: record(string(), number().int()),
16287
+ secretRefs: SecretRefsList
16288
+ }), {
16289
+ kind: "mutation",
16290
+ auth: "admin"
16291
+ }), method(object(KindShape), object({ id: number().int() }), {
16292
+ kind: "mutation",
16293
+ auth: "admin"
16294
+ });
16295
+ /** One table of the settings database. */
16296
+ var StorageTableSchema = object({
16297
+ /** The table's full name, e.g. `recorder:addon-settings` or `addon-device-settings`. */
16298
+ name: string(),
16299
+ /** The owner prefix of a scoped name (`recorder` for `recorder:addon-settings`), else null. */
16300
+ owner: string().nullable(),
16301
+ rows: number().int().nonnegative(),
16302
+ /** Bytes the table's pages occupy (`dbstat`); null when the engine cannot measure. */
16303
+ bytes: number().int().nonnegative().nullable(),
16304
+ /** Declared by an addon since this engine process started (a running addon claims it). */
16305
+ declaredThisBoot: boolean()
16306
+ });
16307
+ /** One declared record kind (D881) as System -> Data shows it. */
16308
+ var StorageKindSchema = object({
16309
+ owner: string(),
16310
+ kind: string(),
16311
+ database: _enum(["settings", "events"]),
16312
+ class: string(),
16313
+ state: _enum([
16314
+ "declared",
16315
+ "orphaned",
16316
+ "dropped"
16317
+ ]),
16318
+ /** `null` when the caller asked for no counts (`counts: false`). */
16319
+ rows: number().int().nonnegative().nullable(),
16320
+ /** Rows x the average size of a sample; null for an empty kind. */
16321
+ bytesEstimate: number().int().nonnegative().nullable(),
16322
+ writeTrigger: string(),
16323
+ retention: RecordRetentionSchema,
16324
+ /** `true` when the kind is an entry kind (the generic entries UI lists it). */
16325
+ entry: boolean(),
16326
+ /** The whole declaration, secret paths and entry descriptor included (the entries service builds its handle from it). */
16327
+ declaration: RecordKindDeclarationSchema
16328
+ });
16329
+ method(object({ ownerPrefix: string().min(1).optional() }), object({ tables: array(StorageTableSchema) }), { auth: "admin" }), method(object({
16330
+ collection: string().min(1),
16331
+ expectRows: number().int().nonnegative()
16332
+ }), object({
16333
+ dropped: literal(true),
16334
+ rows: number().int().nonnegative()
16335
+ }), {
16336
+ kind: "mutation",
16337
+ auth: "admin"
16338
+ }), method(object({
16339
+ owner: string().min(1).optional(),
16340
+ /** `false` skips the per-kind row count (a catalog read only). Default true. */
16341
+ counts: boolean().optional()
16342
+ }), object({ kinds: array(StorageKindSchema) }), { auth: "admin" }), method(RecordQueryInputSchema.extend({
16343
+ owner: string().min(1),
16344
+ kind: RecordKindNameSchema
16345
+ }), RecordQueryResultSchema, { auth: "admin" }), method(object({
16346
+ owner: string().min(1),
16347
+ kind: RecordKindNameSchema,
16348
+ records: array(RecordInputSchema).max(RECORD_BATCH_MAX),
16349
+ /** The LAST batch: the copy is complete, the boot guard stops asking. */
16350
+ complete: boolean().optional()
16351
+ }).refine((input) => input.records.length > 0 || input.complete === true, { message: "records must be non-empty unless complete is true" }), object({ adopted: number().int() }), {
16352
+ kind: "mutation",
16353
+ auth: "admin"
16354
+ }), method(object({
16355
+ collection: string().min(1),
16356
+ cursor: string().optional(),
16357
+ limit: number().int().min(1).max(1e3).optional()
16358
+ }), object({
16359
+ rows: array(object({
16360
+ id: string(),
16361
+ data: record(string(), unknown())
16362
+ })),
16363
+ nextCursor: string().nullable()
16364
+ }), { auth: "admin" }), method(object({ collection: string().min(1) }), object({ adopted: boolean() }), { auth: "admin" });
16365
+ /**
16366
+ * record-entries - the ONE admin surface for every list of user-created entries
16367
+ * (D881): notification targets, brokers, LLM profiles, anything an addon
16368
+ * declares as an ENTRY kind (`entry: { title }` in `defineRecordKinds`).
16369
+ *
16370
+ * The UI is generic. `listEntryKinds` hands it, per kind, the JSON Schema of
16371
+ * the entry body with `secret: true` on every credential field, so a password
16372
+ * field is derived from the schema and never from a name. `putEntry` takes the
16373
+ * redaction token for an untouched secret (the stored value is kept), a string
16374
+ * for a new one, and the clear instruction to remove one. A read never carries
16375
+ * a secret value, and a locked keychain refuses the write with
16376
+ * `records/secret-unavailable` instead of storing plaintext.
16377
+ *
16378
+ * Hub-only, served in-process (it acts for each entry's owner on the keychain).
16379
+ */
16380
+ var EntryKindInfoSchema = object({
16381
+ owner: string(),
16382
+ kind: RecordKindNameSchema,
16383
+ title: string(),
16384
+ nameField: string(),
16385
+ /** JSON Schema of the body; `secret: true` marks a password field. */
16386
+ fields: record(string(), unknown()),
16387
+ secretPaths: array(string()),
16388
+ rows: number().int().nonnegative()
16389
+ });
16390
+ var EntryViewSchema = object({
16391
+ id: RecordIdSchema,
16392
+ name: string(),
16393
+ rev: number().int(),
16394
+ updatedAt: number(),
16395
+ /** Secret fields hold the redaction token. */
16396
+ data: RecordBodySchema
16397
+ });
16398
+ var EntryAddress = {
16399
+ owner: string().min(1),
16400
+ kind: RecordKindNameSchema
16401
+ };
16402
+ method(object({}), object({ kinds: array(EntryKindInfoSchema) }), { auth: "admin" }), method(object({ ...EntryAddress }), object({ entries: array(EntryViewSchema) }), { auth: "admin" }), method(object({
16403
+ ...EntryAddress,
16404
+ id: RecordIdSchema.optional(),
16405
+ data: RecordBodySchema,
16406
+ ifRev: number().int().min(1).optional()
16407
+ }), object({
16408
+ id: string(),
16409
+ rev: number().int()
16410
+ }), {
16411
+ kind: "mutation",
16412
+ auth: "admin"
16413
+ }), method(object({
16414
+ ...EntryAddress,
16415
+ id: RecordIdSchema
16416
+ }), object({ deleted: boolean() }), {
16417
+ kind: "mutation",
16418
+ auth: "admin"
16419
+ });
16420
+ /**
15837
16421
  * `keychain` — the hub's encrypted store of secret values (D787).
15838
16422
  *
15839
16423
  * Settings blobs never hold a secret: they hold a marker
@@ -16374,6 +16958,16 @@ method(object({}), KeychainStatusSchema, { auth: "admin" }), method(object({}),
16374
16958
  kind: "mutation",
16375
16959
  auth: "admin",
16376
16960
  caller: "required"
16961
+ }), method(object({
16962
+ ref: string().min(1),
16963
+ value: string().min(1)
16964
+ }), object({
16965
+ ref: string(),
16966
+ version: number().int()
16967
+ }), {
16968
+ kind: "mutation",
16969
+ auth: "admin",
16970
+ caller: "required"
16377
16971
  }), method(object({ refs: array(string().min(1)).max(1e3) }), object({
16378
16972
  deleted: array(string()).readonly(),
16379
16973
  kept: array(object({
@@ -16784,7 +17378,11 @@ DeviceType.Hub, DeviceDiscoveryStatusSchema.extend({ lastFetchedAt: number().int
16784
17378
  });
16785
17379
  /**
16786
17380
  * `device-adoption` — generic discovery + adoption surface,
16787
- * system-scoped singleton. The de-HA-ified successor to `ha-discovery`:
17381
+ * system-scoped collection (one provider per integration addon), routed
17382
+ * by explicit `{ addonId }` on direct `deviceAdoption.*` calls — the same
17383
+ * pin model as `connection-test`. The admin UI keeps using
17384
+ * `deviceManager.adoption*` (which already threads `addonId`). The de-HA-ified
17385
+ * successor to `ha-discovery`:
16788
17386
  * keyed by `integrationId` (the addon resolves integrationId → broker
16789
17387
  * internally) rather than a connection-specific `brokerId`, and it
16790
17388
  * REUSES the shared `DiscoveredChildDevice` candidate type from
@@ -39037,6 +39635,9 @@ method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, {
39037
39635
  }), _void(), { kind: "mutation" }), method(object({}), array(LlmProfileKindDescriptorSchema)), method(object({}), array(LlmProfileSchema)), method(object({ profile: LlmProfileSchema }), LlmProfileSchema, {
39038
39636
  kind: "mutation",
39039
39637
  auth: "admin"
39638
+ }), method(RawSecretMigrationInputSchema, RawSecretMigrationReportSchema, {
39639
+ kind: "mutation",
39640
+ auth: "admin"
39040
39641
  }), method(ProfileRefInputSchema, _void(), {
39041
39642
  kind: "mutation",
39042
39643
  auth: "admin"
@@ -49460,6 +50061,41 @@ var ServerRollbackInfoSchema = object({
49460
50061
  atMs: number(),
49461
50062
  reason: string()
49462
50063
  });
50064
+ /**
50065
+ * The runner boot check (D877): the runners this node PLANNED (hub: one per
50066
+ * `resolveRunnerId` over its forked addons; agent: the runners its process
50067
+ * service holds, because only the hub plans) against the states the process
50068
+ * service reports. Kept in memory, recomputed by the same one-shot check after
50069
+ * every boot, served on `getServerPackageStatus`.
50070
+ *
50071
+ * `failed` is the D6 breaker's terminal state, `refused` a deterministic Init
50072
+ * refusal (an addon that said "I will not start, and here is why"), `missing` a
50073
+ * planned runner the process service has no entry for.
50074
+ */
50075
+ var RunnerRefusalSchema = object({
50076
+ runnerId: string(),
50077
+ addonIds: array(string()),
50078
+ reason: string()
50079
+ });
50080
+ var RunnerBootCheckSchema = object({
50081
+ checkedAtMs: number(),
50082
+ /** Runners planned for this node. */
50083
+ expected: number(),
50084
+ /** Planned runners whose process is `running`. */
50085
+ running: number(),
50086
+ failed: array(string()),
50087
+ refused: array(RunnerRefusalSchema),
50088
+ missing: array(string()),
50089
+ /**
50090
+ * Runners still on their way: `starting`, or `crashed` waiting on a backoff
50091
+ * respawn. The check is FINAL only when this is empty; until then nothing is
50092
+ * pushed and the verdict is re-evaluated on the next runner state change.
50093
+ * Optional for version skew (absent = settled).
50094
+ */
50095
+ pending: array(string()).optional(),
50096
+ /** True when the plan is the hub's (`missing` is then meaningful); false on an agent. */
50097
+ planKnown: boolean()
50098
+ });
49463
50099
  var ServerPackageStatusSchema = object({
49464
50100
  /** Root package name (`@camstack/server` on the hub). */
49465
50101
  packageName: string(),
@@ -49522,7 +50158,14 @@ var ServerPackageStatusSchema = object({
49522
50158
  * for version skew: an older provider's payload simply omits it, and an
49523
50159
  * absent wrapper is unknown — never `native`.
49524
50160
  */
49525
- wrapper: WrapperIdentitySchema.optional()
50161
+ wrapper: WrapperIdentitySchema.optional(),
50162
+ /**
50163
+ * What this node PLANNED to run against what its process service reports
50164
+ * (D877). Absent until the one-shot boot check has run (~60 s after boot) and
50165
+ * on a provider that predates it. Absent is "not checked yet", never "all
50166
+ * well": a consumer that needs the answer treats it as pending.
50167
+ */
50168
+ runners: RunnerBootCheckSchema.optional()
49526
50169
  });
49527
50170
  var ServerUpdateCheckResultSchema = object({
49528
50171
  packageName: string(),
@@ -49573,6 +50216,13 @@ var ServerUpdateOutcomeSchema = _enum([
49573
50216
  "refused",
49574
50217
  "failed"
49575
50218
  ]);
50219
+ /** One addon the pre-flight found the target version would refuse (D877). */
50220
+ var UpdateBlockerSchema = object({
50221
+ addonId: string(),
50222
+ reason: string(),
50223
+ /** What the operator does about it. */
50224
+ remedy: string()
50225
+ });
49576
50226
  var ServerUpdateActionResultSchema = object({
49577
50227
  accepted: boolean(),
49578
50228
  targetVersion: string().nullable(),
@@ -49590,14 +50240,27 @@ var ServerUpdateActionResultSchema = object({
49590
50240
  * The failure itself, verbatim enough to act on (the npm output for a
49591
50241
  * staging install). Non-null only for `failed`.
49592
50242
  */
49593
- error: string().nullable().optional()
50243
+ error: string().nullable().optional(),
50244
+ /**
50245
+ * The addons the target version would refuse to start on this node's live
50246
+ * store (D877), present when the pre-flight refused the update
50247
+ * (`reason: 'addon-would-refuse'`). Optional for version skew.
50248
+ */
50249
+ blockers: array(UpdateBlockerSchema).optional()
49594
50250
  });
49595
50251
  method(_void(), ServerPackageStatusSchema, { auth: "admin" }), method(_void(), ServerUpdateCheckResultSchema, {
49596
50252
  kind: "mutation",
49597
50253
  auth: "admin"
49598
- }), method(object({
49599
- /** Explicit target version; omitted = latest from the registry. */
49600
- version: string().optional() }), ServerUpdateActionResultSchema, {
50254
+ }), method(object({
50255
+ /** Explicit target version; omitted = latest from the registry. */
50256
+ version: string().optional(),
50257
+ /**
50258
+ * Apply even though the pre-flight (D877) found addons the target would
50259
+ * refuse to start. Off by default: those addons stay down until the
50260
+ * remedy is run, which is the incident this gate exists to prevent.
50261
+ */
50262
+ acknowledgeRefusals: boolean().optional()
50263
+ }), ServerUpdateActionResultSchema, {
49601
50264
  kind: "mutation",
49602
50265
  auth: "admin",
49603
50266
  timeoutMs: 16 * 6e4
@@ -52114,7 +52777,9 @@ var ManifestShapeSchema = object({
52114
52777
  var AddonProcessSchema = object({
52115
52778
  pid: number().optional(),
52116
52779
  mode: string(),
52117
- state: string()
52780
+ state: string(),
52781
+ /** Why the runner is `refused` (an addon's own words), when it is (D877). */
52782
+ reason: string().optional()
52118
52783
  });
52119
52784
  /**
52120
52785
  * Per-addon health snapshot from the kernel's AddonHealthMonitor.
@@ -52692,7 +53357,7 @@ var BatteryStatusSchema = object({
52692
53357
  */
52693
53358
  binary: boolean().optional()
52694
53359
  });
52695
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, method(object({
53360
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, method(object({
52696
53361
  deviceId: number(),
52697
53362
  /** Bound on the wait. Sensible range 3000–10000ms. */
52698
53363
  timeoutMs: number().int().min(500).max(3e4).default(8e3)
@@ -53117,6 +53782,12 @@ object({
53117
53782
  /** Horizontal louver swing on/off. Null when the device has no
53118
53783
  * horizontal swing surface (gate with `DeviceFeature.ClimateSwingHorizontal`). */
53119
53784
  swingHorizontal: boolean().nullable(),
53785
+ /** Lowest setpoint the device accepts, Celsius. Absent / null = not reported. */
53786
+ minTemp: number().nullable().optional(),
53787
+ /** Highest setpoint the device accepts, Celsius. Absent / null = not reported. */
53788
+ maxTemp: number().nullable().optional(),
53789
+ /** Setpoint granularity, Celsius (0.5, 1). Absent / null = not reported. */
53790
+ tempStep: number().positive().nullable().optional(),
53120
53791
  /** Ms epoch when the slice was last updated (push or command). */
53121
53792
  lastFetchedAt: number()
53122
53793
  });
@@ -53562,6 +54233,130 @@ object({
53562
54233
  deviceId: number(),
53563
54234
  status: DeviceStatusSchema
53564
54235
  });
54236
+ /**
54237
+ * Smart-dishwasher cap — program lifecycle, door / remote-start gates,
54238
+ * consumable levels (salt, rinse aid) and common program options.
54239
+ *
54240
+ * Sources: native Bosch Home Connect (`dishwasher` device type). Reusable
54241
+ * by any integration that exposes the same program / option surface.
54242
+ *
54243
+ * `kind: 'poll'` — cloud REST APIs typically have no push channel; the
54244
+ * provider refreshes the slice on an interval and eagerly after commands.
54245
+ */
54246
+ var DishwasherStateSchema = _enum([
54247
+ "idle",
54248
+ "running",
54249
+ "paused",
54250
+ "finished",
54251
+ "error",
54252
+ "unavailable"
54253
+ ]);
54254
+ var DishwasherConsumableLevelSchema = _enum([
54255
+ "ok",
54256
+ "low",
54257
+ "empty"
54258
+ ]);
54259
+ object({
54260
+ state: DishwasherStateSchema,
54261
+ /** Active program id/name, or null when none selected / unknown. */
54262
+ program: string().nullable(),
54263
+ /** Program tokens the hardware accepts — drives the UI selector. */
54264
+ availablePrograms: array(string()),
54265
+ /** Minutes remaining on the active cycle, or null when not running. */
54266
+ remainingMinutes: number().int().nonnegative().nullable(),
54267
+ /** Cycle completion 0..100, or null when not applicable. */
54268
+ progressPercent: number().min(0).max(100).nullable(),
54269
+ /** True when the door is reported open. */
54270
+ doorOpen: boolean(),
54271
+ /** True when remote start is allowed (door closed, power on, etc.). */
54272
+ remoteStartAllowed: boolean(),
54273
+ /** Main power / switched-on state. */
54274
+ powerOn: boolean(),
54275
+ saltLevel: DishwasherConsumableLevelSchema.nullable(),
54276
+ rinseAidLevel: DishwasherConsumableLevelSchema.nullable(),
54277
+ halfLoad: boolean(),
54278
+ hygienePlus: boolean(),
54279
+ /** Extra dry option when the appliance exposes it. */
54280
+ extraDry: boolean(),
54281
+ /** Intensive zone (lower basket) when the appliance exposes it. */
54282
+ intensiveZone: boolean(),
54283
+ /** VarioSpeed / VarioSpeed+ when the appliance exposes it. */
54284
+ varioSpeedPlus: boolean(),
54285
+ /** Child lock (controls disabled on the appliance). */
54286
+ childLock: boolean(),
54287
+ errorCode: number().nullable(),
54288
+ errorLabel: string().nullable(),
54289
+ lastFetchedAt: number()
54290
+ });
54291
+ DeviceType.Dishwasher, method(object({ deviceId: number().int().nonnegative() }), _void(), {
54292
+ kind: "mutation",
54293
+ auth: "protected"
54294
+ }), method(object({ deviceId: number().int().nonnegative() }), _void(), {
54295
+ kind: "mutation",
54296
+ auth: "protected"
54297
+ }), method(object({ deviceId: number().int().nonnegative() }), _void(), {
54298
+ kind: "mutation",
54299
+ auth: "protected"
54300
+ }), method(object({
54301
+ deviceId: number().int().nonnegative(),
54302
+ program: string().min(1)
54303
+ }), _void(), {
54304
+ kind: "mutation",
54305
+ auth: "protected"
54306
+ }), method(object({
54307
+ deviceId: number().int().nonnegative(),
54308
+ on: boolean()
54309
+ }), _void(), {
54310
+ kind: "mutation",
54311
+ auth: "protected"
54312
+ }), method(object({
54313
+ deviceId: number().int().nonnegative(),
54314
+ on: boolean()
54315
+ }), _void(), {
54316
+ kind: "mutation",
54317
+ auth: "protected"
54318
+ }), method(object({
54319
+ deviceId: number().int().nonnegative(),
54320
+ on: boolean()
54321
+ }), _void(), {
54322
+ kind: "mutation",
54323
+ auth: "protected"
54324
+ }), method(object({
54325
+ deviceId: number().int().nonnegative(),
54326
+ on: boolean()
54327
+ }), _void(), {
54328
+ kind: "mutation",
54329
+ auth: "protected"
54330
+ }), method(object({
54331
+ deviceId: number().int().nonnegative(),
54332
+ on: boolean()
54333
+ }), _void(), {
54334
+ kind: "mutation",
54335
+ auth: "protected"
54336
+ }), method(object({
54337
+ deviceId: number().int().nonnegative(),
54338
+ on: boolean()
54339
+ }), _void(), {
54340
+ kind: "mutation",
54341
+ auth: "protected"
54342
+ }), method(object({
54343
+ deviceId: number().int().nonnegative(),
54344
+ on: boolean()
54345
+ }), _void(), {
54346
+ kind: "mutation",
54347
+ auth: "protected"
54348
+ }), method(object({
54349
+ deviceId: number().int().nonnegative(),
54350
+ key: string().min(1),
54351
+ value: union([
54352
+ boolean(),
54353
+ string(),
54354
+ number()
54355
+ ])
54356
+ }), _void(), {
54357
+ kind: "mutation",
54358
+ auth: "protected"
54359
+ });
53565
54360
  object({
53566
54361
  /** Ms epoch of the last press. null = never observed since this provider started. */
53567
54362
  lastPressedAt: number().nullable(),
@@ -54127,6 +54922,13 @@ object({
54127
54922
  lastChangedAt: number()
54128
54923
  });
54129
54924
  DeviceType.Sensor;
54925
+ object({
54926
+ /** Radiator valve opening 0 (closed) .. 100 (open). Null = not yet known. */
54927
+ position: number().min(0).max(100).nullable(),
54928
+ /** Ms epoch when the slice was last updated (push or poll). */
54929
+ lastFetchedAt: number()
54930
+ });
54931
+ DeviceType.Thermostat;
54130
54932
  object({
54131
54933
  /** Whether the humidifier is currently on. */
54132
54934
  on: boolean(),
@@ -54937,7 +55739,19 @@ var TlsStatusSchema = object({
54937
55739
  sans: array(string()),
54938
55740
  caCertPem: string().nullable(),
54939
55741
  reissueError: string().nullable(),
54940
- restartRequired: boolean()
55742
+ restartRequired: boolean(),
55743
+ /** An uploaded certificate is served but no CA is kept for it and it is not publicly signed (D873). */
55744
+ caMissing: boolean(),
55745
+ /** Does the hub's own generated CA carry a critical name constraint? `null` while it has none. */
55746
+ localCaConstrained: boolean().nullable(),
55747
+ /** ISO time the generated CA was replaced by a constrained one; devices must re-download it. */
55748
+ caReplacedAt: string().nullable(),
55749
+ /** The uploaded certificate kept on disk, selectable again after "Revert to generated". */
55750
+ storedUpload: object({
55751
+ leafFingerprintSha256: string(),
55752
+ validTo: string(),
55753
+ hasCa: boolean()
55754
+ }).nullable()
54941
55755
  });
54942
55756
  method(_void(), ListResultSchema), method(_void(), PreferredSchema), method(object({
54943
55757
  /**
@@ -54993,6 +55807,9 @@ method(_void(), ListResultSchema), method(_void(), PreferredSchema), method(obje
54993
55807
  }), method(_void(), object({ pem: string() })), method(_void(), TlsStatusSchema, {
54994
55808
  kind: "mutation",
54995
55809
  auth: "admin"
55810
+ }), method(_void(), TlsStatusSchema, {
55811
+ kind: "mutation",
55812
+ auth: "admin"
54996
55813
  });
54997
55814
  object({
54998
55815
  /** Lifecycle state of the lock. `jammed` means the motor reported
@@ -60214,7 +61031,11 @@ method(_void(), array(UserSummarySchema), { auth: "admin" }), method(CreateUserI
60214
61031
  kind: "mutation",
60215
61032
  auth: "admin",
60216
61033
  access: "delete"
60217
- }), method(object({ userId: string() }), TotpStatusSchema, { auth: "admin" }), method(object({
61034
+ }), method(object({ userId: string() }), TotpStatusSchema, { auth: "admin" }), method(RawSecretMigrationInputSchema, RawSecretMigrationReportSchema, {
61035
+ kind: "mutation",
61036
+ auth: "admin",
61037
+ access: "create"
61038
+ }), method(object({
60218
61039
  userId: string(),
60219
61040
  code: string()
60220
61041
  }), object({ valid: boolean() }), {
@@ -61559,6 +62380,12 @@ var BaseDeviceProvider = class extends BaseAddon {
61559
62380
  provider: this
61560
62381
  }];
61561
62382
  }
62383
+ /** Flatten `super.onInitialize()` whether it returned an array or an envelope. */
62384
+ providerRegistrationsFromSuper(result) {
62385
+ if (Array.isArray(result)) return result;
62386
+ if (result !== void 0 && result.providers !== void 0) return [...result.providers];
62387
+ return [];
62388
+ }
61562
62389
  async onShutdown() {
61563
62390
  this._restoreShuttingDown = true;
61564
62391
  this.cancelRestoreRetries();
@@ -62085,7 +62912,7 @@ var BaseDeviceProvider = class extends BaseAddon {
62085
62912
  return toDeviceSummary(device, this.addonId);
62086
62913
  }
62087
62914
  };
62088
- DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder;
62915
+ DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher;
62089
62916
  new Set(Object.values(DeviceType));
62090
62917
  Object.freeze({
62091
62918
  "accessories.getStatus": {
@@ -63234,6 +64061,12 @@ Object.freeze({
63234
64061
  addonId: null,
63235
64062
  access: "view"
63236
64063
  },
64064
+ "coreBlocks.migrateRawSecrets": {
64065
+ capName: "core-blocks",
64066
+ capScope: "system",
64067
+ addonId: null,
64068
+ access: "create"
64069
+ },
63237
64070
  "coreBlocks.restart": {
63238
64071
  capName: "core-blocks",
63239
64072
  capScope: "system",
@@ -64500,6 +65333,84 @@ Object.freeze({
64500
65333
  addonId: null,
64501
65334
  access: "view"
64502
65335
  },
65336
+ "dishwasher.getStatus": {
65337
+ capName: "dishwasher",
65338
+ capScope: "device",
65339
+ addonId: null,
65340
+ access: "view"
65341
+ },
65342
+ "dishwasher.pause": {
65343
+ capName: "dishwasher",
65344
+ capScope: "device",
65345
+ addonId: null,
65346
+ access: "create"
65347
+ },
65348
+ "dishwasher.setChildLock": {
65349
+ capName: "dishwasher",
65350
+ capScope: "device",
65351
+ addonId: null,
65352
+ access: "create"
65353
+ },
65354
+ "dishwasher.setExtraDry": {
65355
+ capName: "dishwasher",
65356
+ capScope: "device",
65357
+ addonId: null,
65358
+ access: "create"
65359
+ },
65360
+ "dishwasher.setHalfLoad": {
65361
+ capName: "dishwasher",
65362
+ capScope: "device",
65363
+ addonId: null,
65364
+ access: "create"
65365
+ },
65366
+ "dishwasher.setHygienePlus": {
65367
+ capName: "dishwasher",
65368
+ capScope: "device",
65369
+ addonId: null,
65370
+ access: "create"
65371
+ },
65372
+ "dishwasher.setIntensiveZone": {
65373
+ capName: "dishwasher",
65374
+ capScope: "device",
65375
+ addonId: null,
65376
+ access: "create"
65377
+ },
65378
+ "dishwasher.setOption": {
65379
+ capName: "dishwasher",
65380
+ capScope: "device",
65381
+ addonId: null,
65382
+ access: "create"
65383
+ },
65384
+ "dishwasher.setPower": {
65385
+ capName: "dishwasher",
65386
+ capScope: "device",
65387
+ addonId: null,
65388
+ access: "create"
65389
+ },
65390
+ "dishwasher.setProgram": {
65391
+ capName: "dishwasher",
65392
+ capScope: "device",
65393
+ addonId: null,
65394
+ access: "create"
65395
+ },
65396
+ "dishwasher.setVarioSpeedPlus": {
65397
+ capName: "dishwasher",
65398
+ capScope: "device",
65399
+ addonId: null,
65400
+ access: "create"
65401
+ },
65402
+ "dishwasher.start": {
65403
+ capName: "dishwasher",
65404
+ capScope: "device",
65405
+ addonId: null,
65406
+ access: "create"
65407
+ },
65408
+ "dishwasher.stop": {
65409
+ capName: "dishwasher",
65410
+ capScope: "device",
65411
+ addonId: null,
65412
+ access: "create"
65413
+ },
64503
65414
  "doorbell.getStatus": {
64504
65415
  capName: "doorbell",
64505
65416
  capScope: "device",
@@ -64710,6 +65621,12 @@ Object.freeze({
64710
65621
  addonId: null,
64711
65622
  access: "view"
64712
65623
  },
65624
+ "heatingValve.getStatus": {
65625
+ capName: "heating-valve",
65626
+ capScope: "device",
65627
+ addonId: null,
65628
+ access: "view"
65629
+ },
64713
65630
  "humidifier.getStatus": {
64714
65631
  capName: "humidifier",
64715
65632
  capScope: "device",
@@ -64920,6 +65837,12 @@ Object.freeze({
64920
65837
  addonId: null,
64921
65838
  access: "create"
64922
65839
  },
65840
+ "keychainAdmin.importSecret": {
65841
+ capName: "keychain-admin",
65842
+ capScope: "system",
65843
+ addonId: null,
65844
+ access: "create"
65845
+ },
64923
65846
  "keychainAdmin.listAudit": {
64924
65847
  capName: "keychain-admin",
64925
65848
  capScope: "system",
@@ -65088,6 +66011,12 @@ Object.freeze({
65088
66011
  addonId: null,
65089
66012
  access: "view"
65090
66013
  },
66014
+ "llm.migrateRawSecrets": {
66015
+ capName: "llm",
66016
+ capScope: "system",
66017
+ addonId: null,
66018
+ access: "create"
66019
+ },
65091
66020
  "llm.resolveModelRef": {
65092
66021
  capName: "llm",
65093
66022
  capScope: "system",
@@ -65316,6 +66245,12 @@ Object.freeze({
65316
66245
  addonId: null,
65317
66246
  access: "create"
65318
66247
  },
66248
+ "localNetwork.useStoredUploadedCertificate": {
66249
+ capName: "local-network",
66250
+ capScope: "system",
66251
+ addonId: null,
66252
+ access: "create"
66253
+ },
65319
66254
  "lockControl.getStatus": {
65320
66255
  capName: "lock-control",
65321
66256
  capScope: "device",
@@ -67968,6 +68903,30 @@ Object.freeze({
67968
68903
  addonId: null,
67969
68904
  access: "create"
67970
68905
  },
68906
+ "recordEntries.deleteEntry": {
68907
+ capName: "record-entries",
68908
+ capScope: "system",
68909
+ addonId: null,
68910
+ access: "delete"
68911
+ },
68912
+ "recordEntries.listEntries": {
68913
+ capName: "record-entries",
68914
+ capScope: "system",
68915
+ addonId: null,
68916
+ access: "view"
68917
+ },
68918
+ "recordEntries.listEntryKinds": {
68919
+ capName: "record-entries",
68920
+ capScope: "system",
68921
+ addonId: null,
68922
+ access: "view"
68923
+ },
68924
+ "recordEntries.putEntry": {
68925
+ capName: "record-entries",
68926
+ capScope: "system",
68927
+ addonId: null,
68928
+ access: "create"
68929
+ },
67971
68930
  "recording.getAvailability": {
67972
68931
  capName: "recording",
67973
68932
  capScope: "device",
@@ -68268,6 +69227,102 @@ Object.freeze({
68268
69227
  addonId: null,
68269
69228
  access: "view"
68270
69229
  },
69230
+ "records.aggregate": {
69231
+ capName: "records",
69232
+ capScope: "system",
69233
+ addonId: null,
69234
+ access: "view"
69235
+ },
69236
+ "records.allocateId": {
69237
+ capName: "records",
69238
+ capScope: "system",
69239
+ addonId: null,
69240
+ access: "create"
69241
+ },
69242
+ "records.count": {
69243
+ capName: "records",
69244
+ capScope: "system",
69245
+ addonId: null,
69246
+ access: "view"
69247
+ },
69248
+ "records.declareKinds": {
69249
+ capName: "records",
69250
+ capScope: "system",
69251
+ addonId: null,
69252
+ access: "create"
69253
+ },
69254
+ "records.delete": {
69255
+ capName: "records",
69256
+ capScope: "system",
69257
+ addonId: null,
69258
+ access: "delete"
69259
+ },
69260
+ "records.deleteDevice": {
69261
+ capName: "records",
69262
+ capScope: "system",
69263
+ addonId: null,
69264
+ access: "delete"
69265
+ },
69266
+ "records.deleteMany": {
69267
+ capName: "records",
69268
+ capScope: "system",
69269
+ addonId: null,
69270
+ access: "delete"
69271
+ },
69272
+ "records.deleteWhere": {
69273
+ capName: "records",
69274
+ capScope: "system",
69275
+ addonId: null,
69276
+ access: "delete"
69277
+ },
69278
+ "records.get": {
69279
+ capName: "records",
69280
+ capScope: "system",
69281
+ addonId: null,
69282
+ access: "view"
69283
+ },
69284
+ "records.getMany": {
69285
+ capName: "records",
69286
+ capScope: "system",
69287
+ addonId: null,
69288
+ access: "view"
69289
+ },
69290
+ "records.histogram": {
69291
+ capName: "records",
69292
+ capScope: "system",
69293
+ addonId: null,
69294
+ access: "view"
69295
+ },
69296
+ "records.patch": {
69297
+ capName: "records",
69298
+ capScope: "system",
69299
+ addonId: null,
69300
+ access: "create"
69301
+ },
69302
+ "records.put": {
69303
+ capName: "records",
69304
+ capScope: "system",
69305
+ addonId: null,
69306
+ access: "create"
69307
+ },
69308
+ "records.putMany": {
69309
+ capName: "records",
69310
+ capScope: "system",
69311
+ addonId: null,
69312
+ access: "create"
69313
+ },
69314
+ "records.query": {
69315
+ capName: "records",
69316
+ capScope: "system",
69317
+ addonId: null,
69318
+ access: "view"
69319
+ },
69320
+ "records.secretRefs": {
69321
+ capName: "records",
69322
+ capScope: "system",
69323
+ addonId: null,
69324
+ access: "view"
69325
+ },
68271
69326
  "sceneMonitor.captureReference": {
68272
69327
  capName: "scene-monitor",
68273
69328
  capScope: "device",
@@ -68700,6 +69755,48 @@ Object.freeze({
68700
69755
  addonId: null,
68701
69756
  access: "create"
68702
69757
  },
69758
+ "storageAdmin.adoptRecords": {
69759
+ capName: "storage-admin",
69760
+ capScope: "system",
69761
+ addonId: null,
69762
+ access: "create"
69763
+ },
69764
+ "storageAdmin.dropCollection": {
69765
+ capName: "storage-admin",
69766
+ capScope: "system",
69767
+ addonId: null,
69768
+ access: "delete"
69769
+ },
69770
+ "storageAdmin.isAdoptedLegacyTable": {
69771
+ capName: "storage-admin",
69772
+ capScope: "system",
69773
+ addonId: null,
69774
+ access: "view"
69775
+ },
69776
+ "storageAdmin.listKinds": {
69777
+ capName: "storage-admin",
69778
+ capScope: "system",
69779
+ addonId: null,
69780
+ access: "view"
69781
+ },
69782
+ "storageAdmin.listTables": {
69783
+ capName: "storage-admin",
69784
+ capScope: "system",
69785
+ addonId: null,
69786
+ access: "view"
69787
+ },
69788
+ "storageAdmin.readLegacyCollection": {
69789
+ capName: "storage-admin",
69790
+ capScope: "system",
69791
+ addonId: null,
69792
+ access: "view"
69793
+ },
69794
+ "storageAdmin.readRecords": {
69795
+ capName: "storage-admin",
69796
+ capScope: "system",
69797
+ addonId: null,
69798
+ access: "view"
69799
+ },
68703
69800
  "storageEvictable.evict": {
68704
69801
  capName: "storage-evictable",
68705
69802
  capScope: "system",
@@ -69612,6 +70709,12 @@ Object.freeze({
69612
70709
  addonId: null,
69613
70710
  access: "view"
69614
70711
  },
70712
+ "userManagement.migrateRawSecrets": {
70713
+ capName: "user-management",
70714
+ capScope: "system",
70715
+ addonId: null,
70716
+ access: "create"
70717
+ },
69615
70718
  "userManagement.oauthExchangeCode": {
69616
70719
  capName: "user-management",
69617
70720
  capScope: "system",
@@ -70111,7 +71214,7 @@ Object.freeze({
70111
71214
  access: "create"
70112
71215
  }
70113
71216
  });
70114
- DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder;
71217
+ DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher;
70115
71218
  DeviceFeature.BatteryOperated;
70116
71219
  /** Reject after `ms`; always clears its own timer. */
70117
71220
  async function withTimeout$1(promise, ms, label) {
@@ -71001,6 +72104,71 @@ Object.freeze({
71001
72104
  form: "single",
71002
72105
  optional: false
71003
72106
  }],
72107
+ "dishwasher.getStatus": [{
72108
+ name: "deviceId",
72109
+ form: "single",
72110
+ optional: false
72111
+ }],
72112
+ "dishwasher.pause": [{
72113
+ name: "deviceId",
72114
+ form: "single",
72115
+ optional: false
72116
+ }],
72117
+ "dishwasher.setChildLock": [{
72118
+ name: "deviceId",
72119
+ form: "single",
72120
+ optional: false
72121
+ }],
72122
+ "dishwasher.setExtraDry": [{
72123
+ name: "deviceId",
72124
+ form: "single",
72125
+ optional: false
72126
+ }],
72127
+ "dishwasher.setHalfLoad": [{
72128
+ name: "deviceId",
72129
+ form: "single",
72130
+ optional: false
72131
+ }],
72132
+ "dishwasher.setHygienePlus": [{
72133
+ name: "deviceId",
72134
+ form: "single",
72135
+ optional: false
72136
+ }],
72137
+ "dishwasher.setIntensiveZone": [{
72138
+ name: "deviceId",
72139
+ form: "single",
72140
+ optional: false
72141
+ }],
72142
+ "dishwasher.setOption": [{
72143
+ name: "deviceId",
72144
+ form: "single",
72145
+ optional: false
72146
+ }],
72147
+ "dishwasher.setPower": [{
72148
+ name: "deviceId",
72149
+ form: "single",
72150
+ optional: false
72151
+ }],
72152
+ "dishwasher.setProgram": [{
72153
+ name: "deviceId",
72154
+ form: "single",
72155
+ optional: false
72156
+ }],
72157
+ "dishwasher.setVarioSpeedPlus": [{
72158
+ name: "deviceId",
72159
+ form: "single",
72160
+ optional: false
72161
+ }],
72162
+ "dishwasher.start": [{
72163
+ name: "deviceId",
72164
+ form: "single",
72165
+ optional: false
72166
+ }],
72167
+ "dishwasher.stop": [{
72168
+ name: "deviceId",
72169
+ form: "single",
72170
+ optional: false
72171
+ }],
71004
72172
  "doorbell.getStatus": [{
71005
72173
  name: "deviceId",
71006
72174
  form: "single",
@@ -71070,6 +72238,11 @@ Object.freeze({
71070
72238
  form: "single",
71071
72239
  optional: false
71072
72240
  }],
72241
+ "heatingValve.getStatus": [{
72242
+ name: "deviceId",
72243
+ form: "single",
72244
+ optional: false
72245
+ }],
71073
72246
  "humidifier.getStatus": [{
71074
72247
  name: "deviceId",
71075
72248
  form: "single",
@@ -72354,6 +73527,37 @@ Object.freeze({
72354
73527
  form: "single",
72355
73528
  optional: false
72356
73529
  }],
73530
+ "records.count": [{
73531
+ name: "deviceId",
73532
+ form: "single",
73533
+ optional: true
73534
+ }],
73535
+ "records.deleteDevice": [{
73536
+ name: "deviceId",
73537
+ form: "single",
73538
+ optional: false
73539
+ }],
73540
+ "records.deleteWhere": [{
73541
+ name: "deviceId",
73542
+ form: "single",
73543
+ optional: true
73544
+ }],
73545
+ "records.histogram": [{
73546
+ name: "deviceId",
73547
+ form: "single",
73548
+ optional: true
73549
+ }],
73550
+ "records.putMany": [{
73551
+ name: "records",
73552
+ form: "object-array",
73553
+ optional: false,
73554
+ itemField: "deviceId"
73555
+ }],
73556
+ "records.query": [{
73557
+ name: "deviceId",
73558
+ form: "single",
73559
+ optional: true
73560
+ }],
72357
73561
  "sceneMonitor.captureReference": [{
72358
73562
  name: "deviceId",
72359
73563
  form: "single",
@@ -72470,6 +73674,17 @@ Object.freeze({
72470
73674
  form: "single",
72471
73675
  optional: false
72472
73676
  }],
73677
+ "storageAdmin.adoptRecords": [{
73678
+ name: "records",
73679
+ form: "object-array",
73680
+ optional: false,
73681
+ itemField: "deviceId"
73682
+ }],
73683
+ "storageAdmin.readRecords": [{
73684
+ name: "deviceId",
73685
+ form: "single",
73686
+ optional: true
73687
+ }],
72473
73688
  "streamBroker.acquireEgressTranscode": [{
72474
73689
  name: "deviceId",
72475
73690
  form: "single",