@camstack/addon-provider-rademacher 0.2.100 → 0.2.101

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.
package/dist/addon.js CHANGED
@@ -984,7 +984,7 @@ var Rademacher = class {
984
984
  }
985
985
  };
986
986
  //#endregion
987
- //#region ../types/dist/event-category-ZyX6jcse.mjs
987
+ //#region ../types/dist/event-category-BVDXG4tB.mjs
988
988
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
989
989
  EventCategory["SystemBoot"] = "system.boot";
990
990
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -1601,6 +1601,20 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
1601
1601
  * pull-reconcile from the provider's `getStatus` on reconnect. */
1602
1602
  EventCategory["MeshNetworkChanged"] = "network.mesh.changed";
1603
1603
  EventCategory["BackupCompleted"] = "backup.completed";
1604
+ /**
1605
+ * A whole backup RUN finished — every destination attempted, win or lose.
1606
+ *
1607
+ * `backup.completed` fires once per DESTINATION, which is the right grain for
1608
+ * a progress UI and the wrong one for a notification: an operator with three
1609
+ * destinations would be told three times. And a run where two of three
1610
+ * destinations succeeded is not a clean success — a single "backup
1611
+ * completed" that hid the failed one would be a lie, so the count of each is
1612
+ * carried here and the message says both.
1613
+ *
1614
+ * Emitted by the backup orchestrator only after the destination loop, so a
1615
+ * run that dies during the BUILD phase produces no completion at all.
1616
+ */
1617
+ EventCategory["BackupRunCompleted"] = "backup.run-completed";
1604
1618
  EventCategory["BackupRestored"] = "backup.restored";
1605
1619
  EventCategory["NotificationDispatched"] = "notification.dispatched";
1606
1620
  EventCategory["NotificationFailed"] = "notification.failed";
@@ -6331,7 +6345,7 @@ var ZodIssueCode = {
6331
6345
  var ZodFirstPartyTypeKind;
6332
6346
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
6333
6347
  //#endregion
6334
- //#region ../types/dist/sleep-DBKu2-U5.mjs
6348
+ //#region ../types/dist/sleep-DEuj7E3j.mjs
6335
6349
  /**
6336
6350
  * The audio chunk plane's byte format, and the ONE expansion from a coded
6337
6351
  * window to float samples (D455).
@@ -12475,6 +12489,72 @@ method(ListInputSchema, array(BrokerInfoSchema$1)), method(GetInputSchema, Broke
12475
12489
  auth: "admin"
12476
12490
  }), method(GetStateInputSchema, unknown().nullable()), method(_void(), RegistryStatusSchema);
12477
12491
  DeviceType.Camera;
12492
+ /**
12493
+ * The signals a device can emit to WAKE its own stream.
12494
+ *
12495
+ * A camera whose stream is built on demand sleeps until something asks for it,
12496
+ * and "something" cannot be a consumer that is merely attached — a Frigate-style
12497
+ * puller holds a session open for ever, and treating that as demand would keep
12498
+ * a battery camera awake for ever, which is the whole thing the battery is for
12499
+ * (D173). So the wake has to come from the CAMERA: an event it noticed by
12500
+ * itself, with no stream running.
12501
+ *
12502
+ * ## The vocabulary is the PROVIDER'S, not ours
12503
+ *
12504
+ * Like `consumables`, this cap declares no vocabulary of its own. A provider
12505
+ * names each signal with a `code` it chooses and a `label` an operator reads.
12506
+ * Reolink offers motion and camera-native detection; another provider may offer
12507
+ * a tamper, a doorbell press, a PIR, or something no camera in this fleet has
12508
+ * yet. A fixed enum here would mean every new signal is a framework release.
12509
+ *
12510
+ * It is deliberately NOT derived from the caps a device already binds. Whether
12511
+ * a camera CAN push firmware motion is expressed by `motionSources` containing
12512
+ * `'onboard'`, and whether it does AI on-camera by the `native-object-detection`
12513
+ * binding — but both answer "what drives the detection pipeline", which is a
12514
+ * different question from "what may wake a sleeping stream". A camera can do
12515
+ * the first and not be trusted with the second, and the operator picks per
12516
+ * camera. Two questions, two authorities.
12517
+ *
12518
+ * ## Availability is not permission
12519
+ *
12520
+ * `listSignals` says what the device CAN emit. Whether a given signal actually
12521
+ * wakes the stream is the operator's per-camera choice, held by the broker
12522
+ * alongside the cooldown — see the stream-broker cap's wake settings. A
12523
+ * provider declaring a signal is not a provider enabling it.
12524
+ */
12525
+ /** One signal a device can emit. */
12526
+ var StreamSignalSchema = object({
12527
+ /** Stable id chosen by the provider, e.g. `'motion'`, `'person'`, `'tamper'`. */
12528
+ code: string().min(1),
12529
+ /** What an operator reads in the picker. The provider's own wording. */
12530
+ label: string().min(1),
12531
+ /**
12532
+ * Whether the provider recommends this signal ON when a camera is first set
12533
+ * up. A provider knows which of its signals are cheap and reliable; an
12534
+ * operator should not have to discover that by trial. Reolink recommends
12535
+ * both of its own.
12536
+ */
12537
+ recommended: boolean()
12538
+ });
12539
+ var StreamSignalsStatusSchema = object({
12540
+ signals: array(StreamSignalSchema),
12541
+ lastFetchedAt: number()
12542
+ });
12543
+ var streamSignalsCapability = {
12544
+ name: "stream-signals",
12545
+ scope: "device",
12546
+ deviceNative: true,
12547
+ mode: "singleton",
12548
+ deviceTypes: Object.values(DeviceType),
12549
+ runtimeState: StreamSignalsStatusSchema,
12550
+ methods: {
12551
+ /**
12552
+ * What this device can emit. Empty is a valid and common answer — most
12553
+ * cameras have nothing to offer here, and an empty list is what makes the
12554
+ * broker's picker show nothing rather than a false choice.
12555
+ */
12556
+ listSignals: method(_void(), array(StreamSignalSchema).readonly()) }
12557
+ };
12478
12558
  /** Stream delivery format. (Relocated from the retired `streaming-engine` cap.) */
12479
12559
  var StreamFormatSchema = _enum([
12480
12560
  "webrtc",
@@ -12871,6 +12951,22 @@ var EgressTranscodeSchema = object({
12871
12951
  camStreamId: string().nullable()
12872
12952
  });
12873
12953
  method(object({
12954
+ deviceId: number().int().nonnegative(),
12955
+ /** The provider's signal code. */
12956
+ code: string().min(1),
12957
+ /** Ms epoch. Absent ⇒ now. */
12958
+ at: number().optional()
12959
+ }), object({
12960
+ /** Whether the broker acted on it, and if not, why. */
12961
+ accepted: boolean(),
12962
+ reason: _enum([
12963
+ "woke",
12964
+ "hold-extended",
12965
+ "not-enabled",
12966
+ "no-consumer",
12967
+ "unknown-code"
12968
+ ])
12969
+ }), { kind: "mutation" }), method(object({
12874
12970
  deviceId: number().int().nonnegative(),
12875
12971
  camStreamId: string().min(1),
12876
12972
  kind: CamStreamKindSchema,
@@ -13125,6 +13221,16 @@ var PickStreamRequirementsSchema = object({
13125
13221
  acceptCodecs: array(StreamCodecSchema).readonly().optional(),
13126
13222
  /** Minimum vertical resolution. Streams shorter than this are dropped. */
13127
13223
  minHeight: number().int().positive().optional(),
13224
+ /**
13225
+ * Maximum vertical resolution. Streams TALLER than this are dropped.
13226
+ *
13227
+ * A consumer can have a ceiling as real as its floor: Alexa documents
13228
+ * 480p to 1080p, and a 4K stream is as unusable to an Echo as a 360p one.
13229
+ * Without this the ceiling had to be re-implemented by every caller — and
13230
+ * one caller implementing it privately is how a second scoring authority
13231
+ * gets born.
13232
+ */
13233
+ maxHeight: number().int().positive().optional(),
13128
13234
  /** Minimum horizontal resolution. */
13129
13235
  minWidth: number().int().positive().optional(),
13130
13236
  /**
@@ -13141,7 +13247,22 @@ var PickStreamRequirementsSchema = object({
13141
13247
  * transcoded" guard: if the device is already serving the consumer's
13142
13248
  * codec end-to-end, there's nothing to optimise.
13143
13249
  */
13144
- requireSiblingCodec: array(StreamCodecSchema).readonly().optional()
13250
+ requireSiblingCodec: array(StreamCodecSchema).readonly().optional(),
13251
+ /**
13252
+ * Whether a stream the consumer CANNOT decode may still be picked, on the
13253
+ * understanding that it will be transcoded.
13254
+ *
13255
+ * Default `false` — today's behaviour, and the right one for a bypass
13256
+ * question ("is there a stream I can forward untouched?"). Set `true` to
13257
+ * ask the larger question: "what is the best stream for me, transcoding if
13258
+ * I must?" A stream that satisfies `acceptCodecs` always outranks one that
13259
+ * does not, so a passthrough is never lost to a transcode; the answer says
13260
+ * which it is in {@link PickedCamStreamSchema.transcodes}.
13261
+ *
13262
+ * This is what lets one picker serve both the bypass and the full source
13263
+ * choice, instead of a consumer scoring privately when the bypass misses.
13264
+ */
13265
+ allowTranscode: boolean().optional()
13145
13266
  }).readonly();
13146
13267
  var PickStreamPreferencesSchema = object({
13147
13268
  /**
@@ -13155,12 +13276,32 @@ var PickStreamPreferencesSchema = object({
13155
13276
  * picks the tallest stream; `'lowest'` picks the shortest (used by
13156
13277
  * memory-constrained consumers / Apple Home guest sessions).
13157
13278
  */
13158
- resolutionPreference: _enum(["highest", "lowest"]).optional()
13279
+ resolutionPreference: _enum(["highest", "lowest"]).optional(),
13280
+ /**
13281
+ * The height the consumer actually wants to DELIVER.
13282
+ *
13283
+ * Not a constraint — an ordering. With it set, the SMALLEST stream at or
13284
+ * above the target wins, and only if nothing reaches it does the tallest
13285
+ * take over. Pulling 1296 lines to draw 720 on a 1280x800 Echo panel costs
13286
+ * a decode and buys nothing, and `resolutionPreference: 'highest'` cannot
13287
+ * express that: it says "as big as possible", which is a different wish.
13288
+ *
13289
+ * Ignored when absent, so every existing caller keeps its ordering.
13290
+ */
13291
+ targetHeight: number().int().positive().optional()
13159
13292
  }).readonly();
13160
13293
  var PickedCamStreamSchema = object({
13161
13294
  camStreamId: string(),
13162
13295
  codec: string().optional(),
13163
13296
  resolution: CamStreamResolutionSchema.optional(),
13297
+ /**
13298
+ * Whether serving this stream requires a decode + re-encode.
13299
+ *
13300
+ * `false` is a stream the consumer can take as it stands. Only ever `true`
13301
+ * when the caller asked for it with `allowTranscode`, so a caller that did
13302
+ * not ask cannot be handed a cost it never agreed to pay.
13303
+ */
13304
+ transcodes: boolean(),
13164
13305
  /** One-line explanation of why this stream won — for logs / debug UI. */
13165
13306
  reason: string()
13166
13307
  });
@@ -17677,6 +17818,8 @@ var NcSystemEventKindSchema = _enum([
17677
17818
  "device-enabled",
17678
17819
  "device-battery-low",
17679
17820
  "device-battery-normal",
17821
+ "device-consumable-low",
17822
+ "device-consumable-normal",
17680
17823
  "stream-online",
17681
17824
  "stream-offline",
17682
17825
  "node-online",
@@ -17695,6 +17838,7 @@ var NcSystemEventKindSchema = _enum([
17695
17838
  "addon-updated",
17696
17839
  "server-updated",
17697
17840
  "export-completed",
17841
+ "backup-completed",
17698
17842
  "camera-online",
17699
17843
  "camera-offline",
17700
17844
  "camera-disabled",
@@ -24976,10 +25120,28 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
24976
25120
  }), boolean()), method(object({
24977
25121
  deviceId: number().int().nonnegative(),
24978
25122
  sessionId: string()
24979
- }), object({ pendingRenegotiation: object({
24980
- target: WebrtcStreamTargetSchema,
24981
- epoch: number()
24982
- }).nullable() }));
25123
+ }), object({
25124
+ pendingRenegotiation: object({
25125
+ target: WebrtcStreamTargetSchema,
25126
+ epoch: number()
25127
+ }).nullable(),
25128
+ /**
25129
+ * Whether the session still EXISTS.
25130
+ *
25131
+ * A consumer that holds a resource for the life of a session needs to
25132
+ * be able to ask, because a session does not always end the way it
25133
+ * began. Measured on this hub 2026-09-13: an Echo that got stuck never
25134
+ * sent `SessionDisconnected`, so the Alexa exporter's
25135
+ * `releaseEgressTranscode` never ran, and a 2304x1296 HEVC to 720p
25136
+ * H.264 transcode kept running for NOBODY for more than twenty
25137
+ * minutes. The WebRTC session had logged `WebRTC session closed`
25138
+ * minutes earlier — the broker knew; the holder had no way to ask.
25139
+ *
25140
+ * `false` for a session id the provider has never heard of, which is
25141
+ * the same answer as "it ended": either way nothing is holding it up.
25142
+ */
25143
+ alive: boolean()
25144
+ }));
24983
25145
  object({
24984
25146
  /** All accessory children of the parent. */
24985
25147
  childDeviceIds: array(number()).readonly(),
@@ -34898,6 +35060,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
34898
35060
  smoke: smokeCapability,
34899
35061
  streamCatalog: streamCatalogCapability,
34900
35062
  streamParams: streamParamsCapability,
35063
+ streamSignals: streamSignalsCapability,
34901
35064
  switch: switchCapability,
34902
35065
  tamper: tamperCapability,
34903
35066
  temperatureSensor: temperatureSensorCapability,
@@ -41471,6 +41634,12 @@ Object.freeze({
41471
41634
  addonId: null,
41472
41635
  access: "create"
41473
41636
  },
41637
+ "streamBroker.reportStreamSignal": {
41638
+ capName: "stream-broker",
41639
+ capScope: "system",
41640
+ addonId: null,
41641
+ access: "create"
41642
+ },
41474
41643
  "streamBroker.restartProfile": {
41475
41644
  capName: "stream-broker",
41476
41645
  capScope: "system",
@@ -41555,6 +41724,12 @@ Object.freeze({
41555
41724
  addonId: null,
41556
41725
  access: "create"
41557
41726
  },
41727
+ "streamSignals.listSignals": {
41728
+ capName: "stream-signals",
41729
+ capScope: "device",
41730
+ addonId: null,
41731
+ access: "view"
41732
+ },
41558
41733
  "switch.setState": {
41559
41734
  capName: "switch",
41560
41735
  capScope: "device",
@@ -43927,6 +44102,11 @@ Object.freeze({
43927
44102
  form: "single",
43928
44103
  optional: false
43929
44104
  }],
44105
+ "streamBroker.reportStreamSignal": [{
44106
+ name: "deviceId",
44107
+ form: "single",
44108
+ optional: false
44109
+ }],
43930
44110
  "streamBroker.restartProfile": [{
43931
44111
  name: "deviceId",
43932
44112
  form: "single",
package/dist/addon.mjs CHANGED
@@ -983,7 +983,7 @@ var Rademacher = class {
983
983
  }
984
984
  };
985
985
  //#endregion
986
- //#region ../types/dist/event-category-ZyX6jcse.mjs
986
+ //#region ../types/dist/event-category-BVDXG4tB.mjs
987
987
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
988
988
  EventCategory["SystemBoot"] = "system.boot";
989
989
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -1600,6 +1600,20 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
1600
1600
  * pull-reconcile from the provider's `getStatus` on reconnect. */
1601
1601
  EventCategory["MeshNetworkChanged"] = "network.mesh.changed";
1602
1602
  EventCategory["BackupCompleted"] = "backup.completed";
1603
+ /**
1604
+ * A whole backup RUN finished — every destination attempted, win or lose.
1605
+ *
1606
+ * `backup.completed` fires once per DESTINATION, which is the right grain for
1607
+ * a progress UI and the wrong one for a notification: an operator with three
1608
+ * destinations would be told three times. And a run where two of three
1609
+ * destinations succeeded is not a clean success — a single "backup
1610
+ * completed" that hid the failed one would be a lie, so the count of each is
1611
+ * carried here and the message says both.
1612
+ *
1613
+ * Emitted by the backup orchestrator only after the destination loop, so a
1614
+ * run that dies during the BUILD phase produces no completion at all.
1615
+ */
1616
+ EventCategory["BackupRunCompleted"] = "backup.run-completed";
1603
1617
  EventCategory["BackupRestored"] = "backup.restored";
1604
1618
  EventCategory["NotificationDispatched"] = "notification.dispatched";
1605
1619
  EventCategory["NotificationFailed"] = "notification.failed";
@@ -6330,7 +6344,7 @@ var ZodIssueCode = {
6330
6344
  var ZodFirstPartyTypeKind;
6331
6345
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
6332
6346
  //#endregion
6333
- //#region ../types/dist/sleep-DBKu2-U5.mjs
6347
+ //#region ../types/dist/sleep-DEuj7E3j.mjs
6334
6348
  /**
6335
6349
  * The audio chunk plane's byte format, and the ONE expansion from a coded
6336
6350
  * window to float samples (D455).
@@ -12474,6 +12488,72 @@ method(ListInputSchema, array(BrokerInfoSchema$1)), method(GetInputSchema, Broke
12474
12488
  auth: "admin"
12475
12489
  }), method(GetStateInputSchema, unknown().nullable()), method(_void(), RegistryStatusSchema);
12476
12490
  DeviceType.Camera;
12491
+ /**
12492
+ * The signals a device can emit to WAKE its own stream.
12493
+ *
12494
+ * A camera whose stream is built on demand sleeps until something asks for it,
12495
+ * and "something" cannot be a consumer that is merely attached — a Frigate-style
12496
+ * puller holds a session open for ever, and treating that as demand would keep
12497
+ * a battery camera awake for ever, which is the whole thing the battery is for
12498
+ * (D173). So the wake has to come from the CAMERA: an event it noticed by
12499
+ * itself, with no stream running.
12500
+ *
12501
+ * ## The vocabulary is the PROVIDER'S, not ours
12502
+ *
12503
+ * Like `consumables`, this cap declares no vocabulary of its own. A provider
12504
+ * names each signal with a `code` it chooses and a `label` an operator reads.
12505
+ * Reolink offers motion and camera-native detection; another provider may offer
12506
+ * a tamper, a doorbell press, a PIR, or something no camera in this fleet has
12507
+ * yet. A fixed enum here would mean every new signal is a framework release.
12508
+ *
12509
+ * It is deliberately NOT derived from the caps a device already binds. Whether
12510
+ * a camera CAN push firmware motion is expressed by `motionSources` containing
12511
+ * `'onboard'`, and whether it does AI on-camera by the `native-object-detection`
12512
+ * binding — but both answer "what drives the detection pipeline", which is a
12513
+ * different question from "what may wake a sleeping stream". A camera can do
12514
+ * the first and not be trusted with the second, and the operator picks per
12515
+ * camera. Two questions, two authorities.
12516
+ *
12517
+ * ## Availability is not permission
12518
+ *
12519
+ * `listSignals` says what the device CAN emit. Whether a given signal actually
12520
+ * wakes the stream is the operator's per-camera choice, held by the broker
12521
+ * alongside the cooldown — see the stream-broker cap's wake settings. A
12522
+ * provider declaring a signal is not a provider enabling it.
12523
+ */
12524
+ /** One signal a device can emit. */
12525
+ var StreamSignalSchema = object({
12526
+ /** Stable id chosen by the provider, e.g. `'motion'`, `'person'`, `'tamper'`. */
12527
+ code: string().min(1),
12528
+ /** What an operator reads in the picker. The provider's own wording. */
12529
+ label: string().min(1),
12530
+ /**
12531
+ * Whether the provider recommends this signal ON when a camera is first set
12532
+ * up. A provider knows which of its signals are cheap and reliable; an
12533
+ * operator should not have to discover that by trial. Reolink recommends
12534
+ * both of its own.
12535
+ */
12536
+ recommended: boolean()
12537
+ });
12538
+ var StreamSignalsStatusSchema = object({
12539
+ signals: array(StreamSignalSchema),
12540
+ lastFetchedAt: number()
12541
+ });
12542
+ var streamSignalsCapability = {
12543
+ name: "stream-signals",
12544
+ scope: "device",
12545
+ deviceNative: true,
12546
+ mode: "singleton",
12547
+ deviceTypes: Object.values(DeviceType),
12548
+ runtimeState: StreamSignalsStatusSchema,
12549
+ methods: {
12550
+ /**
12551
+ * What this device can emit. Empty is a valid and common answer — most
12552
+ * cameras have nothing to offer here, and an empty list is what makes the
12553
+ * broker's picker show nothing rather than a false choice.
12554
+ */
12555
+ listSignals: method(_void(), array(StreamSignalSchema).readonly()) }
12556
+ };
12477
12557
  /** Stream delivery format. (Relocated from the retired `streaming-engine` cap.) */
12478
12558
  var StreamFormatSchema = _enum([
12479
12559
  "webrtc",
@@ -12870,6 +12950,22 @@ var EgressTranscodeSchema = object({
12870
12950
  camStreamId: string().nullable()
12871
12951
  });
12872
12952
  method(object({
12953
+ deviceId: number().int().nonnegative(),
12954
+ /** The provider's signal code. */
12955
+ code: string().min(1),
12956
+ /** Ms epoch. Absent ⇒ now. */
12957
+ at: number().optional()
12958
+ }), object({
12959
+ /** Whether the broker acted on it, and if not, why. */
12960
+ accepted: boolean(),
12961
+ reason: _enum([
12962
+ "woke",
12963
+ "hold-extended",
12964
+ "not-enabled",
12965
+ "no-consumer",
12966
+ "unknown-code"
12967
+ ])
12968
+ }), { kind: "mutation" }), method(object({
12873
12969
  deviceId: number().int().nonnegative(),
12874
12970
  camStreamId: string().min(1),
12875
12971
  kind: CamStreamKindSchema,
@@ -13124,6 +13220,16 @@ var PickStreamRequirementsSchema = object({
13124
13220
  acceptCodecs: array(StreamCodecSchema).readonly().optional(),
13125
13221
  /** Minimum vertical resolution. Streams shorter than this are dropped. */
13126
13222
  minHeight: number().int().positive().optional(),
13223
+ /**
13224
+ * Maximum vertical resolution. Streams TALLER than this are dropped.
13225
+ *
13226
+ * A consumer can have a ceiling as real as its floor: Alexa documents
13227
+ * 480p to 1080p, and a 4K stream is as unusable to an Echo as a 360p one.
13228
+ * Without this the ceiling had to be re-implemented by every caller — and
13229
+ * one caller implementing it privately is how a second scoring authority
13230
+ * gets born.
13231
+ */
13232
+ maxHeight: number().int().positive().optional(),
13127
13233
  /** Minimum horizontal resolution. */
13128
13234
  minWidth: number().int().positive().optional(),
13129
13235
  /**
@@ -13140,7 +13246,22 @@ var PickStreamRequirementsSchema = object({
13140
13246
  * transcoded" guard: if the device is already serving the consumer's
13141
13247
  * codec end-to-end, there's nothing to optimise.
13142
13248
  */
13143
- requireSiblingCodec: array(StreamCodecSchema).readonly().optional()
13249
+ requireSiblingCodec: array(StreamCodecSchema).readonly().optional(),
13250
+ /**
13251
+ * Whether a stream the consumer CANNOT decode may still be picked, on the
13252
+ * understanding that it will be transcoded.
13253
+ *
13254
+ * Default `false` — today's behaviour, and the right one for a bypass
13255
+ * question ("is there a stream I can forward untouched?"). Set `true` to
13256
+ * ask the larger question: "what is the best stream for me, transcoding if
13257
+ * I must?" A stream that satisfies `acceptCodecs` always outranks one that
13258
+ * does not, so a passthrough is never lost to a transcode; the answer says
13259
+ * which it is in {@link PickedCamStreamSchema.transcodes}.
13260
+ *
13261
+ * This is what lets one picker serve both the bypass and the full source
13262
+ * choice, instead of a consumer scoring privately when the bypass misses.
13263
+ */
13264
+ allowTranscode: boolean().optional()
13144
13265
  }).readonly();
13145
13266
  var PickStreamPreferencesSchema = object({
13146
13267
  /**
@@ -13154,12 +13275,32 @@ var PickStreamPreferencesSchema = object({
13154
13275
  * picks the tallest stream; `'lowest'` picks the shortest (used by
13155
13276
  * memory-constrained consumers / Apple Home guest sessions).
13156
13277
  */
13157
- resolutionPreference: _enum(["highest", "lowest"]).optional()
13278
+ resolutionPreference: _enum(["highest", "lowest"]).optional(),
13279
+ /**
13280
+ * The height the consumer actually wants to DELIVER.
13281
+ *
13282
+ * Not a constraint — an ordering. With it set, the SMALLEST stream at or
13283
+ * above the target wins, and only if nothing reaches it does the tallest
13284
+ * take over. Pulling 1296 lines to draw 720 on a 1280x800 Echo panel costs
13285
+ * a decode and buys nothing, and `resolutionPreference: 'highest'` cannot
13286
+ * express that: it says "as big as possible", which is a different wish.
13287
+ *
13288
+ * Ignored when absent, so every existing caller keeps its ordering.
13289
+ */
13290
+ targetHeight: number().int().positive().optional()
13158
13291
  }).readonly();
13159
13292
  var PickedCamStreamSchema = object({
13160
13293
  camStreamId: string(),
13161
13294
  codec: string().optional(),
13162
13295
  resolution: CamStreamResolutionSchema.optional(),
13296
+ /**
13297
+ * Whether serving this stream requires a decode + re-encode.
13298
+ *
13299
+ * `false` is a stream the consumer can take as it stands. Only ever `true`
13300
+ * when the caller asked for it with `allowTranscode`, so a caller that did
13301
+ * not ask cannot be handed a cost it never agreed to pay.
13302
+ */
13303
+ transcodes: boolean(),
13163
13304
  /** One-line explanation of why this stream won — for logs / debug UI. */
13164
13305
  reason: string()
13165
13306
  });
@@ -17676,6 +17817,8 @@ var NcSystemEventKindSchema = _enum([
17676
17817
  "device-enabled",
17677
17818
  "device-battery-low",
17678
17819
  "device-battery-normal",
17820
+ "device-consumable-low",
17821
+ "device-consumable-normal",
17679
17822
  "stream-online",
17680
17823
  "stream-offline",
17681
17824
  "node-online",
@@ -17694,6 +17837,7 @@ var NcSystemEventKindSchema = _enum([
17694
17837
  "addon-updated",
17695
17838
  "server-updated",
17696
17839
  "export-completed",
17840
+ "backup-completed",
17697
17841
  "camera-online",
17698
17842
  "camera-offline",
17699
17843
  "camera-disabled",
@@ -24975,10 +25119,28 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
24975
25119
  }), boolean()), method(object({
24976
25120
  deviceId: number().int().nonnegative(),
24977
25121
  sessionId: string()
24978
- }), object({ pendingRenegotiation: object({
24979
- target: WebrtcStreamTargetSchema,
24980
- epoch: number()
24981
- }).nullable() }));
25122
+ }), object({
25123
+ pendingRenegotiation: object({
25124
+ target: WebrtcStreamTargetSchema,
25125
+ epoch: number()
25126
+ }).nullable(),
25127
+ /**
25128
+ * Whether the session still EXISTS.
25129
+ *
25130
+ * A consumer that holds a resource for the life of a session needs to
25131
+ * be able to ask, because a session does not always end the way it
25132
+ * began. Measured on this hub 2026-09-13: an Echo that got stuck never
25133
+ * sent `SessionDisconnected`, so the Alexa exporter's
25134
+ * `releaseEgressTranscode` never ran, and a 2304x1296 HEVC to 720p
25135
+ * H.264 transcode kept running for NOBODY for more than twenty
25136
+ * minutes. The WebRTC session had logged `WebRTC session closed`
25137
+ * minutes earlier — the broker knew; the holder had no way to ask.
25138
+ *
25139
+ * `false` for a session id the provider has never heard of, which is
25140
+ * the same answer as "it ended": either way nothing is holding it up.
25141
+ */
25142
+ alive: boolean()
25143
+ }));
24982
25144
  object({
24983
25145
  /** All accessory children of the parent. */
24984
25146
  childDeviceIds: array(number()).readonly(),
@@ -34897,6 +35059,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
34897
35059
  smoke: smokeCapability,
34898
35060
  streamCatalog: streamCatalogCapability,
34899
35061
  streamParams: streamParamsCapability,
35062
+ streamSignals: streamSignalsCapability,
34900
35063
  switch: switchCapability,
34901
35064
  tamper: tamperCapability,
34902
35065
  temperatureSensor: temperatureSensorCapability,
@@ -41470,6 +41633,12 @@ Object.freeze({
41470
41633
  addonId: null,
41471
41634
  access: "create"
41472
41635
  },
41636
+ "streamBroker.reportStreamSignal": {
41637
+ capName: "stream-broker",
41638
+ capScope: "system",
41639
+ addonId: null,
41640
+ access: "create"
41641
+ },
41473
41642
  "streamBroker.restartProfile": {
41474
41643
  capName: "stream-broker",
41475
41644
  capScope: "system",
@@ -41554,6 +41723,12 @@ Object.freeze({
41554
41723
  addonId: null,
41555
41724
  access: "create"
41556
41725
  },
41726
+ "streamSignals.listSignals": {
41727
+ capName: "stream-signals",
41728
+ capScope: "device",
41729
+ addonId: null,
41730
+ access: "view"
41731
+ },
41557
41732
  "switch.setState": {
41558
41733
  capName: "switch",
41559
41734
  capScope: "device",
@@ -43926,6 +44101,11 @@ Object.freeze({
43926
44101
  form: "single",
43927
44102
  optional: false
43928
44103
  }],
44104
+ "streamBroker.reportStreamSignal": [{
44105
+ name: "deviceId",
44106
+ form: "single",
44107
+ optional: false
44108
+ }],
43929
44109
  "streamBroker.restartProfile": [{
43930
44110
  name: "deviceId",
43931
44111
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-rademacher",
3
- "version": "0.2.100",
3
+ "version": "0.2.101",
4
4
  "description": "Rademacher HomePilot device-provider addon for CamStack — wraps the @apocaliss92/noderademacher local-hub client (roller shutters over the cover cap)",
5
5
  "keywords": [
6
6
  "camstack",