@camstack/addon-provider-rademacher 0.2.127 → 0.2.128

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 +1402 -129
  2. package/dist/addon.mjs +1402 -129
  3. package/package.json +1 -1
package/dist/addon.js CHANGED
@@ -984,7 +984,7 @@ var Rademacher = class {
984
984
  }
985
985
  };
986
986
  //#endregion
987
- //#region ../types/dist/event-category-C4hVnRo8.mjs
987
+ //#region ../types/dist/event-category-BvOFi6PY.mjs
988
988
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
989
989
  EventCategory["SystemBoot"] = "system.boot";
990
990
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -1048,6 +1048,24 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
1048
1048
  * consumes this category and maps it to the `addon-crash-loop` kind.
1049
1049
  */
1050
1050
  EventCategory["AddonRunnerFailed"] = "addon.runner-failed";
1051
+ /**
1052
+ * A runner whose addon refused to start with a typed reason (D877) - parked
1053
+ * in `refused`, never counted by the crash breaker, retried on operator
1054
+ * action. One event per refusal.
1055
+ */
1056
+ EventCategory["AddonRunnerRefused"] = "addon.runner-refused";
1057
+ /**
1058
+ * A runner settled on a state (D877): `running` (READY), `crashed`, `failed` or
1059
+ * `refused`. In-process telemetry for the boot check (re-evaluate while any
1060
+ * runner is still pending) and the alert centre (close a recovered runner).
1061
+ */
1062
+ EventCategory["ProcessStateChanged"] = "process.state-changed";
1063
+ /**
1064
+ * The node's one-shot runner boot check (D877): planned runners against the
1065
+ * process service, `degraded` when any is failed, refused or missing. The
1066
+ * alert centre turns it into one alert and a direct critical push.
1067
+ */
1068
+ EventCategory["SystemRunnerCheck"] = "system.runner-check";
1051
1069
  EventCategory["AddonError"] = "addon.error";
1052
1070
  EventCategory["AddonPageReady"] = "addon.page-ready";
1053
1071
  EventCategory["AddonWidgetReady"] = "addon.widget-ready";
@@ -6372,7 +6390,7 @@ var ZodIssueCode = {
6372
6390
  var ZodFirstPartyTypeKind;
6373
6391
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
6374
6392
  //#endregion
6375
- //#region ../types/dist/sleep-DRqxtc0C.mjs
6393
+ //#region ../types/dist/sleep-BegKjwUu.mjs
6376
6394
  /**
6377
6395
  * The audio chunk plane's byte format, and the ONE expansion from a coded
6378
6396
  * window to float samples (D455).
@@ -6489,7 +6507,7 @@ function isKeychainStoredField(field) {
6489
6507
  var SECRET_CLEAR = { $secretClear: true };
6490
6508
  /** The `'***'` token D634 redaction writes for non-admins. */
6491
6509
  var LEGACY_DEVICE_REDACTION = "***";
6492
- function isRecord$2(value) {
6510
+ function isRecord$5(value) {
6493
6511
  return typeof value === "object" && value !== null && !Array.isArray(value);
6494
6512
  }
6495
6513
  function makeSecretMarker(ref) {
@@ -6500,12 +6518,12 @@ function makeSecretMarker(ref) {
6500
6518
  }
6501
6519
  /** A stored marker: an object whose `$secret` is a non-empty string. */
6502
6520
  function isSecretMarker(value) {
6503
- if (!isRecord$2(value)) return false;
6521
+ if (!isRecord$5(value)) return false;
6504
6522
  const ref = value["$secret"];
6505
6523
  return typeof ref === "string" && ref.length > 0;
6506
6524
  }
6507
6525
  function isSecretClear(value) {
6508
- return isRecord$2(value) && value["$secretClear"] === true;
6526
+ return isRecord$5(value) && value["$secretClear"] === true;
6509
6527
  }
6510
6528
  /**
6511
6529
  * The UI view of a stored secret field value: a marker becomes "set", inline
@@ -7115,7 +7133,7 @@ var KeychainWriteRefusedError = class extends Error {
7115
7133
  }
7116
7134
  };
7117
7135
  var KEEP = { kind: "keep" };
7118
- function isRecord$1(value) {
7136
+ function isRecord$4(value) {
7119
7137
  return typeof value === "object" && value !== null && !Array.isArray(value);
7120
7138
  }
7121
7139
  function defaultMintId() {
@@ -7128,7 +7146,7 @@ function collectSecretMarkerRefs(value, out = []) {
7128
7146
  return out;
7129
7147
  }
7130
7148
  if (Array.isArray(value)) for (const item of value) collectSecretMarkerRefs(item, out);
7131
- else if (isRecord$1(value)) for (const child of Object.values(value)) collectSecretMarkerRefs(child, out);
7149
+ else if (isRecord$4(value)) for (const child of Object.values(value)) collectSecretMarkerRefs(child, out);
7132
7150
  return out;
7133
7151
  }
7134
7152
  async function storedValueEquals(secrets, marker, candidate) {
@@ -7183,7 +7201,7 @@ function rowId(row, idKey) {
7183
7201
  return null;
7184
7202
  }
7185
7203
  async function writeArray(ctx, node, incoming, stored, fieldPath) {
7186
- const storedRows = Array.isArray(stored) ? stored.filter(isRecord$1) : [];
7204
+ const storedRows = Array.isArray(stored) ? stored.filter(isRecord$4) : [];
7187
7205
  if (!Array.isArray(incoming)) {
7188
7206
  ctx.deletes.push(...collectSecretMarkerRefs(storedRows));
7189
7207
  return {
@@ -7199,7 +7217,7 @@ async function writeArray(ctx, node, incoming, stored, fieldPath) {
7199
7217
  const kept = /* @__PURE__ */ new Set();
7200
7218
  const rows = [];
7201
7219
  for (const row of incoming) {
7202
- if (!isRecord$1(row)) {
7220
+ if (!isRecord$4(row)) {
7203
7221
  rows.push(row);
7204
7222
  continue;
7205
7223
  }
@@ -7224,7 +7242,7 @@ async function writeNode(ctx, node, incoming, stored, fieldPath) {
7224
7242
  case "leaf": return writeLeaf(ctx, incoming, stored, fieldPath);
7225
7243
  case "array": return writeArray(ctx, node, incoming, stored, fieldPath);
7226
7244
  case "object": {
7227
- if (!isRecord$1(incoming)) {
7245
+ if (!isRecord$4(incoming)) {
7228
7246
  if (incoming === void 0) return KEEP;
7229
7247
  ctx.deletes.push(...collectSecretMarkerRefs(stored));
7230
7248
  return {
@@ -7232,7 +7250,7 @@ async function writeNode(ctx, node, incoming, stored, fieldPath) {
7232
7250
  value: incoming
7233
7251
  };
7234
7252
  }
7235
- const storedObj = isRecord$1(stored) ? stored : {};
7253
+ const storedObj = isRecord$4(stored) ? stored : {};
7236
7254
  return {
7237
7255
  kind: "value",
7238
7256
  value: await writeMembers(ctx, node.children, incoming, storedObj, (m) => `${fieldPath}.${m}`)
@@ -7355,7 +7373,7 @@ async function resolveSecretMarkers(value, secrets, options = {}) {
7355
7373
  value: items
7356
7374
  };
7357
7375
  }
7358
- if (isRecord$1(v)) {
7376
+ if (isRecord$4(v)) {
7359
7377
  const out = {};
7360
7378
  for (const [k, child] of Object.entries(v)) {
7361
7379
  const s = substitute(child);
@@ -7387,7 +7405,7 @@ var SecretOverwriteRefusedError = class extends Error {
7387
7405
  this.name = "SecretOverwriteRefusedError";
7388
7406
  }
7389
7407
  };
7390
- function isRecord(value) {
7408
+ function isRecord$3(value) {
7391
7409
  return typeof value === "object" && value !== null && !Array.isArray(value);
7392
7410
  }
7393
7411
  function resolvedValue(pass, marker) {
@@ -7416,7 +7434,7 @@ function inArray(pass, incoming, stored) {
7416
7434
  return incoming.map((item, index) => {
7417
7435
  const twin = stored[index];
7418
7436
  if (isSecretMarker(twin)) return typeof item === "string" && item === resolvedValue(pass, twin) ? twin : item;
7419
- if (isRecord(item) && isRecord(twin)) return inArrayRow(pass, item, twin);
7437
+ if (isRecord$3(item) && isRecord$3(twin)) return inArrayRow(pass, item, twin);
7420
7438
  if (Array.isArray(item) && Array.isArray(twin)) return inArray(pass, item, twin);
7421
7439
  return item;
7422
7440
  });
@@ -7427,7 +7445,7 @@ function inArrayRow(pass, incoming, stored) {
7427
7445
  const twin = stored[key];
7428
7446
  if (isSecretMarker(twin)) {
7429
7447
  if (typeof value === "string" && value === resolvedValue(pass, twin)) out[key] = twin;
7430
- } else if (isRecord(value) && isRecord(twin)) out[key] = inArrayRow(pass, value, twin);
7448
+ } else if (isRecord$3(value) && isRecord$3(twin)) out[key] = inArrayRow(pass, value, twin);
7431
7449
  else if (Array.isArray(value) && Array.isArray(twin)) out[key] = inArray(pass, value, twin);
7432
7450
  }
7433
7451
  return out;
@@ -7435,7 +7453,7 @@ function inArrayRow(pass, incoming, stored) {
7435
7453
  async function walk(pass, incoming, stored) {
7436
7454
  if (isSecretMarker(stored)) return atMarker(pass, incoming, stored);
7437
7455
  if (Array.isArray(incoming) && Array.isArray(stored)) return inArray(pass, incoming, stored);
7438
- if (!isRecord(incoming) || !isRecord(stored)) return incoming;
7456
+ if (!isRecord$3(incoming) || !isRecord$3(stored)) return incoming;
7439
7457
  const out = { ...incoming };
7440
7458
  for (const [key, value] of Object.entries(incoming)) out[key] = await walk(pass, value, stored[key]);
7441
7459
  return out;
@@ -7466,7 +7484,7 @@ async function restoreUnchangedSecrets(input) {
7466
7484
  function isJsonEqual(a, b) {
7467
7485
  if (Object.is(a, b)) return true;
7468
7486
  if (Array.isArray(a)) return Array.isArray(b) && a.length === b.length && a.every((v, i) => isJsonEqual(v, b[i]));
7469
- if (isRecord(a) && isRecord(b)) {
7487
+ if (isRecord$3(a) && isRecord$3(b)) {
7470
7488
  const keys = Object.keys(a);
7471
7489
  if (keys.length !== Object.keys(b).length) return false;
7472
7490
  return keys.every((k) => Object.prototype.hasOwnProperty.call(b, k) && isJsonEqual(a[k], b[k]));
@@ -7490,7 +7508,7 @@ function markerKeysOf(blob, owner) {
7490
7508
  }
7491
7509
  function nodeFromStored(value, owner) {
7492
7510
  if (isSecretMarker(value)) return isSecretRefOwnedBy(value.$secret, owner) ? { kind: "leaf" } : null;
7493
- if (!isRecord(value)) return null;
7511
+ if (!isRecord$3(value)) return null;
7494
7512
  const children = /* @__PURE__ */ new Map();
7495
7513
  for (const [key, child] of Object.entries(value)) {
7496
7514
  const node = nodeFromStored(child, owner);
@@ -7623,7 +7641,6 @@ function createHandle(raw, opts) {
7623
7641
  const writeAddon = (patch) => write("addon", opts.addonTree(), void 0, patch, () => readStoredAddonBlob(raw), (p) => raw.writeAddonStore(p));
7624
7642
  const readAddonStoreResult = raw.readAddonStoreResult;
7625
7643
  const readAddonStoreKeyResult = raw.readAddonStoreKeyResult;
7626
- const readDeviceStoreBatch = raw.readDeviceStoreBatch;
7627
7644
  const overrides = {
7628
7645
  readAddonStore: async () => resolveRead("addon", await raw.readAddonStore()),
7629
7646
  ...readAddonStoreResult !== void 0 ? { readAddonStoreResult: async () => {
@@ -7647,12 +7664,12 @@ function createHandle(raw, opts) {
7647
7664
  };
7648
7665
  } } : {},
7649
7666
  readDeviceStore: async (deviceId) => resolveRead(`device:${deviceId}`, await raw.readDeviceStore(deviceId)),
7650
- ...readDeviceStoreBatch !== void 0 ? { readDeviceStoreBatch: async (deviceIds) => {
7651
- const rows = await readDeviceStoreBatch.call(raw, deviceIds);
7667
+ readDeviceStoreBatch: async (deviceIds) => {
7668
+ const rows = await raw.readDeviceStoreBatch(deviceIds);
7652
7669
  const out = /* @__PURE__ */ new Map();
7653
7670
  for (const [deviceId, blob] of rows) out.set(deviceId, await resolveRead(`device:${deviceId}`, blob));
7654
7671
  return out;
7655
- } } : {},
7672
+ },
7656
7673
  writeAddonStore: async (patch) => {
7657
7674
  await writeAddon(patch);
7658
7675
  },
@@ -8279,7 +8296,7 @@ var BaseAddon = class {
8279
8296
  if (!ctx) return;
8280
8297
  const addonId = ctx.id;
8281
8298
  setImmediate(() => {
8282
- ctx.api.addons?.restartAddon?.mutate({ addonId }).then(() => {
8299
+ ctx.api.addons.restartAddon.mutate({ addonId }).then(() => {
8283
8300
  ctx.logger.info("addon auto-restart triggered by restart-required setting change", { meta: { changedFields: patchKeys.filter((k) => restartKeys.has(k)) } });
8284
8301
  }).catch((err) => {
8285
8302
  ctx.logger.error("addon auto-restart failed", { meta: { error: err instanceof Error ? err.message : String(err) } });
@@ -8479,7 +8496,7 @@ var BaseAddon = class {
8479
8496
  return this._addonSecretTree;
8480
8497
  }
8481
8498
  deviceSecretTree() {
8482
- this._deviceSecretTree ??= secretTreeFromSchema(this.deviceSettingsSchema());
8499
+ this._deviceSecretTree ??= mergeSecretStatePaths(secretTreeFromSchema(this.deviceSettingsSchema()), this.secretStatePaths);
8483
8500
  return this._deviceSecretTree;
8484
8501
  }
8485
8502
  /**
@@ -8555,42 +8572,135 @@ var BaseAddon = class {
8555
8572
  this[timerOf] = timer;
8556
8573
  }
8557
8574
  /**
8558
- * Wrap `ctx.settings.readAddonStore()` with a short retry budget so a
8559
- * transient settings-store outage (mid-restart of sqlite-settings, tsx-watch
8560
- * swap, or any race where the SqliteSettingsBackend is between shutdown and
8561
- * re-initialize) doesn't propagate up into `initialize()` and leave the
8575
+ * Wrap `ctx.settings.readAddonStore()` with a retry budget so a transient
8576
+ * settings-store outage doesn't propagate up into `initialize()` and leave the
8562
8577
  * addon permanently broken.
8563
8578
  *
8564
- * Retry only the two known infra fingerprints. Anything else propagates so
8565
- * real bugs surface immediately. After the budget expires we fall back to
8566
- * `{}` (defaults) — the addon's first successful patch will rehydrate.
8579
+ * Two kinds of outage, two budgets:
8580
+ * - the store's own restart fingerprints (`SqliteSettingsBackend not
8581
+ * initialized`, `provider not available`): a short budget, then the addon
8582
+ * falls back to `{}` (defaults) - its first successful patch rehydrates;
8583
+ * - a TRANSPORT failure (the hub is restarting while this runner boots:
8584
+ * `discovery deadline exceeded`, `parent could not route`, a refused or
8585
+ * timed-out connection). Since D870 a runner's settings read THROWS instead
8586
+ * of answering `{}`, so without a budget a hub restart ends in a respawn
8587
+ * loop. A long, bounded budget; only after it the error propagates - the
8588
+ * addon never runs on defaults for a store it could not ask.
8589
+ * Anything else propagates immediately so real bugs surface.
8567
8590
  */
8568
8591
  async readAddonStoreWithRetry() {
8569
8592
  const settings = this.rawSettings();
8570
8593
  if (!settings) return {};
8571
- const delaysMs = [
8572
- 150,
8573
- 350,
8574
- 600,
8575
- 900
8576
- ];
8577
8594
  let lastErr;
8578
- for (let attempt = 0; attempt <= delaysMs.length; attempt++) try {
8595
+ for (let attempt = 0;; attempt++) try {
8579
8596
  const stored = await settings.readAddonStore() ?? {};
8580
8597
  this.settingsStoreReady = true;
8581
8598
  return stored;
8582
8599
  } catch (err) {
8583
8600
  lastErr = err;
8584
- const msg = err instanceof Error ? err.message : String(err);
8585
- if (!(msg.includes("SqliteSettingsBackend not initialized") || msg.includes("provider not available"))) throw err;
8586
- if (attempt === delaysMs.length) break;
8587
- await new Promise((r) => setTimeout(r, delaysMs[attempt]));
8601
+ const kind = classifyStoreError(err);
8602
+ if (kind === "permanent") throw err;
8603
+ const delay = (kind === "transport" ? TRANSPORT_RETRY_DELAYS_MS : RESTART_RETRY_DELAYS_MS)[attempt];
8604
+ if (delay === void 0) {
8605
+ if (kind === "transport") throw err;
8606
+ break;
8607
+ }
8608
+ await new Promise((r) => setTimeout(r, delay));
8588
8609
  }
8589
8610
  this.settingsStoreReady = false;
8590
8611
  this._ctx?.logger?.warn?.("readAddonStore: settings-store unavailable after retries — using defaults", { meta: { error: lastErr instanceof Error ? lastErr.message : String(lastErr) } });
8591
8612
  return {};
8592
8613
  }
8593
8614
  };
8615
+ /** The settings store's own restart fingerprints. */
8616
+ var RESTART_RETRY_DELAYS_MS = [
8617
+ 150,
8618
+ 350,
8619
+ 600,
8620
+ 900
8621
+ ];
8622
+ /** A hub restarting under a booting runner: ~100 s in total. */
8623
+ var TRANSPORT_RETRY_DELAYS_MS = [
8624
+ 150,
8625
+ 350,
8626
+ 600,
8627
+ 900,
8628
+ 2e3,
8629
+ 5e3,
8630
+ 1e4,
8631
+ 2e4,
8632
+ 3e4,
8633
+ 3e4
8634
+ ];
8635
+ var RESTART_FINGERPRINTS = ["SqliteSettingsBackend not initialized", "provider not available"];
8636
+ /** Node / socket error codes of a connection that did not happen or broke. */
8637
+ var TRANSPORT_CODES = new Set([
8638
+ "ECONNREFUSED",
8639
+ "ECONNRESET",
8640
+ "ETIMEDOUT",
8641
+ "EPIPE",
8642
+ "EHOSTUNREACH",
8643
+ "ENETUNREACH"
8644
+ ]);
8645
+ /** tRPC error codes that mean "the other side is not answering now", not "your call is wrong". */
8646
+ var UNAVAILABLE_TRPC_CODES = new Set([
8647
+ "TIMEOUT",
8648
+ "SERVICE_UNAVAILABLE",
8649
+ "BAD_GATEWAY",
8650
+ "GATEWAY_TIMEOUT"
8651
+ ]);
8652
+ /** The exact phrases OUR transport raises when it cannot reach the hub. */
8653
+ var TRANSPORT_PHRASES = [
8654
+ "discovery deadline exceeded",
8655
+ "parent could not route child unowned cap call",
8656
+ "UDS request timed out after",
8657
+ "channel closed"
8658
+ ];
8659
+ /** Moleculer error `type`s of a call that could not be served right now. */
8660
+ var MOLECULER_TRANSIENT_TYPES = new Set([
8661
+ "REQUEST_TIMEOUT",
8662
+ "SERVICE_NOT_FOUND",
8663
+ "SERVICE_NOT_AVAILABLE",
8664
+ "REQUEST_REJECTED",
8665
+ "BROKER_DISCONNECTED"
8666
+ ]);
8667
+ function stringProp(value, key) {
8668
+ if (typeof value !== "object" || value === null) return void 0;
8669
+ const found = Reflect.get(value, key);
8670
+ return typeof found === "string" ? found : void 0;
8671
+ }
8672
+ /** The code an error carries: its own, its cause's, or a tRPC `data.code`. */
8673
+ function errorCode(err) {
8674
+ const out = {};
8675
+ const cause = typeof err === "object" && err !== null ? Reflect.get(err, "cause") : void 0;
8676
+ const data = typeof err === "object" && err !== null ? Reflect.get(err, "data") : void 0;
8677
+ const node = stringProp(err, "code") ?? stringProp(cause, "code");
8678
+ if (node !== void 0) out.node = node;
8679
+ const trpc = stringProp(data, "code");
8680
+ if (trpc !== void 0) out.trpc = trpc;
8681
+ return out;
8682
+ }
8683
+ /**
8684
+ * Is a settings read failure worth retrying, and with which budget? Only
8685
+ * EXPLICIT signals count: a socket error code, a tRPC "unavailable" code, or
8686
+ * one of the exact phrases our own transport raises. A message that merely
8687
+ * contains "timed out" or "unreachable" is not evidence of anything, and
8688
+ * `settings store not wired` is a wiring bug that retrying cannot fix.
8689
+ */
8690
+ function classifyStoreError(err) {
8691
+ const message = err instanceof Error ? err.message : String(err);
8692
+ if (RESTART_FINGERPRINTS.some((f) => message.includes(f))) return "restart";
8693
+ const code = errorCode(err);
8694
+ if (code.node !== void 0 && TRANSPORT_CODES.has(code.node)) return "transport";
8695
+ if (code.trpc !== void 0 && UNAVAILABLE_TRPC_CODES.has(code.trpc)) return "transport";
8696
+ if (typeof err === "object" && err !== null) {
8697
+ if (Reflect.get(err, "retryable") === true) return "transport";
8698
+ const type = stringProp(err, "type");
8699
+ if (type !== void 0 && MOLECULER_TRANSIENT_TYPES.has(type)) return "transport";
8700
+ }
8701
+ if (TRANSPORT_PHRASES.some((f) => message.includes(f))) return "transport";
8702
+ return "permanent";
8703
+ }
8594
8704
  /**
8595
8705
  * Collect the keys of every field marked `perNode: true`, recursing into
8596
8706
  * layout containers (`group` fields and `sub-tabs` tabs) the same way
@@ -8680,6 +8790,156 @@ var PeerBytesTicketSchema = object({
8680
8790
  */
8681
8791
  declaredBytes: number().int().nonnegative().nullable()
8682
8792
  });
8793
+ /** Limits and names of `ctx.records` (D881). One authority; the engine and the facade read it. */
8794
+ /** The files a kind may live in. `history` is device-history's (D850), never records. */
8795
+ var RECORD_DATABASES = ["settings", "events"];
8796
+ /** The classes of a kind: the `@durable` vocabulary, one authority (replaces the annotation). */
8797
+ var RECORD_CLASSES = [
8798
+ "config",
8799
+ "ledger",
8800
+ "audit",
8801
+ "mirror",
8802
+ "ephemeral"
8803
+ ];
8804
+ var RECORD_DEFAULT_MAX_DATA_BYTES = 64 * 1024;
8805
+ var RECORD_MAX_DATA_BYTES = 1024 * 1024;
8806
+ var RECORD_BATCH_MAX = 1e3;
8807
+ var RECORD_QUERY_MAX = 1e3;
8808
+ function defOf(schema) {
8809
+ const zodBag = Reflect.get(schema, "_zod");
8810
+ if (typeof zodBag !== "object" || zodBag === null) return {};
8811
+ const def = Reflect.get(zodBag, "def");
8812
+ if (typeof def !== "object" || def === null) return {};
8813
+ return def;
8814
+ }
8815
+ function declaredHere(schema) {
8816
+ return globalRegistry.get(schema)?.secret === true;
8817
+ }
8818
+ /** Wrapper kinds whose `innerType` is the field itself. */
8819
+ var WRAPPERS = new Set([
8820
+ "optional",
8821
+ "nullable",
8822
+ "default",
8823
+ "prefault",
8824
+ "catch",
8825
+ "readonly",
8826
+ "nonoptional"
8827
+ ]);
8828
+ /**
8829
+ * The schema layers that make up ONE field: the schema itself and every
8830
+ * wrapper below it (optional / default / nullable / readonly / catch), plus
8831
+ * both sides of a pipe (`z.preprocess` puts the real schema on `out`,
8832
+ * `.transform` on `in`).
8833
+ */
8834
+ function layersOf(schema) {
8835
+ const out = [];
8836
+ const queue = [schema];
8837
+ while (queue.length > 0) {
8838
+ const s = queue.shift();
8839
+ if (!s || out.includes(s)) continue;
8840
+ out.push(s);
8841
+ const def = defOf(s);
8842
+ if (def.type !== void 0 && WRAPPERS.has(def.type) && def.innerType) queue.push(def.innerType);
8843
+ if (def.type === "pipe") {
8844
+ if (def.in) queue.push(def.in);
8845
+ if (def.out) queue.push(def.out);
8846
+ }
8847
+ }
8848
+ return out;
8849
+ }
8850
+ /** True when any layer of this field declares `.meta({ secret: true })`. */
8851
+ function isZodSecret(schema) {
8852
+ return layersOf(schema).some(declaredHere);
8853
+ }
8854
+ /**
8855
+ * Every declared secret path in a config schema: dotted keys, `[]` for "each
8856
+ * element of this array" (`connection.password`, `rows[].token`). A declared
8857
+ * object or array is reported as one path and not descended into — everything
8858
+ * under it is secret.
8859
+ */
8860
+ function collectZodSecretPaths(schema, prefix = "") {
8861
+ if (isZodSecret(schema)) return prefix.length > 0 ? [prefix] : [];
8862
+ const paths = [];
8863
+ for (const layer of layersOf(schema)) {
8864
+ const def = defOf(layer);
8865
+ if (def.type === "object" && def.shape) for (const [key, child] of Object.entries(def.shape)) paths.push(...collectZodSecretPaths(child, prefix ? `${prefix}.${key}` : key));
8866
+ else if (def.type === "array" && def.element) paths.push(...collectZodSecretPaths(def.element, `${prefix}[]`));
8867
+ else if (def.type === "union" && def.options) for (const option of def.options) paths.push(...collectZodSecretPaths(option, prefix));
8868
+ else if (def.type === "intersection") {
8869
+ if (def.left) paths.push(...collectZodSecretPaths(def.left, prefix));
8870
+ if (def.right) paths.push(...collectZodSecretPaths(def.right, prefix));
8871
+ }
8872
+ }
8873
+ return [...new Set(paths)];
8874
+ }
8875
+ /**
8876
+ * Record kinds (D881): the declaration an addon makes of one kind of fact, the
8877
+ * Zod row schema that describes it, and the helper that turns the two into the
8878
+ * JSON the engine stores.
8879
+ *
8880
+ * A kind is declared ONCE, next to the code that owns it, and the engine's
8881
+ * reconciler creates its indexes - nothing creates DDL at runtime from a write.
8882
+ * Everything the generic machinery needs (secret fields, the entry descriptor)
8883
+ * is DERIVED from the Zod schema: `.meta({ secret: true })` marks a credential,
8884
+ * never a field name (D879).
8885
+ */
8886
+ /** A JSON field path: `trackId`, `auth.accessToken`. Charset-restricted: it is rendered into DDL. */
8887
+ var RecordFieldPathSchema = string().regex(/^[A-Za-z_][A-Za-z0-9_]{0,63}(\.[A-Za-z_][A-Za-z0-9_]{0,63}){0,3}$/);
8888
+ var RecordIndexSchema = object({
8889
+ name: string().regex(/^[a-z][a-z0-9_]{0,31}$/),
8890
+ fields: array(RecordFieldPathSchema).min(1).max(4),
8891
+ unique: boolean().optional()
8892
+ }).strict();
8893
+ var RecordRetentionSchema = union([
8894
+ object({
8895
+ ttlMs: number().int().positive(),
8896
+ from: _enum(["at", "write"])
8897
+ }).strict(),
8898
+ object({
8899
+ maxRows: number().int().positive().optional(),
8900
+ maxRowsPerDevice: number().int().positive().optional()
8901
+ }).strict().refine((r) => r.maxRows !== void 0 || r.maxRowsPerDevice !== void 0, { message: "name maxRows, maxRowsPerDevice or both" }),
8902
+ object({
8903
+ owner: string().min(1),
8904
+ reason: string().min(1)
8905
+ }).strict(),
8906
+ object({ none: string().min(1) }).strict()
8907
+ ]);
8908
+ /** The descriptor a generic entries UI reads (D881 "generic entries"). */
8909
+ var EntryDescriptorSchema = object({
8910
+ title: string().min(1),
8911
+ /** The record body field shown as the entry's name. */
8912
+ nameField: string().min(1),
8913
+ /** JSON Schema of the entry body; `secret: true` marks a password field. */
8914
+ fields: record(string(), unknown())
8915
+ }).strict();
8916
+ /** What crosses the wire and sits in the engine's catalog: JSON only, no Zod. */
8917
+ var RecordKindDeclarationSchema = object({
8918
+ database: _enum(RECORD_DATABASES).default("settings"),
8919
+ class: _enum(RECORD_CLASSES),
8920
+ writeTrigger: string().min(1),
8921
+ device: _enum([
8922
+ "required",
8923
+ "optional",
8924
+ "none"
8925
+ ]).default("none"),
8926
+ at: _enum(["required", "none"]).default("none"),
8927
+ indexes: array(RecordIndexSchema).max(8).default([]),
8928
+ retention: RecordRetentionSchema,
8929
+ deviceRemoval: _enum(["delete", "none"]).default("none"),
8930
+ maxDataBytes: number().int().positive().max(RECORD_MAX_DATA_BYTES).default(RECORD_DEFAULT_MAX_DATA_BYTES),
8931
+ /** Derived from the Zod schema; never written by hand. */
8932
+ secretPaths: array(string().min(1)).default([]),
8933
+ /** The id key of each array that carries a secret (`{ headers: 'name' }`). */
8934
+ secretArrayKeys: record(string(), string()).default({}),
8935
+ /** The legacy table this kind adopts from; the boot guard reads it (D853: no migration code). */
8936
+ adoptsFrom: string().min(1).optional(),
8937
+ /** Kinds that must agree through `transact` sit in one file under one family name. */
8938
+ transactFamily: string().min(1).optional(),
8939
+ entry: EntryDescriptorSchema.optional()
8940
+ }).strict();
8941
+ /** The kind names: lower-case, dash separated, short enough for an index name. */
8942
+ var RecordKindNameSchema = string().regex(/^[a-z][a-z0-9-]{0,47}$/);
8683
8943
  /** Shared Zod schemas used across streaming capabilities. */
8684
8944
  var CamProfileSchema = _enum([
8685
8945
  "high",
@@ -9144,75 +9404,12 @@ method(object({ deviceId: number() }), array(StreamSourceEntrySchema)), method(o
9144
9404
  kind: "mutation",
9145
9405
  auth: "admin"
9146
9406
  }), method(object({ deviceId: number() }), unknown().nullable()), method(object({ deviceId: number() }), RawStateResultSchema.nullable(), { auth: "protected" });
9147
- function defOf(schema) {
9148
- return schema._zod?.def ?? {};
9149
- }
9150
- function declaredHere(schema) {
9151
- return globalRegistry.get(schema)?.secret === true;
9152
- }
9153
- /** Wrapper kinds whose `innerType` is the field itself. */
9154
- var WRAPPERS = new Set([
9155
- "optional",
9156
- "nullable",
9157
- "default",
9158
- "prefault",
9159
- "catch",
9160
- "readonly",
9161
- "nonoptional"
9162
- ]);
9163
- /**
9164
- * The schema layers that make up ONE field: the schema itself and every
9165
- * wrapper below it (optional / default / nullable / readonly / catch), plus
9166
- * both sides of a pipe (`z.preprocess` puts the real schema on `out`,
9167
- * `.transform` on `in`).
9168
- */
9169
- function layersOf(schema) {
9170
- const out = [];
9171
- const queue = [schema];
9172
- while (queue.length > 0) {
9173
- const s = queue.shift();
9174
- if (!s || out.includes(s)) continue;
9175
- out.push(s);
9176
- const def = defOf(s);
9177
- if (def.type !== void 0 && WRAPPERS.has(def.type) && def.innerType) queue.push(def.innerType);
9178
- if (def.type === "pipe") {
9179
- if (def.in) queue.push(def.in);
9180
- if (def.out) queue.push(def.out);
9181
- }
9182
- }
9183
- return out;
9184
- }
9185
- /** True when any layer of this field declares `.meta({ secret: true })`. */
9186
- function isZodSecret(schema) {
9187
- return layersOf(schema).some(declaredHere);
9188
- }
9189
- /**
9190
- * Every declared secret path in a config schema: dotted keys, `[]` for "each
9191
- * element of this array" (`connection.password`, `rows[].token`). A declared
9192
- * object or array is reported as one path and not descended into — everything
9193
- * under it is secret.
9194
- */
9195
- function collectZodSecretPaths(schema, prefix = "") {
9196
- if (isZodSecret(schema)) return prefix.length > 0 ? [prefix] : [];
9197
- const paths = [];
9198
- for (const layer of layersOf(schema)) {
9199
- const def = defOf(layer);
9200
- if (def.type === "object" && def.shape) for (const [key, child] of Object.entries(def.shape)) paths.push(...collectZodSecretPaths(child, prefix ? `${prefix}.${key}` : key));
9201
- else if (def.type === "array" && def.element) paths.push(...collectZodSecretPaths(def.element, `${prefix}[]`));
9202
- else if (def.type === "union" && def.options) for (const option of def.options) paths.push(...collectZodSecretPaths(option, prefix));
9203
- else if (def.type === "intersection") {
9204
- if (def.left) paths.push(...collectZodSecretPaths(def.left, prefix));
9205
- if (def.right) paths.push(...collectZodSecretPaths(def.right, prefix));
9206
- }
9207
- }
9208
- return [...new Set(paths)];
9209
- }
9210
9407
  object({
9211
9408
  code: string().regex(/^[a-z][a-z0-9-]*(\.[a-z0-9-]+)+$/),
9212
9409
  params: record(string(), union([string(), number()])).optional()
9213
9410
  });
9214
9411
  //#endregion
9215
- //#region ../types/dist/err-msg-DLerKiVO.mjs
9412
+ //#region ../types/dist/err-msg-BXKzRBwg.mjs
9216
9413
  var DeviceType = /* @__PURE__ */ function(DeviceType) {
9217
9414
  DeviceType["Camera"] = "camera";
9218
9415
  DeviceType["Hub"] = "hub";
@@ -9304,6 +9501,10 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
9304
9501
  * native PetKit (`nodepetkit` `FeederDevice`), reusable by other feeder
9305
9502
  * integrations sharing the same food/desiccant/hopper surface. */
9306
9503
  DeviceType["PetFeeder"] = "pet-feeder";
9504
+ /** Built-in dishwasher — program lifecycle, door / remote-start gates,
9505
+ * salt and rinse-aid levels. Installed with the `dishwasher` cap.
9506
+ * Sources: native Bosch Home Connect, reusable by similar integrations. */
9507
+ DeviceType["Dishwasher"] = "dishwasher";
9307
9508
  return DeviceType;
9308
9509
  }({});
9309
9510
  var DeviceFeature = /* @__PURE__ */ function(DeviceFeature) {
@@ -9481,6 +9682,9 @@ var DeviceRole = /* @__PURE__ */ function(DeviceRole) {
9481
9682
  /** Virtual HA toggle (input_boolean.*) — distinguishable from a
9482
9683
  * real Switch device for UI rendering / export adapters. */
9483
9684
  DeviceRole["BinaryHelper"] = "binary-helper";
9685
+ /** A smart plug: a `switch` whose source says it is an outlet (HA
9686
+ * `device_class: outlet`). The Alexa export shows it as a SMARTPLUG. */
9687
+ DeviceRole["Outlet"] = "outlet";
9484
9688
  /** Generic motion / occupancy / moving event source. Distinct from
9485
9689
  * the camera accessory PirSensor role: that one is a camera child;
9486
9690
  * this is a standalone HA / 3rd-party motion sensor. */
@@ -9558,7 +9762,7 @@ function errMsg(err) {
9558
9762
  return String(err);
9559
9763
  }
9560
9764
  //#endregion
9561
- //#region ../types/dist/composition-EQ9Ok0Ee.mjs
9765
+ //#region ../types/dist/composition-CB6PMT9p.mjs
9562
9766
  /**
9563
9767
  * The ffmpeg build every CamStack node downloads, per platform and arch.
9564
9768
  *
@@ -12762,11 +12966,10 @@ var ClipModelMetaSchema = object({
12762
12966
  /**
12763
12967
  * The `vector-store` index this model's vectors live in. ONE feature space
12764
12968
  * per index: two models share an index only when their vectors are ranked
12765
- * against each other, which for CLIP means never across families. MobileCLIP
12766
- * S1 and S2 share `object-clip` for history (separated by the row's
12767
- * `modelId`); any other model gets its own.
12969
+ * against each other, which for CLIP means never across families. Every
12970
+ * model gets its own.
12768
12971
  */
12769
- vectorIndex: string().regex(/^object-clip(-[a-z0-9][a-z0-9-]*)?$/),
12972
+ vectorIndex: string().regex(/^object-clip-[a-z0-9][a-z0-9-]*$/),
12770
12973
  /**
12771
12974
  * The text encoder's tokenizer, a declared SIBLING file of its onnx. The name
12772
12975
  * must be unique per tokenizer: every model's siblings land in ONE flat
@@ -13945,8 +14148,13 @@ var AlertSeveritySchema = _enum([
13945
14148
  "info",
13946
14149
  "success",
13947
14150
  "warning",
13948
- "error"
14151
+ "error",
14152
+ "critical"
13949
14153
  ]);
14154
+ var AlertActionSchema = object({
14155
+ label: string(),
14156
+ href: string().optional()
14157
+ });
13950
14158
  var AlertStatusSchema = _enum([
13951
14159
  "active",
13952
14160
  "in-progress",
@@ -13964,6 +14172,7 @@ var AlertSchema = object({
13964
14172
  severity: AlertSeveritySchema,
13965
14173
  title: string(),
13966
14174
  message: string(),
14175
+ action: AlertActionSchema.optional(),
13967
14176
  status: AlertStatusSchema,
13968
14177
  progress: number().optional(),
13969
14178
  read: boolean(),
@@ -16499,6 +16708,41 @@ var ComposableCapabilitiesSchema = object({ caps: array(object({
16499
16708
  keyField: string()
16500
16709
  }).optional()
16501
16710
  })) });
16711
+ /**
16712
+ * The report of a one-shot "move this owner's plaintext secrets into the
16713
+ * keychain" run (D878). COUNTS only - never a value, never a ref.
16714
+ *
16715
+ * The owner runs it on its own rows, through its own write path; an operator
16716
+ * script (`scripts/hub/migrate-raw-secrets.ts`) calls the owner's cap method.
16717
+ * Dry run (`apply: false`) reports what WOULD move and changes nothing.
16718
+ */
16719
+ var RawSecretMigrationInputSchema = object({
16720
+ /** `false` (the default of the script) = report only. */
16721
+ apply: boolean() });
16722
+ var RawSecretMigrationReportSchema = object({
16723
+ apply: boolean(),
16724
+ /** Rows that can carry a secret (a profile, an enrolment). */
16725
+ rows: number().int(),
16726
+ /** Rows whose secret was plaintext when the run started. */
16727
+ raw: number().int(),
16728
+ /** Rows that already held a keychain marker when the run started. */
16729
+ markers: number().int(),
16730
+ /** Plaintext rows moved by THIS run (always 0 on a dry run). */
16731
+ migrated: number().int(),
16732
+ /** Plaintext rows left in place because the move or its read-back failed. */
16733
+ failed: number().int(),
16734
+ /** After the run: rows still holding plaintext. */
16735
+ remainingRaw: number().int(),
16736
+ /** After the run: markers the keychain could not resolve right now. */
16737
+ unresolvedMarkers: number().int(),
16738
+ /**
16739
+ * A second, redundant copy of the secrets' rows that the run found (and, on
16740
+ * `apply`, deleted after verifying the first). Owners with a single copy omit it.
16741
+ */
16742
+ redundantCopies: number().int().optional(),
16743
+ /** True when nothing is raw and every marker resolves. */
16744
+ verified: boolean()
16745
+ });
16502
16746
  /** Where a block runs. The operator chooses — a block driving a device on an
16503
16747
  * agent is the reason placement is not fixed to the hub. */
16504
16748
  var CoreBlockPlacementSchema = union([literal("hub"), string().min(1)]);
@@ -16725,6 +16969,9 @@ method(object({}), object({ blocks: array(CoreBlockSchema) }), { auth: "admin" }
16725
16969
  }), SettingsUpdateResultSchema, {
16726
16970
  kind: "mutation",
16727
16971
  auth: "admin"
16972
+ }), method(RawSecretMigrationInputSchema, RawSecretMigrationReportSchema, {
16973
+ kind: "mutation",
16974
+ auth: "admin"
16728
16975
  }), method(object({}), object({ libs: array(object({
16729
16976
  filePath: string(),
16730
16977
  content: string()
@@ -16988,6 +17235,347 @@ id: union([string(), number()]) }), {
16988
17235
  auth: "admin"
16989
17236
  });
16990
17237
  /**
17238
+ * records - an addon's own facts and documents (D881): ledgers, audit rows,
17239
+ * config documents, mirrors. The third storage API next to `ctx.settings`
17240
+ * (operator intent, D870) and device-history (numbers over time, D850).
17241
+ *
17242
+ * Who the OWNER is: `callerAddonId`, stamped by the transport on a call that
17243
+ * crossed a process and stated by a hub in-process caller (`ctx.records` does
17244
+ * that with the addon id closed over). It is deliberately NOT in any input
17245
+ * schema, so a session can never supply it, and a call with no stamp is refused
17246
+ * `records/no-caller`. A kind is readable and writable only by its owner; other
17247
+ * addons go through the owner's capability.
17248
+ *
17249
+ * Every read is three-way: a row, `null`, or the call THROWS. A failed read is
17250
+ * never `[]`. Secret fields are never on the wire: a read shows the
17251
+ * redaction token, `secretRefs` hands the owner's `ctx.secrets` the refs it
17252
+ * resolves itself, and a write may carry only a keychain marker bound to the
17253
+ * row's own ref.
17254
+ *
17255
+ * Internal: addons reach it through `ctx.records`, never directly.
17256
+ */
17257
+ var RecordIdSchema = string().min(1).max(256);
17258
+ /** A JSON object body. Size is the engine's check (`maxDataBytes`), not a schema's. */
17259
+ var RecordBodySchema = record(string(), unknown());
17260
+ var RecordInputSchema = object({
17261
+ id: RecordIdSchema,
17262
+ /** The device this row belongs to (D865 removal, per-device reads). */
17263
+ deviceId: number().int().optional(),
17264
+ /** The domain clock, ms: observed / created / opened. */
17265
+ at: number().int().optional(),
17266
+ /** Producer-set expiry, ms. Refused on a kind whose retention is an engine TTL. */
17267
+ expiresAt: number().int().optional(),
17268
+ data: RecordBodySchema
17269
+ });
17270
+ var RecordViewSchema = object({
17271
+ id: string(),
17272
+ deviceId: number().int().nullable(),
17273
+ at: number().nullable(),
17274
+ expiresAt: number().nullable(),
17275
+ rev: number().int(),
17276
+ updatedAt: number(),
17277
+ data: RecordBodySchema
17278
+ });
17279
+ /** Declared index fields only. Anything else does not compile, by design. */
17280
+ var RecordWhereSchema = record(RecordFieldPathSchema, union([
17281
+ string(),
17282
+ number(),
17283
+ boolean(),
17284
+ object({ in: array(union([
17285
+ string(),
17286
+ number(),
17287
+ boolean()
17288
+ ])).min(1).max(RECORD_BATCH_MAX) }),
17289
+ object({
17290
+ gt: union([string(), number()]).optional(),
17291
+ gte: union([string(), number()]).optional(),
17292
+ lt: union([string(), number()]).optional(),
17293
+ lte: union([string(), number()]).optional()
17294
+ }).refine((r) => Object.keys(r).length > 0, { message: "name at least one bound" })
17295
+ ]));
17296
+ var KindShape = { kind: RecordKindNameSchema };
17297
+ var TimeWindowShape = {
17298
+ deviceId: number().int().optional(),
17299
+ atFrom: number().optional(),
17300
+ atTo: number().optional()
17301
+ };
17302
+ var RecordQueryInputSchema = object({
17303
+ ...KindShape,
17304
+ ...TimeWindowShape,
17305
+ where: RecordWhereSchema.optional(),
17306
+ /** Without `where`: `at` (default for a kind with a clock) or `id`. With `where` the order is the index's. */
17307
+ order: _enum(["at", "id"]).optional(),
17308
+ desc: boolean().optional(),
17309
+ limit: number().int().min(1).max(RECORD_QUERY_MAX).default(100),
17310
+ /** Opaque keyset cursor from a previous answer. There is no offset. */
17311
+ cursor: string().min(1).optional()
17312
+ });
17313
+ var RecordQueryResultSchema = object({
17314
+ records: array(RecordViewSchema),
17315
+ nextCursor: string().nullable()
17316
+ });
17317
+ var RecordKindStateSchema = _enum([
17318
+ "created",
17319
+ "unchanged",
17320
+ "updated"
17321
+ ]);
17322
+ var DeclareKindResultSchema = object({
17323
+ kindId: number().int(),
17324
+ state: RecordKindStateSchema,
17325
+ createdIndexes: array(string()),
17326
+ /** The boot guard: the kind is empty while its legacy table still holds rows. */
17327
+ adoptionPending: object({
17328
+ legacyTable: string(),
17329
+ legacyRows: number().int()
17330
+ }).nullable()
17331
+ });
17332
+ /** Keychain refs a write released (the old marker is gone from the row): the owner deletes the values. */
17333
+ var SecretRefsList = array(string());
17334
+ var RecordSecretRefsSchema = record(string(), record(string(), string()));
17335
+ method(object({ kinds: record(RecordKindNameSchema, RecordKindDeclarationSchema) }), object({ kinds: record(string(), DeclareKindResultSchema) }), {
17336
+ kind: "mutation",
17337
+ auth: "admin"
17338
+ }), method(object({
17339
+ ...KindShape,
17340
+ id: RecordIdSchema
17341
+ }), RecordViewSchema.nullable(), { auth: "admin" }), method(object({
17342
+ ...KindShape,
17343
+ ids: array(RecordIdSchema).min(1).max(RECORD_BATCH_MAX)
17344
+ }), array(RecordViewSchema), { auth: "admin" }), method(object({
17345
+ ...KindShape,
17346
+ ids: array(RecordIdSchema).min(1).max(RECORD_BATCH_MAX)
17347
+ }), RecordSecretRefsSchema, { auth: "admin" }), method(object({
17348
+ ...KindShape,
17349
+ record: RecordInputSchema,
17350
+ /** Compare-and-set. `0` means "the row must not exist". */
17351
+ ifRev: number().int().min(0).optional()
17352
+ }), object({
17353
+ rev: number().int(),
17354
+ releasedRefs: SecretRefsList
17355
+ }), {
17356
+ kind: "mutation",
17357
+ auth: "admin"
17358
+ }), method(object({
17359
+ ...KindShape,
17360
+ records: array(RecordInputSchema).min(1).max(RECORD_BATCH_MAX)
17361
+ }), object({
17362
+ count: number().int(),
17363
+ releasedRefs: SecretRefsList
17364
+ }), {
17365
+ kind: "mutation",
17366
+ auth: "admin"
17367
+ }), method(object({
17368
+ ...KindShape,
17369
+ id: RecordIdSchema,
17370
+ data: RecordBodySchema,
17371
+ at: number().int().nullable().optional(),
17372
+ expiresAt: number().int().nullable().optional(),
17373
+ ifRev: number().int().min(1).optional()
17374
+ }), object({
17375
+ rev: number().int(),
17376
+ releasedRefs: SecretRefsList
17377
+ }), {
17378
+ kind: "mutation",
17379
+ auth: "admin"
17380
+ }), method(object({
17381
+ ...KindShape,
17382
+ id: RecordIdSchema
17383
+ }), object({
17384
+ deleted: boolean(),
17385
+ secretRefs: SecretRefsList
17386
+ }), {
17387
+ kind: "mutation",
17388
+ auth: "admin"
17389
+ }), method(object({
17390
+ ...KindShape,
17391
+ ids: array(RecordIdSchema).min(1).max(RECORD_BATCH_MAX)
17392
+ }), object({
17393
+ deleted: number().int(),
17394
+ secretRefs: SecretRefsList
17395
+ }), {
17396
+ kind: "mutation",
17397
+ auth: "admin"
17398
+ }), method(RecordQueryInputSchema, RecordQueryResultSchema, { auth: "admin" }), method(object({
17399
+ ...KindShape,
17400
+ ...TimeWindowShape,
17401
+ where: RecordWhereSchema.optional()
17402
+ }), object({ count: number().int() }), { auth: "admin" }), method(object({
17403
+ ...KindShape,
17404
+ deviceId: number().int().optional(),
17405
+ from: number(),
17406
+ to: number(),
17407
+ bucketMs: number().int().positive()
17408
+ }), object({ buckets: array(object({
17409
+ bucketStart: number(),
17410
+ count: number().int()
17411
+ })) }), { auth: "admin" }), method(object({
17412
+ ...KindShape,
17413
+ op: _enum([
17414
+ "sum",
17415
+ "min",
17416
+ "max",
17417
+ "count"
17418
+ ]),
17419
+ field: RecordFieldPathSchema.optional(),
17420
+ groupBy: RecordFieldPathSchema.optional(),
17421
+ where: RecordWhereSchema.optional()
17422
+ }), object({ rows: array(object({
17423
+ group: union([
17424
+ string(),
17425
+ number(),
17426
+ _null()
17427
+ ]),
17428
+ value: number().nullable()
17429
+ })) }), { auth: "admin" }), method(object({
17430
+ ...KindShape,
17431
+ deviceId: number().int().optional(),
17432
+ atBefore: number().optional(),
17433
+ where: RecordWhereSchema.optional()
17434
+ }), object({
17435
+ deleted: number().int(),
17436
+ secretRefs: SecretRefsList
17437
+ }), {
17438
+ kind: "mutation",
17439
+ auth: "admin"
17440
+ }), method(object({
17441
+ deviceId: number().int(),
17442
+ kinds: array(RecordKindNameSchema).optional()
17443
+ }), object({
17444
+ deleted: record(string(), number().int()),
17445
+ secretRefs: SecretRefsList
17446
+ }), {
17447
+ kind: "mutation",
17448
+ auth: "admin"
17449
+ }), method(object(KindShape), object({ id: number().int() }), {
17450
+ kind: "mutation",
17451
+ auth: "admin"
17452
+ });
17453
+ /** One table of the settings database. */
17454
+ var StorageTableSchema = object({
17455
+ /** The table's full name, e.g. `recorder:addon-settings` or `addon-device-settings`. */
17456
+ name: string(),
17457
+ /** The owner prefix of a scoped name (`recorder` for `recorder:addon-settings`), else null. */
17458
+ owner: string().nullable(),
17459
+ rows: number().int().nonnegative(),
17460
+ /** Bytes the table's pages occupy (`dbstat`); null when the engine cannot measure. */
17461
+ bytes: number().int().nonnegative().nullable(),
17462
+ /** Declared by an addon since this engine process started (a running addon claims it). */
17463
+ declaredThisBoot: boolean()
17464
+ });
17465
+ /** One declared record kind (D881) as System -> Data shows it. */
17466
+ var StorageKindSchema = object({
17467
+ owner: string(),
17468
+ kind: string(),
17469
+ database: _enum(["settings", "events"]),
17470
+ class: string(),
17471
+ state: _enum([
17472
+ "declared",
17473
+ "orphaned",
17474
+ "dropped"
17475
+ ]),
17476
+ /** `null` when the caller asked for no counts (`counts: false`). */
17477
+ rows: number().int().nonnegative().nullable(),
17478
+ /** Rows x the average size of a sample; null for an empty kind. */
17479
+ bytesEstimate: number().int().nonnegative().nullable(),
17480
+ writeTrigger: string(),
17481
+ retention: RecordRetentionSchema,
17482
+ /** `true` when the kind is an entry kind (the generic entries UI lists it). */
17483
+ entry: boolean(),
17484
+ /** The whole declaration, secret paths and entry descriptor included (the entries service builds its handle from it). */
17485
+ declaration: RecordKindDeclarationSchema
17486
+ });
17487
+ method(object({ ownerPrefix: string().min(1).optional() }), object({ tables: array(StorageTableSchema) }), { auth: "admin" }), method(object({
17488
+ collection: string().min(1),
17489
+ expectRows: number().int().nonnegative()
17490
+ }), object({
17491
+ dropped: literal(true),
17492
+ rows: number().int().nonnegative()
17493
+ }), {
17494
+ kind: "mutation",
17495
+ auth: "admin"
17496
+ }), method(object({
17497
+ owner: string().min(1).optional(),
17498
+ /** `false` skips the per-kind row count (a catalog read only). Default true. */
17499
+ counts: boolean().optional()
17500
+ }), object({ kinds: array(StorageKindSchema) }), { auth: "admin" }), method(RecordQueryInputSchema.extend({
17501
+ owner: string().min(1),
17502
+ kind: RecordKindNameSchema
17503
+ }), RecordQueryResultSchema, { auth: "admin" }), method(object({
17504
+ owner: string().min(1),
17505
+ kind: RecordKindNameSchema,
17506
+ records: array(RecordInputSchema).max(RECORD_BATCH_MAX),
17507
+ /** The LAST batch: the copy is complete, the boot guard stops asking. */
17508
+ complete: boolean().optional()
17509
+ }).refine((input) => input.records.length > 0 || input.complete === true, { message: "records must be non-empty unless complete is true" }), object({ adopted: number().int() }), {
17510
+ kind: "mutation",
17511
+ auth: "admin"
17512
+ }), method(object({
17513
+ collection: string().min(1),
17514
+ cursor: string().optional(),
17515
+ limit: number().int().min(1).max(1e3).optional()
17516
+ }), object({
17517
+ rows: array(object({
17518
+ id: string(),
17519
+ data: record(string(), unknown())
17520
+ })),
17521
+ nextCursor: string().nullable()
17522
+ }), { auth: "admin" }), method(object({ collection: string().min(1) }), object({ adopted: boolean() }), { auth: "admin" });
17523
+ /**
17524
+ * record-entries - the ONE admin surface for every list of user-created entries
17525
+ * (D881): notification targets, brokers, LLM profiles, anything an addon
17526
+ * declares as an ENTRY kind (`entry: { title }` in `defineRecordKinds`).
17527
+ *
17528
+ * The UI is generic. `listEntryKinds` hands it, per kind, the JSON Schema of
17529
+ * the entry body with `secret: true` on every credential field, so a password
17530
+ * field is derived from the schema and never from a name. `putEntry` takes the
17531
+ * redaction token for an untouched secret (the stored value is kept), a string
17532
+ * for a new one, and the clear instruction to remove one. A read never carries
17533
+ * a secret value, and a locked keychain refuses the write with
17534
+ * `records/secret-unavailable` instead of storing plaintext.
17535
+ *
17536
+ * Hub-only, served in-process (it acts for each entry's owner on the keychain).
17537
+ */
17538
+ var EntryKindInfoSchema = object({
17539
+ owner: string(),
17540
+ kind: RecordKindNameSchema,
17541
+ title: string(),
17542
+ nameField: string(),
17543
+ /** JSON Schema of the body; `secret: true` marks a password field. */
17544
+ fields: record(string(), unknown()),
17545
+ secretPaths: array(string()),
17546
+ rows: number().int().nonnegative()
17547
+ });
17548
+ var EntryViewSchema = object({
17549
+ id: RecordIdSchema,
17550
+ name: string(),
17551
+ rev: number().int(),
17552
+ updatedAt: number(),
17553
+ /** Secret fields hold the redaction token. */
17554
+ data: RecordBodySchema
17555
+ });
17556
+ var EntryAddress = {
17557
+ owner: string().min(1),
17558
+ kind: RecordKindNameSchema
17559
+ };
17560
+ method(object({}), object({ kinds: array(EntryKindInfoSchema) }), { auth: "admin" }), method(object({ ...EntryAddress }), object({ entries: array(EntryViewSchema) }), { auth: "admin" }), method(object({
17561
+ ...EntryAddress,
17562
+ id: RecordIdSchema.optional(),
17563
+ data: RecordBodySchema,
17564
+ ifRev: number().int().min(1).optional()
17565
+ }), object({
17566
+ id: string(),
17567
+ rev: number().int()
17568
+ }), {
17569
+ kind: "mutation",
17570
+ auth: "admin"
17571
+ }), method(object({
17572
+ ...EntryAddress,
17573
+ id: RecordIdSchema
17574
+ }), object({ deleted: boolean() }), {
17575
+ kind: "mutation",
17576
+ auth: "admin"
17577
+ });
17578
+ /**
16991
17579
  * `keychain` — the hub's encrypted store of secret values (D787).
16992
17580
  *
16993
17581
  * Settings blobs never hold a secret: they hold a marker
@@ -17528,6 +18116,16 @@ method(object({}), KeychainStatusSchema, { auth: "admin" }), method(object({}),
17528
18116
  kind: "mutation",
17529
18117
  auth: "admin",
17530
18118
  caller: "required"
18119
+ }), method(object({
18120
+ ref: string().min(1),
18121
+ value: string().min(1)
18122
+ }), object({
18123
+ ref: string(),
18124
+ version: number().int()
18125
+ }), {
18126
+ kind: "mutation",
18127
+ auth: "admin",
18128
+ caller: "required"
17531
18129
  }), method(object({ refs: array(string().min(1)).max(1e3) }), object({
17532
18130
  deleted: array(string()).readonly(),
17533
18131
  kept: array(object({
@@ -18049,7 +18647,11 @@ var deviceDiscoveryCapability = {
18049
18647
  };
18050
18648
  /**
18051
18649
  * `device-adoption` — generic discovery + adoption surface,
18052
- * system-scoped singleton. The de-HA-ified successor to `ha-discovery`:
18650
+ * system-scoped collection (one provider per integration addon), routed
18651
+ * by explicit `{ addonId }` on direct `deviceAdoption.*` calls — the same
18652
+ * pin model as `connection-test`. The admin UI keeps using
18653
+ * `deviceManager.adoption*` (which already threads `addonId`). The de-HA-ified
18654
+ * successor to `ha-discovery`:
18053
18655
  * keyed by `integrationId` (the addon resolves integrationId → broker
18054
18656
  * internally) rather than a connection-specific `brokerId`, and it
18055
18657
  * REUSES the shared `DiscoveredChildDevice` candidate type from
@@ -40302,6 +40904,9 @@ method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, {
40302
40904
  }), _void(), { kind: "mutation" }), method(object({}), array(LlmProfileKindDescriptorSchema)), method(object({}), array(LlmProfileSchema)), method(object({ profile: LlmProfileSchema }), LlmProfileSchema, {
40303
40905
  kind: "mutation",
40304
40906
  auth: "admin"
40907
+ }), method(RawSecretMigrationInputSchema, RawSecretMigrationReportSchema, {
40908
+ kind: "mutation",
40909
+ auth: "admin"
40305
40910
  }), method(ProfileRefInputSchema, _void(), {
40306
40911
  kind: "mutation",
40307
40912
  auth: "admin"
@@ -50811,6 +51416,41 @@ var ServerRollbackInfoSchema = object({
50811
51416
  atMs: number(),
50812
51417
  reason: string()
50813
51418
  });
51419
+ /**
51420
+ * The runner boot check (D877): the runners this node PLANNED (hub: one per
51421
+ * `resolveRunnerId` over its forked addons; agent: the runners its process
51422
+ * service holds, because only the hub plans) against the states the process
51423
+ * service reports. Kept in memory, recomputed by the same one-shot check after
51424
+ * every boot, served on `getServerPackageStatus`.
51425
+ *
51426
+ * `failed` is the D6 breaker's terminal state, `refused` a deterministic Init
51427
+ * refusal (an addon that said "I will not start, and here is why"), `missing` a
51428
+ * planned runner the process service has no entry for.
51429
+ */
51430
+ var RunnerRefusalSchema = object({
51431
+ runnerId: string(),
51432
+ addonIds: array(string()),
51433
+ reason: string()
51434
+ });
51435
+ var RunnerBootCheckSchema = object({
51436
+ checkedAtMs: number(),
51437
+ /** Runners planned for this node. */
51438
+ expected: number(),
51439
+ /** Planned runners whose process is `running`. */
51440
+ running: number(),
51441
+ failed: array(string()),
51442
+ refused: array(RunnerRefusalSchema),
51443
+ missing: array(string()),
51444
+ /**
51445
+ * Runners still on their way: `starting`, or `crashed` waiting on a backoff
51446
+ * respawn. The check is FINAL only when this is empty; until then nothing is
51447
+ * pushed and the verdict is re-evaluated on the next runner state change.
51448
+ * Optional for version skew (absent = settled).
51449
+ */
51450
+ pending: array(string()).optional(),
51451
+ /** True when the plan is the hub's (`missing` is then meaningful); false on an agent. */
51452
+ planKnown: boolean()
51453
+ });
50814
51454
  var ServerPackageStatusSchema = object({
50815
51455
  /** Root package name (`@camstack/server` on the hub). */
50816
51456
  packageName: string(),
@@ -50873,7 +51513,14 @@ var ServerPackageStatusSchema = object({
50873
51513
  * for version skew: an older provider's payload simply omits it, and an
50874
51514
  * absent wrapper is unknown — never `native`.
50875
51515
  */
50876
- wrapper: WrapperIdentitySchema.optional()
51516
+ wrapper: WrapperIdentitySchema.optional(),
51517
+ /**
51518
+ * What this node PLANNED to run against what its process service reports
51519
+ * (D877). Absent until the one-shot boot check has run (~60 s after boot) and
51520
+ * on a provider that predates it. Absent is "not checked yet", never "all
51521
+ * well": a consumer that needs the answer treats it as pending.
51522
+ */
51523
+ runners: RunnerBootCheckSchema.optional()
50877
51524
  });
50878
51525
  var ServerUpdateCheckResultSchema = object({
50879
51526
  packageName: string(),
@@ -50924,6 +51571,13 @@ var ServerUpdateOutcomeSchema = _enum([
50924
51571
  "refused",
50925
51572
  "failed"
50926
51573
  ]);
51574
+ /** One addon the pre-flight found the target version would refuse (D877). */
51575
+ var UpdateBlockerSchema = object({
51576
+ addonId: string(),
51577
+ reason: string(),
51578
+ /** What the operator does about it. */
51579
+ remedy: string()
51580
+ });
50927
51581
  var ServerUpdateActionResultSchema = object({
50928
51582
  accepted: boolean(),
50929
51583
  targetVersion: string().nullable(),
@@ -50941,14 +51595,27 @@ var ServerUpdateActionResultSchema = object({
50941
51595
  * The failure itself, verbatim enough to act on (the npm output for a
50942
51596
  * staging install). Non-null only for `failed`.
50943
51597
  */
50944
- error: string().nullable().optional()
51598
+ error: string().nullable().optional(),
51599
+ /**
51600
+ * The addons the target version would refuse to start on this node's live
51601
+ * store (D877), present when the pre-flight refused the update
51602
+ * (`reason: 'addon-would-refuse'`). Optional for version skew.
51603
+ */
51604
+ blockers: array(UpdateBlockerSchema).optional()
50945
51605
  });
50946
51606
  method(_void(), ServerPackageStatusSchema, { auth: "admin" }), method(_void(), ServerUpdateCheckResultSchema, {
50947
51607
  kind: "mutation",
50948
51608
  auth: "admin"
50949
- }), method(object({
50950
- /** Explicit target version; omitted = latest from the registry. */
50951
- version: string().optional() }), ServerUpdateActionResultSchema, {
51609
+ }), method(object({
51610
+ /** Explicit target version; omitted = latest from the registry. */
51611
+ version: string().optional(),
51612
+ /**
51613
+ * Apply even though the pre-flight (D877) found addons the target would
51614
+ * refuse to start. Off by default: those addons stay down until the
51615
+ * remedy is run, which is the incident this gate exists to prevent.
51616
+ */
51617
+ acknowledgeRefusals: boolean().optional()
51618
+ }), ServerUpdateActionResultSchema, {
50952
51619
  kind: "mutation",
50953
51620
  auth: "admin",
50954
51621
  timeoutMs: 16 * 6e4
@@ -53394,7 +54061,9 @@ var ManifestShapeSchema = object({
53394
54061
  var AddonProcessSchema = object({
53395
54062
  pid: number().optional(),
53396
54063
  mode: string(),
53397
- state: string()
54064
+ state: string(),
54065
+ /** Why the runner is `refused` (an addon's own words), when it is (D877). */
54066
+ reason: string().optional()
53398
54067
  });
53399
54068
  /**
53400
54069
  * Per-addon health snapshot from the kernel's AddonHealthMonitor.
@@ -54162,7 +54831,8 @@ var batteryCapability = {
54162
54831
  DeviceType.Button,
54163
54832
  DeviceType.Switch,
54164
54833
  DeviceType.PetFeeder,
54165
- DeviceType.Container
54834
+ DeviceType.Container,
54835
+ DeviceType.Thermostat
54166
54836
  ],
54167
54837
  methods: {
54168
54838
  /**
@@ -54783,6 +55453,12 @@ var ClimateControlStatusSchema = object({
54783
55453
  /** Horizontal louver swing on/off. Null when the device has no
54784
55454
  * horizontal swing surface (gate with `DeviceFeature.ClimateSwingHorizontal`). */
54785
55455
  swingHorizontal: boolean().nullable(),
55456
+ /** Lowest setpoint the device accepts, Celsius. Absent / null = not reported. */
55457
+ minTemp: number().nullable().optional(),
55458
+ /** Highest setpoint the device accepts, Celsius. Absent / null = not reported. */
55459
+ maxTemp: number().nullable().optional(),
55460
+ /** Setpoint granularity, Celsius (0.5, 1). Absent / null = not reported. */
55461
+ tempStep: number().positive().nullable().optional(),
54786
55462
  /** Ms epoch when the slice was last updated (push or command). */
54787
55463
  lastFetchedAt: number()
54788
55464
  });
@@ -55629,6 +56305,161 @@ onStatusChanged: { data: object({
55629
56305
  * whether persisting is worth a SQLite commit. */
55630
56306
  volatileStateFields: ["lastChangedAt"]
55631
56307
  };
56308
+ /**
56309
+ * Smart-dishwasher cap — program lifecycle, door / remote-start gates,
56310
+ * consumable levels (salt, rinse aid) and common program options.
56311
+ *
56312
+ * Sources: native Bosch Home Connect (`dishwasher` device type). Reusable
56313
+ * by any integration that exposes the same program / option surface.
56314
+ *
56315
+ * `kind: 'poll'` — cloud REST APIs typically have no push channel; the
56316
+ * provider refreshes the slice on an interval and eagerly after commands.
56317
+ */
56318
+ var DishwasherStateSchema = _enum([
56319
+ "idle",
56320
+ "running",
56321
+ "paused",
56322
+ "finished",
56323
+ "error",
56324
+ "unavailable"
56325
+ ]);
56326
+ var DishwasherConsumableLevelSchema = _enum([
56327
+ "ok",
56328
+ "low",
56329
+ "empty"
56330
+ ]);
56331
+ var DishwasherStatusSchema = object({
56332
+ state: DishwasherStateSchema,
56333
+ /** Active program id/name, or null when none selected / unknown. */
56334
+ program: string().nullable(),
56335
+ /** Program tokens the hardware accepts — drives the UI selector. */
56336
+ availablePrograms: array(string()),
56337
+ /** Minutes remaining on the active cycle, or null when not running. */
56338
+ remainingMinutes: number().int().nonnegative().nullable(),
56339
+ /** Cycle completion 0..100, or null when not applicable. */
56340
+ progressPercent: number().min(0).max(100).nullable(),
56341
+ /** True when the door is reported open. */
56342
+ doorOpen: boolean(),
56343
+ /** True when remote start is allowed (door closed, power on, etc.). */
56344
+ remoteStartAllowed: boolean(),
56345
+ /** Main power / switched-on state. */
56346
+ powerOn: boolean(),
56347
+ saltLevel: DishwasherConsumableLevelSchema.nullable(),
56348
+ rinseAidLevel: DishwasherConsumableLevelSchema.nullable(),
56349
+ halfLoad: boolean(),
56350
+ hygienePlus: boolean(),
56351
+ /** Extra dry option when the appliance exposes it. */
56352
+ extraDry: boolean(),
56353
+ /** Intensive zone (lower basket) when the appliance exposes it. */
56354
+ intensiveZone: boolean(),
56355
+ /** VarioSpeed / VarioSpeed+ when the appliance exposes it. */
56356
+ varioSpeedPlus: boolean(),
56357
+ /** Child lock (controls disabled on the appliance). */
56358
+ childLock: boolean(),
56359
+ errorCode: number().nullable(),
56360
+ errorLabel: string().nullable(),
56361
+ lastFetchedAt: number()
56362
+ });
56363
+ var dishwasherCapability = {
56364
+ name: "dishwasher",
56365
+ scope: "device",
56366
+ deviceNative: true,
56367
+ mode: "singleton",
56368
+ deviceTypes: [DeviceType.Dishwasher],
56369
+ methods: {
56370
+ start: method(object({ deviceId: number().int().nonnegative() }), _void(), {
56371
+ kind: "mutation",
56372
+ auth: "protected"
56373
+ }),
56374
+ pause: method(object({ deviceId: number().int().nonnegative() }), _void(), {
56375
+ kind: "mutation",
56376
+ auth: "protected"
56377
+ }),
56378
+ stop: method(object({ deviceId: number().int().nonnegative() }), _void(), {
56379
+ kind: "mutation",
56380
+ auth: "protected"
56381
+ }),
56382
+ setProgram: method(object({
56383
+ deviceId: number().int().nonnegative(),
56384
+ program: string().min(1)
56385
+ }), _void(), {
56386
+ kind: "mutation",
56387
+ auth: "protected"
56388
+ }),
56389
+ setPower: method(object({
56390
+ deviceId: number().int().nonnegative(),
56391
+ on: boolean()
56392
+ }), _void(), {
56393
+ kind: "mutation",
56394
+ auth: "protected"
56395
+ }),
56396
+ setHalfLoad: method(object({
56397
+ deviceId: number().int().nonnegative(),
56398
+ on: boolean()
56399
+ }), _void(), {
56400
+ kind: "mutation",
56401
+ auth: "protected"
56402
+ }),
56403
+ setHygienePlus: method(object({
56404
+ deviceId: number().int().nonnegative(),
56405
+ on: boolean()
56406
+ }), _void(), {
56407
+ kind: "mutation",
56408
+ auth: "protected"
56409
+ }),
56410
+ setExtraDry: method(object({
56411
+ deviceId: number().int().nonnegative(),
56412
+ on: boolean()
56413
+ }), _void(), {
56414
+ kind: "mutation",
56415
+ auth: "protected"
56416
+ }),
56417
+ setIntensiveZone: method(object({
56418
+ deviceId: number().int().nonnegative(),
56419
+ on: boolean()
56420
+ }), _void(), {
56421
+ kind: "mutation",
56422
+ auth: "protected"
56423
+ }),
56424
+ setVarioSpeedPlus: method(object({
56425
+ deviceId: number().int().nonnegative(),
56426
+ on: boolean()
56427
+ }), _void(), {
56428
+ kind: "mutation",
56429
+ auth: "protected"
56430
+ }),
56431
+ setChildLock: method(object({
56432
+ deviceId: number().int().nonnegative(),
56433
+ on: boolean()
56434
+ }), _void(), {
56435
+ kind: "mutation",
56436
+ auth: "protected"
56437
+ }),
56438
+ setOption: method(object({
56439
+ deviceId: number().int().nonnegative(),
56440
+ key: string().min(1),
56441
+ value: union([
56442
+ boolean(),
56443
+ string(),
56444
+ number()
56445
+ ])
56446
+ }), _void(), {
56447
+ kind: "mutation",
56448
+ auth: "protected"
56449
+ })
56450
+ },
56451
+ status: {
56452
+ schema: DishwasherStatusSchema,
56453
+ kind: "poll"
56454
+ },
56455
+ runtimeState: DishwasherStatusSchema,
56456
+ durability: "session",
56457
+ history: { fields: { progressPercent: {
56458
+ kind: "gauge",
56459
+ unit: "%",
56460
+ deadband: 2
56461
+ } } }
56462
+ };
55632
56463
  var DoorbellStatusSchema = object({
55633
56464
  /** Ms epoch of the last press. null = never observed since this provider started. */
55634
56465
  lastPressedAt: number().nullable(),
@@ -56431,6 +57262,32 @@ var gasCapability = {
56431
57262
  * whether persisting is worth a SQLite commit. */
56432
57263
  volatileStateFields: ["lastChangedAt"]
56433
57264
  };
57265
+ var HeatingValveStatusSchema = object({
57266
+ /** Radiator valve opening 0 (closed) .. 100 (open). Null = not yet known. */
57267
+ position: number().min(0).max(100).nullable(),
57268
+ /** Ms epoch when the slice was last updated (push or poll). */
57269
+ lastFetchedAt: number()
57270
+ });
57271
+ var heatingValveCapability = {
57272
+ name: "heating-valve",
57273
+ scope: "device",
57274
+ deviceNative: true,
57275
+ mode: "singleton",
57276
+ deviceTypes: [DeviceType.Thermostat],
57277
+ methods: {},
57278
+ status: {
57279
+ schema: HeatingValveStatusSchema,
57280
+ kind: "push"
57281
+ },
57282
+ runtimeState: HeatingValveStatusSchema,
57283
+ durability: "session",
57284
+ history: { fields: { position: {
57285
+ kind: "gauge",
57286
+ unit: "%",
57287
+ deadband: 1
57288
+ } } },
57289
+ volatileStateFields: ["lastFetchedAt"]
57290
+ };
56434
57291
  /**
56435
57292
  * Humidifier / dehumidifier cap. Models HA `humidifier.*` entities —
56436
57293
  * an on/off actuator with an optional target-humidity setpoint and an
@@ -57563,7 +58420,19 @@ var TlsStatusSchema = object({
57563
58420
  sans: array(string()),
57564
58421
  caCertPem: string().nullable(),
57565
58422
  reissueError: string().nullable(),
57566
- restartRequired: boolean()
58423
+ restartRequired: boolean(),
58424
+ /** An uploaded certificate is served but no CA is kept for it and it is not publicly signed (D873). */
58425
+ caMissing: boolean(),
58426
+ /** Does the hub's own generated CA carry a critical name constraint? `null` while it has none. */
58427
+ localCaConstrained: boolean().nullable(),
58428
+ /** ISO time the generated CA was replaced by a constrained one; devices must re-download it. */
58429
+ caReplacedAt: string().nullable(),
58430
+ /** The uploaded certificate kept on disk, selectable again after "Revert to generated". */
58431
+ storedUpload: object({
58432
+ leafFingerprintSha256: string(),
58433
+ validTo: string(),
58434
+ hasCa: boolean()
58435
+ }).nullable()
57567
58436
  });
57568
58437
  method(_void(), ListResultSchema), method(_void(), PreferredSchema), method(object({
57569
58438
  /**
@@ -57619,6 +58488,9 @@ method(_void(), ListResultSchema), method(_void(), PreferredSchema), method(obje
57619
58488
  }), method(_void(), object({ pem: string() })), method(_void(), TlsStatusSchema, {
57620
58489
  kind: "mutation",
57621
58490
  auth: "admin"
58491
+ }), method(_void(), TlsStatusSchema, {
58492
+ kind: "mutation",
58493
+ auth: "admin"
57622
58494
  });
57623
58495
  var LockControlStatusSchema = object({
57624
58496
  /** Lifecycle state of the lock. `jammed` means the motor reported
@@ -64112,7 +64984,11 @@ method(_void(), array(UserSummarySchema), { auth: "admin" }), method(CreateUserI
64112
64984
  kind: "mutation",
64113
64985
  auth: "admin",
64114
64986
  access: "delete"
64115
- }), method(object({ userId: string() }), TotpStatusSchema, { auth: "admin" }), method(object({
64987
+ }), method(object({ userId: string() }), TotpStatusSchema, { auth: "admin" }), method(RawSecretMigrationInputSchema, RawSecretMigrationReportSchema, {
64988
+ kind: "mutation",
64989
+ auth: "admin",
64990
+ access: "create"
64991
+ }), method(object({
64116
64992
  userId: string(),
64117
64993
  code: string()
64118
64994
  }), object({ valid: boolean() }), {
@@ -65832,6 +66708,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
65832
66708
  dayNight: dayNightCapability,
65833
66709
  deviceDiscovery: deviceDiscoveryCapability,
65834
66710
  deviceStatus: deviceStatusCapability,
66711
+ dishwasher: dishwasherCapability,
65835
66712
  doorbell: doorbellCapability,
65836
66713
  enumSensor: enumSensorCapability,
65837
66714
  eventEmitter: eventEmitterCapability,
@@ -65839,6 +66716,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
65839
66716
  featureProbe: featureProbeCapability,
65840
66717
  flood: floodCapability,
65841
66718
  gas: gasCapability,
66719
+ heatingValve: heatingValveCapability,
65842
66720
  humidifier: humidifierCapability,
65843
66721
  humiditySensor: humiditySensorCapability,
65844
66722
  image: imageCapability,
@@ -65924,13 +66802,14 @@ var BaseDevice = class {
65924
66802
  get state() {
65925
66803
  if (!this._stateProxyCache) {
65926
66804
  const cache = {};
65927
- const handler = { get: (_target, key) => {
66805
+ const handler = { get: (target, key) => {
65928
66806
  const k = key;
65929
- if (k in cache) return cache[k];
66807
+ const existing = Reflect.get(target, k);
66808
+ if (existing !== void 0) return existing;
65930
66809
  const cap = DEVICE_LOCAL_STATE_CAPS[k];
65931
66810
  if (!cap) return void 0;
65932
66811
  const proxy = this.sliceProxy(cap);
65933
- cache[k] = proxy;
66812
+ Reflect.set(target, k, proxy);
65934
66813
  return proxy;
65935
66814
  } };
65936
66815
  this._stateProxyCache = new Proxy(cache, handler);
@@ -66129,7 +67008,7 @@ var BaseDevice = class {
66129
67008
  async updateSourceInfo(patch) {
66130
67009
  const next = mergeSourceInfo(this.sourceInfo, patch);
66131
67010
  this._sourceInfoCache = Object.freeze({ ...next });
66132
- const action = this.ctx.api?.deviceManager?.setMetadata;
67011
+ const action = this.ctx.api.deviceManager?.setMetadata;
66133
67012
  if (action) try {
66134
67013
  await action.mutate({
66135
67014
  deviceId: this.id,
@@ -66164,7 +67043,7 @@ var BaseDevice = class {
66164
67043
  * device boot on a meta refresh.
66165
67044
  */
66166
67045
  async refreshFeatures() {
66167
- const action = this.ctx.api?.deviceManager?.registerDevice;
67046
+ const action = this.ctx.api.deviceManager?.registerDevice;
66168
67047
  if (!action) return;
66169
67048
  try {
66170
67049
  await action.mutate({
@@ -66563,6 +67442,12 @@ var BaseDeviceProvider = class extends BaseAddon {
66563
67442
  provider: this
66564
67443
  }];
66565
67444
  }
67445
+ /** Flatten `super.onInitialize()` whether it returned an array or an envelope. */
67446
+ providerRegistrationsFromSuper(result) {
67447
+ if (Array.isArray(result)) return result;
67448
+ if (result !== void 0 && result.providers !== void 0) return [...result.providers];
67449
+ return [];
67450
+ }
66566
67451
  async onShutdown() {
66567
67452
  this._restoreShuttingDown = true;
66568
67453
  this.cancelRestoreRetries();
@@ -67089,7 +67974,7 @@ var BaseDeviceProvider = class extends BaseAddon {
67089
67974
  return toDeviceSummary(device, this.addonId);
67090
67975
  }
67091
67976
  };
67092
- 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;
67977
+ 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;
67093
67978
  new Set(Object.values(DeviceType));
67094
67979
  Object.freeze({
67095
67980
  "accessories.getStatus": {
@@ -68238,6 +69123,12 @@ Object.freeze({
68238
69123
  addonId: null,
68239
69124
  access: "view"
68240
69125
  },
69126
+ "coreBlocks.migrateRawSecrets": {
69127
+ capName: "core-blocks",
69128
+ capScope: "system",
69129
+ addonId: null,
69130
+ access: "create"
69131
+ },
68241
69132
  "coreBlocks.restart": {
68242
69133
  capName: "core-blocks",
68243
69134
  capScope: "system",
@@ -69504,6 +70395,84 @@ Object.freeze({
69504
70395
  addonId: null,
69505
70396
  access: "view"
69506
70397
  },
70398
+ "dishwasher.getStatus": {
70399
+ capName: "dishwasher",
70400
+ capScope: "device",
70401
+ addonId: null,
70402
+ access: "view"
70403
+ },
70404
+ "dishwasher.pause": {
70405
+ capName: "dishwasher",
70406
+ capScope: "device",
70407
+ addonId: null,
70408
+ access: "create"
70409
+ },
70410
+ "dishwasher.setChildLock": {
70411
+ capName: "dishwasher",
70412
+ capScope: "device",
70413
+ addonId: null,
70414
+ access: "create"
70415
+ },
70416
+ "dishwasher.setExtraDry": {
70417
+ capName: "dishwasher",
70418
+ capScope: "device",
70419
+ addonId: null,
70420
+ access: "create"
70421
+ },
70422
+ "dishwasher.setHalfLoad": {
70423
+ capName: "dishwasher",
70424
+ capScope: "device",
70425
+ addonId: null,
70426
+ access: "create"
70427
+ },
70428
+ "dishwasher.setHygienePlus": {
70429
+ capName: "dishwasher",
70430
+ capScope: "device",
70431
+ addonId: null,
70432
+ access: "create"
70433
+ },
70434
+ "dishwasher.setIntensiveZone": {
70435
+ capName: "dishwasher",
70436
+ capScope: "device",
70437
+ addonId: null,
70438
+ access: "create"
70439
+ },
70440
+ "dishwasher.setOption": {
70441
+ capName: "dishwasher",
70442
+ capScope: "device",
70443
+ addonId: null,
70444
+ access: "create"
70445
+ },
70446
+ "dishwasher.setPower": {
70447
+ capName: "dishwasher",
70448
+ capScope: "device",
70449
+ addonId: null,
70450
+ access: "create"
70451
+ },
70452
+ "dishwasher.setProgram": {
70453
+ capName: "dishwasher",
70454
+ capScope: "device",
70455
+ addonId: null,
70456
+ access: "create"
70457
+ },
70458
+ "dishwasher.setVarioSpeedPlus": {
70459
+ capName: "dishwasher",
70460
+ capScope: "device",
70461
+ addonId: null,
70462
+ access: "create"
70463
+ },
70464
+ "dishwasher.start": {
70465
+ capName: "dishwasher",
70466
+ capScope: "device",
70467
+ addonId: null,
70468
+ access: "create"
70469
+ },
70470
+ "dishwasher.stop": {
70471
+ capName: "dishwasher",
70472
+ capScope: "device",
70473
+ addonId: null,
70474
+ access: "create"
70475
+ },
69507
70476
  "doorbell.getStatus": {
69508
70477
  capName: "doorbell",
69509
70478
  capScope: "device",
@@ -69714,6 +70683,12 @@ Object.freeze({
69714
70683
  addonId: null,
69715
70684
  access: "view"
69716
70685
  },
70686
+ "heatingValve.getStatus": {
70687
+ capName: "heating-valve",
70688
+ capScope: "device",
70689
+ addonId: null,
70690
+ access: "view"
70691
+ },
69717
70692
  "humidifier.getStatus": {
69718
70693
  capName: "humidifier",
69719
70694
  capScope: "device",
@@ -69924,6 +70899,12 @@ Object.freeze({
69924
70899
  addonId: null,
69925
70900
  access: "create"
69926
70901
  },
70902
+ "keychainAdmin.importSecret": {
70903
+ capName: "keychain-admin",
70904
+ capScope: "system",
70905
+ addonId: null,
70906
+ access: "create"
70907
+ },
69927
70908
  "keychainAdmin.listAudit": {
69928
70909
  capName: "keychain-admin",
69929
70910
  capScope: "system",
@@ -70092,6 +71073,12 @@ Object.freeze({
70092
71073
  addonId: null,
70093
71074
  access: "view"
70094
71075
  },
71076
+ "llm.migrateRawSecrets": {
71077
+ capName: "llm",
71078
+ capScope: "system",
71079
+ addonId: null,
71080
+ access: "create"
71081
+ },
70095
71082
  "llm.resolveModelRef": {
70096
71083
  capName: "llm",
70097
71084
  capScope: "system",
@@ -70320,6 +71307,12 @@ Object.freeze({
70320
71307
  addonId: null,
70321
71308
  access: "create"
70322
71309
  },
71310
+ "localNetwork.useStoredUploadedCertificate": {
71311
+ capName: "local-network",
71312
+ capScope: "system",
71313
+ addonId: null,
71314
+ access: "create"
71315
+ },
70323
71316
  "lockControl.getStatus": {
70324
71317
  capName: "lock-control",
70325
71318
  capScope: "device",
@@ -72972,6 +73965,30 @@ Object.freeze({
72972
73965
  addonId: null,
72973
73966
  access: "create"
72974
73967
  },
73968
+ "recordEntries.deleteEntry": {
73969
+ capName: "record-entries",
73970
+ capScope: "system",
73971
+ addonId: null,
73972
+ access: "delete"
73973
+ },
73974
+ "recordEntries.listEntries": {
73975
+ capName: "record-entries",
73976
+ capScope: "system",
73977
+ addonId: null,
73978
+ access: "view"
73979
+ },
73980
+ "recordEntries.listEntryKinds": {
73981
+ capName: "record-entries",
73982
+ capScope: "system",
73983
+ addonId: null,
73984
+ access: "view"
73985
+ },
73986
+ "recordEntries.putEntry": {
73987
+ capName: "record-entries",
73988
+ capScope: "system",
73989
+ addonId: null,
73990
+ access: "create"
73991
+ },
72975
73992
  "recording.getAvailability": {
72976
73993
  capName: "recording",
72977
73994
  capScope: "device",
@@ -73272,6 +74289,102 @@ Object.freeze({
73272
74289
  addonId: null,
73273
74290
  access: "view"
73274
74291
  },
74292
+ "records.aggregate": {
74293
+ capName: "records",
74294
+ capScope: "system",
74295
+ addonId: null,
74296
+ access: "view"
74297
+ },
74298
+ "records.allocateId": {
74299
+ capName: "records",
74300
+ capScope: "system",
74301
+ addonId: null,
74302
+ access: "create"
74303
+ },
74304
+ "records.count": {
74305
+ capName: "records",
74306
+ capScope: "system",
74307
+ addonId: null,
74308
+ access: "view"
74309
+ },
74310
+ "records.declareKinds": {
74311
+ capName: "records",
74312
+ capScope: "system",
74313
+ addonId: null,
74314
+ access: "create"
74315
+ },
74316
+ "records.delete": {
74317
+ capName: "records",
74318
+ capScope: "system",
74319
+ addonId: null,
74320
+ access: "delete"
74321
+ },
74322
+ "records.deleteDevice": {
74323
+ capName: "records",
74324
+ capScope: "system",
74325
+ addonId: null,
74326
+ access: "delete"
74327
+ },
74328
+ "records.deleteMany": {
74329
+ capName: "records",
74330
+ capScope: "system",
74331
+ addonId: null,
74332
+ access: "delete"
74333
+ },
74334
+ "records.deleteWhere": {
74335
+ capName: "records",
74336
+ capScope: "system",
74337
+ addonId: null,
74338
+ access: "delete"
74339
+ },
74340
+ "records.get": {
74341
+ capName: "records",
74342
+ capScope: "system",
74343
+ addonId: null,
74344
+ access: "view"
74345
+ },
74346
+ "records.getMany": {
74347
+ capName: "records",
74348
+ capScope: "system",
74349
+ addonId: null,
74350
+ access: "view"
74351
+ },
74352
+ "records.histogram": {
74353
+ capName: "records",
74354
+ capScope: "system",
74355
+ addonId: null,
74356
+ access: "view"
74357
+ },
74358
+ "records.patch": {
74359
+ capName: "records",
74360
+ capScope: "system",
74361
+ addonId: null,
74362
+ access: "create"
74363
+ },
74364
+ "records.put": {
74365
+ capName: "records",
74366
+ capScope: "system",
74367
+ addonId: null,
74368
+ access: "create"
74369
+ },
74370
+ "records.putMany": {
74371
+ capName: "records",
74372
+ capScope: "system",
74373
+ addonId: null,
74374
+ access: "create"
74375
+ },
74376
+ "records.query": {
74377
+ capName: "records",
74378
+ capScope: "system",
74379
+ addonId: null,
74380
+ access: "view"
74381
+ },
74382
+ "records.secretRefs": {
74383
+ capName: "records",
74384
+ capScope: "system",
74385
+ addonId: null,
74386
+ access: "view"
74387
+ },
73275
74388
  "sceneMonitor.captureReference": {
73276
74389
  capName: "scene-monitor",
73277
74390
  capScope: "device",
@@ -73704,6 +74817,48 @@ Object.freeze({
73704
74817
  addonId: null,
73705
74818
  access: "create"
73706
74819
  },
74820
+ "storageAdmin.adoptRecords": {
74821
+ capName: "storage-admin",
74822
+ capScope: "system",
74823
+ addonId: null,
74824
+ access: "create"
74825
+ },
74826
+ "storageAdmin.dropCollection": {
74827
+ capName: "storage-admin",
74828
+ capScope: "system",
74829
+ addonId: null,
74830
+ access: "delete"
74831
+ },
74832
+ "storageAdmin.isAdoptedLegacyTable": {
74833
+ capName: "storage-admin",
74834
+ capScope: "system",
74835
+ addonId: null,
74836
+ access: "view"
74837
+ },
74838
+ "storageAdmin.listKinds": {
74839
+ capName: "storage-admin",
74840
+ capScope: "system",
74841
+ addonId: null,
74842
+ access: "view"
74843
+ },
74844
+ "storageAdmin.listTables": {
74845
+ capName: "storage-admin",
74846
+ capScope: "system",
74847
+ addonId: null,
74848
+ access: "view"
74849
+ },
74850
+ "storageAdmin.readLegacyCollection": {
74851
+ capName: "storage-admin",
74852
+ capScope: "system",
74853
+ addonId: null,
74854
+ access: "view"
74855
+ },
74856
+ "storageAdmin.readRecords": {
74857
+ capName: "storage-admin",
74858
+ capScope: "system",
74859
+ addonId: null,
74860
+ access: "view"
74861
+ },
73707
74862
  "storageEvictable.evict": {
73708
74863
  capName: "storage-evictable",
73709
74864
  capScope: "system",
@@ -74616,6 +75771,12 @@ Object.freeze({
74616
75771
  addonId: null,
74617
75772
  access: "view"
74618
75773
  },
75774
+ "userManagement.migrateRawSecrets": {
75775
+ capName: "user-management",
75776
+ capScope: "system",
75777
+ addonId: null,
75778
+ access: "create"
75779
+ },
74619
75780
  "userManagement.oauthExchangeCode": {
74620
75781
  capName: "user-management",
74621
75782
  capScope: "system",
@@ -75115,7 +76276,7 @@ Object.freeze({
75115
76276
  access: "create"
75116
76277
  }
75117
76278
  });
75118
- 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;
76279
+ 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;
75119
76280
  DeviceFeature.BatteryOperated;
75120
76281
  Object.freeze({
75121
76282
  "accessories.getStatus": [{
@@ -75939,6 +77100,71 @@ Object.freeze({
75939
77100
  form: "single",
75940
77101
  optional: false
75941
77102
  }],
77103
+ "dishwasher.getStatus": [{
77104
+ name: "deviceId",
77105
+ form: "single",
77106
+ optional: false
77107
+ }],
77108
+ "dishwasher.pause": [{
77109
+ name: "deviceId",
77110
+ form: "single",
77111
+ optional: false
77112
+ }],
77113
+ "dishwasher.setChildLock": [{
77114
+ name: "deviceId",
77115
+ form: "single",
77116
+ optional: false
77117
+ }],
77118
+ "dishwasher.setExtraDry": [{
77119
+ name: "deviceId",
77120
+ form: "single",
77121
+ optional: false
77122
+ }],
77123
+ "dishwasher.setHalfLoad": [{
77124
+ name: "deviceId",
77125
+ form: "single",
77126
+ optional: false
77127
+ }],
77128
+ "dishwasher.setHygienePlus": [{
77129
+ name: "deviceId",
77130
+ form: "single",
77131
+ optional: false
77132
+ }],
77133
+ "dishwasher.setIntensiveZone": [{
77134
+ name: "deviceId",
77135
+ form: "single",
77136
+ optional: false
77137
+ }],
77138
+ "dishwasher.setOption": [{
77139
+ name: "deviceId",
77140
+ form: "single",
77141
+ optional: false
77142
+ }],
77143
+ "dishwasher.setPower": [{
77144
+ name: "deviceId",
77145
+ form: "single",
77146
+ optional: false
77147
+ }],
77148
+ "dishwasher.setProgram": [{
77149
+ name: "deviceId",
77150
+ form: "single",
77151
+ optional: false
77152
+ }],
77153
+ "dishwasher.setVarioSpeedPlus": [{
77154
+ name: "deviceId",
77155
+ form: "single",
77156
+ optional: false
77157
+ }],
77158
+ "dishwasher.start": [{
77159
+ name: "deviceId",
77160
+ form: "single",
77161
+ optional: false
77162
+ }],
77163
+ "dishwasher.stop": [{
77164
+ name: "deviceId",
77165
+ form: "single",
77166
+ optional: false
77167
+ }],
75942
77168
  "doorbell.getStatus": [{
75943
77169
  name: "deviceId",
75944
77170
  form: "single",
@@ -76008,6 +77234,11 @@ Object.freeze({
76008
77234
  form: "single",
76009
77235
  optional: false
76010
77236
  }],
77237
+ "heatingValve.getStatus": [{
77238
+ name: "deviceId",
77239
+ form: "single",
77240
+ optional: false
77241
+ }],
76011
77242
  "humidifier.getStatus": [{
76012
77243
  name: "deviceId",
76013
77244
  form: "single",
@@ -77292,6 +78523,37 @@ Object.freeze({
77292
78523
  form: "single",
77293
78524
  optional: false
77294
78525
  }],
78526
+ "records.count": [{
78527
+ name: "deviceId",
78528
+ form: "single",
78529
+ optional: true
78530
+ }],
78531
+ "records.deleteDevice": [{
78532
+ name: "deviceId",
78533
+ form: "single",
78534
+ optional: false
78535
+ }],
78536
+ "records.deleteWhere": [{
78537
+ name: "deviceId",
78538
+ form: "single",
78539
+ optional: true
78540
+ }],
78541
+ "records.histogram": [{
78542
+ name: "deviceId",
78543
+ form: "single",
78544
+ optional: true
78545
+ }],
78546
+ "records.putMany": [{
78547
+ name: "records",
78548
+ form: "object-array",
78549
+ optional: false,
78550
+ itemField: "deviceId"
78551
+ }],
78552
+ "records.query": [{
78553
+ name: "deviceId",
78554
+ form: "single",
78555
+ optional: true
78556
+ }],
77295
78557
  "sceneMonitor.captureReference": [{
77296
78558
  name: "deviceId",
77297
78559
  form: "single",
@@ -77408,6 +78670,17 @@ Object.freeze({
77408
78670
  form: "single",
77409
78671
  optional: false
77410
78672
  }],
78673
+ "storageAdmin.adoptRecords": [{
78674
+ name: "records",
78675
+ form: "object-array",
78676
+ optional: false,
78677
+ itemField: "deviceId"
78678
+ }],
78679
+ "storageAdmin.readRecords": [{
78680
+ name: "deviceId",
78681
+ form: "single",
78682
+ optional: true
78683
+ }],
77411
78684
  "streamBroker.acquireEgressTranscode": [{
77412
78685
  name: "deviceId",
77413
78686
  form: "single",