@camstack/types 1.2.60 → 1.2.61

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.
@@ -180,7 +180,7 @@ export { type IPtzProvider, PtzMoveCommandSchema, type PtzOptions, PtzOptionsSch
180
180
  export { type IPtzAutotrackProvider, type PtzAutotrackRuntimeState, PtzAutotrackRuntimeStateSchema, type PtzAutotrackSettings, PtzAutotrackSettingsSchema, type PtzAutotrackStatus, PtzAutotrackStatusSchema, type PtzAutotrackTargetOption, PtzAutotrackTargetOptionSchema, ptzAutotrackCapability, } from './ptz-autotrack.cap.js';
181
181
  export { type IRebootProvider, rebootCapability } from './reboot.cap.js';
182
182
  export { type IRecordingProvider, type LocateSegmentResult, LocateSegmentResultSchema, type ReadGopBytesResult, ReadGopBytesResultSchema, type ReadSegmentBytesResult, ReadSegmentBytesResultSchema, type RecordingAvailability, RecordingAvailabilitySchema, type RecordingDays, RecordingDaysSchema, type RecordingDeviceUsage, RecordingDeviceUsageSchema, type RecordingLocationUsage, RecordingLocationUsageSchema, type RecordingManifest, RecordingManifestSchema, RecordingRangeSchema, type RecordingStatus, RecordingStatusSchema, type RecordingStorageUsage, RecordingStorageUsageSchema, recordingCapability, } from './recording.cap.js';
183
- export { type ExportDownload, ExportDownloadSchema, type ExportOptions, ExportOptionsSchema, type ExportRecord, ExportRecordSchema, ExportSpeedSchema, type ExportState, ExportStateSchema, ExportTimelapseSchema, type IRecordingExportProvider, recordingExportCapability, } from './recording-export.cap.js';
183
+ export { EXPORT_DENSE_MAX_RANGES, RECORDING_EXPORT_MAX_READ_BYTES, type ExportBytes, ExportBytesSchema, type ExportDense, type ExportDenseRange, ExportDenseRangeSchema, ExportDenseSchema, type ExportDownload, ExportDownloadSchema, type ExportOptions, ExportOptionsSchema, type ExportRecord, ExportRecordSchema, ExportSpeedSchema, type ExportState, ExportStateSchema, ExportTimelapseSchema, type IRecordingExportProvider, recordingExportCapability, } from './recording-export.cap.js';
184
184
  export { type ISceneMonitorProvider, type SceneCheck, SceneCheckSchema, type SceneCondition, SceneConditionSchema, type SceneMonitor, SceneMonitorSchema, type SceneMonitorState, SceneMonitorStateSchema, type SceneMonitorStatus, SceneMonitorStatusSchema, type SceneReference, SceneReferenceSchema, sceneMonitorCapability, } from './scene-monitor.cap.js';
185
185
  export { type ZoneRule, type ZoneRuleMode, ZoneRuleModeEnum, ZoneRuleSchema, type ZoneRules, ZoneRulesArraySchema, } from './schemas/zone-rule.js';
186
186
  export { type IScriptRunnerProvider, type ScriptRunnerStatus, ScriptRunnerStatusSchema, scriptRunnerCapability, } from './script-runner.cap.js';
@@ -1146,6 +1146,10 @@ export declare const pipelineOrchestratorCapability: {
1146
1146
  }, z.core.$strip>>>;
1147
1147
  }, z.core.$strip>, import("./capability-definition.js").CapabilityMethodKind>;
1148
1148
  /**
1149
+ * @deprecated The aggregate switch group is being withdrawn
1150
+ * ([D113](../../../../docs/decisions/adr-0113.md)). Build nothing new on
1151
+ * this pair; read the authority directly.
1152
+ *
1149
1153
  * The whole per-camera function switch group, DERIVED — never a stored
1150
1154
  * list ([D61](../../../../docs/decisions/adr-0067.md)).
1151
1155
  *
@@ -1159,6 +1163,16 @@ export declare const pipelineOrchestratorCapability: {
1159
1163
  * `auth: 'view'` deliberately — a NON-admin must be able to see that a
1160
1164
  * camera is quiet because somebody switched it off. Only the mutation is
1161
1165
  * admin-gated.
1166
+ *
1167
+ * **Removal plan.** It stays and it KEEPS WORKING while shipped viewers
1168
+ * (v1.0.305) and the admin UI still call it — removing it now is a broken
1169
+ * app on a device nobody can redeploy from here. It is served by a thin
1170
+ * shim over the same authorities (`camera-switch-service.ts`), so the
1171
+ * behaviour of the pair is the behaviour of the authorities by
1172
+ * construction. It is deleted once every surface reaches its own
1173
+ * component's options and the last caller is gone. Nothing on this server
1174
+ * reads it: `CameraStatus.switchedOff` is composed from the authorities
1175
+ * directly via `composeSwitchedOff`.
1162
1176
  */
1163
1177
  readonly getCameraSwitches: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
1164
1178
  deviceId: z.ZodNumber;
@@ -1206,6 +1220,10 @@ export declare const pipelineOrchestratorCapability: {
1206
1220
  fetchedAt: z.ZodNumber;
1207
1221
  }, z.core.$strip>, import("./capability-definition.js").CapabilityMethodKind>;
1208
1222
  /**
1223
+ * @deprecated See {@link getCameraSwitches}. Write the authority — the
1224
+ * wrapper binding, `RecordingConfig.enabled`, the notification mute — not
1225
+ * this ([D113](../../../../docs/decisions/adr-0113.md)).
1226
+ *
1209
1227
  * Flip ONE switch, routed to its existing authority.
1210
1228
  *
1211
1229
  * Never writes a parallel map: `recording` patches `RecordingConfig.enabled`
@@ -16,10 +16,56 @@ import { z } from 'zod';
16
16
  import { type InferProvider } from './capability-definition.js';
17
17
  /** Playback-speed multiplier for the render (1 = realtime). */
18
18
  export declare const ExportSpeedSchema: z.ZodNumber;
19
+ /**
20
+ * One dense interval, in SECONDS FROM THE EXPORT'S OWN `fromMs`.
21
+ *
22
+ * Relative and not absolute epoch on purpose: the renderer's frame-select
23
+ * expression sees ffmpeg's `t`, which starts at 0 for the export's source
24
+ * playlist. Handing it absolute epochs would make every call site responsible
25
+ * for the same subtraction, and the one that forgot would emit a filter that
26
+ * selects nothing — silently, as a uniform timelapse.
27
+ */
28
+ export declare const ExportDenseRangeSchema: z.ZodObject<{
29
+ fromSec: z.ZodNumber;
30
+ toSec: z.ZodNumber;
31
+ }, z.core.$strip>;
32
+ export type ExportDenseRange = z.infer<typeof ExportDenseRangeSchema>;
33
+ /**
34
+ * Hard ceiling on dense ranges in ONE render.
35
+ *
36
+ * The ranges become terms of a single ffmpeg `select` expression, so the count
37
+ * is the length of a command-line argument. The producer (the timelapse
38
+ * scheduler) coalesces and then falls back to the base cadence alone rather
39
+ * than trimming — a truncated range list is a video that quietly omits the
40
+ * evening.
41
+ */
42
+ export declare const EXPORT_DENSE_MAX_RANGES = 200;
43
+ /**
44
+ * Dense-interval overlay for a timelapse: sample at `dense.everyMs` INSIDE the
45
+ * listed ranges and at the base `everyMs` everywhere else.
46
+ *
47
+ * `everyMs` must be strictly smaller than the base cadence — a dense rate that
48
+ * is not denser renders a uniform timelapse the operator believes is two-rate.
49
+ */
50
+ export declare const ExportDenseSchema: z.ZodObject<{
51
+ everyMs: z.ZodNumber;
52
+ ranges: z.ZodArray<z.ZodObject<{
53
+ fromSec: z.ZodNumber;
54
+ toSec: z.ZodNumber;
55
+ }, z.core.$strip>>;
56
+ }, z.core.$strip>;
57
+ export type ExportDense = z.infer<typeof ExportDenseSchema>;
19
58
  /** Timelapse cadence — sample one source frame per `everyMs`, output at `outputFps`. */
20
59
  export declare const ExportTimelapseSchema: z.ZodObject<{
21
60
  everyMs: z.ZodNumber;
22
61
  outputFps: z.ZodOptional<z.ZodNumber>;
62
+ dense: z.ZodOptional<z.ZodObject<{
63
+ everyMs: z.ZodNumber;
64
+ ranges: z.ZodArray<z.ZodObject<{
65
+ fromSec: z.ZodNumber;
66
+ toSec: z.ZodNumber;
67
+ }, z.core.$strip>>;
68
+ }, z.core.$strip>>;
23
69
  }, z.core.$strip>;
24
70
  /**
25
71
  * Render options. `speed` and `timelapse` are mutually exclusive. `includeAudio`
@@ -32,6 +78,13 @@ export declare const ExportOptionsSchema: z.ZodObject<{
32
78
  timelapse: z.ZodOptional<z.ZodObject<{
33
79
  everyMs: z.ZodNumber;
34
80
  outputFps: z.ZodOptional<z.ZodNumber>;
81
+ dense: z.ZodOptional<z.ZodObject<{
82
+ everyMs: z.ZodNumber;
83
+ ranges: z.ZodArray<z.ZodObject<{
84
+ fromSec: z.ZodNumber;
85
+ toSec: z.ZodNumber;
86
+ }, z.core.$strip>>;
87
+ }, z.core.$strip>>;
35
88
  }, z.core.$strip>>;
36
89
  includeAudio: z.ZodBoolean;
37
90
  maxLifeMs: z.ZodNumber;
@@ -60,6 +113,13 @@ export declare const ExportRecordSchema: z.ZodObject<{
60
113
  timelapse: z.ZodOptional<z.ZodObject<{
61
114
  everyMs: z.ZodNumber;
62
115
  outputFps: z.ZodOptional<z.ZodNumber>;
116
+ dense: z.ZodOptional<z.ZodObject<{
117
+ everyMs: z.ZodNumber;
118
+ ranges: z.ZodArray<z.ZodObject<{
119
+ fromSec: z.ZodNumber;
120
+ toSec: z.ZodNumber;
121
+ }, z.core.$strip>>;
122
+ }, z.core.$strip>>;
63
123
  }, z.core.$strip>>;
64
124
  includeAudio: z.ZodBoolean;
65
125
  maxLifeMs: z.ZodNumber;
@@ -90,6 +150,38 @@ export declare const ExportDownloadSchema: z.ZodObject<{
90
150
  endpoints: z.ZodArray<z.ZodString>;
91
151
  }, z.core.$strip>;
92
152
  export type ExportDownload = z.infer<typeof ExportDownloadSchema>;
153
+ /**
154
+ * Hard ceiling on ONE {@link recordingExportCapability} byte read — 50 MiB.
155
+ *
156
+ * Two independent reasons land on the same number, which is why it is this one
157
+ * and not a rounder guess:
158
+ *
159
+ * - **Nobody would accept more.** The roomiest byte cap any notifier backend
160
+ * declares is telegram's 50 MiB, and the degrade engine DROPS an over-cap
161
+ * attachment outright rather than degrading it to a link. Bytes above this
162
+ * are read, encoded and moved to be thrown away at the last step.
163
+ * - **The envelope is unary.** A base64 payload is held whole, ~1.33× its
164
+ * size, in the provider AND in the caller — on a hub this repo has already
165
+ * OOM'd once (D9/D18). A bounded on-demand read at human speed is the shape
166
+ * those records permit; an unbounded one is the shape they forbid.
167
+ *
168
+ * Above it the provider REFUSES with a log line rather than truncating: half a
169
+ * video is worse than a notification that says there is no attachment.
170
+ */
171
+ export declare const RECORDING_EXPORT_MAX_READ_BYTES: number;
172
+ /**
173
+ * A finished export's bytes, inline.
174
+ *
175
+ * `bytes` is the DECODED length — the number the caller bounds and logs
176
+ * against, so nobody has to infer it from the base64 length.
177
+ */
178
+ export declare const ExportBytesSchema: z.ZodObject<{
179
+ base64: z.ZodString;
180
+ contentType: z.ZodString;
181
+ name: z.ZodString;
182
+ bytes: z.ZodNumber;
183
+ }, z.core.$strip>;
184
+ export type ExportBytes = z.infer<typeof ExportBytesSchema>;
93
185
  export declare const recordingExportCapability: {
94
186
  readonly name: "recordingExport";
95
187
  readonly scope: "system";
@@ -107,6 +199,13 @@ export declare const recordingExportCapability: {
107
199
  timelapse: z.ZodOptional<z.ZodObject<{
108
200
  everyMs: z.ZodNumber;
109
201
  outputFps: z.ZodOptional<z.ZodNumber>;
202
+ dense: z.ZodOptional<z.ZodObject<{
203
+ everyMs: z.ZodNumber;
204
+ ranges: z.ZodArray<z.ZodObject<{
205
+ fromSec: z.ZodNumber;
206
+ toSec: z.ZodNumber;
207
+ }, z.core.$strip>>;
208
+ }, z.core.$strip>>;
110
209
  }, z.core.$strip>>;
111
210
  includeAudio: z.ZodBoolean;
112
211
  maxLifeMs: z.ZodNumber;
@@ -124,6 +223,13 @@ export declare const recordingExportCapability: {
124
223
  timelapse: z.ZodOptional<z.ZodObject<{
125
224
  everyMs: z.ZodNumber;
126
225
  outputFps: z.ZodOptional<z.ZodNumber>;
226
+ dense: z.ZodOptional<z.ZodObject<{
227
+ everyMs: z.ZodNumber;
228
+ ranges: z.ZodArray<z.ZodObject<{
229
+ fromSec: z.ZodNumber;
230
+ toSec: z.ZodNumber;
231
+ }, z.core.$strip>>;
232
+ }, z.core.$strip>>;
127
233
  }, z.core.$strip>>;
128
234
  includeAudio: z.ZodBoolean;
129
235
  maxLifeMs: z.ZodNumber;
@@ -161,6 +267,13 @@ export declare const recordingExportCapability: {
161
267
  timelapse: z.ZodOptional<z.ZodObject<{
162
268
  everyMs: z.ZodNumber;
163
269
  outputFps: z.ZodOptional<z.ZodNumber>;
270
+ dense: z.ZodOptional<z.ZodObject<{
271
+ everyMs: z.ZodNumber;
272
+ ranges: z.ZodArray<z.ZodObject<{
273
+ fromSec: z.ZodNumber;
274
+ toSec: z.ZodNumber;
275
+ }, z.core.$strip>>;
276
+ }, z.core.$strip>>;
164
277
  }, z.core.$strip>>;
165
278
  includeAudio: z.ZodBoolean;
166
279
  maxLifeMs: z.ZodNumber;
@@ -197,6 +310,13 @@ export declare const recordingExportCapability: {
197
310
  timelapse: z.ZodOptional<z.ZodObject<{
198
311
  everyMs: z.ZodNumber;
199
312
  outputFps: z.ZodOptional<z.ZodNumber>;
313
+ dense: z.ZodOptional<z.ZodObject<{
314
+ everyMs: z.ZodNumber;
315
+ ranges: z.ZodArray<z.ZodObject<{
316
+ fromSec: z.ZodNumber;
317
+ toSec: z.ZodNumber;
318
+ }, z.core.$strip>>;
319
+ }, z.core.$strip>>;
200
320
  }, z.core.$strip>>;
201
321
  includeAudio: z.ZodBoolean;
202
322
  maxLifeMs: z.ZodNumber;
@@ -234,6 +354,13 @@ export declare const recordingExportCapability: {
234
354
  timelapse: z.ZodOptional<z.ZodObject<{
235
355
  everyMs: z.ZodNumber;
236
356
  outputFps: z.ZodOptional<z.ZodNumber>;
357
+ dense: z.ZodOptional<z.ZodObject<{
358
+ everyMs: z.ZodNumber;
359
+ ranges: z.ZodArray<z.ZodObject<{
360
+ fromSec: z.ZodNumber;
361
+ toSec: z.ZodNumber;
362
+ }, z.core.$strip>>;
363
+ }, z.core.$strip>>;
237
364
  }, z.core.$strip>>;
238
365
  includeAudio: z.ZodBoolean;
239
366
  maxLifeMs: z.ZodNumber;
@@ -271,6 +398,13 @@ export declare const recordingExportCapability: {
271
398
  timelapse: z.ZodOptional<z.ZodObject<{
272
399
  everyMs: z.ZodNumber;
273
400
  outputFps: z.ZodOptional<z.ZodNumber>;
401
+ dense: z.ZodOptional<z.ZodObject<{
402
+ everyMs: z.ZodNumber;
403
+ ranges: z.ZodArray<z.ZodObject<{
404
+ fromSec: z.ZodNumber;
405
+ toSec: z.ZodNumber;
406
+ }, z.core.$strip>>;
407
+ }, z.core.$strip>>;
274
408
  }, z.core.$strip>>;
275
409
  includeAudio: z.ZodBoolean;
276
410
  maxLifeMs: z.ZodNumber;
@@ -300,6 +434,31 @@ export declare const recordingExportCapability: {
300
434
  url: z.ZodString;
301
435
  endpoints: z.ZodArray<z.ZodString>;
302
436
  }, z.core.$strip>, "query">;
437
+ /**
438
+ * The finished file's BYTES, base64, for a caller that must republish them
439
+ * somewhere a session-less fetcher can reach.
440
+ *
441
+ * `getDownloadUrl` is the right answer for a human: the download route is
442
+ * served `access: 'authenticated'`, which a browser satisfies and a
443
+ * notifier BACKEND does not. It answers a RELATIVE path, so it is not even
444
+ * a URL an outside fetcher could try. This method exists for the one case
445
+ * that needs the other thing — a scheduled timelapse whose video has to
446
+ * become a public attachment on the notification artifact plane.
447
+ *
448
+ * Deliberately narrow: `ready` only (a queued, rendering, failed, expired
449
+ * or deleted export has no file, and answering "0 bytes" for one is how a
450
+ * caller ships an empty attachment), still inside its lifetime, and under
451
+ * {@link RECORDING_EXPORT_MAX_READ_BYTES}. Every refusal throws with the
452
+ * reason — none of them is silent.
453
+ */
454
+ readonly readExportBytes: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
455
+ exportId: z.ZodString;
456
+ }, z.core.$strip>, z.ZodObject<{
457
+ base64: z.ZodString;
458
+ contentType: z.ZodString;
459
+ name: z.ZodString;
460
+ bytes: z.ZodNumber;
461
+ }, z.core.$strip>, "query">;
303
462
  };
304
463
  };
305
464
  export type IRecordingExportProvider = InferProvider<typeof recordingExportCapability>;
@@ -6359,6 +6359,13 @@ export type AppRouter = TrpcCoreRouter<{
6359
6359
  output: z.infer<typeof recordingExportCapability.methods.getDownloadUrl.output>;
6360
6360
  meta: object;
6361
6361
  }>;
6362
+ readExportBytes: TRPCQueryProcedure<{
6363
+ input: {
6364
+ [x: string]: unknown;
6365
+ } & z.input<typeof recordingExportCapability.methods.readExportBytes.input>;
6366
+ output: z.infer<typeof recordingExportCapability.methods.readExportBytes.output>;
6367
+ meta: object;
6368
+ }>;
6362
6369
  }>>;
6363
6370
  sceneMonitor: TRPCBuiltRouter<{
6364
6371
  ctx: TrpcContext;
@@ -6,7 +6,7 @@
6
6
  * scope+access check inside `protectedProcedure` (see
7
7
  * `server/backend/src/api/trpc/trpc.middleware.ts`).
8
8
  *
9
- * Coverage: 927 method paths across 123 capabilities.
9
+ * Coverage: 928 method paths across 123 capabilities.
10
10
  */
11
11
  import type { CapabilityMethodAccess } from '../capabilities/capability-definition.js';
12
12
  export interface MethodAccessRecord {
@@ -88,7 +88,7 @@ export interface SystemProxy {
88
88
  readonly pipelineRunner: Pick<InferProvider<typeof pipelineRunnerCapability>, 'attachCamera' | 'reportMotion' | 'getLocalLoad' | 'getLocalMetrics' | 'getAllCameraMetrics' | 'getLocalCameras' | 'getNativeCrop' | 'runStatelessStep'>;
89
89
  readonly plateGallery: Pick<InferProvider<typeof plateGalleryCapability>, 'getPlateMedia' | 'searchPlates' | 'suggestPlateClusters' | 'correctPlateText' | 'deletePlate' | 'listVehicles' | 'createVehicle' | 'renameVehicle' | 'deleteVehicle' | 'listVehicleSamples' | 'removeVehicleSample' | 'assignPlate' | 'unassignPlate' | 'assignPlates' | 'unassignPlates'>;
90
90
  readonly recording: Pick<InferProvider<typeof recordingCapability>, 'getStorageUsage' | 'listOpsLog' | 'pauseForStorageMigration' | 'resumeForStorageMigration' | 'refreshStorageLocationsForMigration' | 'startStorageMigrationMove' | 'getStorageMigrationMoveStatus' | 'cancelStorageMigrationMove'>;
91
- readonly recordingExport: Pick<InferProvider<typeof recordingExportCapability>, 'getExport' | 'cancelExport' | 'deleteExport' | 'getDownloadUrl'>;
91
+ readonly recordingExport: Pick<InferProvider<typeof recordingExportCapability>, 'getExport' | 'cancelExport' | 'deleteExport' | 'getDownloadUrl' | 'readExportBytes'>;
92
92
  readonly serverManagement: Pick<InferProvider<typeof serverManagementCapability>, 'getServerPackageStatus' | 'checkServerUpdate' | 'applyServerUpdate' | 'rollbackServerUpdate' | 'restartServer'>;
93
93
  readonly settingsStore: Pick<InferProvider<typeof settingsStoreCapability>, 'get' | 'set' | 'query' | 'insert' | 'update' | 'delete' | 'deleteWhere' | 'updateWhere' | 'count' | 'histogram' | 'isEmpty' | 'declareCollection'>;
94
94
  readonly storage: Pick<InferProvider<typeof storageCapability>, 'resolve' | 'write' | 'read' | 'exists' | 'list' | 'delete' | 'getAvailableSpace' | 'beginUpload' | 'writeChunk' | 'finalizeUpload' | 'abortUpload' | 'beginDownload' | 'readChunk' | 'endDownload' | 'listLocations' | 'getDefaultLocation' | 'listLocationDeclarations' | 'upsertLocation' | 'deleteLocation' | 'testLocation' | 'listProviders' | 'testConfig'>;
package/dist/index.d.ts CHANGED
@@ -189,7 +189,7 @@ export { type PreparedAction, type PreparedAttachment, type PreparedNotification
189
189
  export { htmlToText, markdownToHtmlLite, markdownToText, type NotificationFormat as NotificationBodyFormat, resolveFormat, textToHtml, transcodeBody, } from './notification/format-transcode.js';
190
190
  export { isScheduleActive } from './notification/schedule.js';
191
191
  export type { TimelapseRule, TimelapseRuleInput, TimelapseRulePatch, TimelapseTemplate, } from './notification/timelapse-rule.js';
192
- export { TimelapseRuleInputSchema, TimelapseRulePatchSchema, TimelapseRuleSchema, TimelapseTemplateSchema, } from './notification/timelapse-rule.js';
192
+ export { readTimelapseGeneratedAt, TimelapseRuleInputSchema, TimelapseRulePatchSchema, TimelapseRuleSchema, TimelapseTemplateSchema, } from './notification/timelapse-rule.js';
193
193
  export { DEFAULT_DETAIL_CROP_CONVENTION, DETAIL_CROP_PADDING_FIELD, DETAIL_CROP_PADDING_KEY, DETAIL_CROP_SECTION_ID, DETAIL_CROP_SQUARE_KEY, type DetailCropConvention, DetailCropConventionSchema, type DetailCropRect, deriveDetailCropRect, type HydratedSettingsSection, type HydratedSettingsView, pickDetailCropConvention, readDetailCropConvention, } from './pipeline/detail-crop.js';
194
194
  export { DEFAULT_NATIVE_LEASE_SETTINGS, NATIVE_LEASE_ACTIVITY_FIELD, NATIVE_LEASE_ACTIVITY_KEY, NATIVE_LEASE_ADMISSION_FIELD, NATIVE_LEASE_ADMISSION_KEY, NATIVE_LEASE_BUDGET_FIELD, NATIVE_LEASE_BUDGET_KEY, NATIVE_LEASE_SECTION_ID, NATIVE_LEASE_TTL_FIELD, NATIVE_LEASE_TTL_KEY, type NativeLeaseAdmission, NativeLeaseAdmissionSchema, type NativeLeaseKnob, type NativeLeaseNumberKnob, type NativeLeaseSettings, type NativeLeaseSettingsOverride, NativeLeaseSettingsSchema, pickNativeLeaseOverride, readNativeLeaseOverride, } from './pipeline/native-lease.js';
195
195
  export { type ApiKeyRecord, ApiKeyRecordSchema, type CapScope, CapScopeSchema, type MethodAccess, MethodAccessSchema, type ScopedToken, ScopedTokenSchema, type TokenScope, TokenScopeSchema, type UserRecord, UserRecordSchema, } from './schemas/auth-records.js';
package/dist/index.js CHANGED
@@ -695,8 +695,31 @@ var DEFAULT_RETENTION = {
695
695
  //#endregion
696
696
  //#region src/interfaces/camera-switches.ts
697
697
  /**
698
- * Per-camera FUNCTION SWITCHES — the one coherent on/off surface over the
699
- * pipeline functions an operator thinks in terms of.
698
+ * Per-camera FUNCTION SWITCHES.
699
+ *
700
+ * ## The aggregate group is being withdrawn — the BADGE is not (D113)
701
+ *
702
+ * This file shipped as "the one coherent on/off surface over the pipeline
703
+ * functions an operator thinks in terms of". The operator's verdict on
704
+ * 2026-08-12 was that the coherent surface bought complexity and no clarity:
705
+ * every function already had a settings page of its own, and a second place to
706
+ * turn it off is a second place to look. Each switch is going back to its own
707
+ * component's original options — detection to the detection-pipeline wrapper
708
+ * binding, audio analysis to its own, recording to `RecordingConfig.enabled`
709
+ * (which was always first-class; the switch was a veneer over
710
+ * `recording.setDeviceConfig`), notifications to a notification-center
711
+ * per-device setting, the two camera planes to their own components.
712
+ *
713
+ * What survives is {@link composeSwitchedOff}: `CameraStatus.switchedOff`, the
714
+ * thing that lets a status surface say DISABLED instead of BROKEN, recomposed
715
+ * straight from the authorities with no group in the middle. That rule was
716
+ * never about a control panel.
717
+ *
718
+ * Everything else here — {@link CAMERA_SWITCH_CATALOG}, {@link CameraSwitch},
719
+ * {@link deriveCameraSwitches}, the `pipelineOrchestrator.getCameraSwitches` /
720
+ * `setCameraSwitch` pair — is a COMPATIBILITY surface for as long as deployed
721
+ * viewers (v1.0.305) and the admin UI still call it. It is deleted when they
722
+ * stop; nothing new may be built on it.
700
723
  *
701
724
  * ## This file adds no state
702
725
  *
@@ -1120,6 +1143,42 @@ function deriveCameraSwitches(input) {
1120
1143
  function switchedOffIds(switches) {
1121
1144
  return switches.filter((s) => CAMERA_SWITCH_CATALOG[s.id].countsAsSwitchedOff && s.available && !s.enabled).map((s) => s.id);
1122
1145
  }
1146
+ /**
1147
+ * Compose the `switchedOff` badge STRAIGHT from the authorities (D113).
1148
+ *
1149
+ * This is the half of this file that outlives the switch group.
1150
+ * {@link deriveCameraSwitches} exists to paint a control panel — labels, cost
1151
+ * lines, `available`/`unavailableReason` — and that panel is being dismantled:
1152
+ * each function is going back to its own component's settings. The BADGE is
1153
+ * not: "a switched-off camera must read as DISABLED, not broken" is a rule
1154
+ * about status, not about a control group, and it survives every surface change
1155
+ * underneath it.
1156
+ *
1157
+ * So the badge gets its own entry point over the same authority reads, and the
1158
+ * caller that only needs the badge never builds eight labelled rows to throw
1159
+ * seven of them away.
1160
+ *
1161
+ * `privacy-mask` appears in NEITHER list, whichever way it is sitting and
1162
+ * whether or not it could be read — its ON means "the mask is obscuring video",
1163
+ * not "this function works" ({@link CameraSwitchDescriptor.countsAsSwitchedOff}).
1164
+ * Counting it unreadable would be its own bug: the mask cannot contribute to
1165
+ * the badge, so failing to read it cannot make the badge incomplete.
1166
+ */
1167
+ function composeSwitchedOff(input) {
1168
+ const switchedOff = [];
1169
+ const unreadable = [];
1170
+ for (const id of CAMERA_SWITCH_ORDER) {
1171
+ const descriptor = CAMERA_SWITCH_CATALOG[id];
1172
+ if (!descriptor.countsAsSwitchedOff) continue;
1173
+ const state = resolveState(descriptor, input);
1174
+ if (state.unavailableReason === "source-unreachable") unreadable.push(id);
1175
+ else if (state.available && !state.enabled) switchedOff.push(id);
1176
+ }
1177
+ return {
1178
+ switchedOff,
1179
+ unreadable
1180
+ };
1181
+ }
1123
1182
  //#endregion
1124
1183
  //#region src/interfaces/device-capabilities/camera.ts
1125
1184
  /** Friendly display labels for stream quality IDs. */
@@ -16813,9 +16872,16 @@ var CameraStatusSchema = zod.z.object({
16813
16872
  audio: CameraAudioStatusSchema.nullable(),
16814
16873
  recording: CameraRecordingStatusSchema.nullable(),
16815
16874
  /**
16816
- * Per-camera function switches an OPERATOR has turned off
16875
+ * Per-camera functions an OPERATOR has turned off
16817
16876
  * ([D61](../../../../docs/decisions/adr-0067.md)).
16818
16877
  *
16878
+ * Composed from the AUTHORITIES themselves — the wrapper bindings,
16879
+ * `RecordingConfig.enabled`, the notification mute, the broker's audio
16880
+ * policy, the camera's own microphone — via `composeSwitchedOff`, not from
16881
+ * the deprecated `getCameraSwitches` group ([D113](../../../../docs/decisions/adr-0113.md)).
16882
+ * The badge outlives the control panel: the panel was a convenience, this is
16883
+ * the difference between a camera being off and a camera being dead.
16884
+ *
16819
16885
  * This is the difference between DISABLED and BROKEN. A camera whose
16820
16886
  * `detection` block reports zero fps and whose `switchedOff` contains
16821
16887
  * `'object-detection'` was switched off by a person; the same camera with an
@@ -17254,6 +17320,10 @@ var pipelineOrchestratorCapability = {
17254
17320
  agentNodeId: zod.z.string().optional()
17255
17321
  }), CameraPipelineConfigSchema),
17256
17322
  /**
17323
+ * @deprecated The aggregate switch group is being withdrawn
17324
+ * ([D113](../../../../docs/decisions/adr-0113.md)). Build nothing new on
17325
+ * this pair; read the authority directly.
17326
+ *
17257
17327
  * The whole per-camera function switch group, DERIVED — never a stored
17258
17328
  * list ([D61](../../../../docs/decisions/adr-0067.md)).
17259
17329
  *
@@ -17267,9 +17337,23 @@ var pipelineOrchestratorCapability = {
17267
17337
  * `auth: 'view'` deliberately — a NON-admin must be able to see that a
17268
17338
  * camera is quiet because somebody switched it off. Only the mutation is
17269
17339
  * admin-gated.
17340
+ *
17341
+ * **Removal plan.** It stays and it KEEPS WORKING while shipped viewers
17342
+ * (v1.0.305) and the admin UI still call it — removing it now is a broken
17343
+ * app on a device nobody can redeploy from here. It is served by a thin
17344
+ * shim over the same authorities (`camera-switch-service.ts`), so the
17345
+ * behaviour of the pair is the behaviour of the authorities by
17346
+ * construction. It is deleted once every surface reaches its own
17347
+ * component's options and the last caller is gone. Nothing on this server
17348
+ * reads it: `CameraStatus.switchedOff` is composed from the authorities
17349
+ * directly via `composeSwitchedOff`.
17270
17350
  */
17271
17351
  getCameraSwitches: require_sleep.method(zod.z.object({ deviceId: zod.z.number() }), CameraSwitchGroupSchema),
17272
17352
  /**
17353
+ * @deprecated See {@link getCameraSwitches}. Write the authority — the
17354
+ * wrapper binding, `RecordingConfig.enabled`, the notification mute — not
17355
+ * this ([D113](../../../../docs/decisions/adr-0113.md)).
17356
+ *
17273
17357
  * Flip ONE switch, routed to its existing authority.
17274
17358
  *
17275
17359
  * Never writes a parallel map: `recording` patches `RecordingConfig.enabled`
@@ -25813,10 +25897,52 @@ var recordingCapability = {
25813
25897
  */
25814
25898
  /** Playback-speed multiplier for the render (1 = realtime). */
25815
25899
  var ExportSpeedSchema = zod.z.number().min(.25).max(32);
25900
+ /**
25901
+ * One dense interval, in SECONDS FROM THE EXPORT'S OWN `fromMs`.
25902
+ *
25903
+ * Relative and not absolute epoch on purpose: the renderer's frame-select
25904
+ * expression sees ffmpeg's `t`, which starts at 0 for the export's source
25905
+ * playlist. Handing it absolute epochs would make every call site responsible
25906
+ * for the same subtraction, and the one that forgot would emit a filter that
25907
+ * selects nothing — silently, as a uniform timelapse.
25908
+ */
25909
+ var ExportDenseRangeSchema = zod.z.object({
25910
+ fromSec: zod.z.number().nonnegative(),
25911
+ toSec: zod.z.number().nonnegative()
25912
+ }).refine((r) => r.toSec > r.fromSec, { message: "dense range must have toSec > fromSec" });
25913
+ /**
25914
+ * Hard ceiling on dense ranges in ONE render.
25915
+ *
25916
+ * The ranges become terms of a single ffmpeg `select` expression, so the count
25917
+ * is the length of a command-line argument. The producer (the timelapse
25918
+ * scheduler) coalesces and then falls back to the base cadence alone rather
25919
+ * than trimming — a truncated range list is a video that quietly omits the
25920
+ * evening.
25921
+ */
25922
+ var EXPORT_DENSE_MAX_RANGES = 200;
25923
+ /**
25924
+ * Dense-interval overlay for a timelapse: sample at `dense.everyMs` INSIDE the
25925
+ * listed ranges and at the base `everyMs` everywhere else.
25926
+ *
25927
+ * `everyMs` must be strictly smaller than the base cadence — a dense rate that
25928
+ * is not denser renders a uniform timelapse the operator believes is two-rate.
25929
+ */
25930
+ var ExportDenseSchema = zod.z.object({
25931
+ everyMs: zod.z.number().int().positive(),
25932
+ ranges: zod.z.array(ExportDenseRangeSchema).min(1).max(200)
25933
+ });
25816
25934
  /** Timelapse cadence — sample one source frame per `everyMs`, output at `outputFps`. */
25817
25935
  var ExportTimelapseSchema = zod.z.object({
25818
25936
  everyMs: zod.z.number().int().positive(),
25819
- outputFps: zod.z.number().int().min(1).max(60).optional()
25937
+ outputFps: zod.z.number().int().min(1).max(60).optional(),
25938
+ /** Optional second, FASTER rate over the intervals that matter. */
25939
+ dense: ExportDenseSchema.optional()
25940
+ }).superRefine((v, ctx) => {
25941
+ if (v.dense !== void 0 && v.dense.everyMs >= v.everyMs) ctx.addIssue({
25942
+ code: zod.z.ZodIssueCode.custom,
25943
+ message: "dense.everyMs must be strictly smaller than the base everyMs",
25944
+ path: ["dense", "everyMs"]
25945
+ });
25820
25946
  });
25821
25947
  /**
25822
25948
  * Render options. `speed` and `timelapse` are mutually exclusive. `includeAudio`
@@ -25874,6 +26000,38 @@ var ExportDownloadSchema = zod.z.object({
25874
26000
  url: zod.z.string(),
25875
26001
  endpoints: zod.z.array(zod.z.string())
25876
26002
  });
26003
+ /**
26004
+ * Hard ceiling on ONE {@link recordingExportCapability} byte read — 50 MiB.
26005
+ *
26006
+ * Two independent reasons land on the same number, which is why it is this one
26007
+ * and not a rounder guess:
26008
+ *
26009
+ * - **Nobody would accept more.** The roomiest byte cap any notifier backend
26010
+ * declares is telegram's 50 MiB, and the degrade engine DROPS an over-cap
26011
+ * attachment outright rather than degrading it to a link. Bytes above this
26012
+ * are read, encoded and moved to be thrown away at the last step.
26013
+ * - **The envelope is unary.** A base64 payload is held whole, ~1.33× its
26014
+ * size, in the provider AND in the caller — on a hub this repo has already
26015
+ * OOM'd once (D9/D18). A bounded on-demand read at human speed is the shape
26016
+ * those records permit; an unbounded one is the shape they forbid.
26017
+ *
26018
+ * Above it the provider REFUSES with a log line rather than truncating: half a
26019
+ * video is worse than a notification that says there is no attachment.
26020
+ */
26021
+ var RECORDING_EXPORT_MAX_READ_BYTES = 50 * 1024 * 1024;
26022
+ /**
26023
+ * A finished export's bytes, inline.
26024
+ *
26025
+ * `bytes` is the DECODED length — the number the caller bounds and logs
26026
+ * against, so nobody has to infer it from the base64 length.
26027
+ */
26028
+ var ExportBytesSchema = zod.z.object({
26029
+ base64: zod.z.string(),
26030
+ contentType: zod.z.string(),
26031
+ /** Suggested filename, extension included. */
26032
+ name: zod.z.string(),
26033
+ bytes: zod.z.number().int().nonnegative()
26034
+ });
25877
26035
  var recordingExportCapability = {
25878
26036
  name: "recordingExport",
25879
26037
  scope: "system",
@@ -25913,6 +26071,27 @@ var recordingExportCapability = {
25913
26071
  getDownloadUrl: require_sleep.method(zod.z.object({ exportId: zod.z.string() }), ExportDownloadSchema, {
25914
26072
  kind: "query",
25915
26073
  auth: "protected"
26074
+ }),
26075
+ /**
26076
+ * The finished file's BYTES, base64, for a caller that must republish them
26077
+ * somewhere a session-less fetcher can reach.
26078
+ *
26079
+ * `getDownloadUrl` is the right answer for a human: the download route is
26080
+ * served `access: 'authenticated'`, which a browser satisfies and a
26081
+ * notifier BACKEND does not. It answers a RELATIVE path, so it is not even
26082
+ * a URL an outside fetcher could try. This method exists for the one case
26083
+ * that needs the other thing — a scheduled timelapse whose video has to
26084
+ * become a public attachment on the notification artifact plane.
26085
+ *
26086
+ * Deliberately narrow: `ready` only (a queued, rendering, failed, expired
26087
+ * or deleted export has no file, and answering "0 bytes" for one is how a
26088
+ * caller ships an empty attachment), still inside its lifetime, and under
26089
+ * {@link RECORDING_EXPORT_MAX_READ_BYTES}. Every refusal throws with the
26090
+ * reason — none of them is silent.
26091
+ */
26092
+ readExportBytes: require_sleep.method(zod.z.object({ exportId: zod.z.string() }), ExportBytesSchema, {
26093
+ kind: "query",
26094
+ auth: "protected"
25916
26095
  })
25917
26096
  }
25918
26097
  };
@@ -35806,6 +35985,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
35806
35985
  addonId: null,
35807
35986
  access: "view"
35808
35987
  },
35988
+ "recordingExport.readExportBytes": {
35989
+ capName: "recordingExport",
35990
+ capScope: "system",
35991
+ addonId: null,
35992
+ access: "view"
35993
+ },
35809
35994
  "sceneMonitor.captureReference": {
35810
35995
  capName: "scene-monitor",
35811
35996
  capScope: "device",
@@ -37937,7 +38122,8 @@ function createSystemProxy(api) {
37937
38122
  getExport: (input) => dispatch("recordingExport", "getExport", "query", input),
37938
38123
  cancelExport: (input) => dispatch("recordingExport", "cancelExport", "mutation", input),
37939
38124
  deleteExport: (input) => dispatch("recordingExport", "deleteExport", "mutation", input),
37940
- getDownloadUrl: (input) => dispatch("recordingExport", "getDownloadUrl", "query", input)
38125
+ getDownloadUrl: (input) => dispatch("recordingExport", "getDownloadUrl", "query", input),
38126
+ readExportBytes: (input) => dispatch("recordingExport", "readExportBytes", "query", input)
37941
38127
  },
37942
38128
  serverManagement: {
37943
38129
  getServerPackageStatus: (input) => dispatch("serverManagement", "getServerPackageStatus", "query", input),
@@ -38554,15 +38740,50 @@ var TimelapseRuleSchema = TimelapseRuleInputSchema.extend({
38554
38740
  */
38555
38741
  ownerUserId: zod.z.string().optional(),
38556
38742
  /**
38557
- * Epoch-ms of the last successful generation the 1-hour re-generation
38558
- * guard's durable state (predecessor parity). Absent = never generated.
38743
+ * Epoch-ms of the NEWEST successful generation across every camera of this
38744
+ * rule. What a UI shows, and the compatibility floor for
38745
+ * {@link readTimelapseGeneratedAt}. Absent = never generated.
38559
38746
  */
38560
38747
  lastGeneratedAt: zod.z.number().optional(),
38748
+ /**
38749
+ * PER-CAMERA generation state, keyed by `String(deviceId)` — the
38750
+ * re-generation guard's real durable state.
38751
+ *
38752
+ * One rule covers several cameras and each renders its own video, so a rule
38753
+ * -wide stamp is wrong in the direction that DESTROYS work: camera A
38754
+ * succeeding at 06:05 tells camera B, whose render failed, that it is
38755
+ * already done — and B's night is gone for good, because the window will not
38756
+ * come back.
38757
+ *
38758
+ * ADDITIVE, so the migration is free: a row written before this field simply
38759
+ * has no map, and {@link readTimelapseGeneratedAt} falls back to
38760
+ * {@link TimelapseRuleSchema.shape.lastGeneratedAt}. Reading an old row as
38761
+ * "never generated" would re-render and re-notify every camera of every rule
38762
+ * once, on the deploy that shipped the map.
38763
+ */
38764
+ generatedByDevice: zod.z.record(zod.z.string(), zod.z.number()).optional(),
38561
38765
  /** userId of the caller who created the rule (server-stamped). */
38562
38766
  createdBy: zod.z.string(),
38563
38767
  createdAt: zod.z.number(),
38564
38768
  updatedAt: zod.z.number()
38565
38769
  });
38770
+ /**
38771
+ * The last successful generation for ONE camera of a rule, epoch-ms.
38772
+ *
38773
+ * The per-device map wins; a rule with no map falls back to the rule-wide
38774
+ * `lastGeneratedAt` (the compatible-migration path — see
38775
+ * {@link TimelapseRuleSchema}); a rule with neither returns 0, which every
38776
+ * guard reads as "never generated".
38777
+ *
38778
+ * Read through this helper and never off the field directly: the fallback is
38779
+ * the whole migration, and a call site that forgot it would re-render an
38780
+ * entire rule set once.
38781
+ */
38782
+ function readTimelapseGeneratedAt(rule, deviceId) {
38783
+ const map = rule.generatedByDevice;
38784
+ if (map !== void 0) return map[String(deviceId)] ?? 0;
38785
+ return rule.lastGeneratedAt ?? 0;
38786
+ }
38566
38787
  //#endregion
38567
38788
  //#region src/pipeline/detail-crop.ts
38568
38789
  /**
@@ -40566,6 +40787,7 @@ exports.EVENTFUL_CAP_NAMES = EVENTFUL_CAP_NAMES;
40566
40787
  exports.EVENT_KIND_BY_CAP = EVENT_KIND_BY_CAP;
40567
40788
  exports.EVENT_PAD_MS = EVENT_PAD_MS;
40568
40789
  exports.EVENT_TAXONOMY = EVENT_TAXONOMY;
40790
+ exports.EXPORT_DENSE_MAX_RANGES = EXPORT_DENSE_MAX_RANGES;
40569
40791
  exports.EXPRESSION_BUILTINS = EXPRESSION_BUILTINS;
40570
40792
  exports.EXPRESSION_BUILTIN_NAMES = EXPRESSION_BUILTIN_NAMES;
40571
40793
  exports.EXPRESSION_COMPILE_CACHE_CAPACITY = EXPRESSION_COMPILE_CACHE_CAPACITY;
@@ -40597,6 +40819,9 @@ exports.EventMediaCoverageSchema = EventMediaCoverageSchema;
40597
40819
  exports.EventMediaKindSchema = EventMediaKindSchema;
40598
40820
  exports.EventMediaProductionSchema = EventMediaProductionSchema;
40599
40821
  exports.EventSourceType = require_enums.EventSourceType$1;
40822
+ exports.ExportBytesSchema = ExportBytesSchema;
40823
+ exports.ExportDenseRangeSchema = ExportDenseRangeSchema;
40824
+ exports.ExportDenseSchema = ExportDenseSchema;
40600
40825
  exports.ExportDownloadSchema = ExportDownloadSchema;
40601
40826
  exports.ExportOptionsSchema = ExportOptionsSchema;
40602
40827
  exports.ExportRecordSchema = ExportRecordSchema;
@@ -40895,6 +41120,7 @@ exports.REACHABILITY_FAILURES_TO_OFFLINE = REACHABILITY_FAILURES_TO_OFFLINE;
40895
41120
  exports.REACHABILITY_POLL_INTERVAL_MS = REACHABILITY_POLL_INTERVAL_MS;
40896
41121
  exports.REACHABILITY_PROBE_TIMEOUT_MS = REACHABILITY_PROBE_TIMEOUT_MS;
40897
41122
  exports.RECOGNITION_TYPES = RECOGNITION_TYPES;
41123
+ exports.RECORDING_EXPORT_MAX_READ_BYTES = RECORDING_EXPORT_MAX_READ_BYTES;
40898
41124
  exports.RESERVED_BINDING_NAMES = RESERVED_BINDING_NAMES;
40899
41125
  exports.RUNTIME_DEFAULTS = RUNTIME_DEFAULTS;
40900
41126
  exports.RUNTIME_TO_FORMAT = RUNTIME_TO_FORMAT;
@@ -41201,6 +41427,7 @@ exports.colorCapability = colorCapability;
41201
41427
  exports.colorForKind = colorForKind;
41202
41428
  exports.compileExpression = compileExpression;
41203
41429
  exports.compileExpressionSafe = compileExpressionSafe;
41430
+ exports.composeSwitchedOff = composeSwitchedOff;
41204
41431
  exports.conditionDepth = conditionDepth;
41205
41432
  exports.connectionTestCapability = connectionTestCapability;
41206
41433
  exports.connectivityCapability = connectivityCapability;
@@ -41397,6 +41624,7 @@ exports.readDetailCropConvention = readDetailCropConvention;
41397
41624
  exports.readDeviceStateFrom = readDeviceStateFrom;
41398
41625
  exports.readNativeLeaseOverride = readNativeLeaseOverride;
41399
41626
  exports.readNodePin = require_sleep.readNodePin;
41627
+ exports.readTimelapseGeneratedAt = readTimelapseGeneratedAt;
41400
41628
  exports.readinessKey = require_sleep.readinessKey;
41401
41629
  exports.rebootCapability = rebootCapability;
41402
41630
  exports.recordingCapability = recordingCapability;
package/dist/index.mjs CHANGED
@@ -694,8 +694,31 @@ var DEFAULT_RETENTION = {
694
694
  //#endregion
695
695
  //#region src/interfaces/camera-switches.ts
696
696
  /**
697
- * Per-camera FUNCTION SWITCHES — the one coherent on/off surface over the
698
- * pipeline functions an operator thinks in terms of.
697
+ * Per-camera FUNCTION SWITCHES.
698
+ *
699
+ * ## The aggregate group is being withdrawn — the BADGE is not (D113)
700
+ *
701
+ * This file shipped as "the one coherent on/off surface over the pipeline
702
+ * functions an operator thinks in terms of". The operator's verdict on
703
+ * 2026-08-12 was that the coherent surface bought complexity and no clarity:
704
+ * every function already had a settings page of its own, and a second place to
705
+ * turn it off is a second place to look. Each switch is going back to its own
706
+ * component's original options — detection to the detection-pipeline wrapper
707
+ * binding, audio analysis to its own, recording to `RecordingConfig.enabled`
708
+ * (which was always first-class; the switch was a veneer over
709
+ * `recording.setDeviceConfig`), notifications to a notification-center
710
+ * per-device setting, the two camera planes to their own components.
711
+ *
712
+ * What survives is {@link composeSwitchedOff}: `CameraStatus.switchedOff`, the
713
+ * thing that lets a status surface say DISABLED instead of BROKEN, recomposed
714
+ * straight from the authorities with no group in the middle. That rule was
715
+ * never about a control panel.
716
+ *
717
+ * Everything else here — {@link CAMERA_SWITCH_CATALOG}, {@link CameraSwitch},
718
+ * {@link deriveCameraSwitches}, the `pipelineOrchestrator.getCameraSwitches` /
719
+ * `setCameraSwitch` pair — is a COMPATIBILITY surface for as long as deployed
720
+ * viewers (v1.0.305) and the admin UI still call it. It is deleted when they
721
+ * stop; nothing new may be built on it.
699
722
  *
700
723
  * ## This file adds no state
701
724
  *
@@ -1119,6 +1142,42 @@ function deriveCameraSwitches(input) {
1119
1142
  function switchedOffIds(switches) {
1120
1143
  return switches.filter((s) => CAMERA_SWITCH_CATALOG[s.id].countsAsSwitchedOff && s.available && !s.enabled).map((s) => s.id);
1121
1144
  }
1145
+ /**
1146
+ * Compose the `switchedOff` badge STRAIGHT from the authorities (D113).
1147
+ *
1148
+ * This is the half of this file that outlives the switch group.
1149
+ * {@link deriveCameraSwitches} exists to paint a control panel — labels, cost
1150
+ * lines, `available`/`unavailableReason` — and that panel is being dismantled:
1151
+ * each function is going back to its own component's settings. The BADGE is
1152
+ * not: "a switched-off camera must read as DISABLED, not broken" is a rule
1153
+ * about status, not about a control group, and it survives every surface change
1154
+ * underneath it.
1155
+ *
1156
+ * So the badge gets its own entry point over the same authority reads, and the
1157
+ * caller that only needs the badge never builds eight labelled rows to throw
1158
+ * seven of them away.
1159
+ *
1160
+ * `privacy-mask` appears in NEITHER list, whichever way it is sitting and
1161
+ * whether or not it could be read — its ON means "the mask is obscuring video",
1162
+ * not "this function works" ({@link CameraSwitchDescriptor.countsAsSwitchedOff}).
1163
+ * Counting it unreadable would be its own bug: the mask cannot contribute to
1164
+ * the badge, so failing to read it cannot make the badge incomplete.
1165
+ */
1166
+ function composeSwitchedOff(input) {
1167
+ const switchedOff = [];
1168
+ const unreadable = [];
1169
+ for (const id of CAMERA_SWITCH_ORDER) {
1170
+ const descriptor = CAMERA_SWITCH_CATALOG[id];
1171
+ if (!descriptor.countsAsSwitchedOff) continue;
1172
+ const state = resolveState(descriptor, input);
1173
+ if (state.unavailableReason === "source-unreachable") unreadable.push(id);
1174
+ else if (state.available && !state.enabled) switchedOff.push(id);
1175
+ }
1176
+ return {
1177
+ switchedOff,
1178
+ unreadable
1179
+ };
1180
+ }
1122
1181
  //#endregion
1123
1182
  //#region src/interfaces/device-capabilities/camera.ts
1124
1183
  /** Friendly display labels for stream quality IDs. */
@@ -16812,9 +16871,16 @@ var CameraStatusSchema = z.object({
16812
16871
  audio: CameraAudioStatusSchema.nullable(),
16813
16872
  recording: CameraRecordingStatusSchema.nullable(),
16814
16873
  /**
16815
- * Per-camera function switches an OPERATOR has turned off
16874
+ * Per-camera functions an OPERATOR has turned off
16816
16875
  * ([D61](../../../../docs/decisions/adr-0067.md)).
16817
16876
  *
16877
+ * Composed from the AUTHORITIES themselves — the wrapper bindings,
16878
+ * `RecordingConfig.enabled`, the notification mute, the broker's audio
16879
+ * policy, the camera's own microphone — via `composeSwitchedOff`, not from
16880
+ * the deprecated `getCameraSwitches` group ([D113](../../../../docs/decisions/adr-0113.md)).
16881
+ * The badge outlives the control panel: the panel was a convenience, this is
16882
+ * the difference between a camera being off and a camera being dead.
16883
+ *
16818
16884
  * This is the difference between DISABLED and BROKEN. A camera whose
16819
16885
  * `detection` block reports zero fps and whose `switchedOff` contains
16820
16886
  * `'object-detection'` was switched off by a person; the same camera with an
@@ -17253,6 +17319,10 @@ var pipelineOrchestratorCapability = {
17253
17319
  agentNodeId: z.string().optional()
17254
17320
  }), CameraPipelineConfigSchema),
17255
17321
  /**
17322
+ * @deprecated The aggregate switch group is being withdrawn
17323
+ * ([D113](../../../../docs/decisions/adr-0113.md)). Build nothing new on
17324
+ * this pair; read the authority directly.
17325
+ *
17256
17326
  * The whole per-camera function switch group, DERIVED — never a stored
17257
17327
  * list ([D61](../../../../docs/decisions/adr-0067.md)).
17258
17328
  *
@@ -17266,9 +17336,23 @@ var pipelineOrchestratorCapability = {
17266
17336
  * `auth: 'view'` deliberately — a NON-admin must be able to see that a
17267
17337
  * camera is quiet because somebody switched it off. Only the mutation is
17268
17338
  * admin-gated.
17339
+ *
17340
+ * **Removal plan.** It stays and it KEEPS WORKING while shipped viewers
17341
+ * (v1.0.305) and the admin UI still call it — removing it now is a broken
17342
+ * app on a device nobody can redeploy from here. It is served by a thin
17343
+ * shim over the same authorities (`camera-switch-service.ts`), so the
17344
+ * behaviour of the pair is the behaviour of the authorities by
17345
+ * construction. It is deleted once every surface reaches its own
17346
+ * component's options and the last caller is gone. Nothing on this server
17347
+ * reads it: `CameraStatus.switchedOff` is composed from the authorities
17348
+ * directly via `composeSwitchedOff`.
17269
17349
  */
17270
17350
  getCameraSwitches: method(z.object({ deviceId: z.number() }), CameraSwitchGroupSchema),
17271
17351
  /**
17352
+ * @deprecated See {@link getCameraSwitches}. Write the authority — the
17353
+ * wrapper binding, `RecordingConfig.enabled`, the notification mute — not
17354
+ * this ([D113](../../../../docs/decisions/adr-0113.md)).
17355
+ *
17272
17356
  * Flip ONE switch, routed to its existing authority.
17273
17357
  *
17274
17358
  * Never writes a parallel map: `recording` patches `RecordingConfig.enabled`
@@ -25812,10 +25896,52 @@ var recordingCapability = {
25812
25896
  */
25813
25897
  /** Playback-speed multiplier for the render (1 = realtime). */
25814
25898
  var ExportSpeedSchema = z.number().min(.25).max(32);
25899
+ /**
25900
+ * One dense interval, in SECONDS FROM THE EXPORT'S OWN `fromMs`.
25901
+ *
25902
+ * Relative and not absolute epoch on purpose: the renderer's frame-select
25903
+ * expression sees ffmpeg's `t`, which starts at 0 for the export's source
25904
+ * playlist. Handing it absolute epochs would make every call site responsible
25905
+ * for the same subtraction, and the one that forgot would emit a filter that
25906
+ * selects nothing — silently, as a uniform timelapse.
25907
+ */
25908
+ var ExportDenseRangeSchema = z.object({
25909
+ fromSec: z.number().nonnegative(),
25910
+ toSec: z.number().nonnegative()
25911
+ }).refine((r) => r.toSec > r.fromSec, { message: "dense range must have toSec > fromSec" });
25912
+ /**
25913
+ * Hard ceiling on dense ranges in ONE render.
25914
+ *
25915
+ * The ranges become terms of a single ffmpeg `select` expression, so the count
25916
+ * is the length of a command-line argument. The producer (the timelapse
25917
+ * scheduler) coalesces and then falls back to the base cadence alone rather
25918
+ * than trimming — a truncated range list is a video that quietly omits the
25919
+ * evening.
25920
+ */
25921
+ var EXPORT_DENSE_MAX_RANGES = 200;
25922
+ /**
25923
+ * Dense-interval overlay for a timelapse: sample at `dense.everyMs` INSIDE the
25924
+ * listed ranges and at the base `everyMs` everywhere else.
25925
+ *
25926
+ * `everyMs` must be strictly smaller than the base cadence — a dense rate that
25927
+ * is not denser renders a uniform timelapse the operator believes is two-rate.
25928
+ */
25929
+ var ExportDenseSchema = z.object({
25930
+ everyMs: z.number().int().positive(),
25931
+ ranges: z.array(ExportDenseRangeSchema).min(1).max(200)
25932
+ });
25815
25933
  /** Timelapse cadence — sample one source frame per `everyMs`, output at `outputFps`. */
25816
25934
  var ExportTimelapseSchema = z.object({
25817
25935
  everyMs: z.number().int().positive(),
25818
- outputFps: z.number().int().min(1).max(60).optional()
25936
+ outputFps: z.number().int().min(1).max(60).optional(),
25937
+ /** Optional second, FASTER rate over the intervals that matter. */
25938
+ dense: ExportDenseSchema.optional()
25939
+ }).superRefine((v, ctx) => {
25940
+ if (v.dense !== void 0 && v.dense.everyMs >= v.everyMs) ctx.addIssue({
25941
+ code: z.ZodIssueCode.custom,
25942
+ message: "dense.everyMs must be strictly smaller than the base everyMs",
25943
+ path: ["dense", "everyMs"]
25944
+ });
25819
25945
  });
25820
25946
  /**
25821
25947
  * Render options. `speed` and `timelapse` are mutually exclusive. `includeAudio`
@@ -25873,6 +25999,38 @@ var ExportDownloadSchema = z.object({
25873
25999
  url: z.string(),
25874
26000
  endpoints: z.array(z.string())
25875
26001
  });
26002
+ /**
26003
+ * Hard ceiling on ONE {@link recordingExportCapability} byte read — 50 MiB.
26004
+ *
26005
+ * Two independent reasons land on the same number, which is why it is this one
26006
+ * and not a rounder guess:
26007
+ *
26008
+ * - **Nobody would accept more.** The roomiest byte cap any notifier backend
26009
+ * declares is telegram's 50 MiB, and the degrade engine DROPS an over-cap
26010
+ * attachment outright rather than degrading it to a link. Bytes above this
26011
+ * are read, encoded and moved to be thrown away at the last step.
26012
+ * - **The envelope is unary.** A base64 payload is held whole, ~1.33× its
26013
+ * size, in the provider AND in the caller — on a hub this repo has already
26014
+ * OOM'd once (D9/D18). A bounded on-demand read at human speed is the shape
26015
+ * those records permit; an unbounded one is the shape they forbid.
26016
+ *
26017
+ * Above it the provider REFUSES with a log line rather than truncating: half a
26018
+ * video is worse than a notification that says there is no attachment.
26019
+ */
26020
+ var RECORDING_EXPORT_MAX_READ_BYTES = 50 * 1024 * 1024;
26021
+ /**
26022
+ * A finished export's bytes, inline.
26023
+ *
26024
+ * `bytes` is the DECODED length — the number the caller bounds and logs
26025
+ * against, so nobody has to infer it from the base64 length.
26026
+ */
26027
+ var ExportBytesSchema = z.object({
26028
+ base64: z.string(),
26029
+ contentType: z.string(),
26030
+ /** Suggested filename, extension included. */
26031
+ name: z.string(),
26032
+ bytes: z.number().int().nonnegative()
26033
+ });
25876
26034
  var recordingExportCapability = {
25877
26035
  name: "recordingExport",
25878
26036
  scope: "system",
@@ -25912,6 +26070,27 @@ var recordingExportCapability = {
25912
26070
  getDownloadUrl: method(z.object({ exportId: z.string() }), ExportDownloadSchema, {
25913
26071
  kind: "query",
25914
26072
  auth: "protected"
26073
+ }),
26074
+ /**
26075
+ * The finished file's BYTES, base64, for a caller that must republish them
26076
+ * somewhere a session-less fetcher can reach.
26077
+ *
26078
+ * `getDownloadUrl` is the right answer for a human: the download route is
26079
+ * served `access: 'authenticated'`, which a browser satisfies and a
26080
+ * notifier BACKEND does not. It answers a RELATIVE path, so it is not even
26081
+ * a URL an outside fetcher could try. This method exists for the one case
26082
+ * that needs the other thing — a scheduled timelapse whose video has to
26083
+ * become a public attachment on the notification artifact plane.
26084
+ *
26085
+ * Deliberately narrow: `ready` only (a queued, rendering, failed, expired
26086
+ * or deleted export has no file, and answering "0 bytes" for one is how a
26087
+ * caller ships an empty attachment), still inside its lifetime, and under
26088
+ * {@link RECORDING_EXPORT_MAX_READ_BYTES}. Every refusal throws with the
26089
+ * reason — none of them is silent.
26090
+ */
26091
+ readExportBytes: method(z.object({ exportId: z.string() }), ExportBytesSchema, {
26092
+ kind: "query",
26093
+ auth: "protected"
25915
26094
  })
25916
26095
  }
25917
26096
  };
@@ -35805,6 +35984,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
35805
35984
  addonId: null,
35806
35985
  access: "view"
35807
35986
  },
35987
+ "recordingExport.readExportBytes": {
35988
+ capName: "recordingExport",
35989
+ capScope: "system",
35990
+ addonId: null,
35991
+ access: "view"
35992
+ },
35808
35993
  "sceneMonitor.captureReference": {
35809
35994
  capName: "scene-monitor",
35810
35995
  capScope: "device",
@@ -37936,7 +38121,8 @@ function createSystemProxy(api) {
37936
38121
  getExport: (input) => dispatch("recordingExport", "getExport", "query", input),
37937
38122
  cancelExport: (input) => dispatch("recordingExport", "cancelExport", "mutation", input),
37938
38123
  deleteExport: (input) => dispatch("recordingExport", "deleteExport", "mutation", input),
37939
- getDownloadUrl: (input) => dispatch("recordingExport", "getDownloadUrl", "query", input)
38124
+ getDownloadUrl: (input) => dispatch("recordingExport", "getDownloadUrl", "query", input),
38125
+ readExportBytes: (input) => dispatch("recordingExport", "readExportBytes", "query", input)
37940
38126
  },
37941
38127
  serverManagement: {
37942
38128
  getServerPackageStatus: (input) => dispatch("serverManagement", "getServerPackageStatus", "query", input),
@@ -38553,15 +38739,50 @@ var TimelapseRuleSchema = TimelapseRuleInputSchema.extend({
38553
38739
  */
38554
38740
  ownerUserId: z.string().optional(),
38555
38741
  /**
38556
- * Epoch-ms of the last successful generation the 1-hour re-generation
38557
- * guard's durable state (predecessor parity). Absent = never generated.
38742
+ * Epoch-ms of the NEWEST successful generation across every camera of this
38743
+ * rule. What a UI shows, and the compatibility floor for
38744
+ * {@link readTimelapseGeneratedAt}. Absent = never generated.
38558
38745
  */
38559
38746
  lastGeneratedAt: z.number().optional(),
38747
+ /**
38748
+ * PER-CAMERA generation state, keyed by `String(deviceId)` — the
38749
+ * re-generation guard's real durable state.
38750
+ *
38751
+ * One rule covers several cameras and each renders its own video, so a rule
38752
+ * -wide stamp is wrong in the direction that DESTROYS work: camera A
38753
+ * succeeding at 06:05 tells camera B, whose render failed, that it is
38754
+ * already done — and B's night is gone for good, because the window will not
38755
+ * come back.
38756
+ *
38757
+ * ADDITIVE, so the migration is free: a row written before this field simply
38758
+ * has no map, and {@link readTimelapseGeneratedAt} falls back to
38759
+ * {@link TimelapseRuleSchema.shape.lastGeneratedAt}. Reading an old row as
38760
+ * "never generated" would re-render and re-notify every camera of every rule
38761
+ * once, on the deploy that shipped the map.
38762
+ */
38763
+ generatedByDevice: z.record(z.string(), z.number()).optional(),
38560
38764
  /** userId of the caller who created the rule (server-stamped). */
38561
38765
  createdBy: z.string(),
38562
38766
  createdAt: z.number(),
38563
38767
  updatedAt: z.number()
38564
38768
  });
38769
+ /**
38770
+ * The last successful generation for ONE camera of a rule, epoch-ms.
38771
+ *
38772
+ * The per-device map wins; a rule with no map falls back to the rule-wide
38773
+ * `lastGeneratedAt` (the compatible-migration path — see
38774
+ * {@link TimelapseRuleSchema}); a rule with neither returns 0, which every
38775
+ * guard reads as "never generated".
38776
+ *
38777
+ * Read through this helper and never off the field directly: the fallback is
38778
+ * the whole migration, and a call site that forgot it would re-render an
38779
+ * entire rule set once.
38780
+ */
38781
+ function readTimelapseGeneratedAt(rule, deviceId) {
38782
+ const map = rule.generatedByDevice;
38783
+ if (map !== void 0) return map[String(deviceId)] ?? 0;
38784
+ return rule.lastGeneratedAt ?? 0;
38785
+ }
38565
38786
  //#endregion
38566
38787
  //#region src/pipeline/detail-crop.ts
38567
38788
  /**
@@ -40308,4 +40529,4 @@ function enumerateInferenceDevices(hw) {
40308
40529
  return out;
40309
40530
  }
40310
40531
  //#endregion
40311
- export { ACCESSORY_LABEL, ALEXA_EGRESS_PROFILE, ALL_CAPABILITY_DEFINITIONS, APPLE_SA_TO_MACRO, AUDIO_ANALYSIS_CAP_NAME, AUDIO_BACKEND_CHOICES, AUDIO_MACRO_LABELS, AUDIO_PRESETS, AccessoriesStatusSchema, AccessoryKind, AddBrokerInputSchema, AddonAutoUpdateSchema, AddonListItemSchema, AddonPageDeclarationSchema, AddonPageInfoSchema, AdoptInputSchema as AdoptionAdoptInputSchema, AdoptResultSchema as AdoptionAdoptResultSchema, AdoptionCandidateResultSchema, AdoptionFilterSchema, GetCandidateInputSchema as AdoptionGetCandidateInputSchema, AdoptionJobSchema, AdoptionJobStateSchema, ListCandidatesInputSchema as AdoptionListCandidatesInputSchema, ListCandidatesOutputSchema as AdoptionListCandidatesOutputSchema, AdoptionOutcomeSchema, ReleaseInputSchema as AdoptionReleaseInputSchema, AdoptionStatusSchema, AgentLoadSummarySchema, AirQualitySensorStatusSchema, AlarmArmModeSchema, AlarmPanelStatusSchema, AlarmStateSchema, AlertSchema, AlertSeveritySchema, AlertSourceSchema, AlertStatusSchema, AmbientLightSensorStatusSchema, ApiKeyRecordSchema, ApiKeySummarySchema, ArchiveEntrySchema, ArchiveManifestSchema, AttachmentMediaTypeSchema, AttachmentSchema, AudioAnalysisResultSchema, AudioAnalysisSettingsSchema, AudioChunkInputSchema, AudioClassSummarySchema, AudioClassificationLabelSchema, AudioClassificationResultSchema, AudioCodecInfoSchema, AudioDecodeSessionConfigSchema, AudioEncodeSchema, AudioEncodeSessionConfigSchema, AudioEncodedChunkSchema, AudioEventSchema, AudioLevelSchema, AudioMetricsHistoryPointSchema, AudioMetricsHistorySchema, AudioMetricsSnapshotSchema, AudioPcmChunkSchema, AuthResultSchema, AutoUpdateSettingsSchema, AutomationActionSchema, AutomationConditionOperatorSchema, AutomationConditionSchema, AutomationControlStatusSchema, AutomationRecipeSchema, AutomationTriggerSchema, AvailableIntegrationTypeSchema, BACKEND_TO_FORMAT, BASE_LIVE_EGRESS_PROFILE, BATTERY_DEVICE_PROFILE, BacklightModeSchema, BackupDestinationInfoSchema, BackupEntrySchema, BaseAddon, BaseDevice, BaseDeviceProvider, BatteryStatusSchema, BinaryStatusSchema, BoundingBoxSchema, BrightnessStatusSchema, AddInputSchema as BrokerAddInputSchema, BrokerAudioClientSchema, BrokerClientsSchema, BrokerConnectionDetailsSchema, BrokerConsumerAttributionSchema, BrokerConsumerKindSchema, BrokerDecodedClientSchema, BrokerEncodedClientSchema, GetStateInputSchema as BrokerGetStateInputSchema, BrokerInfoSchema, BrokerProviderInfoSchema, PublishInputSchema as BrokerPublishInputSchema, RegistryStatusSchema as BrokerRegistryStatusSchema, BrokerRtspClientSchema, BrokerStatsSchema, BrokerStatusEnum, BrokerStatusSchema, SubscribeInputSchema as BrokerSubscribeInputSchema, SubscribeResultSchema as BrokerSubscribeResultSchema, TestConnectionResultSchema as BrokerTestConnectionResultSchema, UnsubscribeInputSchema as BrokerUnsubscribeInputSchema, CAMERA_SWITCH_CATALOG, CAMERA_SWITCH_ORDER, CAM_PROFILE_ORDER, CAPABILITY_NAMES, CAPABILITY_ROUTER_KEYS, CAP_NAMES_WITH_STATUS, CAP_NODE_PIN_CONTEXT_KEY, CAP_PROVIDER_KIND_MAP, COCO_80_LABELS, COCO_TO_MACRO, CONNECTION_TEST_TIMEOUT_MS, CORE_BLOCKS_ADDON_ID, CORE_BLOCK_ADDON_PREFIX, CamProfileSchema, CamStreamDescriptorSchema, CamStreamKindSchema, CamStreamResolutionSchema, CameraAssignmentStatusSchema, CameraAudioStatusSchema, CameraBrokerProfileSchema, CameraBrokerStatusSchema, CameraCredentialsSchema, CameraCredentialsStatusSchema, CameraDecoderShmSchema, CameraDecoderStatusSchema, CameraDetectionPhaseSchema, CameraDetectionProvisioningSchema, CameraDetectionProvisioningStateSchema, CameraDetectionStatusSchema, CameraMetricsSchema, CameraMetricsWithDeviceIdSchema, CameraMotionStatusSchema, CameraRecordingModeSchema, CameraRecordingStatusSchema, CameraSourceStatusSchema, CameraSourceStreamSchema, CameraStatusDegradationReasonSchema, CameraStatusDegradationSchema, CameraStatusSchema, CameraStatusStageSchema, CameraStreamSchema, CameraSwitchAuthoritySchema, CameraSwitchGroupSchema, CameraSwitchIdSchema, CameraSwitchSchema, CameraSwitchUnavailableReasonSchema, CandidateQueryFilterSchema, CapScopeSchema, CapabilityBindingsSchema, CarbonMonoxideStatusSchema, ChargingStatus, ClientNetworkStatsSchema, ClimateControlStatusSchema, ClipPlaybackSchema, ClipSchema, ClusterAddonNodeDeploymentSchema, ClusterAddonStatusEntrySchema, CollectionColumnSchema, CollectionIndexSchema, ColorStatusSchema, ConfigEntrySchema, ConfigSectionWithValuesSchema, ConfigTabDeclarationSchema, ConnectionTestDescriptorSchema, ConnectionTestInputSchema, ConnectionTestOutcomeSchema, ConnectivityStatusSchema, ConsumableItemSchema, ConsumablesStatusSchema, ContactStatusSchema, ControlKindSchema, ControlStatusSchema, ConvertArtifactSchema, ConvertResultSchema, ConvertTargetSchema, CoreBlockCompileResultSchema, CoreBlockInputSchema, CoreBlockPlacementSchema, CoreBlockSchema, CoreBlockStatusSchema, CoverStateSchema, CoverStatusSchema, CreateApiKeyInputSchema, CreateApiKeyResultSchema, CreateIntegrationInputSchema, CreateScopedTokenInputSchema, CreateScopedTokenResultSchema, CreateUserInputSchema, CustomActionInputSchema, CustomModelDescriptorSchema, DATAPLANE_SECRET_HEADER, DECLARED_DEVICE_SWEEP_LIMIT, DECLARED_INTEGRATION_FIXED_KEY, DEFAULT_ADDON_PLACEMENT, DEFAULT_AUDIO_ANALYZER_CONFIG, DEFAULT_DECODER_HWACCEL_CONFIG, DEFAULT_DETAIL_CROP_CONVENTION, DEFAULT_EVENTS_BAND_BUFFER_SEC, DEFAULT_EVENT_COLOR, DEFAULT_FEATURES, DEFAULT_NATIVE_LEASE_SETTINGS, DEFAULT_RETENTION, DEFAULT_SCRUB_THUMBNAIL_PRESET, DETAIL_CROP_PADDING_FIELD, DETAIL_CROP_PADDING_KEY, DETAIL_CROP_SECTION_ID, DETAIL_CROP_SQUARE_KEY, DETECTION_PIPELINE_CAP_NAME, DEVICE_BACKEND_TO_FORMAT, DEVICE_CAP_NAMES, DEVICE_PROFILES, DEVICE_SCOPED_CAPS, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATE_READERS, DEVICE_STATUS_METHOD, DEVICE_TYPE_CONTROL_KIND, DEVICE_TYPE_INFO, EngineInfoSchema as DataStoreEngineInfoSchema, DayNightModeSchema, DayNightOptionsSchema, DayNightSettingsPatchSchema, DayNightStatusSchema, DeclaredDevices, DecodedAudioChunkSchema, DecodedFrameSchema, DecoderSessionConfigSchema, DecoderStatsSchema, DeleteIntegrationResultSchema, DetailCropConventionSchema, DetectionSourceSchema, DeviceCodeSeveritySchema, DeviceConfig, DeviceDiscoveryStatusSchema, ExposeInputSchema as DeviceExportExposeInputSchema, DeviceExportStatusSchema, UnexposeInputSchema as DeviceExportUnexposeInputSchema, DeviceFeature, DeviceInfoSchema, DeviceNetworkStatsSchema, DeviceRole, DeviceRuntimeState, DeviceStatusSchema, DeviceType, DiscoveredChildDeviceSchema, DiscoveredChildStatusSchema, DiscoveredDeviceSchema, DiscoveredTargetSchema, DisposerChain, DoorbellPressEventSchema, DoorbellStatusSchema, EVENTFUL_CAP_NAMES, EVENT_KIND_BY_CAP, EVENT_PAD_MS, EVENT_TAXONOMY, EXPRESSION_BUILTINS, EXPRESSION_BUILTIN_NAMES, EXPRESSION_COMPILE_CACHE_CAPACITY, EXPRESSION_IDENTIFIER_RE, EXPRESSION_INJECTED_NOW, EgressEncodeSchema, EgressRateControlSchema, EgressTranscodeRequestSchema, EgressTranscodeSchema, ElementConfigStore, EmbeddingInfoSchema, EmbeddingResultSchema, EncodeProfileSchema, EncodedPacketSchema, EnrichedWidgetMetadataSchema, EnumSensorDateTimeFormatSchema, EnumSensorStatusSchema, EventCategory, EventEmitterStatusSchema, EventFireSchema, EventItemSchema, EventKindCategorySchema, EventKindDescriptorSchema, EventKindIconSchema, EventKindSchema, EventKindsForDeviceSchema, EventMediaArtifactSchema, EventMediaCoverageSchema, EventMediaKindSchema, EventMediaProductionSchema, EventSourceType, ExportDownloadSchema, ExportOptionsSchema, ExportRecordSchema, ExportSetupFieldSchema, ExportSetupSchema, ExportSpeedSchema, ExportStateSchema, ExportTimelapseSchema, ExposedDeviceSchema, ExposureModeSchema, ExpressionBindingSourceSchema, ExpressionEvalError, ExpressionFieldBindingSchema, ExpressionGlobalBindingSchema, ExpressionLiteralBindingSchema, ExpressionParseError, ExpressionSourceSchema, FanControlStatusSchema, FanDirectionSchema, FeatureManifestSchema, FeatureProbeStatusSchema, FloodStatusSchema, Fmp4BoxSplitter, FrameHandleFormatSchema, FrameHandleSchema, FrameInputSchema, GasStatusSchema, GetStreamWithCodecInputSchema, GlobalMetricsSchema, HAP_AUDIO_BASE, HAP_AUDIO_BITRATE_KBPS, HAP_AUDIO_VBV_KBITS, HAP_KEYFRAME_INTERVAL_SEC, HF_BASE_URL, HF_REPO, HWACCEL_OPTIONS, HealthStatusSchema, HistoryPointSchema, HistoryResolutionEnum, HumidifierStatusSchema, HumiditySensorStatusSchema, HvacModeSchema, ImageContractSchema, ImageContractStateSchema, ImageRotateSchema, ImageSettingsOptionsSchema, ImageSettingsPatchSchema, ImageSettingsStatusSchema, ImageStatusSchema, IngestOwnerSchema, InstalledPackageSchema, IntegrationLiteSchema, IntegrationWithStateSchema, IntercomAbilitySchema, IntercomStatusSchema, KNOWN_CAP_NAMES, KeyEventSchema, LOG_LEVEL_RANK, LabelAttributionSchema, LabelDefinitionSchema, LabelTierSchema, LawnMowerActivitySchema, LawnMowerControlStatusSchema, LinkedDeviceSchema, LinkedDevicesModeSchema, LlmDefaultSchema, LlmDefaultSelectorSchema, LlmErrorCodeSchema, LlmGenerateBaseInputSchema, LlmGenerateErrSchema, LlmGenerateOkSchema, LlmGenerateResultSchema, LlmImageSchema, LlmNodeModelSchema, LlmProfileKindDescriptorSchema, LlmProfileKindSchema, LlmProfileSchema, LlmRuntimeCompleteInputSchema, LlmRuntimeDiskUsageSchema, LlmRuntimeNodeSchema, LlmRuntimeStatusSchema, LlmUsageRollupSchema, LlmUsageSchema, LocateSegmentResultSchema, LocationStatSchema, LockControlStatusSchema, LockStateSchema, LogEntrySchema, LogLevelSchema, LogStreamEntrySchema, LoginMethodContributionSchema, LoginStageEnum, MACRO_LABELS, MAX_CONDITION_DEPTH, MAX_CONDITION_LEAVES, MAX_EXPRESSION_AST_NODES, MAX_EXPRESSION_BINDINGS, MAX_EXPRESSION_CALL_ARGS, MAX_EXPRESSION_EVAL_STEPS, MAX_EXPRESSION_SOURCE_LENGTH, METHOD_ACCESS_MAP, MODEL_FORMATS, MOTION_TRIGGER_FEATURE, ManagedModelCatalogEntrySchema, ManagedModelRefSchema, ManagedRuntimeConfigSchema, MaskGridDimsSchema, MaskGridShapeSchema, MaskLineShapeSchema, MaskPointSchema, MaskPolygonShapeSchema, MaskPolygonVerticesSchema, MaskRectShapeSchema, MaskShapeKindSchema, MaskShapeSchema, MediaFileInfoSchema, MediaFileSchema, MediaPlayerRepeatSchema, MediaPlayerStateSchema, MediaPlayerStatusSchema, MeshPeerSchema, MeshStatusSchema, MethodAccessSchema, ModelCatalogEntrySchema, ModelConvertInputSchema, ModelConvertMetadataSchema, ModelDistributeInputSchema, ModelDistributeResultSchema, ModelExtraFileSchema, ModelFormatEntrySchema, ModelFormatsSchema, ModelSubstitutionSchema, ModelVariantGroupSchema, MotionAnalysisResultSchema, MotionEventSchema, MotionOnMotionChangedDataSchema, MotionRegionSchema, MotionSourceEnum, MotionSourcesSchema, MotionStatusSchema, MotionTriggerRuntimeStateSchema, MotionTriggerStatusSchema, MotionZoneOptionsSchema, MotionZonePatchSchema, MotionZoneRegionSchema, MotionZoneStatusSchema, StatusSchema as MqttBrokerStatusSchema, MutationFilterSchema, NATIVE_LEASE_ACTIVITY_FIELD, NATIVE_LEASE_ACTIVITY_KEY, NATIVE_LEASE_ADMISSION_FIELD, NATIVE_LEASE_ADMISSION_KEY, NATIVE_LEASE_BUDGET_FIELD, NATIVE_LEASE_BUDGET_KEY, NATIVE_LEASE_SECTION_ID, NATIVE_LEASE_TTL_FIELD, NATIVE_LEASE_TTL_KEY, NC_BASE_CONDITION_KEYS, NC_CONDITION_CATALOG, NC_HISTORY_LIMIT_DEFAULT, NC_HISTORY_LIMIT_MAX, NC_MAX_PER_TRACK_IMMEDIATE, NC_SNOOZE_MAX_MINUTES, NC_TAXONOMY, NativeCropBboxSchema, NativeCropRefSchema, NativeCropResultSchema, NativeDetectionSchema, NativeLeaseAdmissionSchema, NativeLeaseSettingsSchema, NativeObjectClassEnum, NativeObjectDetectionRuntimeStateSchema, NativeObjectDetectionStatusSchema, NcAlarmConfigSchema, NcAlarmModeCoverageSchema, NcAlarmSettingsPatchSchema, NcAlarmSettingsSchema, NcConditionDescriptorSchema, NcConditionsSchema, NcCrossingSchema, NcDeliverySchema, NcDeviceStateConditionSchema, NcHistoryEntrySchema, NcHistoryFilterSchema, NcHistoryRecordKindSchema, NcHistoryStatusSchema, NcHistorySubjectSchema, NcMediaFrameSchema, NcMediaPolicySchema, NcOccupancyConditionSchema, NcPlateMatcherSchema, NcRuleActionSchema, NcRuleActionSequenceSchema, NcRuleActionsSchema, NcRuleInputSchema, NcRuleNotificationButtonSchema, NcRulePatchSchema, NcRuleSchema, NcRuleTargetSchema, NcScheduleSchema, NcScheduleWindowSchema, NcSnoozeInputSchema, NcSnoozeSchema, NcSnoozeScopeSchema, NcSnoozeSuppressedSchema, NcSystemEventConditionSchema, NcSystemEventKindSchema, NcTaxonomyEntrySchema, NcTaxonomySchema, NcTestResultSchema, NcThrottleGranularitySchema, NcThrottleSchema, NcZoneConditionSchema, NetworkAccessStatusSchema, NetworkAddressSchema, NetworkEndpointSchema, NotificationActionIconSchema, NotificationActionSchema, NotificationFormatSchema, NotificationSchema, NotifierStatusSchema, NumericSensorStatusSchema, OPS_LOG_DEFAULT_LIMIT, OPS_LOG_RING_DEFAULT_MAX, OauthIntegrationDescriptorSchema, ObjectEventSchema, OpsLogDomainSchema, OpsLogEntrySchema, OpsLogOpSchema, OpsLogQueryInputSchema, OpsLogReasonSchema, OrchestratorMetricsSchema, OsdOverlayKindEnum, OsdOverlayPatchSchema, OsdOverlaySchema, OsdPositionEnum, OsdRenderOutcomeEnum, OsdRenderResultSchema, OsdSlotBindingSchema, OsdSlotViewSchema, OsdSourceOptionSchema, OsdSourceSchema, OsdSourceValueTypeEnum, OsdStatusSchema, PET_FEEDER_MANUAL_FEED_MAX, PET_FEEDER_MANUAL_FEED_MIN, PIPELINE_FLOW_CAPABILITY_NAMES, PIPELINE_OWNER_CAPABILITY_NAMES, PRIVACY_MASK_CAP_NAME, PROVIDER_KIND_CAP_NAMES, PYTHON_SCRIPT, PackageUpdateSchema, PackageVersionInfoSchema, PasskeyLoginMethodSchema, PasskeySummarySchema, PcmSampleFormatSchema, PerScopeBreakdownSchema, PetFeederStatusSchema, PickStreamPreferencesSchema, PickStreamRequirementsSchema, PickedCamStreamSchema, PipelineAssignmentSchema, PipelineDefaultStepSchema, PipelineEngineChoiceSchema, PipelineRunResultBridge, PipelineStepInputSchema, PipelineValidationIssueSchema, PipelineValidationResultSchema, PlaceholderReasonSchema, PolygonPointSchema, PowerMeterStatusSchema, PresenceStatusSchema, PressureSensorStatusSchema, PrivacyMaskOptionsSchema, PrivacyMaskPatchSchema, PrivacyMaskRegionSchema, PrivacyMaskShapeSchema, PrivacyMaskStatusSchema, ProfileRtspEntrySchema, ProfileSlotSchema, ProfileSlotStatusSchema, ProviderStatusSchema, PtzAutotrackRuntimeStateSchema, PtzAutotrackSettingsSchema, PtzAutotrackStatusSchema, PtzAutotrackTargetOptionSchema, PtzMoveCommandSchema, PtzOptionsSchema, PtzPositionSchema, PtzPresetSchema, PtzStatusSchema, QueryFilterSchema, RATE_CONTROL_RELAXED, RATE_CONTROL_TIGHT, REACHABILITY_FAILURES_TO_OFFLINE, REACHABILITY_POLL_INTERVAL_MS, REACHABILITY_PROBE_TIMEOUT_MS, RECOGNITION_TYPES, RESERVED_BINDING_NAMES, RUNTIME_DEFAULTS, RUNTIME_TO_FORMAT, RawStateResultSchema, ReadGopBytesResultSchema, ReadSegmentBytesResultSchema, ReadinessRegistry, ReadinessTimeoutError, RecentTracksPageSchema, RecentTracksQueryInput, RecordingAvailabilitySchema, RecordingBandModeSchema, RecordingBandSchema, RecordingBandTriggersSchema, RecordingConfigSchema, RecordingDaysSchema, RecordingDeviceUsageSchema, RecordingLocationUsageSchema, RecordingManifestSchema, RecordingRangeSchema, RecordingRetentionSchema, RecordingStatusSchema, RecordingStorageModeSchema, RecordingStorageUsageSchema, RecordingTriggersSchema, RecordingWeekdaySchema, RedirectLoginMethodSchema, RelocateFootageClassSchema, RelocateFootageInputSchema, RelocateJobSchema, RelocateJobStateSchema, RelocateMediaInputSchema, RenderedAsSchema, ReportMotionInputSchema, RetrainAnnotationDraftSchema, RetrainAnnotationKindSchema, RetrainAnnotationSchema, RetrainAnnotationSourceSchema, RetrainAssistResultSchema, RetrainAssistSubjectSchema, RetrainCopyRefusalSchema, RetrainFrameCandidateSchema, RetrainFrameListSchema, RetrainFrameSchema, RetrainFrameSelectionSchema, RetrainMacroClassSchema, RetrainStatusSchema, RetrainTrackSchema, RetrainTransitionResultSchema, RingBuffer, RtpSourceSchema, RtspRestreamEntrySchema, RunnerCameraConfigSchema, RunnerCameraDeviceUIFields, RunnerFrameSourceSchema, RunnerInferenceDeviceSchema, RunnerLocalLoadSchema, RunnerLocalMetricsSchema, SCOPE_PRESETS, SCRUB_THUMBNAIL_PRESETS, SCRUB_THUMBNAIL_PRESET_LABELS, SCRUB_THUMBNAIL_PRESET_ORDER, SENSOR_FEATURES, SENSOR_MAP, SOURCE_INFO_METADATA_KEY, STREAM_PROFILE_META, STREAM_QUALITY_LABELS, SUB_DETECTION_TYPES, SYSTEM_CAP_NAMES, SceneCheckSchema, SceneConditionSchema, SceneMonitorSchema, SceneMonitorStateSchema, SceneMonitorStatusSchema, SceneReferenceSchema, ScopedTokenSchema, ScopedTokenSummarySchema, ScoredObjectEventSchema, ScriptRunnerStatusSchema, ScrubThumbnailPresetSchema, SearchResultSchema, SendEmailInputSchema, SendEmailResultSchema, SendResultSchema, SensorEventSchema, ServerBootModeSchema, ServerPackageStatusSchema, ServerRollbackInfoSchema, ServerUpdateActionResultSchema, ServerUpdateCheckResultSchema, ServerUpdateStateSchema, SettingsPatchSchema, SettingsRecordSchema, SettingsSchemaWithValuesSchema, SettingsUpdateResultSchema, ShmRingStatsSchema, SmokeStatusSchema, SmtpStatusSchema, SnapshotImageSchema, SourceInfoSchema, SpatialDetectionSchema, SsoBridgeClaimsSchema, StartEmbeddedInputSchema, StationaryObjectSchema, AbortUploadInputSchema as StorageAbortUploadInputSchema, BeginDownloadInputSchema as StorageBeginDownloadInputSchema, BeginDownloadResultSchema as StorageBeginDownloadResultSchema, BeginUploadInputSchema as StorageBeginUploadInputSchema, BeginUploadResultSchema as StorageBeginUploadResultSchema, EndDownloadInputSchema as StorageEndDownloadInputSchema, FinalizeUploadInputSchema as StorageFinalizeUploadInputSchema, StorageLocationDeclarationSchema, StorageLocationRefSchema, StorageLocationSchema, StorageLocationTypeSchema, StorageMigrationClassSchema, StorageMigrationDestinationsSchema, StorageMigrationFootageMoveInputSchema, StorageMigrationInputSchema, StorageMigrationJobSchema, StorageMigrationLeaseInputSchema, StorageMigrationMediaMoveInputSchema, StorageMigrationMoveSchema, StorageMigrationParticipantSchema, StorageMigrationPhaseSchema, StorageMigrationPlanSchema, ProviderInfoSchema as StorageProviderInfoSchema, ReadChunkInputSchema as StorageReadChunkInputSchema, TestLocationResultSchema as StorageTestLocationResultSchema, WriteChunkInputSchema as StorageWriteChunkInputSchema, StreamCodecSchema, StreamFormatSchema, StreamNetworkStatsSchema, StreamParamsOptionsSchema, StreamParamsStatusSchema, StreamProfileConfigSchema, StreamProfileOptionsSchema, StreamProfilePatchSchema, StreamProfileSchema, StreamSourceEntrySchema, StreamSourceSchema, SubscribeAudioChunksInputSchema, SubscribeAudioChunksResultSchema, SubscribeFramesInputSchema, SubscribeFramesResultSchema, SwitchStatusSchema, SystemMetricsSchema, SystemMirror, TAXONOMY_COLORS, TIMEZONES, TRANSCODE_DOWN_MAX_BITRATE_KBPS, TRANSCODE_DOWN_MAX_HEIGHT, TamperStatusSchema, TankStatusSchema, TargetKindCapsSchema, TargetKindLevelSchema, TargetKindSchema, TargetSchema, TemperatureSensorStatusSchema, TerminalInstanceInfoSchema, TerminalLegacyCameraSchema, TerminalOutputBatchSchema, TerminalOutputEventSchema, TerminalProfileInfoSchema, TerminalSessionInfoSchema, TestConnectionResultSchema$1 as TestConnectionResultSchema, TestConnectionStatusEnum, TestResultSchema, TimelapseRuleInputSchema, TimelapseRulePatchSchema, TimelapseRuleSchema, TimelapseTemplateSchema, ToastSchema, TokenScopeSchema, TopologyNodeSchema, TopologyProcessSchema, TopologyServiceSchema, TrackCascadeCountsSchema, TrackEnvelopeSchema, TrackFlagsPatchSchema, TrackFlagsSchema, TrackProjectionSchema, TrackSchema, TrackSourceSchema, TrackStateSchema, TrackZoneFilterSchema, TrackedDetectionSchema, TrainingExportDeviceTotalsSchema, TrainingExportSummarySchema, TurnServerSchema, UNIT_TABLE, BrokerInfoSchema$1 as UnifiedBrokerInfoSchema, UnitConversionError, UpdateIntegrationInputSchema, UpdateStatusSchema, UpdateUserInputSchema, UserRecordSchema, UserSummarySchema, VacuumControlStatusSchema, VacuumStateSchema, ValveStateSchema, ValveStatusSchema, VectorDeclareIndexInputSchema, VectorDeleteByFilterInputSchema, VectorDeleteInputSchema, VectorDeleteResultSchema, VectorFilterSchema, VectorGetInputSchema, VectorGetResultSchema, VectorItemSchema, VectorMatchSchema, VectorMetadataSchema, VectorMetricSchema, VectorQueryInputSchema, VectorQueryResultSchema, VectorStatsInputSchema, VectorStatsResultSchema, VectorUpsertInputSchema, VectorUpsertResultSchema, VibrationStatusSchema, VideoEncodeSchema, WEBRTC_EGRESS_PROFILE, WELL_KNOWN_TABS, WELL_KNOWN_TAB_MAP, WaterHeaterStatusSchema, WeatherStatusSchema, WebrtcStreamChoiceSchema, WebrtcStreamTargetSchema, WhiteBalanceModeSchema, WidgetHostEnum, WidgetLoginMethodSchema, WidgetMetadataSchema, WidgetRemoteSchema, WidgetSizeEnum, YAMNET_TO_MACRO, ZoneCrossingDirectionSchema, ZoneCrossingSchema, ZoneKindEnum, ZoneRuleModeEnum, ZoneRuleSchema, ZoneRuleStageEnum, ZoneRulesArraySchema, ZoneSchema, ZoneScopeBreakdownSchema, accessoriesCapability, accessoryStableId, addonPagesCapability, addonPagesSourceCapability, addonRoutesCapability, addonSettingsCapability, addonWidgetsCapability, addonWidgetsSourceCapability, addonsCapability, adminUiCapability, airQualitySensorCapability, alarmPanelCapability, alertsCapability, ambientLightSensorCapability, asBoolean, asJsonArray, asJsonObject, asNumber, asString, audioAnalysisCapability, audioAnalyzerCapability, audioCodecCapability, audioMetricsCapability, audioPlanFromEncodeProfile, authProviderCapability, autoAssignProfiles, automationControlCapability, backupCapability, bareAddonId, batteryCapability, bestLocationMatch, binaryCapability, bindAddonActions, brightnessCapability, brokerCapability, buildAddonRouteProvider, buildAudioArgs, buildEventKindDescriptor, buildFfmpegArgs, buildInputArgs, buildModelVariantGroups, buildNcTaxonomy, buildStreamParamsConfigSchema, buildVideoArgs, buttonCapability, cameraCredentialsCapability, cameraPipelineConfigCapability, cameraStreamsCapability, canConvertUnit, canonicalEgressPlan, carbonMonoxideCapability, cellsToRects, classifyBearerPrincipal, classifyStream, classifyStreams, climateControlCapability, collectHydratedFieldEntries, collectHydratedFieldValues, colorCapability, colorForKind, compileExpression, compileExpressionSafe, conditionDepth, connectionTestCapability, connectivityCapability, consumablesCapability, contactCapability, controlCapability, convertUnit, coreBlockAddonId, coreBlockIdFromAddonId, coreBlocksCapability, cosineSimilarity, countConditionLeaves, coverCapability, createDeviceProxy, createDurableState, createEvent, createExpressionScope, createHwAccelCache, createLazyTrpcSource, createMirrorSource, createRuntimeStateBridge, createSliceHandle, createSystemProxy, customAction, customModelRegistryCapability, dataStoreProviderCapability, dayNightCapability, declarationOwnerNodeId, decodeVectorBase64, decoderCapability, defaultDeviceFor, defineCustomActions, deriveCameraSwitches, deriveDetailCropRect, deriveRecordingMode, describeModelVariant, detectionPipelineCapability, deviceAdoptionCapability, deviceBackendToFormat, deviceCustomAction, deviceDiscoveryCapability, deviceExportCapability, deviceManagerCapability, deviceMatchesProfile, deviceOpsCapability, deviceProviderCapability, deviceStateCapability, deviceStatusCapability, doorbellCapability, egressTranscodeSharingKey, egressTransportFromRequest, embeddingEncoderCapability, emitDownForOwnedCaps, emitReadiness, encodeProfileFromStreamShape, encodeVectorBase64, enumSensorCapability, enumerateInferenceDevices, enumerateItemArrayFields, enumerateSchemaFields, errMsg, evaluateAst, evaluateExpressionSource, evaluateZoneRules, event, eventEmitterCapability, eventsCapability, expandCapMethods, extractNestedAddonId, extractSourceInfoFromMetadata, faceGalleryCapability, fanControlCapability, featureProbeCapability, filesystemBrowseCapability, findTimezone, floodCapability, formatForBackend, formatForRuntime, gasCapability, generateAutomationBlock, getAudioMacroClassIds, getByPath, getCapsByProviderKind, getTaxonomyEntry, hasMotionTrigger, hfModelUrl, htmlToText, humidifierCapability, humiditySensorCapability, hydrateSchema, imageCapability, imageSettingsCapability, integrationsCapability, intercomCapability, invocationFromEncodeProfile, isAgentOnlyPlacement, isArrayOutputSchema, isBaseConditionKey, isCollectionArrayMethod, isDeployableToAgent, isDeviceConfigCap, isDeviceScopedCap, isEvent, isNode, isObjectInput, isSameAddonId, isScheduleActive, isSoftwareDecode, isVoidInput, jobKindSchema, kebabToCamel, knownValues, lawnMowerControlCapability, lifecycleJobSchema, lifecycleJobScopeSchema, lifecycleJobStateSchema, lifecycleTaskSchema, llmCapability, llmRuntimeCapability, localNetworkCapability, locationSimilarity, lockControlCapability, logBannerArgs, logDestinationCapability, logLevelAtMost, loginMethodCapability, looseSchema, makeProfileBrokerId, makeSourceBrokerId, mapAudioLabelToMacro, markdownToHtmlLite, markdownToText, maskUrlCredentials, mediaPlayerCapability, mergeSourceInfo, meshNetworkCapability, method, methodAccessForHttpMethod, metricsProviderCapability, modelConvertCapability, modelDistributorCapability, modelFormatForRuntime, motionCapability, motionDetectionCapability, motionTriggerCapability, motionZonesCapability, mqttBrokerCapability, nativeObjectDetectionCapability, networkAccessCapability, networkQualityCapability, nodePin, nodesCapability, normalizeAddonInitResult, normalizeUnit, notificationOutputCapability, notificationRulesCapability, notifierCapability, numericSensorCapability, oauthIntegrationCapability, objectInputDeclaresAddonId, osdCapability, osdManagerCapability, parseCameraStreamConfig, parseExpression, parseJsonArray, parseJsonObject, parseJsonUnknown, parseProfileBrokerId, parseStreamParamsFormPatch, petFeederCapability, pickAccessoryControl, pickDetailCropConvention, pickNativeLeaseOverride, pickPreferredRtspEntry, pickVideoEncoder, pickerForCondition, pipelineAnalyticsCapability, pipelineExecutorCapability, pipelineOrchestratorCapability, pipelineRunnerCapability, plateGalleryCapability, platformProbeCapability, powerMeterCapability, prepareNotification, presenceCapability, pressureSensorCapability, principalMayReachAddon, privacyMaskCapability, procedureAuthKey, ptzAutotrackCapability, ptzCapability, pythonScriptForBackend, readDetailCropConvention, readDeviceStateFrom, readNativeLeaseOverride, readNodePin, readinessKey, rebootCapability, recordingCapability, recordingExportCapability, rectsToCells, requiresPython, resolveAddonExecution, resolveAddonGroup, resolveAddonPlacement, resolveAddonRuntime, resolveCapMount, resolveDetectionRuntime, resolveDeviceControlKind, resolveDeviceProfile, resolveEgressDecodeHwAccel, resolveFormat, resolveHydratedFieldValue, resolveModelFormat, resolveMutate, resolveRunnerId, resolveScrubThumbnailGeometry, resolveVariantModelId, runInferenceStep, runtimeDevices, sceneMonitorCapability, scopeKey, scopesAllowAddon, scopesAllowDeviceCap, scoreRuntimes, scriptRunnerCapability, selectAssignedProfileSlots, serverManagementCapability, setByPath, settingsStoreCapability, sleep, sleepCancellable, smokeCapability, smtpProviderCapability, snapshotCapability, ssoBridgeCapability, startReachabilityPoll, stateVocabularyFor, storageCapability, storageEvictableCapability, storageMigrationCapability, storageProviderCapability, streamBrokerCapability, streamCatalogCapability, streamParamsCapability, streamPixels, streamQualityLabel, subKindsOf, summarisePrivacyAudio, supportedRuntimes, switchCapability, switchedOffIds, synthesizeSourceInfo, systemCapability, tamperCapability, taskLogEntrySchema, taskPhaseSchema, taskTargetSchema, temperatureSensorCapability, terminalSessionCapability, textToHtml, toDeviceSummary, toExpressionValue, toNodeId, toStreamSourceEntry, toastCapability, tokenize, transcodeBody, tryConvertUnit, turnProviderCapability, unitDimension, unitsForDimension, updateCapability, userManagementCapability, userPasskeysCapability, vacuumControlCapability, validateExpressionSource, validateRecipeBounds, valveCapability, vectorDimFromBase64, vectorStoreCapability, vibrationCapability, videoclipsCapability, viewerUiCapability, waterHeaterCapability, weatherCapability, webrtcClientHintsSchema, webrtcSessionCapability, wiringAddonHealthSchema, wiringHealthSnapshotSchema, wiringNodeHealthSchema, wiringProbeKindSchema, wiringProbeResultSchema, zodEntriesToConfigUI, zoneAnalyticsCapability, zoneRulesCapability, zonesCapability };
40532
+ export { ACCESSORY_LABEL, ALEXA_EGRESS_PROFILE, ALL_CAPABILITY_DEFINITIONS, APPLE_SA_TO_MACRO, AUDIO_ANALYSIS_CAP_NAME, AUDIO_BACKEND_CHOICES, AUDIO_MACRO_LABELS, AUDIO_PRESETS, AccessoriesStatusSchema, AccessoryKind, AddBrokerInputSchema, AddonAutoUpdateSchema, AddonListItemSchema, AddonPageDeclarationSchema, AddonPageInfoSchema, AdoptInputSchema as AdoptionAdoptInputSchema, AdoptResultSchema as AdoptionAdoptResultSchema, AdoptionCandidateResultSchema, AdoptionFilterSchema, GetCandidateInputSchema as AdoptionGetCandidateInputSchema, AdoptionJobSchema, AdoptionJobStateSchema, ListCandidatesInputSchema as AdoptionListCandidatesInputSchema, ListCandidatesOutputSchema as AdoptionListCandidatesOutputSchema, AdoptionOutcomeSchema, ReleaseInputSchema as AdoptionReleaseInputSchema, AdoptionStatusSchema, AgentLoadSummarySchema, AirQualitySensorStatusSchema, AlarmArmModeSchema, AlarmPanelStatusSchema, AlarmStateSchema, AlertSchema, AlertSeveritySchema, AlertSourceSchema, AlertStatusSchema, AmbientLightSensorStatusSchema, ApiKeyRecordSchema, ApiKeySummarySchema, ArchiveEntrySchema, ArchiveManifestSchema, AttachmentMediaTypeSchema, AttachmentSchema, AudioAnalysisResultSchema, AudioAnalysisSettingsSchema, AudioChunkInputSchema, AudioClassSummarySchema, AudioClassificationLabelSchema, AudioClassificationResultSchema, AudioCodecInfoSchema, AudioDecodeSessionConfigSchema, AudioEncodeSchema, AudioEncodeSessionConfigSchema, AudioEncodedChunkSchema, AudioEventSchema, AudioLevelSchema, AudioMetricsHistoryPointSchema, AudioMetricsHistorySchema, AudioMetricsSnapshotSchema, AudioPcmChunkSchema, AuthResultSchema, AutoUpdateSettingsSchema, AutomationActionSchema, AutomationConditionOperatorSchema, AutomationConditionSchema, AutomationControlStatusSchema, AutomationRecipeSchema, AutomationTriggerSchema, AvailableIntegrationTypeSchema, BACKEND_TO_FORMAT, BASE_LIVE_EGRESS_PROFILE, BATTERY_DEVICE_PROFILE, BacklightModeSchema, BackupDestinationInfoSchema, BackupEntrySchema, BaseAddon, BaseDevice, BaseDeviceProvider, BatteryStatusSchema, BinaryStatusSchema, BoundingBoxSchema, BrightnessStatusSchema, AddInputSchema as BrokerAddInputSchema, BrokerAudioClientSchema, BrokerClientsSchema, BrokerConnectionDetailsSchema, BrokerConsumerAttributionSchema, BrokerConsumerKindSchema, BrokerDecodedClientSchema, BrokerEncodedClientSchema, GetStateInputSchema as BrokerGetStateInputSchema, BrokerInfoSchema, BrokerProviderInfoSchema, PublishInputSchema as BrokerPublishInputSchema, RegistryStatusSchema as BrokerRegistryStatusSchema, BrokerRtspClientSchema, BrokerStatsSchema, BrokerStatusEnum, BrokerStatusSchema, SubscribeInputSchema as BrokerSubscribeInputSchema, SubscribeResultSchema as BrokerSubscribeResultSchema, TestConnectionResultSchema as BrokerTestConnectionResultSchema, UnsubscribeInputSchema as BrokerUnsubscribeInputSchema, CAMERA_SWITCH_CATALOG, CAMERA_SWITCH_ORDER, CAM_PROFILE_ORDER, CAPABILITY_NAMES, CAPABILITY_ROUTER_KEYS, CAP_NAMES_WITH_STATUS, CAP_NODE_PIN_CONTEXT_KEY, CAP_PROVIDER_KIND_MAP, COCO_80_LABELS, COCO_TO_MACRO, CONNECTION_TEST_TIMEOUT_MS, CORE_BLOCKS_ADDON_ID, CORE_BLOCK_ADDON_PREFIX, CamProfileSchema, CamStreamDescriptorSchema, CamStreamKindSchema, CamStreamResolutionSchema, CameraAssignmentStatusSchema, CameraAudioStatusSchema, CameraBrokerProfileSchema, CameraBrokerStatusSchema, CameraCredentialsSchema, CameraCredentialsStatusSchema, CameraDecoderShmSchema, CameraDecoderStatusSchema, CameraDetectionPhaseSchema, CameraDetectionProvisioningSchema, CameraDetectionProvisioningStateSchema, CameraDetectionStatusSchema, CameraMetricsSchema, CameraMetricsWithDeviceIdSchema, CameraMotionStatusSchema, CameraRecordingModeSchema, CameraRecordingStatusSchema, CameraSourceStatusSchema, CameraSourceStreamSchema, CameraStatusDegradationReasonSchema, CameraStatusDegradationSchema, CameraStatusSchema, CameraStatusStageSchema, CameraStreamSchema, CameraSwitchAuthoritySchema, CameraSwitchGroupSchema, CameraSwitchIdSchema, CameraSwitchSchema, CameraSwitchUnavailableReasonSchema, CandidateQueryFilterSchema, CapScopeSchema, CapabilityBindingsSchema, CarbonMonoxideStatusSchema, ChargingStatus, ClientNetworkStatsSchema, ClimateControlStatusSchema, ClipPlaybackSchema, ClipSchema, ClusterAddonNodeDeploymentSchema, ClusterAddonStatusEntrySchema, CollectionColumnSchema, CollectionIndexSchema, ColorStatusSchema, ConfigEntrySchema, ConfigSectionWithValuesSchema, ConfigTabDeclarationSchema, ConnectionTestDescriptorSchema, ConnectionTestInputSchema, ConnectionTestOutcomeSchema, ConnectivityStatusSchema, ConsumableItemSchema, ConsumablesStatusSchema, ContactStatusSchema, ControlKindSchema, ControlStatusSchema, ConvertArtifactSchema, ConvertResultSchema, ConvertTargetSchema, CoreBlockCompileResultSchema, CoreBlockInputSchema, CoreBlockPlacementSchema, CoreBlockSchema, CoreBlockStatusSchema, CoverStateSchema, CoverStatusSchema, CreateApiKeyInputSchema, CreateApiKeyResultSchema, CreateIntegrationInputSchema, CreateScopedTokenInputSchema, CreateScopedTokenResultSchema, CreateUserInputSchema, CustomActionInputSchema, CustomModelDescriptorSchema, DATAPLANE_SECRET_HEADER, DECLARED_DEVICE_SWEEP_LIMIT, DECLARED_INTEGRATION_FIXED_KEY, DEFAULT_ADDON_PLACEMENT, DEFAULT_AUDIO_ANALYZER_CONFIG, DEFAULT_DECODER_HWACCEL_CONFIG, DEFAULT_DETAIL_CROP_CONVENTION, DEFAULT_EVENTS_BAND_BUFFER_SEC, DEFAULT_EVENT_COLOR, DEFAULT_FEATURES, DEFAULT_NATIVE_LEASE_SETTINGS, DEFAULT_RETENTION, DEFAULT_SCRUB_THUMBNAIL_PRESET, DETAIL_CROP_PADDING_FIELD, DETAIL_CROP_PADDING_KEY, DETAIL_CROP_SECTION_ID, DETAIL_CROP_SQUARE_KEY, DETECTION_PIPELINE_CAP_NAME, DEVICE_BACKEND_TO_FORMAT, DEVICE_CAP_NAMES, DEVICE_PROFILES, DEVICE_SCOPED_CAPS, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATE_READERS, DEVICE_STATUS_METHOD, DEVICE_TYPE_CONTROL_KIND, DEVICE_TYPE_INFO, EngineInfoSchema as DataStoreEngineInfoSchema, DayNightModeSchema, DayNightOptionsSchema, DayNightSettingsPatchSchema, DayNightStatusSchema, DeclaredDevices, DecodedAudioChunkSchema, DecodedFrameSchema, DecoderSessionConfigSchema, DecoderStatsSchema, DeleteIntegrationResultSchema, DetailCropConventionSchema, DetectionSourceSchema, DeviceCodeSeveritySchema, DeviceConfig, DeviceDiscoveryStatusSchema, ExposeInputSchema as DeviceExportExposeInputSchema, DeviceExportStatusSchema, UnexposeInputSchema as DeviceExportUnexposeInputSchema, DeviceFeature, DeviceInfoSchema, DeviceNetworkStatsSchema, DeviceRole, DeviceRuntimeState, DeviceStatusSchema, DeviceType, DiscoveredChildDeviceSchema, DiscoveredChildStatusSchema, DiscoveredDeviceSchema, DiscoveredTargetSchema, DisposerChain, DoorbellPressEventSchema, DoorbellStatusSchema, EVENTFUL_CAP_NAMES, EVENT_KIND_BY_CAP, EVENT_PAD_MS, EVENT_TAXONOMY, EXPORT_DENSE_MAX_RANGES, EXPRESSION_BUILTINS, EXPRESSION_BUILTIN_NAMES, EXPRESSION_COMPILE_CACHE_CAPACITY, EXPRESSION_IDENTIFIER_RE, EXPRESSION_INJECTED_NOW, EgressEncodeSchema, EgressRateControlSchema, EgressTranscodeRequestSchema, EgressTranscodeSchema, ElementConfigStore, EmbeddingInfoSchema, EmbeddingResultSchema, EncodeProfileSchema, EncodedPacketSchema, EnrichedWidgetMetadataSchema, EnumSensorDateTimeFormatSchema, EnumSensorStatusSchema, EventCategory, EventEmitterStatusSchema, EventFireSchema, EventItemSchema, EventKindCategorySchema, EventKindDescriptorSchema, EventKindIconSchema, EventKindSchema, EventKindsForDeviceSchema, EventMediaArtifactSchema, EventMediaCoverageSchema, EventMediaKindSchema, EventMediaProductionSchema, EventSourceType, ExportBytesSchema, ExportDenseRangeSchema, ExportDenseSchema, ExportDownloadSchema, ExportOptionsSchema, ExportRecordSchema, ExportSetupFieldSchema, ExportSetupSchema, ExportSpeedSchema, ExportStateSchema, ExportTimelapseSchema, ExposedDeviceSchema, ExposureModeSchema, ExpressionBindingSourceSchema, ExpressionEvalError, ExpressionFieldBindingSchema, ExpressionGlobalBindingSchema, ExpressionLiteralBindingSchema, ExpressionParseError, ExpressionSourceSchema, FanControlStatusSchema, FanDirectionSchema, FeatureManifestSchema, FeatureProbeStatusSchema, FloodStatusSchema, Fmp4BoxSplitter, FrameHandleFormatSchema, FrameHandleSchema, FrameInputSchema, GasStatusSchema, GetStreamWithCodecInputSchema, GlobalMetricsSchema, HAP_AUDIO_BASE, HAP_AUDIO_BITRATE_KBPS, HAP_AUDIO_VBV_KBITS, HAP_KEYFRAME_INTERVAL_SEC, HF_BASE_URL, HF_REPO, HWACCEL_OPTIONS, HealthStatusSchema, HistoryPointSchema, HistoryResolutionEnum, HumidifierStatusSchema, HumiditySensorStatusSchema, HvacModeSchema, ImageContractSchema, ImageContractStateSchema, ImageRotateSchema, ImageSettingsOptionsSchema, ImageSettingsPatchSchema, ImageSettingsStatusSchema, ImageStatusSchema, IngestOwnerSchema, InstalledPackageSchema, IntegrationLiteSchema, IntegrationWithStateSchema, IntercomAbilitySchema, IntercomStatusSchema, KNOWN_CAP_NAMES, KeyEventSchema, LOG_LEVEL_RANK, LabelAttributionSchema, LabelDefinitionSchema, LabelTierSchema, LawnMowerActivitySchema, LawnMowerControlStatusSchema, LinkedDeviceSchema, LinkedDevicesModeSchema, LlmDefaultSchema, LlmDefaultSelectorSchema, LlmErrorCodeSchema, LlmGenerateBaseInputSchema, LlmGenerateErrSchema, LlmGenerateOkSchema, LlmGenerateResultSchema, LlmImageSchema, LlmNodeModelSchema, LlmProfileKindDescriptorSchema, LlmProfileKindSchema, LlmProfileSchema, LlmRuntimeCompleteInputSchema, LlmRuntimeDiskUsageSchema, LlmRuntimeNodeSchema, LlmRuntimeStatusSchema, LlmUsageRollupSchema, LlmUsageSchema, LocateSegmentResultSchema, LocationStatSchema, LockControlStatusSchema, LockStateSchema, LogEntrySchema, LogLevelSchema, LogStreamEntrySchema, LoginMethodContributionSchema, LoginStageEnum, MACRO_LABELS, MAX_CONDITION_DEPTH, MAX_CONDITION_LEAVES, MAX_EXPRESSION_AST_NODES, MAX_EXPRESSION_BINDINGS, MAX_EXPRESSION_CALL_ARGS, MAX_EXPRESSION_EVAL_STEPS, MAX_EXPRESSION_SOURCE_LENGTH, METHOD_ACCESS_MAP, MODEL_FORMATS, MOTION_TRIGGER_FEATURE, ManagedModelCatalogEntrySchema, ManagedModelRefSchema, ManagedRuntimeConfigSchema, MaskGridDimsSchema, MaskGridShapeSchema, MaskLineShapeSchema, MaskPointSchema, MaskPolygonShapeSchema, MaskPolygonVerticesSchema, MaskRectShapeSchema, MaskShapeKindSchema, MaskShapeSchema, MediaFileInfoSchema, MediaFileSchema, MediaPlayerRepeatSchema, MediaPlayerStateSchema, MediaPlayerStatusSchema, MeshPeerSchema, MeshStatusSchema, MethodAccessSchema, ModelCatalogEntrySchema, ModelConvertInputSchema, ModelConvertMetadataSchema, ModelDistributeInputSchema, ModelDistributeResultSchema, ModelExtraFileSchema, ModelFormatEntrySchema, ModelFormatsSchema, ModelSubstitutionSchema, ModelVariantGroupSchema, MotionAnalysisResultSchema, MotionEventSchema, MotionOnMotionChangedDataSchema, MotionRegionSchema, MotionSourceEnum, MotionSourcesSchema, MotionStatusSchema, MotionTriggerRuntimeStateSchema, MotionTriggerStatusSchema, MotionZoneOptionsSchema, MotionZonePatchSchema, MotionZoneRegionSchema, MotionZoneStatusSchema, StatusSchema as MqttBrokerStatusSchema, MutationFilterSchema, NATIVE_LEASE_ACTIVITY_FIELD, NATIVE_LEASE_ACTIVITY_KEY, NATIVE_LEASE_ADMISSION_FIELD, NATIVE_LEASE_ADMISSION_KEY, NATIVE_LEASE_BUDGET_FIELD, NATIVE_LEASE_BUDGET_KEY, NATIVE_LEASE_SECTION_ID, NATIVE_LEASE_TTL_FIELD, NATIVE_LEASE_TTL_KEY, NC_BASE_CONDITION_KEYS, NC_CONDITION_CATALOG, NC_HISTORY_LIMIT_DEFAULT, NC_HISTORY_LIMIT_MAX, NC_MAX_PER_TRACK_IMMEDIATE, NC_SNOOZE_MAX_MINUTES, NC_TAXONOMY, NativeCropBboxSchema, NativeCropRefSchema, NativeCropResultSchema, NativeDetectionSchema, NativeLeaseAdmissionSchema, NativeLeaseSettingsSchema, NativeObjectClassEnum, NativeObjectDetectionRuntimeStateSchema, NativeObjectDetectionStatusSchema, NcAlarmConfigSchema, NcAlarmModeCoverageSchema, NcAlarmSettingsPatchSchema, NcAlarmSettingsSchema, NcConditionDescriptorSchema, NcConditionsSchema, NcCrossingSchema, NcDeliverySchema, NcDeviceStateConditionSchema, NcHistoryEntrySchema, NcHistoryFilterSchema, NcHistoryRecordKindSchema, NcHistoryStatusSchema, NcHistorySubjectSchema, NcMediaFrameSchema, NcMediaPolicySchema, NcOccupancyConditionSchema, NcPlateMatcherSchema, NcRuleActionSchema, NcRuleActionSequenceSchema, NcRuleActionsSchema, NcRuleInputSchema, NcRuleNotificationButtonSchema, NcRulePatchSchema, NcRuleSchema, NcRuleTargetSchema, NcScheduleSchema, NcScheduleWindowSchema, NcSnoozeInputSchema, NcSnoozeSchema, NcSnoozeScopeSchema, NcSnoozeSuppressedSchema, NcSystemEventConditionSchema, NcSystemEventKindSchema, NcTaxonomyEntrySchema, NcTaxonomySchema, NcTestResultSchema, NcThrottleGranularitySchema, NcThrottleSchema, NcZoneConditionSchema, NetworkAccessStatusSchema, NetworkAddressSchema, NetworkEndpointSchema, NotificationActionIconSchema, NotificationActionSchema, NotificationFormatSchema, NotificationSchema, NotifierStatusSchema, NumericSensorStatusSchema, OPS_LOG_DEFAULT_LIMIT, OPS_LOG_RING_DEFAULT_MAX, OauthIntegrationDescriptorSchema, ObjectEventSchema, OpsLogDomainSchema, OpsLogEntrySchema, OpsLogOpSchema, OpsLogQueryInputSchema, OpsLogReasonSchema, OrchestratorMetricsSchema, OsdOverlayKindEnum, OsdOverlayPatchSchema, OsdOverlaySchema, OsdPositionEnum, OsdRenderOutcomeEnum, OsdRenderResultSchema, OsdSlotBindingSchema, OsdSlotViewSchema, OsdSourceOptionSchema, OsdSourceSchema, OsdSourceValueTypeEnum, OsdStatusSchema, PET_FEEDER_MANUAL_FEED_MAX, PET_FEEDER_MANUAL_FEED_MIN, PIPELINE_FLOW_CAPABILITY_NAMES, PIPELINE_OWNER_CAPABILITY_NAMES, PRIVACY_MASK_CAP_NAME, PROVIDER_KIND_CAP_NAMES, PYTHON_SCRIPT, PackageUpdateSchema, PackageVersionInfoSchema, PasskeyLoginMethodSchema, PasskeySummarySchema, PcmSampleFormatSchema, PerScopeBreakdownSchema, PetFeederStatusSchema, PickStreamPreferencesSchema, PickStreamRequirementsSchema, PickedCamStreamSchema, PipelineAssignmentSchema, PipelineDefaultStepSchema, PipelineEngineChoiceSchema, PipelineRunResultBridge, PipelineStepInputSchema, PipelineValidationIssueSchema, PipelineValidationResultSchema, PlaceholderReasonSchema, PolygonPointSchema, PowerMeterStatusSchema, PresenceStatusSchema, PressureSensorStatusSchema, PrivacyMaskOptionsSchema, PrivacyMaskPatchSchema, PrivacyMaskRegionSchema, PrivacyMaskShapeSchema, PrivacyMaskStatusSchema, ProfileRtspEntrySchema, ProfileSlotSchema, ProfileSlotStatusSchema, ProviderStatusSchema, PtzAutotrackRuntimeStateSchema, PtzAutotrackSettingsSchema, PtzAutotrackStatusSchema, PtzAutotrackTargetOptionSchema, PtzMoveCommandSchema, PtzOptionsSchema, PtzPositionSchema, PtzPresetSchema, PtzStatusSchema, QueryFilterSchema, RATE_CONTROL_RELAXED, RATE_CONTROL_TIGHT, REACHABILITY_FAILURES_TO_OFFLINE, REACHABILITY_POLL_INTERVAL_MS, REACHABILITY_PROBE_TIMEOUT_MS, RECOGNITION_TYPES, RECORDING_EXPORT_MAX_READ_BYTES, RESERVED_BINDING_NAMES, RUNTIME_DEFAULTS, RUNTIME_TO_FORMAT, RawStateResultSchema, ReadGopBytesResultSchema, ReadSegmentBytesResultSchema, ReadinessRegistry, ReadinessTimeoutError, RecentTracksPageSchema, RecentTracksQueryInput, RecordingAvailabilitySchema, RecordingBandModeSchema, RecordingBandSchema, RecordingBandTriggersSchema, RecordingConfigSchema, RecordingDaysSchema, RecordingDeviceUsageSchema, RecordingLocationUsageSchema, RecordingManifestSchema, RecordingRangeSchema, RecordingRetentionSchema, RecordingStatusSchema, RecordingStorageModeSchema, RecordingStorageUsageSchema, RecordingTriggersSchema, RecordingWeekdaySchema, RedirectLoginMethodSchema, RelocateFootageClassSchema, RelocateFootageInputSchema, RelocateJobSchema, RelocateJobStateSchema, RelocateMediaInputSchema, RenderedAsSchema, ReportMotionInputSchema, RetrainAnnotationDraftSchema, RetrainAnnotationKindSchema, RetrainAnnotationSchema, RetrainAnnotationSourceSchema, RetrainAssistResultSchema, RetrainAssistSubjectSchema, RetrainCopyRefusalSchema, RetrainFrameCandidateSchema, RetrainFrameListSchema, RetrainFrameSchema, RetrainFrameSelectionSchema, RetrainMacroClassSchema, RetrainStatusSchema, RetrainTrackSchema, RetrainTransitionResultSchema, RingBuffer, RtpSourceSchema, RtspRestreamEntrySchema, RunnerCameraConfigSchema, RunnerCameraDeviceUIFields, RunnerFrameSourceSchema, RunnerInferenceDeviceSchema, RunnerLocalLoadSchema, RunnerLocalMetricsSchema, SCOPE_PRESETS, SCRUB_THUMBNAIL_PRESETS, SCRUB_THUMBNAIL_PRESET_LABELS, SCRUB_THUMBNAIL_PRESET_ORDER, SENSOR_FEATURES, SENSOR_MAP, SOURCE_INFO_METADATA_KEY, STREAM_PROFILE_META, STREAM_QUALITY_LABELS, SUB_DETECTION_TYPES, SYSTEM_CAP_NAMES, SceneCheckSchema, SceneConditionSchema, SceneMonitorSchema, SceneMonitorStateSchema, SceneMonitorStatusSchema, SceneReferenceSchema, ScopedTokenSchema, ScopedTokenSummarySchema, ScoredObjectEventSchema, ScriptRunnerStatusSchema, ScrubThumbnailPresetSchema, SearchResultSchema, SendEmailInputSchema, SendEmailResultSchema, SendResultSchema, SensorEventSchema, ServerBootModeSchema, ServerPackageStatusSchema, ServerRollbackInfoSchema, ServerUpdateActionResultSchema, ServerUpdateCheckResultSchema, ServerUpdateStateSchema, SettingsPatchSchema, SettingsRecordSchema, SettingsSchemaWithValuesSchema, SettingsUpdateResultSchema, ShmRingStatsSchema, SmokeStatusSchema, SmtpStatusSchema, SnapshotImageSchema, SourceInfoSchema, SpatialDetectionSchema, SsoBridgeClaimsSchema, StartEmbeddedInputSchema, StationaryObjectSchema, AbortUploadInputSchema as StorageAbortUploadInputSchema, BeginDownloadInputSchema as StorageBeginDownloadInputSchema, BeginDownloadResultSchema as StorageBeginDownloadResultSchema, BeginUploadInputSchema as StorageBeginUploadInputSchema, BeginUploadResultSchema as StorageBeginUploadResultSchema, EndDownloadInputSchema as StorageEndDownloadInputSchema, FinalizeUploadInputSchema as StorageFinalizeUploadInputSchema, StorageLocationDeclarationSchema, StorageLocationRefSchema, StorageLocationSchema, StorageLocationTypeSchema, StorageMigrationClassSchema, StorageMigrationDestinationsSchema, StorageMigrationFootageMoveInputSchema, StorageMigrationInputSchema, StorageMigrationJobSchema, StorageMigrationLeaseInputSchema, StorageMigrationMediaMoveInputSchema, StorageMigrationMoveSchema, StorageMigrationParticipantSchema, StorageMigrationPhaseSchema, StorageMigrationPlanSchema, ProviderInfoSchema as StorageProviderInfoSchema, ReadChunkInputSchema as StorageReadChunkInputSchema, TestLocationResultSchema as StorageTestLocationResultSchema, WriteChunkInputSchema as StorageWriteChunkInputSchema, StreamCodecSchema, StreamFormatSchema, StreamNetworkStatsSchema, StreamParamsOptionsSchema, StreamParamsStatusSchema, StreamProfileConfigSchema, StreamProfileOptionsSchema, StreamProfilePatchSchema, StreamProfileSchema, StreamSourceEntrySchema, StreamSourceSchema, SubscribeAudioChunksInputSchema, SubscribeAudioChunksResultSchema, SubscribeFramesInputSchema, SubscribeFramesResultSchema, SwitchStatusSchema, SystemMetricsSchema, SystemMirror, TAXONOMY_COLORS, TIMEZONES, TRANSCODE_DOWN_MAX_BITRATE_KBPS, TRANSCODE_DOWN_MAX_HEIGHT, TamperStatusSchema, TankStatusSchema, TargetKindCapsSchema, TargetKindLevelSchema, TargetKindSchema, TargetSchema, TemperatureSensorStatusSchema, TerminalInstanceInfoSchema, TerminalLegacyCameraSchema, TerminalOutputBatchSchema, TerminalOutputEventSchema, TerminalProfileInfoSchema, TerminalSessionInfoSchema, TestConnectionResultSchema$1 as TestConnectionResultSchema, TestConnectionStatusEnum, TestResultSchema, TimelapseRuleInputSchema, TimelapseRulePatchSchema, TimelapseRuleSchema, TimelapseTemplateSchema, ToastSchema, TokenScopeSchema, TopologyNodeSchema, TopologyProcessSchema, TopologyServiceSchema, TrackCascadeCountsSchema, TrackEnvelopeSchema, TrackFlagsPatchSchema, TrackFlagsSchema, TrackProjectionSchema, TrackSchema, TrackSourceSchema, TrackStateSchema, TrackZoneFilterSchema, TrackedDetectionSchema, TrainingExportDeviceTotalsSchema, TrainingExportSummarySchema, TurnServerSchema, UNIT_TABLE, BrokerInfoSchema$1 as UnifiedBrokerInfoSchema, UnitConversionError, UpdateIntegrationInputSchema, UpdateStatusSchema, UpdateUserInputSchema, UserRecordSchema, UserSummarySchema, VacuumControlStatusSchema, VacuumStateSchema, ValveStateSchema, ValveStatusSchema, VectorDeclareIndexInputSchema, VectorDeleteByFilterInputSchema, VectorDeleteInputSchema, VectorDeleteResultSchema, VectorFilterSchema, VectorGetInputSchema, VectorGetResultSchema, VectorItemSchema, VectorMatchSchema, VectorMetadataSchema, VectorMetricSchema, VectorQueryInputSchema, VectorQueryResultSchema, VectorStatsInputSchema, VectorStatsResultSchema, VectorUpsertInputSchema, VectorUpsertResultSchema, VibrationStatusSchema, VideoEncodeSchema, WEBRTC_EGRESS_PROFILE, WELL_KNOWN_TABS, WELL_KNOWN_TAB_MAP, WaterHeaterStatusSchema, WeatherStatusSchema, WebrtcStreamChoiceSchema, WebrtcStreamTargetSchema, WhiteBalanceModeSchema, WidgetHostEnum, WidgetLoginMethodSchema, WidgetMetadataSchema, WidgetRemoteSchema, WidgetSizeEnum, YAMNET_TO_MACRO, ZoneCrossingDirectionSchema, ZoneCrossingSchema, ZoneKindEnum, ZoneRuleModeEnum, ZoneRuleSchema, ZoneRuleStageEnum, ZoneRulesArraySchema, ZoneSchema, ZoneScopeBreakdownSchema, accessoriesCapability, accessoryStableId, addonPagesCapability, addonPagesSourceCapability, addonRoutesCapability, addonSettingsCapability, addonWidgetsCapability, addonWidgetsSourceCapability, addonsCapability, adminUiCapability, airQualitySensorCapability, alarmPanelCapability, alertsCapability, ambientLightSensorCapability, asBoolean, asJsonArray, asJsonObject, asNumber, asString, audioAnalysisCapability, audioAnalyzerCapability, audioCodecCapability, audioMetricsCapability, audioPlanFromEncodeProfile, authProviderCapability, autoAssignProfiles, automationControlCapability, backupCapability, bareAddonId, batteryCapability, bestLocationMatch, binaryCapability, bindAddonActions, brightnessCapability, brokerCapability, buildAddonRouteProvider, buildAudioArgs, buildEventKindDescriptor, buildFfmpegArgs, buildInputArgs, buildModelVariantGroups, buildNcTaxonomy, buildStreamParamsConfigSchema, buildVideoArgs, buttonCapability, cameraCredentialsCapability, cameraPipelineConfigCapability, cameraStreamsCapability, canConvertUnit, canonicalEgressPlan, carbonMonoxideCapability, cellsToRects, classifyBearerPrincipal, classifyStream, classifyStreams, climateControlCapability, collectHydratedFieldEntries, collectHydratedFieldValues, colorCapability, colorForKind, compileExpression, compileExpressionSafe, composeSwitchedOff, conditionDepth, connectionTestCapability, connectivityCapability, consumablesCapability, contactCapability, controlCapability, convertUnit, coreBlockAddonId, coreBlockIdFromAddonId, coreBlocksCapability, cosineSimilarity, countConditionLeaves, coverCapability, createDeviceProxy, createDurableState, createEvent, createExpressionScope, createHwAccelCache, createLazyTrpcSource, createMirrorSource, createRuntimeStateBridge, createSliceHandle, createSystemProxy, customAction, customModelRegistryCapability, dataStoreProviderCapability, dayNightCapability, declarationOwnerNodeId, decodeVectorBase64, decoderCapability, defaultDeviceFor, defineCustomActions, deriveCameraSwitches, deriveDetailCropRect, deriveRecordingMode, describeModelVariant, detectionPipelineCapability, deviceAdoptionCapability, deviceBackendToFormat, deviceCustomAction, deviceDiscoveryCapability, deviceExportCapability, deviceManagerCapability, deviceMatchesProfile, deviceOpsCapability, deviceProviderCapability, deviceStateCapability, deviceStatusCapability, doorbellCapability, egressTranscodeSharingKey, egressTransportFromRequest, embeddingEncoderCapability, emitDownForOwnedCaps, emitReadiness, encodeProfileFromStreamShape, encodeVectorBase64, enumSensorCapability, enumerateInferenceDevices, enumerateItemArrayFields, enumerateSchemaFields, errMsg, evaluateAst, evaluateExpressionSource, evaluateZoneRules, event, eventEmitterCapability, eventsCapability, expandCapMethods, extractNestedAddonId, extractSourceInfoFromMetadata, faceGalleryCapability, fanControlCapability, featureProbeCapability, filesystemBrowseCapability, findTimezone, floodCapability, formatForBackend, formatForRuntime, gasCapability, generateAutomationBlock, getAudioMacroClassIds, getByPath, getCapsByProviderKind, getTaxonomyEntry, hasMotionTrigger, hfModelUrl, htmlToText, humidifierCapability, humiditySensorCapability, hydrateSchema, imageCapability, imageSettingsCapability, integrationsCapability, intercomCapability, invocationFromEncodeProfile, isAgentOnlyPlacement, isArrayOutputSchema, isBaseConditionKey, isCollectionArrayMethod, isDeployableToAgent, isDeviceConfigCap, isDeviceScopedCap, isEvent, isNode, isObjectInput, isSameAddonId, isScheduleActive, isSoftwareDecode, isVoidInput, jobKindSchema, kebabToCamel, knownValues, lawnMowerControlCapability, lifecycleJobSchema, lifecycleJobScopeSchema, lifecycleJobStateSchema, lifecycleTaskSchema, llmCapability, llmRuntimeCapability, localNetworkCapability, locationSimilarity, lockControlCapability, logBannerArgs, logDestinationCapability, logLevelAtMost, loginMethodCapability, looseSchema, makeProfileBrokerId, makeSourceBrokerId, mapAudioLabelToMacro, markdownToHtmlLite, markdownToText, maskUrlCredentials, mediaPlayerCapability, mergeSourceInfo, meshNetworkCapability, method, methodAccessForHttpMethod, metricsProviderCapability, modelConvertCapability, modelDistributorCapability, modelFormatForRuntime, motionCapability, motionDetectionCapability, motionTriggerCapability, motionZonesCapability, mqttBrokerCapability, nativeObjectDetectionCapability, networkAccessCapability, networkQualityCapability, nodePin, nodesCapability, normalizeAddonInitResult, normalizeUnit, notificationOutputCapability, notificationRulesCapability, notifierCapability, numericSensorCapability, oauthIntegrationCapability, objectInputDeclaresAddonId, osdCapability, osdManagerCapability, parseCameraStreamConfig, parseExpression, parseJsonArray, parseJsonObject, parseJsonUnknown, parseProfileBrokerId, parseStreamParamsFormPatch, petFeederCapability, pickAccessoryControl, pickDetailCropConvention, pickNativeLeaseOverride, pickPreferredRtspEntry, pickVideoEncoder, pickerForCondition, pipelineAnalyticsCapability, pipelineExecutorCapability, pipelineOrchestratorCapability, pipelineRunnerCapability, plateGalleryCapability, platformProbeCapability, powerMeterCapability, prepareNotification, presenceCapability, pressureSensorCapability, principalMayReachAddon, privacyMaskCapability, procedureAuthKey, ptzAutotrackCapability, ptzCapability, pythonScriptForBackend, readDetailCropConvention, readDeviceStateFrom, readNativeLeaseOverride, readNodePin, readTimelapseGeneratedAt, readinessKey, rebootCapability, recordingCapability, recordingExportCapability, rectsToCells, requiresPython, resolveAddonExecution, resolveAddonGroup, resolveAddonPlacement, resolveAddonRuntime, resolveCapMount, resolveDetectionRuntime, resolveDeviceControlKind, resolveDeviceProfile, resolveEgressDecodeHwAccel, resolveFormat, resolveHydratedFieldValue, resolveModelFormat, resolveMutate, resolveRunnerId, resolveScrubThumbnailGeometry, resolveVariantModelId, runInferenceStep, runtimeDevices, sceneMonitorCapability, scopeKey, scopesAllowAddon, scopesAllowDeviceCap, scoreRuntimes, scriptRunnerCapability, selectAssignedProfileSlots, serverManagementCapability, setByPath, settingsStoreCapability, sleep, sleepCancellable, smokeCapability, smtpProviderCapability, snapshotCapability, ssoBridgeCapability, startReachabilityPoll, stateVocabularyFor, storageCapability, storageEvictableCapability, storageMigrationCapability, storageProviderCapability, streamBrokerCapability, streamCatalogCapability, streamParamsCapability, streamPixels, streamQualityLabel, subKindsOf, summarisePrivacyAudio, supportedRuntimes, switchCapability, switchedOffIds, synthesizeSourceInfo, systemCapability, tamperCapability, taskLogEntrySchema, taskPhaseSchema, taskTargetSchema, temperatureSensorCapability, terminalSessionCapability, textToHtml, toDeviceSummary, toExpressionValue, toNodeId, toStreamSourceEntry, toastCapability, tokenize, transcodeBody, tryConvertUnit, turnProviderCapability, unitDimension, unitsForDimension, updateCapability, userManagementCapability, userPasskeysCapability, vacuumControlCapability, validateExpressionSource, validateRecipeBounds, valveCapability, vectorDimFromBase64, vectorStoreCapability, vibrationCapability, videoclipsCapability, viewerUiCapability, waterHeaterCapability, weatherCapability, webrtcClientHintsSchema, webrtcSessionCapability, wiringAddonHealthSchema, wiringHealthSnapshotSchema, wiringNodeHealthSchema, wiringProbeKindSchema, wiringProbeResultSchema, zodEntriesToConfigUI, zoneAnalyticsCapability, zoneRulesCapability, zonesCapability };
@@ -1,6 +1,29 @@
1
1
  /**
2
- * Per-camera FUNCTION SWITCHES — the one coherent on/off surface over the
3
- * pipeline functions an operator thinks in terms of.
2
+ * Per-camera FUNCTION SWITCHES.
3
+ *
4
+ * ## The aggregate group is being withdrawn — the BADGE is not (D113)
5
+ *
6
+ * This file shipped as "the one coherent on/off surface over the pipeline
7
+ * functions an operator thinks in terms of". The operator's verdict on
8
+ * 2026-08-12 was that the coherent surface bought complexity and no clarity:
9
+ * every function already had a settings page of its own, and a second place to
10
+ * turn it off is a second place to look. Each switch is going back to its own
11
+ * component's original options — detection to the detection-pipeline wrapper
12
+ * binding, audio analysis to its own, recording to `RecordingConfig.enabled`
13
+ * (which was always first-class; the switch was a veneer over
14
+ * `recording.setDeviceConfig`), notifications to a notification-center
15
+ * per-device setting, the two camera planes to their own components.
16
+ *
17
+ * What survives is {@link composeSwitchedOff}: `CameraStatus.switchedOff`, the
18
+ * thing that lets a status surface say DISABLED instead of BROKEN, recomposed
19
+ * straight from the authorities with no group in the middle. That rule was
20
+ * never about a control panel.
21
+ *
22
+ * Everything else here — {@link CAMERA_SWITCH_CATALOG}, {@link CameraSwitch},
23
+ * {@link deriveCameraSwitches}, the `pipelineOrchestrator.getCameraSwitches` /
24
+ * `setCameraSwitch` pair — is a COMPATIBILITY surface for as long as deployed
25
+ * viewers (v1.0.305) and the admin UI still call it. It is deleted when they
26
+ * stop; nothing new may be built on it.
4
27
  *
5
28
  * ## This file adds no state
6
29
  *
@@ -421,3 +444,44 @@ export declare function deriveCameraSwitches(input: CameraSwitchDerivationInput)
421
444
  * "switched off" badge, and the badge that matters would be lost in it.
422
445
  */
423
446
  export declare function switchedOffIds(switches: readonly CameraSwitch[]): readonly CameraSwitchId[];
447
+ /**
448
+ * The badge, and whether the badge is a TOTAL.
449
+ *
450
+ * Two lists rather than one because an empty `switchedOff` means two opposite
451
+ * things depending on the second: with an empty `unreadable` it is the positive
452
+ * claim "the operator turned nothing off" (so a quiet camera is BROKEN); with a
453
+ * non-empty one it is a FLOOR, and a surface that renders it as the positive
454
+ * claim reproduces the 2026-08-08 inversion exactly.
455
+ */
456
+ export interface SwitchedOffComposition {
457
+ /** Functions a person switched off, in {@link CAMERA_SWITCH_ORDER}. */
458
+ readonly switchedOff: readonly CameraSwitchId[];
459
+ /**
460
+ * Functions whose AUTHORITY did not answer. Non-empty ⇒ `switchedOff` is a
461
+ * floor, not a total, and the caller must say so (`CameraStatus.degraded`
462
+ * naming `'switches'`).
463
+ */
464
+ readonly unreadable: readonly CameraSwitchId[];
465
+ }
466
+ /**
467
+ * Compose the `switchedOff` badge STRAIGHT from the authorities (D113).
468
+ *
469
+ * This is the half of this file that outlives the switch group.
470
+ * {@link deriveCameraSwitches} exists to paint a control panel — labels, cost
471
+ * lines, `available`/`unavailableReason` — and that panel is being dismantled:
472
+ * each function is going back to its own component's settings. The BADGE is
473
+ * not: "a switched-off camera must read as DISABLED, not broken" is a rule
474
+ * about status, not about a control group, and it survives every surface change
475
+ * underneath it.
476
+ *
477
+ * So the badge gets its own entry point over the same authority reads, and the
478
+ * caller that only needs the badge never builds eight labelled rows to throw
479
+ * seven of them away.
480
+ *
481
+ * `privacy-mask` appears in NEITHER list, whichever way it is sitting and
482
+ * whether or not it could be read — its ON means "the mask is obscuring video",
483
+ * not "this function works" ({@link CameraSwitchDescriptor.countsAsSwitchedOff}).
484
+ * Counting it unreadable would be its own bug: the mask cannot contribute to
485
+ * the badge, so failing to read it cannot make the badge incomplete.
486
+ */
487
+ export declare function composeSwitchedOff(input: CameraSwitchDerivationInput): SwitchedOffComposition;
@@ -129,8 +129,22 @@ export declare const TimelapseRuleSchema: z.ZodObject<{
129
129
  id: z.ZodString;
130
130
  ownerUserId: z.ZodOptional<z.ZodString>;
131
131
  lastGeneratedAt: z.ZodOptional<z.ZodNumber>;
132
+ generatedByDevice: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
132
133
  createdBy: z.ZodString;
133
134
  createdAt: z.ZodNumber;
134
135
  updatedAt: z.ZodNumber;
135
136
  }, z.core.$strip>;
136
137
  export type TimelapseRule = z.infer<typeof TimelapseRuleSchema>;
138
+ /**
139
+ * The last successful generation for ONE camera of a rule, epoch-ms.
140
+ *
141
+ * The per-device map wins; a rule with no map falls back to the rule-wide
142
+ * `lastGeneratedAt` (the compatible-migration path — see
143
+ * {@link TimelapseRuleSchema}); a rule with neither returns 0, which every
144
+ * guard reads as "never generated".
145
+ *
146
+ * Read through this helper and never off the field directly: the fallback is
147
+ * the whole migration, and a call site that forgot it would re-render an
148
+ * entire rule set once.
149
+ */
150
+ export declare function readTimelapseGeneratedAt(rule: Pick<TimelapseRule, 'lastGeneratedAt' | 'generatedByDevice'>, deviceId: number): number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/types",
3
- "version": "1.2.60",
3
+ "version": "1.2.61",
4
4
  "description": "Shared types, interfaces, and model catalogs for the CamStack detection ecosystem",
5
5
  "keywords": [
6
6
  "camstack",