camstack 1.1.28 → 1.1.29

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.
@@ -14522,7 +14522,7 @@ function date4(params) {
14522
14522
  // ../../node_modules/zod/v4/classic/external.js
14523
14523
  config(en_default());
14524
14524
 
14525
- // ../types/dist/sleep-B3OHhFkL.mjs
14525
+ // ../types/dist/sleep-DOq2moJx.mjs
14526
14526
  var WELL_KNOWN_TABS = [
14527
14527
  {
14528
14528
  id: "overview",
@@ -21806,7 +21806,11 @@ var ZoneRuleSchema = external_exports.object({
21806
21806
  enabled: external_exports.boolean().default(true)
21807
21807
  });
21808
21808
  var ZoneRulesArraySchema = external_exports.array(ZoneRuleSchema).readonly();
21809
- var ZoneRuleStageEnum = external_exports.enum(["motion", "detection"]);
21809
+ var ZoneRuleStageEnum = external_exports.enum([
21810
+ "motion",
21811
+ "detection",
21812
+ "package"
21813
+ ]);
21810
21814
  var zoneRulesCapability = {
21811
21815
  name: "zone-rules",
21812
21816
  scope: "device",
@@ -21833,16 +21837,24 @@ var zoneRulesCapability = {
21833
21837
  })
21834
21838
  },
21835
21839
  /**
21836
- * Runtime-state slice — both stages mirrored together so consumers
21840
+ * Runtime-state slice — every stage mirrored together so consumers
21837
21841
  * see one reactive handle (`device.state.zoneRules.value`) instead
21838
- * of two. Bulk-replace mutations on either stage write the full
21839
- * `{motion, detection}` shape, so subscribers always get the
21842
+ * of one per stage. Bulk-replace mutations on any stage write the full
21843
+ * `{motion, detection, package}` shape, so subscribers always get the
21840
21844
  * complete current set. Consumers that only care about one stage
21841
21845
  * just read the matching property.
21846
+ *
21847
+ * `package` backs the package-drop detector — a package zone is a
21848
+ * `ZoneRule` on the `'package'` stage referencing drawn polygons
21849
+ * (see docs/superpowers/specs/2026-07-17-package-zones-design.md §3.1).
21850
+ * The orchestrator provider that writes this stage lands in a later
21851
+ * slice; until then the mirror carries only `{motion, detection}` and
21852
+ * consumers read `package` as absent (treat as `[]`).
21842
21853
  */
21843
21854
  runtimeState: external_exports.object({
21844
21855
  motion: external_exports.array(ZoneRuleSchema).readonly(),
21845
- detection: external_exports.array(ZoneRuleSchema).readonly()
21856
+ detection: external_exports.array(ZoneRuleSchema).readonly(),
21857
+ package: external_exports.array(ZoneRuleSchema).readonly()
21846
21858
  })
21847
21859
  };
21848
21860
  var UNIT_TABLE = {
@@ -25594,6 +25606,7 @@ var EventKindIconSchema = external_exports.enum([
25594
25606
  "smoke",
25595
25607
  "water",
25596
25608
  "button",
25609
+ "package",
25597
25610
  "generic"
25598
25611
  ]);
25599
25612
  var EventKindCategorySchema = external_exports.enum([
@@ -25601,7 +25614,8 @@ var EventKindCategorySchema = external_exports.enum([
25601
25614
  "audio",
25602
25615
  "detection",
25603
25616
  "sensor",
25604
- "custom"
25617
+ "custom",
25618
+ "package"
25605
25619
  ]);
25606
25620
  var EventKindDescriptorSchema = external_exports.object({
25607
25621
  /** Stable kind id (e.g. 'motion', 'person', 'contact'). */
@@ -30014,6 +30028,101 @@ var recordingCapability = {
30014
30028
  })
30015
30029
  }
30016
30030
  };
30031
+ var ExportSpeedSchema = external_exports.number().min(0.25).max(32);
30032
+ var ExportTimelapseSchema = external_exports.object({
30033
+ everyMs: external_exports.number().int().positive(),
30034
+ outputFps: external_exports.number().int().min(1).max(60).optional()
30035
+ });
30036
+ var ExportOptionsSchema = external_exports.object({
30037
+ speed: ExportSpeedSchema.optional(),
30038
+ timelapse: ExportTimelapseSchema.optional(),
30039
+ includeAudio: external_exports.boolean(),
30040
+ maxLifeMs: external_exports.number().int().positive(),
30041
+ deleteAfterDownload: external_exports.boolean(),
30042
+ title: external_exports.string().max(200).optional()
30043
+ }).superRefine((v, ctx) => {
30044
+ if (v.speed !== void 0 && v.timelapse !== void 0) ctx.addIssue({
30045
+ code: external_exports.ZodIssueCode.custom,
30046
+ message: "speed and timelapse are mutually exclusive",
30047
+ path: ["timelapse"]
30048
+ });
30049
+ });
30050
+ var ExportStateSchema = external_exports.enum([
30051
+ "queued",
30052
+ "rendering",
30053
+ "ready",
30054
+ "failed",
30055
+ "expired",
30056
+ "deleted"
30057
+ ]);
30058
+ var ExportRecordSchema = external_exports.object({
30059
+ id: external_exports.string(),
30060
+ deviceId: external_exports.number(),
30061
+ profile: external_exports.string(),
30062
+ fromMs: external_exports.number(),
30063
+ toMs: external_exports.number(),
30064
+ options: ExportOptionsSchema,
30065
+ state: ExportStateSchema,
30066
+ /** 0–100 while rendering; null otherwise. */
30067
+ progressPct: external_exports.number().nullable(),
30068
+ /** File size once ready; null before. */
30069
+ fileBytes: external_exports.number().nullable(),
30070
+ expiresAt: external_exports.number(),
30071
+ deleteAfterDownload: external_exports.boolean(),
30072
+ /** Epoch of the first complete download; null until then. */
30073
+ downloadedAt: external_exports.number().nullable(),
30074
+ createdAt: external_exports.number(),
30075
+ /** User id/name that requested the export. */
30076
+ createdBy: external_exports.string(),
30077
+ /** Failure reason when state is 'failed'; null otherwise. */
30078
+ error: external_exports.string().nullable()
30079
+ });
30080
+ var ExportDownloadSchema = external_exports.object({
30081
+ url: external_exports.string(),
30082
+ endpoints: external_exports.array(external_exports.string())
30083
+ });
30084
+ var recordingExportCapability = {
30085
+ name: "recordingExport",
30086
+ scope: "system",
30087
+ mode: "singleton",
30088
+ methods: {
30089
+ /** Queue a render of `[fromMs,toMs)` for `deviceId`/`profile`. Fails fast
30090
+ * when no footage covers the range. Returns the queued record. */
30091
+ createExport: method(external_exports.object({
30092
+ deviceId: external_exports.number(),
30093
+ profile: external_exports.string(),
30094
+ fromMs: external_exports.number(),
30095
+ toMs: external_exports.number(),
30096
+ options: ExportOptionsSchema
30097
+ }), ExportRecordSchema, {
30098
+ kind: "mutation",
30099
+ auth: "protected"
30100
+ }),
30101
+ /** All export rows (history included), optionally scoped to one device. */
30102
+ listExports: method(external_exports.object({ deviceId: external_exports.number().optional() }), external_exports.array(ExportRecordSchema), {
30103
+ kind: "query",
30104
+ auth: "protected"
30105
+ }),
30106
+ getExport: method(external_exports.object({ exportId: external_exports.string() }), ExportRecordSchema, {
30107
+ kind: "query",
30108
+ auth: "protected"
30109
+ }),
30110
+ /** Abort a queued/rendering export; the partial file is removed. */
30111
+ cancelExport: method(external_exports.object({ exportId: external_exports.string() }), ExportRecordSchema, {
30112
+ kind: "mutation",
30113
+ auth: "protected"
30114
+ }),
30115
+ /** Remove the file but keep the history row (state → 'deleted'). */
30116
+ deleteExport: method(external_exports.object({ exportId: external_exports.string() }), ExportRecordSchema, {
30117
+ kind: "mutation",
30118
+ auth: "protected"
30119
+ }),
30120
+ getDownloadUrl: method(external_exports.object({ exportId: external_exports.string() }), ExportDownloadSchema, {
30121
+ kind: "query",
30122
+ auth: "protected"
30123
+ })
30124
+ }
30125
+ };
30017
30126
  var CamStreamDescriptorSchema = external_exports.object({
30018
30127
  camStreamId: external_exports.string().min(1),
30019
30128
  kind: CamStreamKindSchema,
@@ -33960,6 +34069,42 @@ var METHOD_ACCESS_MAP = Object.freeze({
33960
34069
  addonId: null,
33961
34070
  access: "create"
33962
34071
  },
34072
+ "recordingExport.cancelExport": {
34073
+ capName: "recordingExport",
34074
+ capScope: "system",
34075
+ addonId: null,
34076
+ access: "create"
34077
+ },
34078
+ "recordingExport.createExport": {
34079
+ capName: "recordingExport",
34080
+ capScope: "system",
34081
+ addonId: null,
34082
+ access: "create"
34083
+ },
34084
+ "recordingExport.deleteExport": {
34085
+ capName: "recordingExport",
34086
+ capScope: "system",
34087
+ addonId: null,
34088
+ access: "delete"
34089
+ },
34090
+ "recordingExport.getDownloadUrl": {
34091
+ capName: "recordingExport",
34092
+ capScope: "system",
34093
+ addonId: null,
34094
+ access: "view"
34095
+ },
34096
+ "recordingExport.getExport": {
34097
+ capName: "recordingExport",
34098
+ capScope: "system",
34099
+ addonId: null,
34100
+ access: "view"
34101
+ },
34102
+ "recordingExport.listExports": {
34103
+ capName: "recordingExport",
34104
+ capScope: "system",
34105
+ addonId: null,
34106
+ access: "view"
34107
+ },
33963
34108
  "sceneMonitor.captureReference": {
33964
34109
  capName: "scene-monitor",
33965
34110
  capScope: "device",
package/dist/cli.js CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  runDiscover
4
- } from "./chunk-REYL2W37.js";
4
+ } from "./chunk-XGNAIFKZ.js";
5
5
  import "./chunk-K3NQKI34.js";
6
6
 
7
7
  // src/cli.ts
@@ -1079,7 +1079,7 @@ function isUnknown(_value) {
1079
1079
  return true;
1080
1080
  }
1081
1081
  async function resolveServerInteractive(presetNamespace) {
1082
- const { discoverNodes, resolveHubFromDiscovered, filterHubNodes, DEFAULT_HUB_HTTPS_PORT } = await import("./discover-OTKOLUJJ.js");
1082
+ const { discoverNodes, resolveHubFromDiscovered, filterHubNodes, DEFAULT_HUB_HTTPS_PORT } = await import("./discover-EB7LI523.js");
1083
1083
  if (presetNamespace) {
1084
1084
  const spinner4 = clack.spinner();
1085
1085
  spinner4.start(`Discovering hub on LAN (namespace "${presetNamespace}")`);
@@ -5,7 +5,7 @@ import {
5
5
  filterHubNodes,
6
6
  resolveHubFromDiscovered,
7
7
  runDiscover
8
- } from "./chunk-REYL2W37.js";
8
+ } from "./chunk-XGNAIFKZ.js";
9
9
  import "./chunk-K3NQKI34.js";
10
10
  export {
11
11
  DEFAULT_HUB_HTTPS_PORT,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "camstack",
3
- "version": "1.1.28",
3
+ "version": "1.1.29",
4
4
  "description": "CLI tool for managing and running CamStack server",
5
5
  "keywords": [
6
6
  "camstack",