@camstack/types 1.1.19 → 1.1.20

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.
@@ -88,6 +88,12 @@ export declare const batteryCapability: {
88
88
  binary: z.ZodOptional<z.ZodBoolean>;
89
89
  }, z.core.$strip>;
90
90
  readonly kind: "push";
91
+ readonly empty: {
92
+ readonly percentage: 0;
93
+ readonly charging: "none";
94
+ readonly sleeping: false;
95
+ readonly lastUpdated: 0;
96
+ };
91
97
  };
92
98
  /**
93
99
  * Runtime-state slice — every provider that registers this cap
@@ -67,10 +67,49 @@ export interface CapabilityEventSchema<TData extends z.ZodType = z.ZodType> {
67
67
  readonly data: TData;
68
68
  }
69
69
  export type CapabilityStatusKind = 'push' | 'poll' | 'command-driven';
70
+ /**
71
+ * Declares that a cap's status is an ITEM-ARRAY wiring target: the status
72
+ * holds an array of keyed items (`consumables.items`) that device-links can
73
+ * populate per item via `DeviceLink.target.itemKey`. Links sharing an
74
+ * `itemKey` are grouped into ONE item: the merge seeds a new item from
75
+ * `emptyItem` (with `keyField` — and `labelField` when declared — set to the
76
+ * itemKey), overlays each link's per-item `fieldPath`, validates the item
77
+ * against `itemSchema`, then upserts it into the array by `keyField`.
78
+ */
79
+ export interface CapabilityStatusItemArray {
80
+ /** Dot-path from the status root to the array field (e.g. 'items'). */
81
+ readonly path: string;
82
+ /** Item field carrying the stable per-item key (e.g. 'key'). */
83
+ readonly keyField: string;
84
+ /** Optional item field defaulted to the itemKey when a NEW item is seeded
85
+ * and no link overlays it (e.g. 'label' — schemas often require it
86
+ * non-empty). Existing items keep their value. */
87
+ readonly labelField?: string;
88
+ /** Zod schema of ONE array item — the per-item validation gate (a bad
89
+ * item is skipped without discarding the other items). */
90
+ readonly itemSchema: z.ZodType;
91
+ /** Seed for a NEW item created from links; `keyField`/`labelField` are
92
+ * overwritten with the itemKey, links overlay the rest. Must produce an
93
+ * `itemSchema`-valid item once seeded. */
94
+ readonly emptyItem: Readonly<Record<string, unknown>>;
95
+ }
70
96
  export interface CapabilityStatusSchema<TStatus extends z.ZodType = z.ZodType> {
71
97
  readonly schema: TStatus;
72
98
  /** Documentation hint on update cadence — used by the aggregator and UI. */
73
99
  readonly kind?: CapabilityStatusKind;
100
+ /**
101
+ * Default status used as the merge BASE when a device-link *synthesizes*
102
+ * this cap (no native provider). Required-but-unlinked fields (enums,
103
+ * timestamps) come from here so the synthesized status validates against
104
+ * `schema`. Omit for caps that are never synthesize targets.
105
+ */
106
+ readonly empty?: z.infer<TStatus>;
107
+ /**
108
+ * Item-array wiring descriptor — set when the status holds an array of
109
+ * keyed items that device-links populate per item (`itemKey` grouping).
110
+ * See {@link CapabilityStatusItemArray}. Omit for scalar-only caps.
111
+ */
112
+ readonly itemArray?: CapabilityStatusItemArray;
74
113
  }
75
114
  /** How a contribution's component is resolved by the renderer. */
76
115
  export type UiContributionKind = 'remote';
@@ -84,6 +84,41 @@ export declare const consumablesCapability: {
84
84
  lastChangedAt: z.ZodNumber;
85
85
  }, z.core.$strip>;
86
86
  readonly kind: "push";
87
+ readonly empty: {
88
+ items: {
89
+ key: string;
90
+ label: string;
91
+ level: number | null;
92
+ status: "replace" | "ok" | null;
93
+ lastResetAt: number | null;
94
+ resettable: boolean;
95
+ }[];
96
+ lastChangedAt: number;
97
+ };
98
+ readonly itemArray: {
99
+ readonly path: "items";
100
+ readonly keyField: "key";
101
+ readonly labelField: "label";
102
+ readonly itemSchema: z.ZodObject<{
103
+ key: z.ZodString;
104
+ label: z.ZodString;
105
+ level: z.ZodNullable<z.ZodNumber>;
106
+ status: z.ZodNullable<z.ZodEnum<{
107
+ replace: "replace";
108
+ ok: "ok";
109
+ }>>;
110
+ lastResetAt: z.ZodNullable<z.ZodNumber>;
111
+ resettable: z.ZodBoolean;
112
+ }, z.core.$strip>;
113
+ readonly emptyItem: {
114
+ key: string;
115
+ label: string;
116
+ level: number | null;
117
+ status: "replace" | "ok" | null;
118
+ lastResetAt: number | null;
119
+ resettable: boolean;
120
+ };
121
+ };
87
122
  };
88
123
  readonly runtimeState: z.ZodObject<{
89
124
  items: z.ZodArray<z.ZodObject<{
@@ -19,6 +19,46 @@
19
19
  import { z } from 'zod';
20
20
  import { DeviceType } from '../device/device-type.js';
21
21
  import { StreamSourceEntrySchema } from './schemas/streaming-shared.js';
22
+ /** Cap-wire shape of a DeviceLink — structurally mirrors `DeviceLink` in
23
+ * `device-management.ts`. Source is a union: a FIELD source copies a sibling
24
+ * accessory's status field (`kind` optional/absent for wire compat); a
25
+ * LITERAL source carries a per-device constant (no sibling is read); a
26
+ * GLOBAL source (P2e) copies ANY device's status field, addressed by the
27
+ * source device's full re-sync-stable `stableId`. */
28
+ export declare const DeviceLinkSchema: z.ZodObject<{
29
+ id: z.ZodString;
30
+ source: z.ZodUnion<readonly [z.ZodObject<{
31
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
32
+ sourceKey: z.ZodString;
33
+ cap: z.ZodString;
34
+ fieldPath: z.ZodString;
35
+ }, z.core.$strip>, z.ZodObject<{
36
+ kind: z.ZodLiteral<"literal">;
37
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
38
+ }, z.core.$strip>, z.ZodObject<{
39
+ kind: z.ZodLiteral<"global">;
40
+ sourceStableId: z.ZodString;
41
+ cap: z.ZodString;
42
+ fieldPath: z.ZodString;
43
+ }, z.core.$strip>]>;
44
+ target: z.ZodObject<{
45
+ cap: z.ZodString;
46
+ fieldPath: z.ZodString;
47
+ itemKey: z.ZodOptional<z.ZodString>;
48
+ }, z.core.$strip>;
49
+ transform: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
50
+ kind: z.ZodLiteral<"identity">;
51
+ }, z.core.$strip>, z.ZodObject<{
52
+ kind: z.ZodLiteral<"enum-map">;
53
+ mapping: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
54
+ fallback: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
55
+ }, z.core.$strip>, z.ZodObject<{
56
+ kind: z.ZodLiteral<"linear">;
57
+ scale: z.ZodNumber;
58
+ offset: z.ZodNumber;
59
+ clamp: z.ZodOptional<z.ZodReadonly<z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>>>;
60
+ }, z.core.$strip>], "kind">>;
61
+ }, z.core.$strip>;
22
62
  /**
23
63
  * Serializable projection of a live IDevice.
24
64
  * Returned by listAll, getDevice, getChildren.
@@ -57,11 +97,20 @@ export declare const DeviceInfoSchema: z.ZodObject<{
57
97
  }, z.core.$strip>>>>;
58
98
  deviceLinks: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
59
99
  id: z.ZodString;
60
- source: z.ZodObject<{
100
+ source: z.ZodUnion<readonly [z.ZodObject<{
101
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
61
102
  sourceKey: z.ZodString;
62
103
  cap: z.ZodString;
63
104
  fieldPath: z.ZodString;
64
- }, z.core.$strip>;
105
+ }, z.core.$strip>, z.ZodObject<{
106
+ kind: z.ZodLiteral<"literal">;
107
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
108
+ }, z.core.$strip>, z.ZodObject<{
109
+ kind: z.ZodLiteral<"global">;
110
+ sourceStableId: z.ZodString;
111
+ cap: z.ZodString;
112
+ fieldPath: z.ZodString;
113
+ }, z.core.$strip>]>;
65
114
  target: z.ZodObject<{
66
115
  cap: z.ZodString;
67
116
  fieldPath: z.ZodString;
@@ -129,11 +178,20 @@ export declare const DeviceMetaSchema: z.ZodObject<{
129
178
  }, z.core.$strip>>>>;
130
179
  deviceLinks: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
131
180
  id: z.ZodString;
132
- source: z.ZodObject<{
181
+ source: z.ZodUnion<readonly [z.ZodObject<{
182
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
133
183
  sourceKey: z.ZodString;
134
184
  cap: z.ZodString;
135
185
  fieldPath: z.ZodString;
136
- }, z.core.$strip>;
186
+ }, z.core.$strip>, z.ZodObject<{
187
+ kind: z.ZodLiteral<"literal">;
188
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
189
+ }, z.core.$strip>, z.ZodObject<{
190
+ kind: z.ZodLiteral<"global">;
191
+ sourceStableId: z.ZodString;
192
+ cap: z.ZodString;
193
+ fieldPath: z.ZodString;
194
+ }, z.core.$strip>]>;
137
195
  target: z.ZodObject<{
138
196
  cap: z.ZodString;
139
197
  fieldPath: z.ZodString;
@@ -254,11 +312,20 @@ export declare const deviceManagerCapability: {
254
312
  }, z.core.$strip>>>>;
255
313
  deviceLinks: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
256
314
  id: z.ZodString;
257
- source: z.ZodObject<{
315
+ source: z.ZodUnion<readonly [z.ZodObject<{
316
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
258
317
  sourceKey: z.ZodString;
259
318
  cap: z.ZodString;
260
319
  fieldPath: z.ZodString;
261
- }, z.core.$strip>;
320
+ }, z.core.$strip>, z.ZodObject<{
321
+ kind: z.ZodLiteral<"literal">;
322
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
323
+ }, z.core.$strip>, z.ZodObject<{
324
+ kind: z.ZodLiteral<"global">;
325
+ sourceStableId: z.ZodString;
326
+ cap: z.ZodString;
327
+ fieldPath: z.ZodString;
328
+ }, z.core.$strip>]>;
262
329
  target: z.ZodObject<{
263
330
  cap: z.ZodString;
264
331
  fieldPath: z.ZodString;
@@ -345,11 +412,20 @@ export declare const deviceManagerCapability: {
345
412
  deviceId: z.ZodNumber;
346
413
  deviceLinks: z.ZodReadonly<z.ZodArray<z.ZodObject<{
347
414
  id: z.ZodString;
348
- source: z.ZodObject<{
415
+ source: z.ZodUnion<readonly [z.ZodObject<{
416
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
349
417
  sourceKey: z.ZodString;
350
418
  cap: z.ZodString;
351
419
  fieldPath: z.ZodString;
352
- }, z.core.$strip>;
420
+ }, z.core.$strip>, z.ZodObject<{
421
+ kind: z.ZodLiteral<"literal">;
422
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
423
+ }, z.core.$strip>, z.ZodObject<{
424
+ kind: z.ZodLiteral<"global">;
425
+ sourceStableId: z.ZodString;
426
+ cap: z.ZodString;
427
+ fieldPath: z.ZodString;
428
+ }, z.core.$strip>]>;
353
429
  target: z.ZodObject<{
354
430
  cap: z.ZodString;
355
431
  fieldPath: z.ZodString;
@@ -370,9 +446,17 @@ export declare const deviceManagerCapability: {
370
446
  }, z.core.$strip>>>;
371
447
  }, z.core.$strip>, z.ZodVoid, "mutation">;
372
448
  /** List the wireable status-schema fields per cap bound to a device.
373
- * Powers the Wiring tab's field pickers. Caps without a status schema are omitted. */
449
+ * Powers the Wiring tab's field pickers. Caps without a status schema are
450
+ * omitted. Item-array caps (`status.itemArray`, e.g. consumables) also
451
+ * emit their per-item fields tagged `item: true` (a link targeting one
452
+ * must carry a `target.itemKey`) plus the cap-level `itemArray`
453
+ * descriptor. `includeSynthesizable: true` (TARGET pickers only) unions
454
+ * in unbound device-scoped caps that declare `status.empty` and match
455
+ * the device's type — so the FIRST link to a synthesize-only cap
456
+ * (consumables on an HA vacuum) can be authored. */
374
457
  readonly getWireableFields: import("./capability-definition.js").CapabilityMethodSchema<z.ZodObject<{
375
458
  deviceId: z.ZodNumber;
459
+ includeSynthesizable: z.ZodOptional<z.ZodBoolean>;
376
460
  }, z.core.$strip>, z.ZodObject<{
377
461
  caps: z.ZodReadonly<z.ZodArray<z.ZodObject<{
378
462
  cap: z.ZodString;
@@ -385,7 +469,12 @@ export declare const deviceManagerCapability: {
385
469
  enum: "enum";
386
470
  }>;
387
471
  enumValues: z.ZodOptional<z.ZodArray<z.ZodString>>;
472
+ item: z.ZodOptional<z.ZodBoolean>;
388
473
  }, z.core.$strip>>>;
474
+ itemArray: z.ZodOptional<z.ZodObject<{
475
+ path: z.ZodString;
476
+ keyField: z.ZodString;
477
+ }, z.core.$strip>>;
389
478
  }, z.core.$strip>>>;
390
479
  }, z.core.$strip>, "query">;
391
480
  /** Stamp (or update) the semantic role on the device's meta row.
@@ -501,11 +590,20 @@ export declare const deviceManagerCapability: {
501
590
  }, z.core.$strip>>>>;
502
591
  deviceLinks: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
503
592
  id: z.ZodString;
504
- source: z.ZodObject<{
593
+ source: z.ZodUnion<readonly [z.ZodObject<{
594
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
505
595
  sourceKey: z.ZodString;
506
596
  cap: z.ZodString;
507
597
  fieldPath: z.ZodString;
508
- }, z.core.$strip>;
598
+ }, z.core.$strip>, z.ZodObject<{
599
+ kind: z.ZodLiteral<"literal">;
600
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
601
+ }, z.core.$strip>, z.ZodObject<{
602
+ kind: z.ZodLiteral<"global">;
603
+ sourceStableId: z.ZodString;
604
+ cap: z.ZodString;
605
+ fieldPath: z.ZodString;
606
+ }, z.core.$strip>]>;
509
607
  target: z.ZodObject<{
510
608
  cap: z.ZodString;
511
609
  fieldPath: z.ZodString;
@@ -561,11 +659,20 @@ export declare const deviceManagerCapability: {
561
659
  }, z.core.$strip>>>>;
562
660
  deviceLinks: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
563
661
  id: z.ZodString;
564
- source: z.ZodObject<{
662
+ source: z.ZodUnion<readonly [z.ZodObject<{
663
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
565
664
  sourceKey: z.ZodString;
566
665
  cap: z.ZodString;
567
666
  fieldPath: z.ZodString;
568
- }, z.core.$strip>;
667
+ }, z.core.$strip>, z.ZodObject<{
668
+ kind: z.ZodLiteral<"literal">;
669
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
670
+ }, z.core.$strip>, z.ZodObject<{
671
+ kind: z.ZodLiteral<"global">;
672
+ sourceStableId: z.ZodString;
673
+ cap: z.ZodString;
674
+ fieldPath: z.ZodString;
675
+ }, z.core.$strip>]>;
569
676
  target: z.ZodObject<{
570
677
  cap: z.ZodString;
571
678
  fieldPath: z.ZodString;
@@ -621,11 +728,20 @@ export declare const deviceManagerCapability: {
621
728
  }, z.core.$strip>>>>;
622
729
  deviceLinks: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
623
730
  id: z.ZodString;
624
- source: z.ZodObject<{
731
+ source: z.ZodUnion<readonly [z.ZodObject<{
732
+ kind: z.ZodOptional<z.ZodLiteral<"field">>;
625
733
  sourceKey: z.ZodString;
626
734
  cap: z.ZodString;
627
735
  fieldPath: z.ZodString;
628
- }, z.core.$strip>;
736
+ }, z.core.$strip>, z.ZodObject<{
737
+ kind: z.ZodLiteral<"literal">;
738
+ value: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>;
739
+ }, z.core.$strip>, z.ZodObject<{
740
+ kind: z.ZodLiteral<"global">;
741
+ sourceStableId: z.ZodString;
742
+ cap: z.ZodString;
743
+ fieldPath: z.ZodString;
744
+ }, z.core.$strip>]>;
629
745
  target: z.ZodObject<{
630
746
  cap: z.ZodString;
631
747
  fieldPath: z.ZodString;
@@ -754,6 +870,7 @@ export declare const deviceManagerCapability: {
754
870
  capName: z.ZodString;
755
871
  kind: z.ZodEnum<{
756
872
  native: "native";
873
+ linked: "linked";
757
874
  wrapped: "wrapped";
758
875
  }>;
759
876
  providerAddonId: z.ZodString;
@@ -775,6 +892,7 @@ export declare const deviceManagerCapability: {
775
892
  capName: z.ZodString;
776
893
  kind: z.ZodEnum<{
777
894
  native: "native";
895
+ linked: "linked";
778
896
  wrapped: "wrapped";
779
897
  }>;
780
898
  providerAddonId: z.ZodString;
@@ -37,7 +37,7 @@ export { ArchiveEntrySchema, ArchiveManifestSchema, BackupDestinationInfoSchema,
37
37
  export { BrokerAddInputSchema, BrokerGetStateInputSchema, type BrokerInfo as UnifiedBrokerInfo, BrokerInfoSchema as UnifiedBrokerInfoSchema, type BrokerProviderInfo, BrokerProviderInfoSchema, BrokerPublishInputSchema, BrokerRegistryStatusSchema, type BrokerStatus as UnifiedBrokerStatus, BrokerStatusEnum, BrokerSubscribeInputSchema, BrokerSubscribeResultSchema, BrokerTestConnectionResultSchema, BrokerUnsubscribeInputSchema, brokerCapability, type IBrokerProvider, } from './broker.cap.js';
38
38
  export { cameraPipelineConfigCapability, type ICameraPipelineConfigProvider, } from './camera-pipeline-config.cap.js';
39
39
  export { cameraStreamsCapability, type ICameraStreamsProvider, type PickedCamStream, PickedCamStreamSchema, PickStreamPreferencesSchema, PickStreamRequirementsSchema, type StreamCodec, StreamCodecSchema, } from './camera-streams.cap.js';
40
- export type { CapabilityDefinition, CapabilityEventSchema, CapabilityMethodAuth, CapabilityMethodKind, CapabilityMethodOptions, CapabilityMethodSchema, CapabilityMountHint, CapabilityMountKind, DeviceConfigDerivedFormUi, DeviceConfigSpec, DeviceConfigUiSpec, DeviceConfigWidgetUi, DeviceSettingsContribution, InferDeviceProxyCap, InferEvents, InferName, InferNativeProvider, InferProvider, InferRuntimeState, ProviderKind, UiContribution, UiContributionKind, UiContributionRemote, } from './capability-definition.js';
40
+ export type { CapabilityDefinition, CapabilityEventSchema, CapabilityMethodAuth, CapabilityMethodKind, CapabilityMethodOptions, CapabilityMethodSchema, CapabilityMountHint, CapabilityMountKind, CapabilityStatusItemArray, CapabilityStatusKind, CapabilityStatusSchema, DeviceConfigDerivedFormUi, DeviceConfigSpec, DeviceConfigUiSpec, DeviceConfigWidgetUi, DeviceSettingsContribution, InferDeviceProxyCap, InferEvents, InferName, InferNativeProvider, InferProvider, InferRuntimeState, ProviderKind, UiContribution, UiContributionKind, UiContributionRemote, } from './capability-definition.js';
41
41
  export { DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATUS_METHOD, event, expandCapMethods, isDeviceConfigCap, method, resolveCapMount, } from './capability-definition.js';
42
42
  export * from './custom-actions.js';
43
43
  export type { CustomModelDescriptor, ICustomModelRegistryProvider, } from './custom-model-registry.cap.js';
@@ -6,13 +6,19 @@
6
6
  */
7
7
  export interface DeviceBindingEntry {
8
8
  capName: string;
9
- kind: 'native' | 'wrapped';
9
+ /** `native`/`wrapped` = a real provider serves the cap. `linked` = the cap
10
+ * is SYNTHESIZED from device-links (no provider — the getStatus dispatcher
11
+ * routes to device-manager's resolveLinkedStatus). UI metadata only —
12
+ * consumers must never branch on it for routing (D13). */
13
+ kind: 'native' | 'wrapped' | 'linked';
10
14
  /** Currently-active provider. For kind='native', equal to `nativeAddonId`.
11
- * For kind='wrapped', the wrapper addon id. */
15
+ * For kind='wrapped', the wrapper addon id. For kind='linked', the
16
+ * device-manager addon id (the synthesize owner). */
12
17
  providerAddonId: string;
13
18
  /** Node where the active provider runs. 'hub' for native; may vary for wrappers. */
14
19
  providerNodeId: string;
15
- /** Always the addon id of the underlying native provider for the device. */
20
+ /** Always the addon id of the underlying native provider for the device.
21
+ * Empty for kind='linked' (no native exists). */
16
22
  nativeAddonId: string;
17
23
  }
18
24
  export interface DeviceBinding {
@@ -95,17 +95,39 @@ export interface ChildLayoutEntry {
95
95
  readonly collapsed?: boolean;
96
96
  }
97
97
  export type ChildLayout = readonly ChildLayoutEntry[];
98
- /** One end of a device link: a single field on a source device's capability,
99
- * addressed by the source's re-sync-stable accessory `stableIdSuffix`
98
+ /** Field source: copy one field of a sibling accessory's cap status.
99
+ * Addressed by the source's re-sync-stable accessory `stableIdSuffix`
100
100
  * (`sourceKey`) — NOT a raw numeric id — so the link survives a re-sync. The
101
101
  * source must be a sibling accessory under the SAME parent container as the
102
- * target device; resolution is `${parentStableId}-${sourceKey}` (cross-parent
103
- * links are out of scope and resolve to no source). */
104
- export interface DeviceLinkSource {
102
+ * target device; resolution is `${parentStableId}-${sourceKey}`. For a source
103
+ * anywhere else in the cluster use `DeviceLinkGlobalSource`. */
104
+ export interface DeviceLinkFieldSource {
105
+ readonly kind?: 'field';
105
106
  readonly sourceKey: string;
106
107
  readonly cap: string;
107
108
  readonly fieldPath: string;
108
109
  }
110
+ /** Literal source: a per-device constant (e.g. `battery.binary = true`,
111
+ * a consumable item's `label`/`resettable`). No sibling is read. */
112
+ export interface DeviceLinkLiteralSource {
113
+ readonly kind: 'literal';
114
+ readonly value: string | number | boolean | null;
115
+ }
116
+ /** Global source (P2e): copy one field of ANY device's cap status, regardless
117
+ * of parent container. Addressed by the source device's FULL `stableId` —
118
+ * chosen over the numeric id because a re-sync (`resetToSource`) REALLOCATES
119
+ * numeric ids while stableIds are deterministic from the provider (the same
120
+ * property the sibling `sourceKey` mechanism relies on). stableId uniqueness
121
+ * is formally per-addon; the resolver matches the first meta row with that
122
+ * stableId (effective global uniqueness — an `addonId` disambiguator can be
123
+ * added later without a wire break). */
124
+ export interface DeviceLinkGlobalSource {
125
+ readonly kind: 'global';
126
+ readonly sourceStableId: string;
127
+ readonly cap: string;
128
+ readonly fieldPath: string;
129
+ }
130
+ export type DeviceLinkSource = DeviceLinkFieldSource | DeviceLinkLiteralSource | DeviceLinkGlobalSource;
109
131
  /** The target field a link writes: a dot-path into the target cap's status. */
110
132
  export interface DeviceLinkTarget {
111
133
  readonly cap: string;
@@ -11,7 +11,7 @@ export type { IDevice } from './device.js';
11
11
  export { DEVICE_PROFILES, BATTERY_DEVICE_PROFILE, deviceMatchesProfile, resolveDeviceProfile, } from './device-profile.js';
12
12
  export type { DeviceProfile, DeviceProfileMatch, DeviceProfileDefaults, PipelinePhaseMode, } from './device-profile.js';
13
13
  export type { ICameraDevice, StreamSourceEntry } from './camera-device.js';
14
- export type { DeviceManualCreation, DeviceDiscovery, DiscoveredDevice, SavedDevice, DeviceMeta, InitialDeviceMeta, CreateDeviceSpec, ChildLayout, ChildLayoutEntry, DeviceLinkSource, DeviceLinkTarget, DeviceLinkTransform, DeviceLink, DeviceLinks, } from './device-management.js';
14
+ export type { DeviceManualCreation, DeviceDiscovery, DiscoveredDevice, SavedDevice, DeviceMeta, InitialDeviceMeta, CreateDeviceSpec, ChildLayout, ChildLayoutEntry, DeviceLinkFieldSource, DeviceLinkLiteralSource, DeviceLinkGlobalSource, DeviceLinkSource, DeviceLinkTarget, DeviceLinkTransform, DeviceLink, DeviceLinks, } from './device-management.js';
15
15
  export { zodEntriesToConfigUI } from './zod-to-config-ui.js';
16
16
  export type { DeviceConfigEntry } from './zod-to-config-ui.js';
17
17
  export { createRuntimeStateBridge } from './runtime-state-helpers.js';
@@ -19,5 +19,5 @@ export type { RuntimeStateBridge } from './runtime-state-helpers.js';
19
19
  export type { IDeviceRuntimeState, Snapshot as RuntimeStateSnapshot, } from './device-runtime-state.js';
20
20
  export { getByPath, setByPath } from './path-util.js';
21
21
  export { applyTransform } from './device-link-transform.js';
22
- export { enumerateSchemaFields } from './schema-fields.js';
22
+ export { enumerateItemArrayFields, enumerateSchemaFields } from './schema-fields.js';
23
23
  export type { WireableField } from './schema-fields.js';
@@ -3,9 +3,22 @@ export interface WireableField {
3
3
  readonly path: string;
4
4
  readonly kind: 'string' | 'number' | 'boolean' | 'enum';
5
5
  readonly enumValues?: readonly string[];
6
+ /** True when `path` is relative to ONE item of an item-array cap (see
7
+ * `CapabilityStatusItemArray`) — a link targeting it must carry a
8
+ * `target.itemKey`. Absent/false for plain status fields. */
9
+ readonly item?: boolean;
6
10
  }
7
11
  /** Walk a cap status schema into flat wireable leaf fields (dotted paths).
8
12
  * Recurses into nested ZodObject (unwrapping nullable/optional/default first),
9
13
  * so fields with null live values are still offered. Arrays / unknown shapes
10
14
  * are skipped — never throws. */
11
15
  export declare function enumerateSchemaFields(schema: z.ZodType, prefix?: string): readonly WireableField[];
16
+ /** Enumerate the per-item wireable fields of an item-array cap (see
17
+ * `CapabilityStatusItemArray`): the item schema's leaf fields, minus the
18
+ * `keyField` (the key comes from the link's `itemKey`, never from a wired
19
+ * source), each tagged `item: true` so the authoring UI collects an
20
+ * `itemKey` alongside the field. Never throws. */
21
+ export declare function enumerateItemArrayFields(itemArray: {
22
+ readonly keyField: string;
23
+ readonly itemSchema: z.ZodType;
24
+ }): readonly WireableField[];
@@ -4100,6 +4100,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4100
4100
  sourceKey: string;
4101
4101
  cap: string;
4102
4102
  fieldPath: string;
4103
+ kind?: "field" | undefined;
4104
+ } | {
4105
+ kind: "literal";
4106
+ value: string | number | boolean | null;
4107
+ } | {
4108
+ kind: "global";
4109
+ sourceStableId: string;
4110
+ cap: string;
4111
+ fieldPath: string;
4103
4112
  };
4104
4113
  target: {
4105
4114
  cap: string;
@@ -4201,6 +4210,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4201
4210
  sourceKey: string;
4202
4211
  cap: string;
4203
4212
  fieldPath: string;
4213
+ kind?: "field" | undefined;
4214
+ } | {
4215
+ kind: "literal";
4216
+ value: string | number | boolean | null;
4217
+ } | {
4218
+ kind: "global";
4219
+ sourceStableId: string;
4220
+ cap: string;
4221
+ fieldPath: string;
4204
4222
  };
4205
4223
  target: {
4206
4224
  cap: string;
@@ -4228,6 +4246,7 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4228
4246
  input: {
4229
4247
  [x: string]: unknown;
4230
4248
  deviceId: number;
4249
+ includeSynthesizable?: boolean | undefined;
4231
4250
  };
4232
4251
  output: {
4233
4252
  caps: readonly {
@@ -4236,7 +4255,12 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4236
4255
  path: string;
4237
4256
  kind: "string" | "number" | "boolean" | "enum";
4238
4257
  enumValues?: string[] | undefined;
4258
+ item?: boolean | undefined;
4239
4259
  }[];
4260
+ itemArray?: {
4261
+ path: string;
4262
+ keyField: string;
4263
+ } | undefined;
4240
4264
  }[];
4241
4265
  };
4242
4266
  meta: object;
@@ -4365,6 +4389,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4365
4389
  sourceKey: string;
4366
4390
  cap: string;
4367
4391
  fieldPath: string;
4392
+ kind?: "field" | undefined;
4393
+ } | {
4394
+ kind: "literal";
4395
+ value: string | number | boolean | null;
4396
+ } | {
4397
+ kind: "global";
4398
+ sourceStableId: string;
4399
+ cap: string;
4400
+ fieldPath: string;
4368
4401
  };
4369
4402
  target: {
4370
4403
  cap: string;
@@ -4429,6 +4462,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4429
4462
  sourceKey: string;
4430
4463
  cap: string;
4431
4464
  fieldPath: string;
4465
+ kind?: "field" | undefined;
4466
+ } | {
4467
+ kind: "literal";
4468
+ value: string | number | boolean | null;
4469
+ } | {
4470
+ kind: "global";
4471
+ sourceStableId: string;
4472
+ cap: string;
4473
+ fieldPath: string;
4432
4474
  };
4433
4475
  target: {
4434
4476
  cap: string;
@@ -4493,6 +4535,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4493
4535
  sourceKey: string;
4494
4536
  cap: string;
4495
4537
  fieldPath: string;
4538
+ kind?: "field" | undefined;
4539
+ } | {
4540
+ kind: "literal";
4541
+ value: string | number | boolean | null;
4542
+ } | {
4543
+ kind: "global";
4544
+ sourceStableId: string;
4545
+ cap: string;
4546
+ fieldPath: string;
4496
4547
  };
4497
4548
  target: {
4498
4549
  cap: string;
@@ -4650,7 +4701,7 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4650
4701
  deviceId: number;
4651
4702
  entries: {
4652
4703
  capName: string;
4653
- kind: "native" | "wrapped";
4704
+ kind: "linked" | "native" | "wrapped";
4654
4705
  providerAddonId: string;
4655
4706
  providerNodeId: string;
4656
4707
  nativeAddonId: string;
@@ -4666,7 +4717,7 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
4666
4717
  deviceId: number;
4667
4718
  entries: {
4668
4719
  capName: string;
4669
- kind: "native" | "wrapped";
4720
+ kind: "linked" | "native" | "wrapped";
4670
4721
  providerAddonId: string;
4671
4722
  providerNodeId: string;
4672
4723
  nativeAddonId: string;
@@ -18124,6 +18175,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18124
18175
  sourceKey: string;
18125
18176
  cap: string;
18126
18177
  fieldPath: string;
18178
+ kind?: "field" | undefined;
18179
+ } | {
18180
+ kind: "literal";
18181
+ value: string | number | boolean | null;
18182
+ } | {
18183
+ kind: "global";
18184
+ sourceStableId: string;
18185
+ cap: string;
18186
+ fieldPath: string;
18127
18187
  };
18128
18188
  target: {
18129
18189
  cap: string;
@@ -18225,6 +18285,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18225
18285
  sourceKey: string;
18226
18286
  cap: string;
18227
18287
  fieldPath: string;
18288
+ kind?: "field" | undefined;
18289
+ } | {
18290
+ kind: "literal";
18291
+ value: string | number | boolean | null;
18292
+ } | {
18293
+ kind: "global";
18294
+ sourceStableId: string;
18295
+ cap: string;
18296
+ fieldPath: string;
18228
18297
  };
18229
18298
  target: {
18230
18299
  cap: string;
@@ -18252,6 +18321,7 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18252
18321
  input: {
18253
18322
  [x: string]: unknown;
18254
18323
  deviceId: number;
18324
+ includeSynthesizable?: boolean | undefined;
18255
18325
  };
18256
18326
  output: {
18257
18327
  caps: readonly {
@@ -18260,7 +18330,12 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18260
18330
  path: string;
18261
18331
  kind: "string" | "number" | "boolean" | "enum";
18262
18332
  enumValues?: string[] | undefined;
18333
+ item?: boolean | undefined;
18263
18334
  }[];
18335
+ itemArray?: {
18336
+ path: string;
18337
+ keyField: string;
18338
+ } | undefined;
18264
18339
  }[];
18265
18340
  };
18266
18341
  meta: object;
@@ -18389,6 +18464,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18389
18464
  sourceKey: string;
18390
18465
  cap: string;
18391
18466
  fieldPath: string;
18467
+ kind?: "field" | undefined;
18468
+ } | {
18469
+ kind: "literal";
18470
+ value: string | number | boolean | null;
18471
+ } | {
18472
+ kind: "global";
18473
+ sourceStableId: string;
18474
+ cap: string;
18475
+ fieldPath: string;
18392
18476
  };
18393
18477
  target: {
18394
18478
  cap: string;
@@ -18453,6 +18537,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18453
18537
  sourceKey: string;
18454
18538
  cap: string;
18455
18539
  fieldPath: string;
18540
+ kind?: "field" | undefined;
18541
+ } | {
18542
+ kind: "literal";
18543
+ value: string | number | boolean | null;
18544
+ } | {
18545
+ kind: "global";
18546
+ sourceStableId: string;
18547
+ cap: string;
18548
+ fieldPath: string;
18456
18549
  };
18457
18550
  target: {
18458
18551
  cap: string;
@@ -18517,6 +18610,15 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18517
18610
  sourceKey: string;
18518
18611
  cap: string;
18519
18612
  fieldPath: string;
18613
+ kind?: "field" | undefined;
18614
+ } | {
18615
+ kind: "literal";
18616
+ value: string | number | boolean | null;
18617
+ } | {
18618
+ kind: "global";
18619
+ sourceStableId: string;
18620
+ cap: string;
18621
+ fieldPath: string;
18520
18622
  };
18521
18623
  target: {
18522
18624
  cap: string;
@@ -18674,7 +18776,7 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18674
18776
  deviceId: number;
18675
18777
  entries: {
18676
18778
  capName: string;
18677
- kind: "native" | "wrapped";
18779
+ kind: "linked" | "native" | "wrapped";
18678
18780
  providerAddonId: string;
18679
18781
  providerNodeId: string;
18680
18782
  nativeAddonId: string;
@@ -18690,7 +18792,7 @@ export type AppRouter = import("@trpc/server/unstable-core-do-not-import").Route
18690
18792
  deviceId: number;
18691
18793
  entries: {
18692
18794
  capName: string;
18693
- kind: "native" | "wrapped";
18795
+ kind: "linked" | "native" | "wrapped";
18694
18796
  providerAddonId: string;
18695
18797
  providerNodeId: string;
18696
18798
  nativeAddonId: string;
package/dist/index.d.ts CHANGED
@@ -147,12 +147,12 @@ export type { ICameraDevice, StreamSourceEntry } from './device/camera-device.js
147
147
  export type { StreamQuality } from './interfaces/device-capabilities/camera.js';
148
148
  export { STREAM_QUALITY_LABELS, streamQualityLabel, } from './interfaces/device-capabilities/camera.js';
149
149
  export type { AudioCodecInfo, AudioDecodeSessionConfig, AudioEncodeSessionConfig, AudioPcmChunk, AudioEncodedChunk, PcmSampleFormat, } from './interfaces/audio-codec.js';
150
- export type { DeviceManualCreation, DeviceDiscovery, DiscoveredDevice, SavedDevice, DeviceMeta, InitialDeviceMeta, CreateDeviceSpec, ChildLayout, ChildLayoutEntry, DeviceLinkSource, DeviceLinkTarget, DeviceLinkTransform, DeviceLink, DeviceLinks, } from './device/device-management.js';
150
+ export type { DeviceManualCreation, DeviceDiscovery, DiscoveredDevice, SavedDevice, DeviceMeta, InitialDeviceMeta, CreateDeviceSpec, ChildLayout, ChildLayoutEntry, DeviceLinkFieldSource, DeviceLinkLiteralSource, DeviceLinkSource, DeviceLinkTarget, DeviceLinkTransform, DeviceLink, DeviceLinks, } from './device/device-management.js';
151
151
  export { zodEntriesToConfigUI } from './device/zod-to-config-ui.js';
152
152
  export type { DeviceConfigEntry } from './device/zod-to-config-ui.js';
153
153
  export { getByPath, setByPath } from './device/path-util.js';
154
154
  export { applyTransform } from './device/device-link-transform.js';
155
- export { enumerateSchemaFields } from './device/schema-fields.js';
155
+ export { enumerateItemArrayFields, enumerateSchemaFields } from './device/schema-fields.js';
156
156
  export type { WireableField } from './device/schema-fields.js';
157
157
  export { EventCategory } from './enums/event-category.js';
158
158
  export type { AppRouter, AddonApi } from './generated/addon-api.js';
package/dist/index.js CHANGED
@@ -3574,7 +3574,13 @@ onStatusChanged: { data: zod.z.object({
3574
3574
  }) } },
3575
3575
  status: {
3576
3576
  schema: BatteryStatusSchema,
3577
- kind: "push"
3577
+ kind: "push",
3578
+ empty: {
3579
+ percentage: 0,
3580
+ charging: "none",
3581
+ sleeping: false,
3582
+ lastUpdated: 0
3583
+ }
3578
3584
  },
3579
3585
  /**
3580
3586
  * Runtime-state slice — every provider that registers this cap
@@ -4754,7 +4760,25 @@ reset: require_sleep.method(zod.z.object({
4754
4760
  }) },
4755
4761
  status: {
4756
4762
  schema: ConsumablesStatusSchema,
4757
- kind: "push"
4763
+ kind: "push",
4764
+ empty: {
4765
+ items: [],
4766
+ lastChangedAt: 0
4767
+ },
4768
+ itemArray: {
4769
+ path: "items",
4770
+ keyField: "key",
4771
+ labelField: "label",
4772
+ itemSchema: ConsumableItemSchema,
4773
+ emptyItem: {
4774
+ key: "",
4775
+ label: "",
4776
+ level: null,
4777
+ status: null,
4778
+ lastResetAt: null,
4779
+ resettable: false
4780
+ }
4781
+ }
4758
4782
  },
4759
4783
  runtimeState: ConsumablesStatusSchema.extend({ lastFetchedAt: zod.z.number() })
4760
4784
  };
@@ -10221,6 +10245,17 @@ function enumerateSchemaFields(schema, prefix = "") {
10221
10245
  }
10222
10246
  return out;
10223
10247
  }
10248
+ /** Enumerate the per-item wireable fields of an item-array cap (see
10249
+ * `CapabilityStatusItemArray`): the item schema's leaf fields, minus the
10250
+ * `keyField` (the key comes from the link's `itemKey`, never from a wired
10251
+ * source), each tagged `item: true` so the authoring UI collects an
10252
+ * `itemKey` alongside the field. Never throws. */
10253
+ function enumerateItemArrayFields(itemArray) {
10254
+ return enumerateSchemaFields(itemArray.itemSchema).filter((f) => f.path !== itemArray.keyField).map((f) => ({
10255
+ ...f,
10256
+ item: true
10257
+ }));
10258
+ }
10224
10259
  //#endregion
10225
10260
  //#region src/utils/zone-rule-eval.ts
10226
10261
  /**
@@ -13323,14 +13358,36 @@ var ChildLayoutEntrySchema = zod.z.object({
13323
13358
  collapsed: zod.z.boolean().optional()
13324
13359
  });
13325
13360
  /** Cap-wire shape of a DeviceLink — structurally mirrors `DeviceLink` in
13326
- * `device-management.ts`. */
13361
+ * `device-management.ts`. Source is a union: a FIELD source copies a sibling
13362
+ * accessory's status field (`kind` optional/absent for wire compat); a
13363
+ * LITERAL source carries a per-device constant (no sibling is read); a
13364
+ * GLOBAL source (P2e) copies ANY device's status field, addressed by the
13365
+ * source device's full re-sync-stable `stableId`. */
13327
13366
  var DeviceLinkSchema = zod.z.object({
13328
13367
  id: zod.z.string(),
13329
- source: zod.z.object({
13330
- sourceKey: zod.z.string(),
13331
- cap: zod.z.string(),
13332
- fieldPath: zod.z.string()
13333
- }),
13368
+ source: zod.z.union([
13369
+ zod.z.object({
13370
+ kind: zod.z.literal("field").optional(),
13371
+ sourceKey: zod.z.string(),
13372
+ cap: zod.z.string(),
13373
+ fieldPath: zod.z.string()
13374
+ }),
13375
+ zod.z.object({
13376
+ kind: zod.z.literal("literal"),
13377
+ value: zod.z.union([
13378
+ zod.z.string(),
13379
+ zod.z.number(),
13380
+ zod.z.boolean(),
13381
+ zod.z.null()
13382
+ ])
13383
+ }),
13384
+ zod.z.object({
13385
+ kind: zod.z.literal("global"),
13386
+ sourceStableId: zod.z.string(),
13387
+ cap: zod.z.string(),
13388
+ fieldPath: zod.z.string()
13389
+ })
13390
+ ]),
13334
13391
  target: zod.z.object({
13335
13392
  cap: zod.z.string(),
13336
13393
  fieldPath: zod.z.string(),
@@ -13636,8 +13693,18 @@ var deviceManagerCapability = {
13636
13693
  auth: "admin"
13637
13694
  }),
13638
13695
  /** List the wireable status-schema fields per cap bound to a device.
13639
- * Powers the Wiring tab's field pickers. Caps without a status schema are omitted. */
13640
- getWireableFields: require_sleep.method(zod.z.object({ deviceId: zod.z.number() }), zod.z.object({ caps: zod.z.array(zod.z.object({
13696
+ * Powers the Wiring tab's field pickers. Caps without a status schema are
13697
+ * omitted. Item-array caps (`status.itemArray`, e.g. consumables) also
13698
+ * emit their per-item fields tagged `item: true` (a link targeting one
13699
+ * must carry a `target.itemKey`) plus the cap-level `itemArray`
13700
+ * descriptor. `includeSynthesizable: true` (TARGET pickers only) unions
13701
+ * in unbound device-scoped caps that declare `status.empty` and match
13702
+ * the device's type — so the FIRST link to a synthesize-only cap
13703
+ * (consumables on an HA vacuum) can be authored. */
13704
+ getWireableFields: require_sleep.method(zod.z.object({
13705
+ deviceId: zod.z.number(),
13706
+ includeSynthesizable: zod.z.boolean().optional()
13707
+ }), zod.z.object({ caps: zod.z.array(zod.z.object({
13641
13708
  cap: zod.z.string(),
13642
13709
  fields: zod.z.array(zod.z.object({
13643
13710
  path: zod.z.string(),
@@ -13647,8 +13714,13 @@ var deviceManagerCapability = {
13647
13714
  "boolean",
13648
13715
  "enum"
13649
13716
  ]),
13650
- enumValues: zod.z.array(zod.z.string()).optional()
13651
- })).readonly()
13717
+ enumValues: zod.z.array(zod.z.string()).optional(),
13718
+ item: zod.z.boolean().optional()
13719
+ })).readonly(),
13720
+ itemArray: zod.z.object({
13721
+ path: zod.z.string(),
13722
+ keyField: zod.z.string()
13723
+ }).optional()
13652
13724
  })).readonly() }), { kind: "query" }),
13653
13725
  /** Stamp (or update) the semantic role on the device's meta row.
13654
13726
  * Called by the kernel's `create()` / `spawnAccessoryChild` pre-seed
@@ -13799,7 +13871,11 @@ var deviceManagerCapability = {
13799
13871
  deviceId: zod.z.number(),
13800
13872
  entries: zod.z.array(zod.z.object({
13801
13873
  capName: zod.z.string(),
13802
- kind: zod.z.enum(["native", "wrapped"]),
13874
+ kind: zod.z.enum([
13875
+ "native",
13876
+ "wrapped",
13877
+ "linked"
13878
+ ]),
13803
13879
  providerAddonId: zod.z.string(),
13804
13880
  providerNodeId: zod.z.string(),
13805
13881
  nativeAddonId: zod.z.string()
@@ -13817,7 +13893,11 @@ var deviceManagerCapability = {
13817
13893
  deviceId: zod.z.number(),
13818
13894
  entries: zod.z.array(zod.z.object({
13819
13895
  capName: zod.z.string(),
13820
- kind: zod.z.enum(["native", "wrapped"]),
13896
+ kind: zod.z.enum([
13897
+ "native",
13898
+ "wrapped",
13899
+ "linked"
13900
+ ]),
13821
13901
  providerAddonId: zod.z.string(),
13822
13902
  providerNodeId: zod.z.string(),
13823
13903
  nativeAddonId: zod.z.string()
@@ -27088,6 +27168,7 @@ exports.emitDownForOwnedCaps = require_sleep.emitDownForOwnedCaps;
27088
27168
  exports.emitReadiness = require_sleep.emitReadiness;
27089
27169
  exports.encodeProfileFromStreamShape = encodeProfileFromStreamShape;
27090
27170
  exports.enumSensorCapability = enumSensorCapability;
27171
+ exports.enumerateItemArrayFields = enumerateItemArrayFields;
27091
27172
  exports.enumerateSchemaFields = enumerateSchemaFields;
27092
27173
  exports.errMsg = require_err_msg.errMsg;
27093
27174
  exports.evaluateZoneRules = evaluateZoneRules;
package/dist/index.mjs CHANGED
@@ -3573,7 +3573,13 @@ onStatusChanged: { data: z.object({
3573
3573
  }) } },
3574
3574
  status: {
3575
3575
  schema: BatteryStatusSchema,
3576
- kind: "push"
3576
+ kind: "push",
3577
+ empty: {
3578
+ percentage: 0,
3579
+ charging: "none",
3580
+ sleeping: false,
3581
+ lastUpdated: 0
3582
+ }
3577
3583
  },
3578
3584
  /**
3579
3585
  * Runtime-state slice — every provider that registers this cap
@@ -4753,7 +4759,25 @@ reset: method(z.object({
4753
4759
  }) },
4754
4760
  status: {
4755
4761
  schema: ConsumablesStatusSchema,
4756
- kind: "push"
4762
+ kind: "push",
4763
+ empty: {
4764
+ items: [],
4765
+ lastChangedAt: 0
4766
+ },
4767
+ itemArray: {
4768
+ path: "items",
4769
+ keyField: "key",
4770
+ labelField: "label",
4771
+ itemSchema: ConsumableItemSchema,
4772
+ emptyItem: {
4773
+ key: "",
4774
+ label: "",
4775
+ level: null,
4776
+ status: null,
4777
+ lastResetAt: null,
4778
+ resettable: false
4779
+ }
4780
+ }
4757
4781
  },
4758
4782
  runtimeState: ConsumablesStatusSchema.extend({ lastFetchedAt: z.number() })
4759
4783
  };
@@ -10220,6 +10244,17 @@ function enumerateSchemaFields(schema, prefix = "") {
10220
10244
  }
10221
10245
  return out;
10222
10246
  }
10247
+ /** Enumerate the per-item wireable fields of an item-array cap (see
10248
+ * `CapabilityStatusItemArray`): the item schema's leaf fields, minus the
10249
+ * `keyField` (the key comes from the link's `itemKey`, never from a wired
10250
+ * source), each tagged `item: true` so the authoring UI collects an
10251
+ * `itemKey` alongside the field. Never throws. */
10252
+ function enumerateItemArrayFields(itemArray) {
10253
+ return enumerateSchemaFields(itemArray.itemSchema).filter((f) => f.path !== itemArray.keyField).map((f) => ({
10254
+ ...f,
10255
+ item: true
10256
+ }));
10257
+ }
10223
10258
  //#endregion
10224
10259
  //#region src/utils/zone-rule-eval.ts
10225
10260
  /**
@@ -13322,14 +13357,36 @@ var ChildLayoutEntrySchema = z.object({
13322
13357
  collapsed: z.boolean().optional()
13323
13358
  });
13324
13359
  /** Cap-wire shape of a DeviceLink — structurally mirrors `DeviceLink` in
13325
- * `device-management.ts`. */
13360
+ * `device-management.ts`. Source is a union: a FIELD source copies a sibling
13361
+ * accessory's status field (`kind` optional/absent for wire compat); a
13362
+ * LITERAL source carries a per-device constant (no sibling is read); a
13363
+ * GLOBAL source (P2e) copies ANY device's status field, addressed by the
13364
+ * source device's full re-sync-stable `stableId`. */
13326
13365
  var DeviceLinkSchema = z.object({
13327
13366
  id: z.string(),
13328
- source: z.object({
13329
- sourceKey: z.string(),
13330
- cap: z.string(),
13331
- fieldPath: z.string()
13332
- }),
13367
+ source: z.union([
13368
+ z.object({
13369
+ kind: z.literal("field").optional(),
13370
+ sourceKey: z.string(),
13371
+ cap: z.string(),
13372
+ fieldPath: z.string()
13373
+ }),
13374
+ z.object({
13375
+ kind: z.literal("literal"),
13376
+ value: z.union([
13377
+ z.string(),
13378
+ z.number(),
13379
+ z.boolean(),
13380
+ z.null()
13381
+ ])
13382
+ }),
13383
+ z.object({
13384
+ kind: z.literal("global"),
13385
+ sourceStableId: z.string(),
13386
+ cap: z.string(),
13387
+ fieldPath: z.string()
13388
+ })
13389
+ ]),
13333
13390
  target: z.object({
13334
13391
  cap: z.string(),
13335
13392
  fieldPath: z.string(),
@@ -13635,8 +13692,18 @@ var deviceManagerCapability = {
13635
13692
  auth: "admin"
13636
13693
  }),
13637
13694
  /** List the wireable status-schema fields per cap bound to a device.
13638
- * Powers the Wiring tab's field pickers. Caps without a status schema are omitted. */
13639
- getWireableFields: method(z.object({ deviceId: z.number() }), z.object({ caps: z.array(z.object({
13695
+ * Powers the Wiring tab's field pickers. Caps without a status schema are
13696
+ * omitted. Item-array caps (`status.itemArray`, e.g. consumables) also
13697
+ * emit their per-item fields tagged `item: true` (a link targeting one
13698
+ * must carry a `target.itemKey`) plus the cap-level `itemArray`
13699
+ * descriptor. `includeSynthesizable: true` (TARGET pickers only) unions
13700
+ * in unbound device-scoped caps that declare `status.empty` and match
13701
+ * the device's type — so the FIRST link to a synthesize-only cap
13702
+ * (consumables on an HA vacuum) can be authored. */
13703
+ getWireableFields: method(z.object({
13704
+ deviceId: z.number(),
13705
+ includeSynthesizable: z.boolean().optional()
13706
+ }), z.object({ caps: z.array(z.object({
13640
13707
  cap: z.string(),
13641
13708
  fields: z.array(z.object({
13642
13709
  path: z.string(),
@@ -13646,8 +13713,13 @@ var deviceManagerCapability = {
13646
13713
  "boolean",
13647
13714
  "enum"
13648
13715
  ]),
13649
- enumValues: z.array(z.string()).optional()
13650
- })).readonly()
13716
+ enumValues: z.array(z.string()).optional(),
13717
+ item: z.boolean().optional()
13718
+ })).readonly(),
13719
+ itemArray: z.object({
13720
+ path: z.string(),
13721
+ keyField: z.string()
13722
+ }).optional()
13651
13723
  })).readonly() }), { kind: "query" }),
13652
13724
  /** Stamp (or update) the semantic role on the device's meta row.
13653
13725
  * Called by the kernel's `create()` / `spawnAccessoryChild` pre-seed
@@ -13798,7 +13870,11 @@ var deviceManagerCapability = {
13798
13870
  deviceId: z.number(),
13799
13871
  entries: z.array(z.object({
13800
13872
  capName: z.string(),
13801
- kind: z.enum(["native", "wrapped"]),
13873
+ kind: z.enum([
13874
+ "native",
13875
+ "wrapped",
13876
+ "linked"
13877
+ ]),
13802
13878
  providerAddonId: z.string(),
13803
13879
  providerNodeId: z.string(),
13804
13880
  nativeAddonId: z.string()
@@ -13816,7 +13892,11 @@ var deviceManagerCapability = {
13816
13892
  deviceId: z.number(),
13817
13893
  entries: z.array(z.object({
13818
13894
  capName: z.string(),
13819
- kind: z.enum(["native", "wrapped"]),
13895
+ kind: z.enum([
13896
+ "native",
13897
+ "wrapped",
13898
+ "linked"
13899
+ ]),
13820
13900
  providerAddonId: z.string(),
13821
13901
  providerNodeId: z.string(),
13822
13902
  nativeAddonId: z.string()
@@ -26502,4 +26582,4 @@ function scoreRuntimes(hw) {
26502
26582
  };
26503
26583
  }
26504
26584
  //#endregion
26505
- export { ACCESSORY_LABEL, ALL_CAPABILITY_DEFINITIONS, APPLE_SA_TO_MACRO, AUDIO_BACKEND_CHOICES, AUDIO_MACRO_LABELS, AccessoriesStatusSchema, AccessoryKind, AddBrokerInputSchema, AddonAutoUpdateSchema, AddonListItemSchema, AddonPageDeclarationSchema, AddonPageInfoSchema, AdoptInputSchema as AdoptionAdoptInputSchema, AdoptResultSchema as AdoptionAdoptResultSchema, AdoptionFilterSchema, GetCandidateInputSchema as AdoptionGetCandidateInputSchema, ListCandidatesInputSchema as AdoptionListCandidatesInputSchema, ListCandidatesOutputSchema as AdoptionListCandidatesOutputSchema, 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, AutomationControlStatusSchema, AvailableIntegrationTypeSchema, BACKEND_TO_FORMAT, BATTERY_DEVICE_PROFILE, 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, 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, CamProfileSchema, CamStreamDescriptorSchema, CamStreamKindSchema, CamStreamResolutionSchema, CameraAssignmentStatusSchema, CameraAudioStatusSchema, CameraBrokerProfileSchema, CameraBrokerStatusSchema, CameraCredentialsSchema, CameraCredentialsStatusSchema, CameraDecoderShmSchema, CameraDecoderStatusSchema, CameraDetectionPhaseSchema, CameraDetectionProvisioningSchema, CameraDetectionProvisioningStateSchema, CameraDetectionStatusSchema, CameraMetricsSchema, CameraMetricsWithDeviceIdSchema, CameraMotionStatusSchema, CameraRecordingModeSchema, CameraRecordingStatusSchema, CameraSourceStatusSchema, CameraSourceStreamSchema, CameraStatusSchema, CameraStreamSchema, CandidateQueryFilterSchema, CapScopeSchema, CapabilityBindingsSchema, CarbonMonoxideStatusSchema, ChargingStatus, ClientNetworkStatsSchema, ClimateControlStatusSchema, ClipPlaybackSchema, ClipSchema, ClusterAddonNodeDeploymentSchema, ClusterAddonStatusEntrySchema, CollectionColumnSchema, CollectionIndexSchema, ColorStatusSchema, ConfigEntrySchema, ConfigSectionWithValuesSchema, ConfigTabDeclarationSchema, ConnectivityStatusSchema, ConsumableItemSchema, ConsumablesStatusSchema, ContactStatusSchema, ControlKindSchema, ControlStatusSchema, ConvertArtifactSchema, ConvertResultSchema, ConvertTargetSchema, CoverStateSchema, CoverStatusSchema, CreateApiKeyInputSchema, CreateApiKeyResultSchema, CreateIntegrationInputSchema, CreateScopedTokenInputSchema, CreateScopedTokenResultSchema, CreateUserInputSchema, CustomActionInputSchema, CustomModelDescriptorSchema, DATAPLANE_SECRET_HEADER, DEFAULT_ADDON_PLACEMENT, DEFAULT_AUDIO_ANALYZER_CONFIG, DEFAULT_DECODER_HWACCEL_CONFIG, DEFAULT_FEATURES, DEFAULT_RETENTION, DEVICE_CAP_NAMES, DEVICE_PROFILES, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATUS_METHOD, DEVICE_TYPE_INFO, DecodedAudioChunkSchema, DecodedFrameSchema, DecoderAssignmentSchema, DecoderSessionConfigSchema, DecoderStatsSchema, DeleteIntegrationResultSchema, DetectionSourceSchema, DetectorOutputSchema, DeviceCodeSeveritySchema, DeviceConfig, DeviceDiscoveryStatusSchema, ExposeInputSchema as DeviceExportExposeInputSchema, DeviceExportStatusSchema, UnexposeInputSchema as DeviceExportUnexposeInputSchema, DeviceFeature, DeviceInfoSchema, DeviceNetworkStatsSchema, DeviceRole, DeviceRuntimeState, DeviceStatusSchema, DeviceType, DiscoveredChildDeviceSchema, DiscoveredChildStatusSchema, DiscoveredDeviceSchema, DiscoveredTargetSchema, DisposerChain, DoorbellPressEventSchema, DoorbellStatusSchema, EVENT_PAD_MS, ElementConfigStore, EmbeddingInfoSchema, EmbeddingResultSchema, EncodeProfileSchema, EncodedPacketSchema, EnrichedWidgetMetadataSchema, EnumSensorDateTimeFormatSchema, EnumSensorStatusSchema, EventCategory, EventEmitterStatusSchema, EventFireSchema, EventItemSchema, EventKindSchema, EventSourceType, ExportSetupFieldSchema, ExportSetupSchema, ExposedDeviceSchema, ExposedResourceSchema, FanControlStatusSchema, FanDirectionSchema, FeatureManifestSchema, FeatureProbeStatusSchema, FloodStatusSchema, FrameHandleFormatSchema, FrameHandleSchema, FrameInputSchema, GasStatusSchema, GetStreamWithCodecInputSchema, GlobalMetricsSchema, HF_BASE_URL, HF_REPO, HWACCEL_OPTIONS, HealthStatusSchema, HistoryPointSchema, HistoryResolutionEnum, HumidifierStatusSchema, HumiditySensorStatusSchema, HvacModeSchema, ImageStatusSchema, InstalledPackageSchema, IntegrationLiteSchema, IntegrationWithStateSchema, IntercomAbilitySchema, IntercomStatusSchema, KNOWN_CAP_NAMES, LabelDefinitionSchema, LawnMowerActivitySchema, LawnMowerControlStatusSchema, LocateSegmentResultSchema, LocationStatSchema, LockControlStatusSchema, LockStateSchema, LogEntrySchema, LogLevelSchema, LogStreamEntrySchema, MACRO_LABELS, METHOD_ACCESS_MAP, MODEL_FORMATS, MaskGridDimsSchema, MaskGridShapeSchema, MaskLineShapeSchema, MaskPointSchema, MaskPolygonShapeSchema, MaskPolygonVerticesSchema, MaskRectShapeSchema, MaskShapeKindSchema, MaskShapeSchema, MediaFileSchema, MediaPlayerRepeatSchema, MediaPlayerStateSchema, MediaPlayerStatusSchema, MeshPeerSchema, MeshStatusSchema, MethodAccessSchema, ModelCatalogEntrySchema, ModelConvertInputSchema, ModelConvertMetadataSchema, ModelDistributeInputSchema, ModelDistributeResultSchema, ModelExtraFileSchema, ModelFormatEntrySchema, ModelFormatsSchema, MotionAnalysisResultSchema, MotionEventSchema, MotionOnMotionChangedDataSchema, MotionRegionSchema, MotionSourceEnum, MotionSourcesSchema, MotionStatusSchema, MotionTriggerRuntimeStateSchema, MotionTriggerStatusSchema, MotionZoneOptionsSchema, MotionZonePatchSchema, MotionZoneRegionSchema, MotionZoneStatusSchema, StatusSchema as MqttBrokerStatusSchema, NativeDetectionSchema, NativeObjectClassEnum, NativeObjectDetectionRuntimeStateSchema, NativeObjectDetectionStatusSchema, NetworkAccessStatusSchema, NetworkAddressSchema, NetworkEndpointSchema, NotificationActionSchema, NotificationFormatSchema, NotificationHistoryEntrySchema, NotificationRuleSchema, NotificationSchema, NotifierStatusSchema, NumericSensorStatusSchema, OauthIntegrationDescriptorSchema, ObjectEventSchema, OrchestratorMetricsSchema, OsdOverlayKindEnum, OsdOverlayPatchSchema, OsdOverlaySchema, OsdPositionEnum, OsdStatusSchema, PIPELINE_FLOW_CAPABILITY_NAMES, PIPELINE_OWNER_CAPABILITY_NAMES, PROVIDER_KIND_CAP_NAMES, PYTHON_SCRIPT, PackageUpdateSchema, PackageVersionInfoSchema, PasskeySummarySchema, PcmSampleFormatSchema, PerScopeBreakdownSchema, PickStreamPreferencesSchema, PickStreamRequirementsSchema, PickedCamStreamSchema, PipelineAssignmentSchema, PipelineDefaultStepSchema, PipelineEngineChoiceSchema, PipelineRunResultBridge, PipelineStepInputSchema, PlaceholderReasonSchema, PolygonPointSchema, PowerMeterStatusSchema, PresenceStatusSchema, PressureSensorStatusSchema, PrivacyMaskOptionsSchema, PrivacyMaskPatchSchema, PrivacyMaskRegionSchema, PrivacyMaskShapeSchema, PrivacyMaskStatusSchema, ProfileRtspEntrySchema, ProfileSlotSchema, ProfileSlotStatusSchema, ProviderStatusSchema, PtzAutotrackRuntimeStateSchema, PtzAutotrackSettingsSchema, PtzAutotrackStatusSchema, PtzAutotrackTargetOptionSchema, PtzMoveCommandSchema, PtzPositionSchema, PtzPresetSchema, PtzStatusSchema, QueryFilterSchema, RECOGNITION_TYPES, RUNTIME_DEFAULTS, RUNTIME_TO_FORMAT, RawStateResultSchema, ReadSegmentBytesResultSchema, ReadinessRegistry, ReadinessTimeoutError, RecordingAvailabilitySchema, RecordingBandModeSchema, RecordingBandSchema, RecordingBandTriggersSchema, RecordingConfigSchema, RecordingDaysSchema, RecordingDeviceUsageSchema, RecordingLocationUsageSchema, RecordingManifestSchema, RecordingModeSchema, RecordingRangeSchema, RecordingRetentionSchema, RecordingRuleSchema, RecordingScheduleSchema, RecordingStatusSchema, RecordingStorageModeSchema, RecordingStorageUsageSchema, RecordingTriggersSchema, RecordingWeekdaySchema, RegisteredStreamSchema, RenderedAsSchema, ReportMotionInputSchema, RingBuffer, RtpSourceSchema, RtspRestreamEntrySchema, RunnerCameraConfigSchema, RunnerCameraDeviceUIFields, RunnerFrameSourceSchema, RunnerLocalLoadSchema, RunnerLocalMetricsSchema, SCOPE_PRESETS, SOURCE_INFO_METADATA_KEY, STREAM_PROFILE_META, STREAM_QUALITY_LABELS, SUB_DETECTION_TYPES, SYSTEM_CAP_NAMES, ScopedTokenSchema, ScopedTokenSummarySchema, ScoredObjectEventSchema, ScriptRunnerStatusSchema, SearchResultSchema, SendEmailInputSchema, SendEmailResultSchema, SendResultSchema, SettingsPatchSchema, SettingsRecordSchema, SettingsSchemaWithValuesSchema, SettingsUpdateResultSchema, ShmRingStatsSchema, SmokeStatusSchema, SmtpStatusSchema, SnapshotImageSchema, SourceInfoSchema, SpatialDetectionSchema, SsoBridgeClaimsSchema, StartEmbeddedInputSchema, 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, ProviderInfoSchema as StorageProviderInfoSchema, ReadChunkInputSchema as StorageReadChunkInputSchema, TestLocationResultSchema as StorageTestLocationResultSchema, WriteChunkInputSchema as StorageWriteChunkInputSchema, StreamCodecSchema, StreamFormatSchema, StreamInfoSchema, StreamNetworkStatsSchema, StreamParamsOptionsSchema, StreamParamsStatusSchema, StreamProfileConfigSchema, StreamProfileOptionsSchema, StreamProfilePatchSchema, StreamProfileSchema, StreamSourceEntrySchema, StreamSourceSchema, SubscribeAudioChunksInputSchema, SubscribeAudioChunksResultSchema, SubscribeFramesInputSchema, SubscribeFramesResultSchema, SwitchStatusSchema, SystemMetricsSchema, SystemMirror, TIMEZONES, TamperStatusSchema, TankStatusSchema, TargetKindCapsSchema, TargetKindLevelSchema, TargetKindSchema, TargetSchema, TemperatureSensorStatusSchema, TestConnectionResultSchema$1 as TestConnectionResultSchema, TestResultSchema, ToastSchema, TokenScopeSchema, TopologyNodeSchema, TopologyProcessSchema, TopologyServiceSchema, TrackSchema, TrackStateSchema, TrackedDetectionSchema, TurnServerSchema, BrokerInfoSchema$1 as UnifiedBrokerInfoSchema, UpdateIntegrationInputSchema, UpdateStatusSchema, UpdateUserInputSchema, UserRecordSchema, UserSummarySchema, VacuumControlStatusSchema, VacuumStateSchema, ValveStateSchema, ValveStatusSchema, VibrationStatusSchema, VideoEncodeSchema, WELL_KNOWN_TABS, WELL_KNOWN_TAB_MAP, WaterHeaterStatusSchema, WeatherStatusSchema, WebrtcStreamChoiceSchema, WebrtcStreamTargetSchema, WidgetHostEnum, WidgetMetadataSchema, WidgetRemoteSchema, WidgetSizeEnum, YAMNET_TO_MACRO, ZoneKindEnum, ZoneRuleModeEnum, ZoneRuleSchema, ZoneRuleStageEnum, ZoneRulesArraySchema, ZoneSchema, ZoneScopeBreakdownSchema, accessoriesCapability, accessoryStableId, addonPagesCapability, addonPagesSourceCapability, addonRoutesCapability, addonSettingsCapability, addonWidgetsCapability, addonWidgetsSourceCapability, addonsCapability, adminUiCapability, advancedNotifierCapability, airQualitySensorCapability, alarmPanelCapability, alertsCapability, ambientLightSensorCapability, applyTransform, asBoolean, asJsonArray, asJsonObject, asNumber, asString, audioAnalysisCapability, audioAnalyzerCapability, audioCodecCapability, audioMetricsCapability, authProviderCapability, autoAssignProfiles, automationControlCapability, backupCapability, batteryCapability, bestLocationMatch, binaryCapability, bindAddonActions, brightnessCapability, brokerCapability, buildAddonRouteProvider, buildStreamParamsConfigSchema, buttonCapability, cameraCredentialsCapability, cameraPipelineConfigCapability, cameraStreamsCapability, carbonMonoxideCapability, cellsToRects, classifyStream, classifyStreams, climateControlCapability, colorCapability, connectivityCapability, consumablesCapability, contactCapability, controlCapability, cosineSimilarity, coverCapability, createDeviceProxy, createDurableState, createEvent, createLazyTrpcSource, createMirrorSource, createRuntimeStateBridge, createSliceHandle, createSystemProxy, customAction, customModelRegistryCapability, decoderCapability, defaultDeviceFor, defineCustomActions, detectionPipelineCapability, deviceAdoptionCapability, deviceCustomAction, deviceDiscoveryCapability, deviceExportCapability, deviceManagerCapability, deviceMatchesProfile, deviceOpsCapability, deviceProviderCapability, deviceStateCapability, deviceStatusCapability, doorbellCapability, embeddingEncoderCapability, emitDownForOwnedCaps, emitReadiness, encodeProfileFromStreamShape, enumSensorCapability, enumerateSchemaFields, errMsg, evaluateZoneRules, event, eventEmitterCapability, eventsCapability, expandCapMethods, extractSourceInfoFromMetadata, faceGalleryCapability, fanControlCapability, featureProbeCapability, filesystemBrowseCapability, findTimezone, floodCapability, formatForBackend, formatForRuntime, frameworkSwapConfirmSchema, frameworkSwapPackageSchema, gasCapability, getAudioMacroClassIds, getByPath, getCapsByProviderKind, hfModelUrl, htmlToText, humidifierCapability, humiditySensorCapability, hydrateSchema, imageCapability, integrationsCapability, intercomCapability, isAgentOnlyPlacement, isDeployableToAgent, isDeviceConfigCap, isEvent, jobKindSchema, lawnMowerControlCapability, lifecycleJobSchema, lifecycleJobScopeSchema, lifecycleJobStateSchema, lifecycleTaskSchema, localNetworkCapability, locationSimilarity, lockControlCapability, logDestinationCapability, makeProfileBrokerId, makeSourceBrokerId, mapAudioLabelToMacro, markdownToHtmlLite, markdownToText, maskUrlCredentials, mediaPlayerCapability, mergeSourceInfo, meshNetworkCapability, method, metricsProviderCapability, migrateConfigToBands, modelConvertCapability, modelDistributorCapability, modelFormatForRuntime, motionCapability, motionDetectionCapability, motionTriggerCapability, motionZonesCapability, mqttBrokerCapability, nativeObjectDetectionCapability, networkAccessCapability, networkQualityCapability, nodePin, nodesCapability, normalizeAddonInitResult, normalizeUnit, notificationOutputCapability, notifierCapability, numericSensorCapability, oauthIntegrationCapability, osdCapability, parseCameraStreamConfig, parseJsonArray, parseJsonObject, parseJsonUnknown, parseProfileBrokerId, parseStreamParamsFormPatch, pendingFrameworkSwapSchema, pickPreferredRtspEntry, pipelineAnalyticsCapability, pipelineExecutorCapability, pipelineOrchestratorCapability, pipelineRunnerCapability, plateGalleryCapability, platformProbeCapability, powerMeterCapability, prepareNotification, presenceCapability, pressureSensorCapability, privacyMaskCapability, ptzAutotrackCapability, ptzCapability, pythonScriptForBackend, readNodePin, readinessKey, rebootCapability, recordingCapability, rectsToCells, requiresPython, resolveAddonExecution, resolveAddonGroup, resolveAddonPlacement, resolveAddonRuntime, resolveCapMount, resolveDetectionRuntime, resolveDeviceProfile, resolveFormat, resolveModelFormat, resolveRunnerId, restreamerCapability, runInferenceStep, runtimeDevices, scopeKey, scoreRuntimes, scriptRunnerCapability, selectAssignedProfileSlots, setByPath, settingsStoreCapability, sleep, sleepCancellable, smokeCapability, smtpProviderCapability, snapshotCapability, snapshotProviderCapability, ssoBridgeCapability, storageCapability, storageEvictableCapability, storageProviderCapability, streamBrokerCapability, streamCatalogCapability, streamParamsCapability, streamPixels, streamQualityLabel, streamingEngineCapability, supportedRuntimes, switchCapability, synthesizeSourceInfo, systemCapability, tamperCapability, taskLogEntrySchema, taskPhaseSchema, taskTargetSchema, temperatureSensorCapability, textToHtml, toDeviceSummary, toStreamSourceEntry, toastCapability, transcodeBody, turnProviderCapability, updateCapability, userManagementCapability, userPasskeysCapability, vacuumControlCapability, valveCapability, vibrationCapability, videoclipsCapability, waterHeaterCapability, weatherCapability, webrtcCapability, webrtcClientHintsSchema, webrtcSessionCapability, wiringAddonHealthSchema, wiringHealthSnapshotSchema, wiringNodeHealthSchema, wiringProbeKindSchema, wiringProbeResultSchema, zodEntriesToConfigUI, zoneAnalyticsCapability, zoneRulesCapability, zonesCapability };
26585
+ export { ACCESSORY_LABEL, ALL_CAPABILITY_DEFINITIONS, APPLE_SA_TO_MACRO, AUDIO_BACKEND_CHOICES, AUDIO_MACRO_LABELS, AccessoriesStatusSchema, AccessoryKind, AddBrokerInputSchema, AddonAutoUpdateSchema, AddonListItemSchema, AddonPageDeclarationSchema, AddonPageInfoSchema, AdoptInputSchema as AdoptionAdoptInputSchema, AdoptResultSchema as AdoptionAdoptResultSchema, AdoptionFilterSchema, GetCandidateInputSchema as AdoptionGetCandidateInputSchema, ListCandidatesInputSchema as AdoptionListCandidatesInputSchema, ListCandidatesOutputSchema as AdoptionListCandidatesOutputSchema, 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, AutomationControlStatusSchema, AvailableIntegrationTypeSchema, BACKEND_TO_FORMAT, BATTERY_DEVICE_PROFILE, 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, 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, CamProfileSchema, CamStreamDescriptorSchema, CamStreamKindSchema, CamStreamResolutionSchema, CameraAssignmentStatusSchema, CameraAudioStatusSchema, CameraBrokerProfileSchema, CameraBrokerStatusSchema, CameraCredentialsSchema, CameraCredentialsStatusSchema, CameraDecoderShmSchema, CameraDecoderStatusSchema, CameraDetectionPhaseSchema, CameraDetectionProvisioningSchema, CameraDetectionProvisioningStateSchema, CameraDetectionStatusSchema, CameraMetricsSchema, CameraMetricsWithDeviceIdSchema, CameraMotionStatusSchema, CameraRecordingModeSchema, CameraRecordingStatusSchema, CameraSourceStatusSchema, CameraSourceStreamSchema, CameraStatusSchema, CameraStreamSchema, CandidateQueryFilterSchema, CapScopeSchema, CapabilityBindingsSchema, CarbonMonoxideStatusSchema, ChargingStatus, ClientNetworkStatsSchema, ClimateControlStatusSchema, ClipPlaybackSchema, ClipSchema, ClusterAddonNodeDeploymentSchema, ClusterAddonStatusEntrySchema, CollectionColumnSchema, CollectionIndexSchema, ColorStatusSchema, ConfigEntrySchema, ConfigSectionWithValuesSchema, ConfigTabDeclarationSchema, ConnectivityStatusSchema, ConsumableItemSchema, ConsumablesStatusSchema, ContactStatusSchema, ControlKindSchema, ControlStatusSchema, ConvertArtifactSchema, ConvertResultSchema, ConvertTargetSchema, CoverStateSchema, CoverStatusSchema, CreateApiKeyInputSchema, CreateApiKeyResultSchema, CreateIntegrationInputSchema, CreateScopedTokenInputSchema, CreateScopedTokenResultSchema, CreateUserInputSchema, CustomActionInputSchema, CustomModelDescriptorSchema, DATAPLANE_SECRET_HEADER, DEFAULT_ADDON_PLACEMENT, DEFAULT_AUDIO_ANALYZER_CONFIG, DEFAULT_DECODER_HWACCEL_CONFIG, DEFAULT_FEATURES, DEFAULT_RETENTION, DEVICE_CAP_NAMES, DEVICE_PROFILES, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATUS_METHOD, DEVICE_TYPE_INFO, DecodedAudioChunkSchema, DecodedFrameSchema, DecoderAssignmentSchema, DecoderSessionConfigSchema, DecoderStatsSchema, DeleteIntegrationResultSchema, DetectionSourceSchema, DetectorOutputSchema, DeviceCodeSeveritySchema, DeviceConfig, DeviceDiscoveryStatusSchema, ExposeInputSchema as DeviceExportExposeInputSchema, DeviceExportStatusSchema, UnexposeInputSchema as DeviceExportUnexposeInputSchema, DeviceFeature, DeviceInfoSchema, DeviceNetworkStatsSchema, DeviceRole, DeviceRuntimeState, DeviceStatusSchema, DeviceType, DiscoveredChildDeviceSchema, DiscoveredChildStatusSchema, DiscoveredDeviceSchema, DiscoveredTargetSchema, DisposerChain, DoorbellPressEventSchema, DoorbellStatusSchema, EVENT_PAD_MS, ElementConfigStore, EmbeddingInfoSchema, EmbeddingResultSchema, EncodeProfileSchema, EncodedPacketSchema, EnrichedWidgetMetadataSchema, EnumSensorDateTimeFormatSchema, EnumSensorStatusSchema, EventCategory, EventEmitterStatusSchema, EventFireSchema, EventItemSchema, EventKindSchema, EventSourceType, ExportSetupFieldSchema, ExportSetupSchema, ExposedDeviceSchema, ExposedResourceSchema, FanControlStatusSchema, FanDirectionSchema, FeatureManifestSchema, FeatureProbeStatusSchema, FloodStatusSchema, FrameHandleFormatSchema, FrameHandleSchema, FrameInputSchema, GasStatusSchema, GetStreamWithCodecInputSchema, GlobalMetricsSchema, HF_BASE_URL, HF_REPO, HWACCEL_OPTIONS, HealthStatusSchema, HistoryPointSchema, HistoryResolutionEnum, HumidifierStatusSchema, HumiditySensorStatusSchema, HvacModeSchema, ImageStatusSchema, InstalledPackageSchema, IntegrationLiteSchema, IntegrationWithStateSchema, IntercomAbilitySchema, IntercomStatusSchema, KNOWN_CAP_NAMES, LabelDefinitionSchema, LawnMowerActivitySchema, LawnMowerControlStatusSchema, LocateSegmentResultSchema, LocationStatSchema, LockControlStatusSchema, LockStateSchema, LogEntrySchema, LogLevelSchema, LogStreamEntrySchema, MACRO_LABELS, METHOD_ACCESS_MAP, MODEL_FORMATS, MaskGridDimsSchema, MaskGridShapeSchema, MaskLineShapeSchema, MaskPointSchema, MaskPolygonShapeSchema, MaskPolygonVerticesSchema, MaskRectShapeSchema, MaskShapeKindSchema, MaskShapeSchema, MediaFileSchema, MediaPlayerRepeatSchema, MediaPlayerStateSchema, MediaPlayerStatusSchema, MeshPeerSchema, MeshStatusSchema, MethodAccessSchema, ModelCatalogEntrySchema, ModelConvertInputSchema, ModelConvertMetadataSchema, ModelDistributeInputSchema, ModelDistributeResultSchema, ModelExtraFileSchema, ModelFormatEntrySchema, ModelFormatsSchema, MotionAnalysisResultSchema, MotionEventSchema, MotionOnMotionChangedDataSchema, MotionRegionSchema, MotionSourceEnum, MotionSourcesSchema, MotionStatusSchema, MotionTriggerRuntimeStateSchema, MotionTriggerStatusSchema, MotionZoneOptionsSchema, MotionZonePatchSchema, MotionZoneRegionSchema, MotionZoneStatusSchema, StatusSchema as MqttBrokerStatusSchema, NativeDetectionSchema, NativeObjectClassEnum, NativeObjectDetectionRuntimeStateSchema, NativeObjectDetectionStatusSchema, NetworkAccessStatusSchema, NetworkAddressSchema, NetworkEndpointSchema, NotificationActionSchema, NotificationFormatSchema, NotificationHistoryEntrySchema, NotificationRuleSchema, NotificationSchema, NotifierStatusSchema, NumericSensorStatusSchema, OauthIntegrationDescriptorSchema, ObjectEventSchema, OrchestratorMetricsSchema, OsdOverlayKindEnum, OsdOverlayPatchSchema, OsdOverlaySchema, OsdPositionEnum, OsdStatusSchema, PIPELINE_FLOW_CAPABILITY_NAMES, PIPELINE_OWNER_CAPABILITY_NAMES, PROVIDER_KIND_CAP_NAMES, PYTHON_SCRIPT, PackageUpdateSchema, PackageVersionInfoSchema, PasskeySummarySchema, PcmSampleFormatSchema, PerScopeBreakdownSchema, PickStreamPreferencesSchema, PickStreamRequirementsSchema, PickedCamStreamSchema, PipelineAssignmentSchema, PipelineDefaultStepSchema, PipelineEngineChoiceSchema, PipelineRunResultBridge, PipelineStepInputSchema, PlaceholderReasonSchema, PolygonPointSchema, PowerMeterStatusSchema, PresenceStatusSchema, PressureSensorStatusSchema, PrivacyMaskOptionsSchema, PrivacyMaskPatchSchema, PrivacyMaskRegionSchema, PrivacyMaskShapeSchema, PrivacyMaskStatusSchema, ProfileRtspEntrySchema, ProfileSlotSchema, ProfileSlotStatusSchema, ProviderStatusSchema, PtzAutotrackRuntimeStateSchema, PtzAutotrackSettingsSchema, PtzAutotrackStatusSchema, PtzAutotrackTargetOptionSchema, PtzMoveCommandSchema, PtzPositionSchema, PtzPresetSchema, PtzStatusSchema, QueryFilterSchema, RECOGNITION_TYPES, RUNTIME_DEFAULTS, RUNTIME_TO_FORMAT, RawStateResultSchema, ReadSegmentBytesResultSchema, ReadinessRegistry, ReadinessTimeoutError, RecordingAvailabilitySchema, RecordingBandModeSchema, RecordingBandSchema, RecordingBandTriggersSchema, RecordingConfigSchema, RecordingDaysSchema, RecordingDeviceUsageSchema, RecordingLocationUsageSchema, RecordingManifestSchema, RecordingModeSchema, RecordingRangeSchema, RecordingRetentionSchema, RecordingRuleSchema, RecordingScheduleSchema, RecordingStatusSchema, RecordingStorageModeSchema, RecordingStorageUsageSchema, RecordingTriggersSchema, RecordingWeekdaySchema, RegisteredStreamSchema, RenderedAsSchema, ReportMotionInputSchema, RingBuffer, RtpSourceSchema, RtspRestreamEntrySchema, RunnerCameraConfigSchema, RunnerCameraDeviceUIFields, RunnerFrameSourceSchema, RunnerLocalLoadSchema, RunnerLocalMetricsSchema, SCOPE_PRESETS, SOURCE_INFO_METADATA_KEY, STREAM_PROFILE_META, STREAM_QUALITY_LABELS, SUB_DETECTION_TYPES, SYSTEM_CAP_NAMES, ScopedTokenSchema, ScopedTokenSummarySchema, ScoredObjectEventSchema, ScriptRunnerStatusSchema, SearchResultSchema, SendEmailInputSchema, SendEmailResultSchema, SendResultSchema, SettingsPatchSchema, SettingsRecordSchema, SettingsSchemaWithValuesSchema, SettingsUpdateResultSchema, ShmRingStatsSchema, SmokeStatusSchema, SmtpStatusSchema, SnapshotImageSchema, SourceInfoSchema, SpatialDetectionSchema, SsoBridgeClaimsSchema, StartEmbeddedInputSchema, 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, ProviderInfoSchema as StorageProviderInfoSchema, ReadChunkInputSchema as StorageReadChunkInputSchema, TestLocationResultSchema as StorageTestLocationResultSchema, WriteChunkInputSchema as StorageWriteChunkInputSchema, StreamCodecSchema, StreamFormatSchema, StreamInfoSchema, StreamNetworkStatsSchema, StreamParamsOptionsSchema, StreamParamsStatusSchema, StreamProfileConfigSchema, StreamProfileOptionsSchema, StreamProfilePatchSchema, StreamProfileSchema, StreamSourceEntrySchema, StreamSourceSchema, SubscribeAudioChunksInputSchema, SubscribeAudioChunksResultSchema, SubscribeFramesInputSchema, SubscribeFramesResultSchema, SwitchStatusSchema, SystemMetricsSchema, SystemMirror, TIMEZONES, TamperStatusSchema, TankStatusSchema, TargetKindCapsSchema, TargetKindLevelSchema, TargetKindSchema, TargetSchema, TemperatureSensorStatusSchema, TestConnectionResultSchema$1 as TestConnectionResultSchema, TestResultSchema, ToastSchema, TokenScopeSchema, TopologyNodeSchema, TopologyProcessSchema, TopologyServiceSchema, TrackSchema, TrackStateSchema, TrackedDetectionSchema, TurnServerSchema, BrokerInfoSchema$1 as UnifiedBrokerInfoSchema, UpdateIntegrationInputSchema, UpdateStatusSchema, UpdateUserInputSchema, UserRecordSchema, UserSummarySchema, VacuumControlStatusSchema, VacuumStateSchema, ValveStateSchema, ValveStatusSchema, VibrationStatusSchema, VideoEncodeSchema, WELL_KNOWN_TABS, WELL_KNOWN_TAB_MAP, WaterHeaterStatusSchema, WeatherStatusSchema, WebrtcStreamChoiceSchema, WebrtcStreamTargetSchema, WidgetHostEnum, WidgetMetadataSchema, WidgetRemoteSchema, WidgetSizeEnum, YAMNET_TO_MACRO, ZoneKindEnum, ZoneRuleModeEnum, ZoneRuleSchema, ZoneRuleStageEnum, ZoneRulesArraySchema, ZoneSchema, ZoneScopeBreakdownSchema, accessoriesCapability, accessoryStableId, addonPagesCapability, addonPagesSourceCapability, addonRoutesCapability, addonSettingsCapability, addonWidgetsCapability, addonWidgetsSourceCapability, addonsCapability, adminUiCapability, advancedNotifierCapability, airQualitySensorCapability, alarmPanelCapability, alertsCapability, ambientLightSensorCapability, applyTransform, asBoolean, asJsonArray, asJsonObject, asNumber, asString, audioAnalysisCapability, audioAnalyzerCapability, audioCodecCapability, audioMetricsCapability, authProviderCapability, autoAssignProfiles, automationControlCapability, backupCapability, batteryCapability, bestLocationMatch, binaryCapability, bindAddonActions, brightnessCapability, brokerCapability, buildAddonRouteProvider, buildStreamParamsConfigSchema, buttonCapability, cameraCredentialsCapability, cameraPipelineConfigCapability, cameraStreamsCapability, carbonMonoxideCapability, cellsToRects, classifyStream, classifyStreams, climateControlCapability, colorCapability, connectivityCapability, consumablesCapability, contactCapability, controlCapability, cosineSimilarity, coverCapability, createDeviceProxy, createDurableState, createEvent, createLazyTrpcSource, createMirrorSource, createRuntimeStateBridge, createSliceHandle, createSystemProxy, customAction, customModelRegistryCapability, decoderCapability, defaultDeviceFor, defineCustomActions, detectionPipelineCapability, deviceAdoptionCapability, deviceCustomAction, deviceDiscoveryCapability, deviceExportCapability, deviceManagerCapability, deviceMatchesProfile, deviceOpsCapability, deviceProviderCapability, deviceStateCapability, deviceStatusCapability, doorbellCapability, embeddingEncoderCapability, emitDownForOwnedCaps, emitReadiness, encodeProfileFromStreamShape, enumSensorCapability, enumerateItemArrayFields, enumerateSchemaFields, errMsg, evaluateZoneRules, event, eventEmitterCapability, eventsCapability, expandCapMethods, extractSourceInfoFromMetadata, faceGalleryCapability, fanControlCapability, featureProbeCapability, filesystemBrowseCapability, findTimezone, floodCapability, formatForBackend, formatForRuntime, frameworkSwapConfirmSchema, frameworkSwapPackageSchema, gasCapability, getAudioMacroClassIds, getByPath, getCapsByProviderKind, hfModelUrl, htmlToText, humidifierCapability, humiditySensorCapability, hydrateSchema, imageCapability, integrationsCapability, intercomCapability, isAgentOnlyPlacement, isDeployableToAgent, isDeviceConfigCap, isEvent, jobKindSchema, lawnMowerControlCapability, lifecycleJobSchema, lifecycleJobScopeSchema, lifecycleJobStateSchema, lifecycleTaskSchema, localNetworkCapability, locationSimilarity, lockControlCapability, logDestinationCapability, makeProfileBrokerId, makeSourceBrokerId, mapAudioLabelToMacro, markdownToHtmlLite, markdownToText, maskUrlCredentials, mediaPlayerCapability, mergeSourceInfo, meshNetworkCapability, method, metricsProviderCapability, migrateConfigToBands, modelConvertCapability, modelDistributorCapability, modelFormatForRuntime, motionCapability, motionDetectionCapability, motionTriggerCapability, motionZonesCapability, mqttBrokerCapability, nativeObjectDetectionCapability, networkAccessCapability, networkQualityCapability, nodePin, nodesCapability, normalizeAddonInitResult, normalizeUnit, notificationOutputCapability, notifierCapability, numericSensorCapability, oauthIntegrationCapability, osdCapability, parseCameraStreamConfig, parseJsonArray, parseJsonObject, parseJsonUnknown, parseProfileBrokerId, parseStreamParamsFormPatch, pendingFrameworkSwapSchema, pickPreferredRtspEntry, pipelineAnalyticsCapability, pipelineExecutorCapability, pipelineOrchestratorCapability, pipelineRunnerCapability, plateGalleryCapability, platformProbeCapability, powerMeterCapability, prepareNotification, presenceCapability, pressureSensorCapability, privacyMaskCapability, ptzAutotrackCapability, ptzCapability, pythonScriptForBackend, readNodePin, readinessKey, rebootCapability, recordingCapability, rectsToCells, requiresPython, resolveAddonExecution, resolveAddonGroup, resolveAddonPlacement, resolveAddonRuntime, resolveCapMount, resolveDetectionRuntime, resolveDeviceProfile, resolveFormat, resolveModelFormat, resolveRunnerId, restreamerCapability, runInferenceStep, runtimeDevices, scopeKey, scoreRuntimes, scriptRunnerCapability, selectAssignedProfileSlots, setByPath, settingsStoreCapability, sleep, sleepCancellable, smokeCapability, smtpProviderCapability, snapshotCapability, snapshotProviderCapability, ssoBridgeCapability, storageCapability, storageEvictableCapability, storageProviderCapability, streamBrokerCapability, streamCatalogCapability, streamParamsCapability, streamPixels, streamQualityLabel, streamingEngineCapability, supportedRuntimes, switchCapability, synthesizeSourceInfo, systemCapability, tamperCapability, taskLogEntrySchema, taskPhaseSchema, taskTargetSchema, temperatureSensorCapability, textToHtml, toDeviceSummary, toStreamSourceEntry, toastCapability, transcodeBody, turnProviderCapability, updateCapability, userManagementCapability, userPasskeysCapability, vacuumControlCapability, valveCapability, vibrationCapability, videoclipsCapability, waterHeaterCapability, weatherCapability, webrtcCapability, webrtcClientHintsSchema, webrtcSessionCapability, wiringAddonHealthSchema, wiringHealthSnapshotSchema, wiringNodeHealthSchema, wiringProbeKindSchema, wiringProbeResultSchema, zodEntriesToConfigUI, zoneAnalyticsCapability, zoneRulesCapability, zonesCapability };
@@ -96,6 +96,13 @@ export interface HubHealthAgentCounts {
96
96
  readonly total: number;
97
97
  readonly online: number;
98
98
  readonly offline: number;
99
+ /**
100
+ * Node ids of the offline agents. Optional (added later) — consumers
101
+ * must tolerate absence on older hubs. Lets health surfaces name the
102
+ * degraded node ("node little-unraid not responding") instead of
103
+ * only counting it.
104
+ */
105
+ readonly offlineIds?: readonly string[];
99
106
  }
100
107
  /** Aggregate cluster health, returned by `GET /health/cluster`. */
101
108
  export interface ClusterHealth {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/types",
3
- "version": "1.1.19",
3
+ "version": "1.1.20",
4
4
  "description": "Shared types, interfaces, and model catalogs for the CamStack detection ecosystem",
5
5
  "keywords": [
6
6
  "camstack",