@camstack/system 1.2.249 → 1.2.250

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 (51) hide show
  1. package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
  2. package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
  3. package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
  4. package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
  5. package/dist/builtins/alerts/alerts.addon.js +1 -1
  6. package/dist/builtins/alerts/alerts.addon.mjs +1 -1
  7. package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +1 -1
  8. package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +1 -1
  9. package/dist/builtins/console-logging/index.js +1 -1
  10. package/dist/builtins/console-logging/index.mjs +1 -1
  11. package/dist/builtins/core-blocks/core-blocks.addon.js +1 -1
  12. package/dist/builtins/core-blocks/core-blocks.addon.mjs +1 -1
  13. package/dist/builtins/device-manager/device-manager.addon.js +2 -2
  14. package/dist/builtins/device-manager/device-manager.addon.mjs +2 -2
  15. package/dist/builtins/doorbell/virtual-doorbell.addon.js +1 -1
  16. package/dist/builtins/doorbell/virtual-doorbell.addon.mjs +1 -1
  17. package/dist/builtins/hub-forwarder/index.js +1 -1
  18. package/dist/builtins/hub-forwarder/index.mjs +1 -1
  19. package/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
  20. package/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
  21. package/dist/builtins/local-auth/local-auth.addon.js +1 -1
  22. package/dist/builtins/local-auth/local-auth.addon.mjs +1 -1
  23. package/dist/builtins/local-network/local-network.addon.js +1 -1
  24. package/dist/builtins/local-network/local-network.addon.mjs +1 -1
  25. package/dist/builtins/loki-logging/index.js +1 -1
  26. package/dist/builtins/loki-logging/index.mjs +1 -1
  27. package/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
  28. package/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
  29. package/dist/builtins/platform-probe/index.js +1 -1
  30. package/dist/builtins/platform-probe/index.mjs +1 -1
  31. package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
  32. package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
  33. package/dist/builtins/snapshot/index.js +1 -1
  34. package/dist/builtins/snapshot/index.mjs +1 -1
  35. package/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
  36. package/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
  37. package/dist/builtins/sqlite-storage/sqlite-settings.addon.js +0 -0
  38. package/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +0 -0
  39. package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
  40. package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
  41. package/dist/builtins/system-config/system-config.addon.js +1 -1
  42. package/dist/builtins/system-config/system-config.addon.mjs +1 -1
  43. package/dist/builtins/winston-logging/index.js +1 -1
  44. package/dist/builtins/winston-logging/index.mjs +1 -1
  45. package/dist/{dist-B67DC-Ss.mjs → dist-BHlcm97I.mjs} +178 -6
  46. package/dist/{dist-DluLUTzR.js → dist-BW7x4kAI.js} +178 -6
  47. package/dist/index.js +1 -1
  48. package/dist/index.mjs +1 -1
  49. package/dist/{retired-settings-keys-VcrnwKN0.js → retired-settings-keys-CeaYCDU4.js} +1 -1
  50. package/dist/{retired-settings-keys-oN5dGOi5.mjs → retired-settings-keys-lPlv147H.mjs} +1 -1
  51. package/package.json +1 -1
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
8
8
  let node_crypto = require("node:crypto");
9
9
  let node_path = require("node:path");
@@ -1,4 +1,4 @@
1
- import { A as addonPagesCapability, Cn as EventCategory, Xt as errMsg, Zt as BaseAddon } from "../../dist-B67DC-Ss.mjs";
1
+ import { A as addonPagesCapability, Cn as EventCategory, Xt as errMsg, Zt as BaseAddon } from "../../dist-BHlcm97I.mjs";
2
2
  import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
3
3
  import { createHash, randomUUID } from "node:crypto";
4
4
  import * as path$1 from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
8
8
  let node_crypto = require("node:crypto");
9
9
  let node_path = require("node:path");
@@ -1,4 +1,4 @@
1
- import { Cn as EventCategory, M as addonWidgetsCapability, Xt as errMsg, Zt as BaseAddon } from "../../dist-B67DC-Ss.mjs";
1
+ import { Cn as EventCategory, M as addonWidgetsCapability, Xt as errMsg, Zt as BaseAddon } from "../../dist-BHlcm97I.mjs";
2
2
  import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
3
3
  import { createHash, randomUUID } from "node:crypto";
4
4
  import * as path$1 from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  //#region src/builtins/alerts/prune-policy.ts
8
8
  /**
9
9
  * Ids older than `cutoffMs`, oldest first.
@@ -1,4 +1,4 @@
1
- import { Cn as EventCategory, N as alertsCapability, Xt as errMsg, Zt as BaseAddon, n as AlertSchema, un as createEvent } from "../../dist-B67DC-Ss.mjs";
1
+ import { Cn as EventCategory, N as alertsCapability, Xt as errMsg, Zt as BaseAddon, n as AlertSchema, un as createEvent } from "../../dist-BHlcm97I.mjs";
2
2
  //#region src/builtins/alerts/prune-policy.ts
3
3
  /**
4
4
  * Ids older than `cutoffMs`, oldest first.
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  let node_crypto = require("node:crypto");
8
8
  let buffer = require("buffer");
9
9
  let node_fs_promises = require("node:fs/promises");
@@ -1,4 +1,4 @@
1
- import { Cn as EventCategory, F as backupCapability, Ut as storageOccupancyCapability, Zt as BaseAddon, xt as mayWriteToLocation } from "../../dist-B67DC-Ss.mjs";
1
+ import { Cn as EventCategory, F as backupCapability, Ut as storageOccupancyCapability, Zt as BaseAddon, xt as mayWriteToLocation } from "../../dist-BHlcm97I.mjs";
2
2
  import { randomBytes, randomUUID } from "node:crypto";
3
3
  import { Buffer as Buffer$1 } from "buffer";
4
4
  import * as fsp from "node:fs/promises";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  const require_formatter = require("../../formatter-DqAKDlvN.js");
8
8
  //#region src/builtins/console-logging/console-destination.ts
9
9
  var LEVEL_RANK = {
@@ -1,4 +1,4 @@
1
- import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-B67DC-Ss.mjs";
1
+ import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-BHlcm97I.mjs";
2
2
  import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
3
3
  //#region src/builtins/console-logging/console-destination.ts
4
4
  var LEVEL_RANK = {
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_chunk = require("../../chunk-Cek0wNdY.js");
3
- const require_dist = require("../../dist-DluLUTzR.js");
3
+ const require_dist = require("../../dist-BW7x4kAI.js");
4
4
  let node_crypto = require("node:crypto");
5
5
  let node_fs_promises = require("node:fs/promises");
6
6
  node_fs_promises = require_chunk.__toESM(node_fs_promises);
@@ -1,4 +1,4 @@
1
- import { B as coreBlockAddonId, H as coreBlocksCapability, V as coreBlockIdFromAddonId, Xt as errMsg, Zt as BaseAddon, c as CORE_BLOCK_ADDON_PREFIX, d as DeclaredDevices, l as CoreBlockSchema, s as CORE_BLOCKS_ADDON_ID } from "../../dist-B67DC-Ss.mjs";
1
+ import { B as coreBlockAddonId, H as coreBlocksCapability, V as coreBlockIdFromAddonId, Xt as errMsg, Zt as BaseAddon, c as CORE_BLOCK_ADDON_PREFIX, d as DeclaredDevices, l as CoreBlockSchema, s as CORE_BLOCKS_ADDON_ID } from "../../dist-BHlcm97I.mjs";
2
2
  import { randomUUID } from "node:crypto";
3
3
  import * as fs from "node:fs/promises";
4
4
  import * as path$1 from "node:path";
@@ -3,8 +3,8 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
7
- const require_retired_settings_keys = require("../../retired-settings-keys-VcrnwKN0.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
+ const require_retired_settings_keys = require("../../retired-settings-keys-CeaYCDU4.js");
8
8
  let node_crypto = require("node:crypto");
9
9
  let _camstack_types_node = require("@camstack/types/node");
10
10
  //#region src/builtins/device-manager/adoption-job-engine.ts
@@ -1,5 +1,5 @@
1
- import { C as STREAM_PROFILE_META, Cn as EventCategory, Et as parseStreamParamsFormPatch, J as deviceStatusCapability, K as deviceManagerCapability, Pt as runtimeStatePolicyFor, Q as enumerateSchemaFields, R as buildStreamParamsConfigSchema, Sn as sleep$1, Xt as errMsg, Z as enumerateItemArrayFields, Zt as BaseAddon, a as CAMERA_SWITCH_ORDER, f as DeviceStatusSchema, gt as locationIconKey, h as LocationIconIdSchema, hn as isDeviceConfigCap, jt as resolveContainerPrimaryChild, nn as DeviceRole, o as CAP_NAMES_WITH_STATUS, on as WELL_KNOWN_TAB_MAP, q as deviceStateCapability, rn as DeviceType, t as ALL_CAPABILITY_DEFINITIONS, tn as DeviceFeature, wt as normalizeUnit, zt as siteZoneKey } from "../../dist-B67DC-Ss.mjs";
2
- import { n as purgeRetiredSettingsRows } from "../../retired-settings-keys-oN5dGOi5.mjs";
1
+ import { C as STREAM_PROFILE_META, Cn as EventCategory, Et as parseStreamParamsFormPatch, J as deviceStatusCapability, K as deviceManagerCapability, Pt as runtimeStatePolicyFor, Q as enumerateSchemaFields, R as buildStreamParamsConfigSchema, Sn as sleep$1, Xt as errMsg, Z as enumerateItemArrayFields, Zt as BaseAddon, a as CAMERA_SWITCH_ORDER, f as DeviceStatusSchema, gt as locationIconKey, h as LocationIconIdSchema, hn as isDeviceConfigCap, jt as resolveContainerPrimaryChild, nn as DeviceRole, o as CAP_NAMES_WITH_STATUS, on as WELL_KNOWN_TAB_MAP, q as deviceStateCapability, rn as DeviceType, t as ALL_CAPABILITY_DEFINITIONS, tn as DeviceFeature, wt as normalizeUnit, zt as siteZoneKey } from "../../dist-BHlcm97I.mjs";
2
+ import { n as purgeRetiredSettingsRows } from "../../retired-settings-keys-lPlv147H.mjs";
3
3
  import { randomUUID } from "node:crypto";
4
4
  import { canonicalDeviceFingerprint } from "@camstack/types/node";
5
5
  //#region src/builtins/device-manager/adoption-job-engine.ts
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  //#region src/builtins/doorbell/trigger-engine.ts
8
8
  /**
9
9
  * Pure trigger logic for the virtual-doorbell builtin — edge detection over
@@ -1,4 +1,4 @@
1
- import { $ as evaluateSensorEdge, Cn as EventCategory, I as bareAddonId, Xt as errMsg, Y as doorbellCapability, Zt as BaseAddon, b as SOURCE_CAPS, lt as isSameAddonId, rn as DeviceType, un as createEvent, ut as isSourceCap, x as SOURCE_DEVICE_TYPES } from "../../dist-B67DC-Ss.mjs";
1
+ import { $ as evaluateSensorEdge, Cn as EventCategory, I as bareAddonId, Xt as errMsg, Y as doorbellCapability, Zt as BaseAddon, b as SOURCE_CAPS, lt as isSameAddonId, rn as DeviceType, un as createEvent, ut as isSourceCap, x as SOURCE_DEVICE_TYPES } from "../../dist-BHlcm97I.mjs";
2
2
  //#region src/builtins/doorbell/trigger-engine.ts
3
3
  /**
4
4
  * Pure trigger logic for the virtual-doorbell builtin — edge detection over
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  const require_formatter = require("../../formatter-DqAKDlvN.js");
8
8
  //#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
9
9
  var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
@@ -1,4 +1,4 @@
1
- import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-B67DC-Ss.mjs";
1
+ import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-BHlcm97I.mjs";
2
2
  import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
3
3
  //#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
4
4
  var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  require("../../chunk-Cek0wNdY.js");
3
- const require_dist = require("../../dist-DluLUTzR.js");
3
+ const require_dist = require("../../dist-BW7x4kAI.js");
4
4
  //#region src/builtins/liveness-monitor/liveness-checks.ts
5
5
  var NO_DEVICES = "liveness:no-devices";
6
6
  var ALL_OFFLINE = "liveness:all-devices-offline";
@@ -1,4 +1,4 @@
1
- import { Cn as EventCategory, Xt as errMsg, Zt as BaseAddon, un as createEvent, y as RecordingStatusSchema } from "../../dist-B67DC-Ss.mjs";
1
+ import { Cn as EventCategory, Xt as errMsg, Zt as BaseAddon, un as createEvent, y as RecordingStatusSchema } from "../../dist-BHlcm97I.mjs";
2
2
  //#region src/builtins/liveness-monitor/liveness-checks.ts
3
3
  var NO_DEVICES = "liveness:no-devices";
4
4
  var ALL_OFFLINE = "liveness:all-devices-offline";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  let node_crypto = require("node:crypto");
8
8
  node_crypto = require_chunk.__toESM(node_crypto);
9
9
  let crypto$1 = require("crypto");
@@ -1,5 +1,5 @@
1
1
  import { i as __require, o as __toESM, t as __commonJSMin } from "../../chunk-CNf5ZN-e.mjs";
2
- import { Kt as userManagementCapability, P as authProviderCapability, Zt as BaseAddon, k as UserRecordSchema, r as ApiKeyRecordSchema, w as ScopedTokenSchema } from "../../dist-B67DC-Ss.mjs";
2
+ import { Kt as userManagementCapability, P as authProviderCapability, Zt as BaseAddon, k as UserRecordSchema, r as ApiKeyRecordSchema, w as ScopedTokenSchema } from "../../dist-BHlcm97I.mjs";
3
3
  import * as crypto$2 from "node:crypto";
4
4
  import { createHash, randomUUID, timingSafeEqual } from "node:crypto";
5
5
  import nodeCrypto from "crypto";
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_chunk = require("../../chunk-Cek0wNdY.js");
3
- const require_dist = require("../../dist-DluLUTzR.js");
3
+ const require_dist = require("../../dist-BW7x4kAI.js");
4
4
  const require_tls = require("../../tls-BFs4PzoW.js");
5
5
  let node_fs_promises = require("node:fs/promises");
6
6
  let node_path = require("node:path");
@@ -1,4 +1,4 @@
1
- import { Cn as EventCategory, Zt as BaseAddon, ht as localNetworkCapability } from "../../dist-B67DC-Ss.mjs";
1
+ import { Cn as EventCategory, Zt as BaseAddon, ht as localNetworkCapability } from "../../dist-BHlcm97I.mjs";
2
2
  import { S as readLanHttpState, _ as DEFAULT_LAN_HTTP_PORT, a as writeTlsMode, i as writeExtraSans, l as reissueTlsLeaf, n as readTlsAccessStatus, o as validateUploadedTls, r as readTlsMode, s as ensureTlsCert, t as readExtraSans, y as applyLanHttp } from "../../tls-2xbgg78V.mjs";
3
3
  import { mkdir, writeFile } from "node:fs/promises";
4
4
  import { join } from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  //#region src/builtins/loki-logging/loki-payload.ts
8
8
  /**
9
9
  * Loki rejects a label name that is not a valid Prometheus label
@@ -1,4 +1,4 @@
1
- import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-B67DC-Ss.mjs";
1
+ import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-BHlcm97I.mjs";
2
2
  //#region src/builtins/loki-logging/loki-payload.ts
3
3
  /**
4
4
  * Loki rejects a label name that is not a valid Prometheus label
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  let node_fs_promises = require("node:fs/promises");
8
8
  let node_fs = require("node:fs");
9
9
  node_fs = require_chunk.__toESM(node_fs);
@@ -1,4 +1,4 @@
1
- import { At as resolveBucketMs, Cn as EventCategory, St as metricsProviderCapability, Xt as errMsg, Zt as BaseAddon, kt as reducePoints, rt as foldSnapshotByFunction, un as createEvent } from "../../dist-B67DC-Ss.mjs";
1
+ import { At as resolveBucketMs, Cn as EventCategory, St as metricsProviderCapability, Xt as errMsg, Zt as BaseAddon, kt as reducePoints, rt as foldSnapshotByFunction, un as createEvent } from "../../dist-BHlcm97I.mjs";
2
2
  import { access, readFile, readdir } from "node:fs/promises";
3
3
  import * as fs from "node:fs";
4
4
  import { constants, readFileSync } from "node:fs";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  let node_fs = require("node:fs");
8
8
  node_fs = require_chunk.__toESM(node_fs);
9
9
  let node_child_process = require("node:child_process");
@@ -1,5 +1,5 @@
1
1
  import { o as __toESM } from "../../chunk-CNf5ZN-e.mjs";
2
- import { Cn as EventCategory, Dt as platformProbeCapability, Lt as scoreRuntimes, X as enumerateInferenceDevices, Xt as errMsg, Zt as BaseAddon, fn as emitReadiness } from "../../dist-B67DC-Ss.mjs";
2
+ import { Cn as EventCategory, Dt as platformProbeCapability, Lt as scoreRuntimes, X as enumerateInferenceDevices, Xt as errMsg, Zt as BaseAddon, fn as emitReadiness } from "../../dist-BHlcm97I.mjs";
3
3
  import * as fs from "node:fs";
4
4
  import { execFile } from "node:child_process";
5
5
  import * as os from "node:os";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  //#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
8
8
  /**
9
9
  * Reconcile the durable `enabledProviders` set against authoritative
@@ -1,4 +1,4 @@
1
- import { Cn as EventCategory, Zt as BaseAddon } from "../../dist-B67DC-Ss.mjs";
1
+ import { Cn as EventCategory, Zt as BaseAddon } from "../../dist-BHlcm97I.mjs";
2
2
  //#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
3
3
  /**
4
4
  * Reconcile the durable `enabledProviders` set against authoritative
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  const require_snapshot_courtesy = require("../../snapshot-courtesy-Cqs7GkOV.js");
8
8
  let zod = require("zod");
9
9
  let node_crypto = require("node:crypto");
@@ -1,4 +1,4 @@
1
- import { Bt as snapshotCapability, Cn as EventCategory, G as deriveBatteryPresence, Gt as streamQualityLabel, I as bareAddonId, L as batteryCapability, Xt as errMsg, Zt as BaseAddon, gn as nodePin, i as BatteryStatusSchema, rn as DeviceType, tn as DeviceFeature } from "../../dist-B67DC-Ss.mjs";
1
+ import { Bt as snapshotCapability, Cn as EventCategory, G as deriveBatteryPresence, Gt as streamQualityLabel, I as bareAddonId, L as batteryCapability, Xt as errMsg, Zt as BaseAddon, gn as nodePin, i as BatteryStatusSchema, rn as DeviceType, tn as DeviceFeature } from "../../dist-BHlcm97I.mjs";
2
2
  import { i as renderCourtesyOverlayJpeg, n as courtesyCacheKey, r as renderCourtesyJpeg } from "../../snapshot-courtesy-CZPvteq2.mjs";
3
3
  import { z } from "zod";
4
4
  import { randomUUID } from "node:crypto";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  let node_crypto = require("node:crypto");
8
8
  let node_fs_promises = require("node:fs/promises");
9
9
  let node_path = require("node:path");
@@ -1,4 +1,4 @@
1
- import { Wt as storageProviderCapability, Zt as BaseAddon, nt as filesystemBrowseCapability } from "../../dist-B67DC-Ss.mjs";
1
+ import { Wt as storageProviderCapability, Zt as BaseAddon, nt as filesystemBrowseCapability } from "../../dist-BHlcm97I.mjs";
2
2
  import { randomUUID } from "node:crypto";
3
3
  import { mkdir, readdir, realpath, statfs } from "node:fs/promises";
4
4
  import * as path$1 from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  const require_hub_cap_forward = require("../../hub-cap-forward-DmHNjbB0.js");
8
8
  let zod = require("zod");
9
9
  let node_crypto = require("node:crypto");
@@ -1,4 +1,4 @@
1
- import { Cn as EventCategory, Ct as modeMayWrite, D as StorageLocationTypeSchema, E as StorageLocationModeSchema, Ht as storageMigrationCapability, Mt as resolveLocationMode, O as StorageMigrationJobSchema, Rt as settingsStoreCapability, T as StorageCleanupJobSchema, Vt as storageCapability, Yt as withLocationMode, Zt as BaseAddon, _ as REDACTED_SECRET, _n as parseJsonObject, bt as mayReadLocation, et as evictionPolicyOfLocation, it as gbToBytes, m as LegacyStorageLocationDefaultSchema, pt as legacyModeOf, st as isLocationEnabled, xt as mayWriteToLocation, z as collectSecretConfigKeys } from "../../dist-B67DC-Ss.mjs";
1
+ import { Cn as EventCategory, Ct as modeMayWrite, D as StorageLocationTypeSchema, E as StorageLocationModeSchema, Ht as storageMigrationCapability, Mt as resolveLocationMode, O as StorageMigrationJobSchema, Rt as settingsStoreCapability, T as StorageCleanupJobSchema, Vt as storageCapability, Yt as withLocationMode, Zt as BaseAddon, _ as REDACTED_SECRET, _n as parseJsonObject, bt as mayReadLocation, et as evictionPolicyOfLocation, it as gbToBytes, m as LegacyStorageLocationDefaultSchema, pt as legacyModeOf, st as isLocationEnabled, xt as mayWriteToLocation, z as collectSecretConfigKeys } from "../../dist-BHlcm97I.mjs";
2
2
  import { t as HUB_CAP_FWD_ACTION } from "../../hub-cap-forward-BdT320dq.mjs";
3
3
  import { z } from "zod";
4
4
  import { randomUUID } from "node:crypto";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  //#region src/builtins/system-config/system-config.addon.ts
8
8
  /**
9
9
  * Built-in `system-config` addon — Phase 4 of the settings redesign.
@@ -1,4 +1,4 @@
1
- import { Xt as errMsg, Zt as BaseAddon, mn as hydrateSchema } from "../../dist-B67DC-Ss.mjs";
1
+ import { Xt as errMsg, Zt as BaseAddon, mn as hydrateSchema } from "../../dist-BHlcm97I.mjs";
2
2
  //#region src/builtins/system-config/system-config.addon.ts
3
3
  /**
4
4
  * Built-in `system-config` addon — Phase 4 of the settings redesign.
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-DluLUTzR.js");
6
+ const require_dist = require("../../dist-BW7x4kAI.js");
7
7
  const require_formatter = require("../../formatter-DqAKDlvN.js");
8
8
  let node_path = require("node:path");
9
9
  node_path = require_chunk.__toESM(node_path);
@@ -1,4 +1,4 @@
1
- import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-B67DC-Ss.mjs";
1
+ import { Zt as BaseAddon, _t as logDestinationCapability } from "../../dist-BHlcm97I.mjs";
2
2
  import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
3
3
  import * as path$1 from "node:path";
4
4
  import path from "node:path";
@@ -690,7 +690,7 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
690
690
  return EventCategory;
691
691
  }({});
692
692
  //#endregion
693
- //#region ../types/dist/sleep-BDR76Ykr.mjs
693
+ //#region ../types/dist/sleep-B1y0Fo1U.mjs
694
694
  /**
695
695
  * The audio chunk plane's byte format, and the ONE expansion from a coded
696
696
  * window to float samples (D455).
@@ -32804,14 +32804,81 @@ var privacyMaskCapability = {
32804
32804
  * whether persisting is worth a SQLite commit. */
32805
32805
  volatileStateFields: ["lastFetchedAt"]
32806
32806
  };
32807
+ /**
32808
+ * What a preset id DOES on this camera.
32809
+ *
32810
+ * On several PTZ firmwares the preset namespace is shared: low ids are stored
32811
+ * positions, a reserved band triggers camera FUNCTIONS. The dispensa camera
32812
+ * (Hikvision) returns its own reserved band in the preset list, named by the
32813
+ * firmware:
32814
+ *
32815
+ * 34 Back to origin · 39 Day mode · 40 Night mode · 46 Day/Night Auto Mode
32816
+ * 92 Set manual limits · 93 Save manual limits · 94 Remote reboot
32817
+ * 95 Call OSD menu
32818
+ *
32819
+ * We used to hand all of these to the UI as ordinary presets. Saving over one
32820
+ * is what produced `PUT /ISAPI/PTZCtrl/channels/1/presets/34 -> HTTP 500`: the
32821
+ * camera refusing to let "Back to origin" be overwritten, surfaced to the
32822
+ * operator as a transport failure.
32823
+ *
32824
+ * A function preset stays fully usable as a DESTINATION -- `goToPreset('34')`
32825
+ * is the single most useful thing that camera can do. Only `savePreset` and
32826
+ * `deletePreset` are gated.
32827
+ */
32828
+ var PtzPresetFunctionSchema = z.enum([
32829
+ "home",
32830
+ "day-mode",
32831
+ "night-mode",
32832
+ "day-night-auto",
32833
+ "set-limits",
32834
+ "save-limits",
32835
+ "reboot",
32836
+ "osd-menu"
32837
+ ]);
32807
32838
  var PtzPresetSchema = z.object({
32808
32839
  id: z.string(),
32809
- name: z.string()
32840
+ name: z.string(),
32841
+ /**
32842
+ * The firmware function this id performs, when the provider KNOWS the id is
32843
+ * reserved. `null` = an ordinary stored position, OR a reserved id this
32844
+ * provider does not recognise -- the two are told apart by `writable`.
32845
+ */
32846
+ fn: PtzPresetFunctionSchema.nullable(),
32847
+ /**
32848
+ * Whether `savePreset` / `deletePreset` may target this id. A provider sets
32849
+ * it false only for a band it KNOWS is reserved; where the firmware is not
32850
+ * documented it stays true and a refusal comes from the camera, named.
32851
+ */
32852
+ writable: z.boolean()
32810
32853
  });
32854
+ /**
32855
+ * Where the head is pointing -- per axis, and `null` when the driver cannot
32856
+ * read it.
32857
+ *
32858
+ * It used to be three REQUIRED numbers, which left a provider that cannot read
32859
+ * position no way to say so. All four said `0`:
32860
+ *
32861
+ * reolink `return { pan: 0, tilt: 0, zoom: 0 }` "until a position-query
32862
+ * path lands upstream"
32863
+ * hikvision stub, "firmware-dependent and frequently absent"
32864
+ * amcrest stub, "no generic absolute-position read for this model family"
32865
+ * onvif throws
32866
+ *
32867
+ * So every consumer asking where a camera points was told "perfectly centred"
32868
+ * by four cameras that had never looked. That is D393 -- a measurement that
32869
+ * FAILED is `null`, never `0`, and the type says so all the way to the
32870
+ * decision -- the same shape as the unreadable `statfs` folded into "0 bytes of
32871
+ * headroom", which evacuated a healthy disk.
32872
+ *
32873
+ * D393 also says to check for a narrower structural TWIN of the result type.
32874
+ * There is one: `PtzStatusSchema` extends this, so the lie had already
32875
+ * propagated into `getStatus`, which is the surface `getPosition`'s own comment
32876
+ * tells callers to migrate to.
32877
+ */
32811
32878
  var PtzPositionSchema = z.object({
32812
- pan: z.number(),
32813
- tilt: z.number(),
32814
- zoom: z.number()
32879
+ pan: z.number().nullable(),
32880
+ tilt: z.number().nullable(),
32881
+ zoom: z.number().nullable()
32815
32882
  });
32816
32883
  var PtzMoveCommandSchema = z.object({
32817
32884
  pan: z.number().optional(),
@@ -32833,7 +32900,72 @@ var PtzOptionsSchema = z.object({
32833
32900
  maxPresets: z.number().optional(),
32834
32901
  /** Whether the camera exposes a controllable autofocus toggle
32835
32902
  * (boolean `hasX` per the getOptions availability convention). */
32836
- hasAutofocus: z.boolean()
32903
+ hasAutofocus: z.boolean(),
32904
+ /**
32905
+ * How many distinct speeds this camera's NATIVE scale offers.
32906
+ *
32907
+ * The cap's `speed` is normalized 0..1 and each provider maps it down --
32908
+ * Baichuan 1..63, Dahua 1..8, ISAPI's percentage -100..100. The normalized
32909
+ * value hides how coarse that really is: asking an amcrest for `0.37` is
32910
+ * meaningless, because it has eight steps and three of them round to the
32911
+ * same one. A loop that tunes its own gain has to know the granularity of
32912
+ * the knob it is turning.
32913
+ *
32914
+ * `null` = the driver does not know, or the scale is continuous (ONVIF takes
32915
+ * a float). Never a made-up number.
32916
+ */
32917
+ speedSteps: z.number().int().positive().nullable(),
32918
+ /**
32919
+ * How long ONE `move` pulse runs on this driver, ms.
32920
+ *
32921
+ * `move` is a self-terminating burst everywhere, but every provider hardcoded
32922
+ * its own duration in private -- 200 reolink, 350 amcrest, 500 hikvision,
32923
+ * 1000 onvif -- so no caller could read it. It is the DENOMINATOR of "how far
32924
+ * did the head travel per pulse": without it a measured displacement has no
32925
+ * gain to be divided into.
32926
+ *
32927
+ * `null` = the driver cannot say.
32928
+ */
32929
+ moveImpulseMs: z.number().int().positive().nullable()
32930
+ });
32931
+ /**
32932
+ * Which preset `goHome` goes to, and WHO decided.
32933
+ *
32934
+ * `goHome` used to be three vendor "conventions" written in three comments --
32935
+ * Reolink preset 0, Hikvision preset '1', Dahua preset 1 -- and on this fleet
32936
+ * not one of the three cameras honours its own:
32937
+ *
32938
+ * 592 Videocamera camera Daniel (reolink) preset 0 holds "stanza"
32939
+ * 1438 Videocamera dispensa (hikvision) preset 1 holds "Credenza"
32940
+ * 3836 Videocamera studio (amcrest) preset 1 holds "Preset1"
32941
+ *
32942
+ * So `goHome` meant "go wherever the operator happened to save in slot 0 or 1",
32943
+ * and two of the three swallowed the failure in a bare `catch`. For autotrack
32944
+ * this is the HOTTEST path -- it runs every time a subject is released -- so it
32945
+ * needs an answer that is true per camera and audible when it is missing.
32946
+ *
32947
+ * `source` is what makes it honest:
32948
+ * - `operator` -- picked in the UI, stored by the provider.
32949
+ * - `firmware` -- the camera itself named a preset `fn: 'home'` (Hikvision's
32950
+ * "Back to origin"), adopted as the default with nothing to configure.
32951
+ * - `native` -- the driver homes WITHOUT a preset at all. ONVIF does:
32952
+ * `goHome` is `ptzAbsoluteMove({x:0, y:0, zoom:0})`. `presetId` is null and
32953
+ * that is not a failure -- there is nothing to pick, and the UI must offer
32954
+ * no picker.
32955
+ * - `none` -- nothing is configured and the camera names nothing.
32956
+ * `goHome` REFUSES rather than moving the head somewhere arbitrary.
32957
+ *
32958
+ * `source === 'none'` is the refusal condition, NOT `presetId === null`: the
32959
+ * native case has no preset and homes perfectly well.
32960
+ */
32961
+ var PtzHomePresetSchema = z.object({
32962
+ presetId: z.string().nullable(),
32963
+ source: z.enum([
32964
+ "operator",
32965
+ "firmware",
32966
+ "native",
32967
+ "none"
32968
+ ])
32837
32969
  });
32838
32970
  var ptzCapability = {
32839
32971
  name: "ptz",
@@ -32874,7 +33006,25 @@ var ptzCapability = {
32874
33006
  auth: "admin"
32875
33007
  }),
32876
33008
  getOptions: method(z.object({ deviceId: z.number() }), PtzOptionsSchema),
33009
+ /**
33010
+ * Move to the camera's configured home preset. THROWS when
33011
+ * `getHomePreset()` resolves to `none` -- a head that did not move must
33012
+ * never look like a head that went home.
33013
+ */
32877
33014
  goHome: method(z.object({ deviceId: z.number() }), z.void(), { kind: "mutation" }),
33015
+ /** Which preset `goHome` targets, and who decided it. */
33016
+ getHomePreset: method(z.object({ deviceId: z.number() }), PtzHomePresetSchema),
33017
+ /**
33018
+ * Pin the home preset for this camera. `null` clears the operator's choice
33019
+ * and falls back to whatever the firmware names, or to `none`.
33020
+ */
33021
+ setHomePreset: method(z.object({
33022
+ deviceId: z.number(),
33023
+ presetId: z.string().nullable()
33024
+ }), z.void(), {
33025
+ kind: "mutation",
33026
+ auth: "admin"
33027
+ }),
32878
33028
  /**
32879
33029
  * Pull the current PTZ position. Redundant with the auto-injected
32880
33030
  * `getStatus` method (see `status` below); kept for callers that
@@ -42271,6 +42421,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
42271
42421
  addonId: null,
42272
42422
  access: "delete"
42273
42423
  },
42424
+ "ptz.getHomePreset": {
42425
+ capName: "ptz",
42426
+ capScope: "device",
42427
+ addonId: null,
42428
+ access: "view"
42429
+ },
42274
42430
  "ptz.getOptions": {
42275
42431
  capName: "ptz",
42276
42432
  capScope: "device",
@@ -42319,6 +42475,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
42319
42475
  addonId: null,
42320
42476
  access: "create"
42321
42477
  },
42478
+ "ptz.setHomePreset": {
42479
+ capName: "ptz",
42480
+ capScope: "device",
42481
+ addonId: null,
42482
+ access: "create"
42483
+ },
42322
42484
  "ptz.stop": {
42323
42485
  capName: "ptz",
42324
42486
  capScope: "device",
@@ -45492,6 +45654,11 @@ Object.freeze({
45492
45654
  form: "single",
45493
45655
  optional: false
45494
45656
  }],
45657
+ "ptz.getHomePreset": [{
45658
+ name: "deviceId",
45659
+ form: "single",
45660
+ optional: false
45661
+ }],
45495
45662
  "ptz.getOptions": [{
45496
45663
  name: "deviceId",
45497
45664
  form: "single",
@@ -45532,6 +45699,11 @@ Object.freeze({
45532
45699
  form: "single",
45533
45700
  optional: false
45534
45701
  }],
45702
+ "ptz.setHomePreset": [{
45703
+ name: "deviceId",
45704
+ form: "single",
45705
+ optional: false
45706
+ }],
45535
45707
  "ptz.stop": [{
45536
45708
  name: "deviceId",
45537
45709
  form: "single",
@@ -690,7 +690,7 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
690
690
  return EventCategory;
691
691
  }({});
692
692
  //#endregion
693
- //#region ../types/dist/sleep-BDR76Ykr.mjs
693
+ //#region ../types/dist/sleep-B1y0Fo1U.mjs
694
694
  /**
695
695
  * The audio chunk plane's byte format, and the ONE expansion from a coded
696
696
  * window to float samples (D455).
@@ -32804,14 +32804,81 @@ var privacyMaskCapability = {
32804
32804
  * whether persisting is worth a SQLite commit. */
32805
32805
  volatileStateFields: ["lastFetchedAt"]
32806
32806
  };
32807
+ /**
32808
+ * What a preset id DOES on this camera.
32809
+ *
32810
+ * On several PTZ firmwares the preset namespace is shared: low ids are stored
32811
+ * positions, a reserved band triggers camera FUNCTIONS. The dispensa camera
32812
+ * (Hikvision) returns its own reserved band in the preset list, named by the
32813
+ * firmware:
32814
+ *
32815
+ * 34 Back to origin · 39 Day mode · 40 Night mode · 46 Day/Night Auto Mode
32816
+ * 92 Set manual limits · 93 Save manual limits · 94 Remote reboot
32817
+ * 95 Call OSD menu
32818
+ *
32819
+ * We used to hand all of these to the UI as ordinary presets. Saving over one
32820
+ * is what produced `PUT /ISAPI/PTZCtrl/channels/1/presets/34 -> HTTP 500`: the
32821
+ * camera refusing to let "Back to origin" be overwritten, surfaced to the
32822
+ * operator as a transport failure.
32823
+ *
32824
+ * A function preset stays fully usable as a DESTINATION -- `goToPreset('34')`
32825
+ * is the single most useful thing that camera can do. Only `savePreset` and
32826
+ * `deletePreset` are gated.
32827
+ */
32828
+ var PtzPresetFunctionSchema = zod.z.enum([
32829
+ "home",
32830
+ "day-mode",
32831
+ "night-mode",
32832
+ "day-night-auto",
32833
+ "set-limits",
32834
+ "save-limits",
32835
+ "reboot",
32836
+ "osd-menu"
32837
+ ]);
32807
32838
  var PtzPresetSchema = zod.z.object({
32808
32839
  id: zod.z.string(),
32809
- name: zod.z.string()
32840
+ name: zod.z.string(),
32841
+ /**
32842
+ * The firmware function this id performs, when the provider KNOWS the id is
32843
+ * reserved. `null` = an ordinary stored position, OR a reserved id this
32844
+ * provider does not recognise -- the two are told apart by `writable`.
32845
+ */
32846
+ fn: PtzPresetFunctionSchema.nullable(),
32847
+ /**
32848
+ * Whether `savePreset` / `deletePreset` may target this id. A provider sets
32849
+ * it false only for a band it KNOWS is reserved; where the firmware is not
32850
+ * documented it stays true and a refusal comes from the camera, named.
32851
+ */
32852
+ writable: zod.z.boolean()
32810
32853
  });
32854
+ /**
32855
+ * Where the head is pointing -- per axis, and `null` when the driver cannot
32856
+ * read it.
32857
+ *
32858
+ * It used to be three REQUIRED numbers, which left a provider that cannot read
32859
+ * position no way to say so. All four said `0`:
32860
+ *
32861
+ * reolink `return { pan: 0, tilt: 0, zoom: 0 }` "until a position-query
32862
+ * path lands upstream"
32863
+ * hikvision stub, "firmware-dependent and frequently absent"
32864
+ * amcrest stub, "no generic absolute-position read for this model family"
32865
+ * onvif throws
32866
+ *
32867
+ * So every consumer asking where a camera points was told "perfectly centred"
32868
+ * by four cameras that had never looked. That is D393 -- a measurement that
32869
+ * FAILED is `null`, never `0`, and the type says so all the way to the
32870
+ * decision -- the same shape as the unreadable `statfs` folded into "0 bytes of
32871
+ * headroom", which evacuated a healthy disk.
32872
+ *
32873
+ * D393 also says to check for a narrower structural TWIN of the result type.
32874
+ * There is one: `PtzStatusSchema` extends this, so the lie had already
32875
+ * propagated into `getStatus`, which is the surface `getPosition`'s own comment
32876
+ * tells callers to migrate to.
32877
+ */
32811
32878
  var PtzPositionSchema = zod.z.object({
32812
- pan: zod.z.number(),
32813
- tilt: zod.z.number(),
32814
- zoom: zod.z.number()
32879
+ pan: zod.z.number().nullable(),
32880
+ tilt: zod.z.number().nullable(),
32881
+ zoom: zod.z.number().nullable()
32815
32882
  });
32816
32883
  var PtzMoveCommandSchema = zod.z.object({
32817
32884
  pan: zod.z.number().optional(),
@@ -32833,7 +32900,72 @@ var PtzOptionsSchema = zod.z.object({
32833
32900
  maxPresets: zod.z.number().optional(),
32834
32901
  /** Whether the camera exposes a controllable autofocus toggle
32835
32902
  * (boolean `hasX` per the getOptions availability convention). */
32836
- hasAutofocus: zod.z.boolean()
32903
+ hasAutofocus: zod.z.boolean(),
32904
+ /**
32905
+ * How many distinct speeds this camera's NATIVE scale offers.
32906
+ *
32907
+ * The cap's `speed` is normalized 0..1 and each provider maps it down --
32908
+ * Baichuan 1..63, Dahua 1..8, ISAPI's percentage -100..100. The normalized
32909
+ * value hides how coarse that really is: asking an amcrest for `0.37` is
32910
+ * meaningless, because it has eight steps and three of them round to the
32911
+ * same one. A loop that tunes its own gain has to know the granularity of
32912
+ * the knob it is turning.
32913
+ *
32914
+ * `null` = the driver does not know, or the scale is continuous (ONVIF takes
32915
+ * a float). Never a made-up number.
32916
+ */
32917
+ speedSteps: zod.z.number().int().positive().nullable(),
32918
+ /**
32919
+ * How long ONE `move` pulse runs on this driver, ms.
32920
+ *
32921
+ * `move` is a self-terminating burst everywhere, but every provider hardcoded
32922
+ * its own duration in private -- 200 reolink, 350 amcrest, 500 hikvision,
32923
+ * 1000 onvif -- so no caller could read it. It is the DENOMINATOR of "how far
32924
+ * did the head travel per pulse": without it a measured displacement has no
32925
+ * gain to be divided into.
32926
+ *
32927
+ * `null` = the driver cannot say.
32928
+ */
32929
+ moveImpulseMs: zod.z.number().int().positive().nullable()
32930
+ });
32931
+ /**
32932
+ * Which preset `goHome` goes to, and WHO decided.
32933
+ *
32934
+ * `goHome` used to be three vendor "conventions" written in three comments --
32935
+ * Reolink preset 0, Hikvision preset '1', Dahua preset 1 -- and on this fleet
32936
+ * not one of the three cameras honours its own:
32937
+ *
32938
+ * 592 Videocamera camera Daniel (reolink) preset 0 holds "stanza"
32939
+ * 1438 Videocamera dispensa (hikvision) preset 1 holds "Credenza"
32940
+ * 3836 Videocamera studio (amcrest) preset 1 holds "Preset1"
32941
+ *
32942
+ * So `goHome` meant "go wherever the operator happened to save in slot 0 or 1",
32943
+ * and two of the three swallowed the failure in a bare `catch`. For autotrack
32944
+ * this is the HOTTEST path -- it runs every time a subject is released -- so it
32945
+ * needs an answer that is true per camera and audible when it is missing.
32946
+ *
32947
+ * `source` is what makes it honest:
32948
+ * - `operator` -- picked in the UI, stored by the provider.
32949
+ * - `firmware` -- the camera itself named a preset `fn: 'home'` (Hikvision's
32950
+ * "Back to origin"), adopted as the default with nothing to configure.
32951
+ * - `native` -- the driver homes WITHOUT a preset at all. ONVIF does:
32952
+ * `goHome` is `ptzAbsoluteMove({x:0, y:0, zoom:0})`. `presetId` is null and
32953
+ * that is not a failure -- there is nothing to pick, and the UI must offer
32954
+ * no picker.
32955
+ * - `none` -- nothing is configured and the camera names nothing.
32956
+ * `goHome` REFUSES rather than moving the head somewhere arbitrary.
32957
+ *
32958
+ * `source === 'none'` is the refusal condition, NOT `presetId === null`: the
32959
+ * native case has no preset and homes perfectly well.
32960
+ */
32961
+ var PtzHomePresetSchema = zod.z.object({
32962
+ presetId: zod.z.string().nullable(),
32963
+ source: zod.z.enum([
32964
+ "operator",
32965
+ "firmware",
32966
+ "native",
32967
+ "none"
32968
+ ])
32837
32969
  });
32838
32970
  var ptzCapability = {
32839
32971
  name: "ptz",
@@ -32874,7 +33006,25 @@ var ptzCapability = {
32874
33006
  auth: "admin"
32875
33007
  }),
32876
33008
  getOptions: method(zod.z.object({ deviceId: zod.z.number() }), PtzOptionsSchema),
33009
+ /**
33010
+ * Move to the camera's configured home preset. THROWS when
33011
+ * `getHomePreset()` resolves to `none` -- a head that did not move must
33012
+ * never look like a head that went home.
33013
+ */
32877
33014
  goHome: method(zod.z.object({ deviceId: zod.z.number() }), zod.z.void(), { kind: "mutation" }),
33015
+ /** Which preset `goHome` targets, and who decided it. */
33016
+ getHomePreset: method(zod.z.object({ deviceId: zod.z.number() }), PtzHomePresetSchema),
33017
+ /**
33018
+ * Pin the home preset for this camera. `null` clears the operator's choice
33019
+ * and falls back to whatever the firmware names, or to `none`.
33020
+ */
33021
+ setHomePreset: method(zod.z.object({
33022
+ deviceId: zod.z.number(),
33023
+ presetId: zod.z.string().nullable()
33024
+ }), zod.z.void(), {
33025
+ kind: "mutation",
33026
+ auth: "admin"
33027
+ }),
32878
33028
  /**
32879
33029
  * Pull the current PTZ position. Redundant with the auto-injected
32880
33030
  * `getStatus` method (see `status` below); kept for callers that
@@ -42271,6 +42421,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
42271
42421
  addonId: null,
42272
42422
  access: "delete"
42273
42423
  },
42424
+ "ptz.getHomePreset": {
42425
+ capName: "ptz",
42426
+ capScope: "device",
42427
+ addonId: null,
42428
+ access: "view"
42429
+ },
42274
42430
  "ptz.getOptions": {
42275
42431
  capName: "ptz",
42276
42432
  capScope: "device",
@@ -42319,6 +42475,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
42319
42475
  addonId: null,
42320
42476
  access: "create"
42321
42477
  },
42478
+ "ptz.setHomePreset": {
42479
+ capName: "ptz",
42480
+ capScope: "device",
42481
+ addonId: null,
42482
+ access: "create"
42483
+ },
42322
42484
  "ptz.stop": {
42323
42485
  capName: "ptz",
42324
42486
  capScope: "device",
@@ -45492,6 +45654,11 @@ Object.freeze({
45492
45654
  form: "single",
45493
45655
  optional: false
45494
45656
  }],
45657
+ "ptz.getHomePreset": [{
45658
+ name: "deviceId",
45659
+ form: "single",
45660
+ optional: false
45661
+ }],
45495
45662
  "ptz.getOptions": [{
45496
45663
  name: "deviceId",
45497
45664
  form: "single",
@@ -45532,6 +45699,11 @@ Object.freeze({
45532
45699
  form: "single",
45533
45700
  optional: false
45534
45701
  }],
45702
+ "ptz.setHomePreset": [{
45703
+ name: "deviceId",
45704
+ form: "single",
45705
+ optional: false
45706
+ }],
45535
45707
  "ptz.stop": [{
45536
45708
  name: "deviceId",
45537
45709
  form: "single",
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_chunk = require("./chunk-Cek0wNdY.js");
3
- const require_dist = require("./dist-DluLUTzR.js");
3
+ const require_dist = require("./dist-BW7x4kAI.js");
4
4
  const require_builtins_alerts_alerts_addon = require("./builtins/alerts/alerts.addon.js");
5
5
  require("./builtins/alerts/index.js");
6
6
  const require_formatter = require("./formatter-DqAKDlvN.js");
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import { a as __toCommonJS, i as __require, n as __esmMin, o as __toESM$1, r as __exportAll, t as __commonJSMin$1 } from "./chunk-CNf5ZN-e.mjs";
2
- import { $t as DEVICE_SETTINGS_CONTRIBUTION_METHODS, Cn as EventCategory$1, Ft as scopesAllowAddon, It as scopesAllowDeviceCap, Nt as resolveMethodAuth, Ot as procedureAuthKey, Qt as DATAPLANE_SECRET_HEADER$1, Tt as objectInputDeclaresAddonId, Xt as errMsg$1, _n as parseJsonObject, an as ReadinessTimeoutError, at as isArrayOutputSchema, bn as resolveCapMount, cn as asNumber, ct as isObjectInput, dn as emitDownForOwnedCaps, dt as isVoidInput, en as DEVICE_STATUS_METHOD, ft as kebabToCamel, g as METHOD_ACCESS_MAP, in as ReadinessRegistry, j as addonSettingsCapability, ln as asString$1, mt as lifecycleJobSchema, ot as isCollectionArrayMethod, p as LOG_LEVEL_RANK, pn as expandCapMethods, sn as asJsonObject$1, t as ALL_CAPABILITY_DEFINITIONS, tt as extractNestedAddonId, un as createEvent, v as RUNTIME_DEFAULTS, vn as parseJsonUnknown, vt as logLevelAtMost, xn as scopeKey, yn as readinessKey, yt as looseSchema } from "./dist-B67DC-Ss.mjs";
2
+ import { $t as DEVICE_SETTINGS_CONTRIBUTION_METHODS, Cn as EventCategory$1, Ft as scopesAllowAddon, It as scopesAllowDeviceCap, Nt as resolveMethodAuth, Ot as procedureAuthKey, Qt as DATAPLANE_SECRET_HEADER$1, Tt as objectInputDeclaresAddonId, Xt as errMsg$1, _n as parseJsonObject, an as ReadinessTimeoutError, at as isArrayOutputSchema, bn as resolveCapMount, cn as asNumber, ct as isObjectInput, dn as emitDownForOwnedCaps, dt as isVoidInput, en as DEVICE_STATUS_METHOD, ft as kebabToCamel, g as METHOD_ACCESS_MAP, in as ReadinessRegistry, j as addonSettingsCapability, ln as asString$1, mt as lifecycleJobSchema, ot as isCollectionArrayMethod, p as LOG_LEVEL_RANK, pn as expandCapMethods, sn as asJsonObject$1, t as ALL_CAPABILITY_DEFINITIONS, tt as extractNestedAddonId, un as createEvent, v as RUNTIME_DEFAULTS, vn as parseJsonUnknown, vt as logLevelAtMost, xn as scopeKey, yn as readinessKey, yt as looseSchema } from "./dist-BHlcm97I.mjs";
3
3
  import { AlertCenterAddon } from "./builtins/alerts/alerts.addon.mjs";
4
4
  import "./builtins/alerts/index.mjs";
5
5
  import { t as formatLogLine } from "./formatter-B7qW8bPJ.mjs";
@@ -1,4 +1,4 @@
1
- const require_dist = require("./dist-DluLUTzR.js");
1
+ const require_dist = require("./dist-BW7x4kAI.js");
2
2
  //#region src/builtins/sqlite-storage/retired-settings-keys.ts
3
3
  /**
4
4
  * Is THIS node the one whose settings store is the cluster's authority?
@@ -1,4 +1,4 @@
1
- import { sn as asJsonObject } from "./dist-B67DC-Ss.mjs";
1
+ import { sn as asJsonObject } from "./dist-BHlcm97I.mjs";
2
2
  //#region src/builtins/sqlite-storage/retired-settings-keys.ts
3
3
  /**
4
4
  * Is THIS node the one whose settings store is the cluster's authority?
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/system",
3
- "version": "1.2.249",
3
+ "version": "1.2.250",
4
4
  "description": "Core addon for CamStack — builtins, pipeline, process management, auth, logging, events",
5
5
  "keywords": [
6
6
  "camstack",