@camstack/addon-provider-rtsp 1.2.100 → 1.2.102

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/dist/addon.js +349 -16
  2. package/dist/addon.mjs +349 -16
  3. package/package.json +1 -1
package/dist/addon.js CHANGED
@@ -23,7 +23,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
23
23
  //#endregion
24
24
  let node_net = require("node:net");
25
25
  node_net = __toESM(node_net);
26
- //#region ../types/dist/event-category-ZyX6jcse.mjs
26
+ //#region ../types/dist/event-category-BVDXG4tB.mjs
27
27
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
28
28
  EventCategory["SystemBoot"] = "system.boot";
29
29
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -640,6 +640,20 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
640
640
  * pull-reconcile from the provider's `getStatus` on reconnect. */
641
641
  EventCategory["MeshNetworkChanged"] = "network.mesh.changed";
642
642
  EventCategory["BackupCompleted"] = "backup.completed";
643
+ /**
644
+ * A whole backup RUN finished — every destination attempted, win or lose.
645
+ *
646
+ * `backup.completed` fires once per DESTINATION, which is the right grain for
647
+ * a progress UI and the wrong one for a notification: an operator with three
648
+ * destinations would be told three times. And a run where two of three
649
+ * destinations succeeded is not a clean success — a single "backup
650
+ * completed" that hid the failed one would be a lie, so the count of each is
651
+ * carried here and the message says both.
652
+ *
653
+ * Emitted by the backup orchestrator only after the destination loop, so a
654
+ * run that dies during the BUILD phase produces no completion at all.
655
+ */
656
+ EventCategory["BackupRunCompleted"] = "backup.run-completed";
643
657
  EventCategory["BackupRestored"] = "backup.restored";
644
658
  EventCategory["NotificationDispatched"] = "notification.dispatched";
645
659
  EventCategory["NotificationFailed"] = "notification.failed";
@@ -5370,7 +5384,7 @@ var ZodIssueCode = {
5370
5384
  var ZodFirstPartyTypeKind;
5371
5385
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5372
5386
  //#endregion
5373
- //#region ../types/dist/sleep-CnLyvg3w.mjs
5387
+ //#region ../types/dist/sleep-DEuj7E3j.mjs
5374
5388
  /**
5375
5389
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5376
5390
  * window to float samples (D455).
@@ -7399,7 +7413,23 @@ var EncodeProfileSchema = object({
7399
7413
  "zerolatency",
7400
7414
  "film",
7401
7415
  "animation"
7402
- ]).optional()
7416
+ ]).optional(),
7417
+ /**
7418
+ * ONE slice per access unit.
7419
+ *
7420
+ * `-tune zerolatency` turns on x264's sliced threads, and a frame then leaves
7421
+ * the encoder as five NAL slices that share one RTP timestamp and carry one
7422
+ * marker bit. A libwebrtc depacketiser sees five frame-starts and one
7423
+ * frame-end per frame: the first pictures render and the video then freezes
7424
+ * for good while the audio, on its own plane, plays on. Measured on this hub
7425
+ * 2026-09-13 against the Echo, and reduced to one slice by this flag alone.
7426
+ *
7427
+ * A NAMED field and not a raw flag, because {@link EgressEncodeSchema} omits
7428
+ * `outputArgs` on purpose: an opaque array is part of the sharing key, so two
7429
+ * consumers meaning the same thing spelled differently would stop sharing one
7430
+ * child. Absent means "whatever the encoder does" — today's behaviour.
7431
+ */
7432
+ singleSlicePerFrame: boolean().optional()
7403
7433
  }),
7404
7434
  audio: union([literal("passthrough"), object({
7405
7435
  codec: _enum([
@@ -7449,7 +7479,7 @@ var BASE_LIVE_EGRESS_PROFILE = {
7449
7479
  audio: "passthrough"
7450
7480
  };
7451
7481
  ({ ...BASE_LIVE_EGRESS_PROFILE }), { ...BASE_LIVE_EGRESS_PROFILE.video };
7452
- ({ ...BASE_LIVE_EGRESS_PROFILE });
7482
+ ({ ...BASE_LIVE_EGRESS_PROFILE }), { ...BASE_LIVE_EGRESS_PROFILE.video };
7453
7483
  /**
7454
7484
  * Deep wiring healthcheck — snapshot of active reachability probes across
7455
7485
  * every declared capability + widget of every installed plugin, on every
@@ -11530,6 +11560,72 @@ method(ListInputSchema, array(BrokerInfoSchema$1)), method(GetInputSchema, Broke
11530
11560
  auth: "admin"
11531
11561
  }), method(GetStateInputSchema, unknown().nullable()), method(_void(), RegistryStatusSchema);
11532
11562
  DeviceType.Camera;
11563
+ /**
11564
+ * The signals a device can emit to WAKE its own stream.
11565
+ *
11566
+ * A camera whose stream is built on demand sleeps until something asks for it,
11567
+ * and "something" cannot be a consumer that is merely attached — a Frigate-style
11568
+ * puller holds a session open for ever, and treating that as demand would keep
11569
+ * a battery camera awake for ever, which is the whole thing the battery is for
11570
+ * (D173). So the wake has to come from the CAMERA: an event it noticed by
11571
+ * itself, with no stream running.
11572
+ *
11573
+ * ## The vocabulary is the PROVIDER'S, not ours
11574
+ *
11575
+ * Like `consumables`, this cap declares no vocabulary of its own. A provider
11576
+ * names each signal with a `code` it chooses and a `label` an operator reads.
11577
+ * Reolink offers motion and camera-native detection; another provider may offer
11578
+ * a tamper, a doorbell press, a PIR, or something no camera in this fleet has
11579
+ * yet. A fixed enum here would mean every new signal is a framework release.
11580
+ *
11581
+ * It is deliberately NOT derived from the caps a device already binds. Whether
11582
+ * a camera CAN push firmware motion is expressed by `motionSources` containing
11583
+ * `'onboard'`, and whether it does AI on-camera by the `native-object-detection`
11584
+ * binding — but both answer "what drives the detection pipeline", which is a
11585
+ * different question from "what may wake a sleeping stream". A camera can do
11586
+ * the first and not be trusted with the second, and the operator picks per
11587
+ * camera. Two questions, two authorities.
11588
+ *
11589
+ * ## Availability is not permission
11590
+ *
11591
+ * `listSignals` says what the device CAN emit. Whether a given signal actually
11592
+ * wakes the stream is the operator's per-camera choice, held by the broker
11593
+ * alongside the cooldown — see the stream-broker cap's wake settings. A
11594
+ * provider declaring a signal is not a provider enabling it.
11595
+ */
11596
+ /** One signal a device can emit. */
11597
+ var StreamSignalSchema = object({
11598
+ /** Stable id chosen by the provider, e.g. `'motion'`, `'person'`, `'tamper'`. */
11599
+ code: string().min(1),
11600
+ /** What an operator reads in the picker. The provider's own wording. */
11601
+ label: string().min(1),
11602
+ /**
11603
+ * Whether the provider recommends this signal ON when a camera is first set
11604
+ * up. A provider knows which of its signals are cheap and reliable; an
11605
+ * operator should not have to discover that by trial. Reolink recommends
11606
+ * both of its own.
11607
+ */
11608
+ recommended: boolean()
11609
+ });
11610
+ var StreamSignalsStatusSchema = object({
11611
+ signals: array(StreamSignalSchema),
11612
+ lastFetchedAt: number()
11613
+ });
11614
+ var streamSignalsCapability = {
11615
+ name: "stream-signals",
11616
+ scope: "device",
11617
+ deviceNative: true,
11618
+ mode: "singleton",
11619
+ deviceTypes: Object.values(DeviceType),
11620
+ runtimeState: StreamSignalsStatusSchema,
11621
+ methods: {
11622
+ /**
11623
+ * What this device can emit. Empty is a valid and common answer — most
11624
+ * cameras have nothing to offer here, and an empty list is what makes the
11625
+ * broker's picker show nothing rather than a false choice.
11626
+ */
11627
+ listSignals: method(_void(), array(StreamSignalSchema).readonly()) }
11628
+ };
11533
11629
  /** Stream delivery format. (Relocated from the retired `streaming-engine` cap.) */
11534
11630
  var StreamFormatSchema = _enum([
11535
11631
  "webrtc",
@@ -11926,6 +12022,22 @@ var EgressTranscodeSchema = object({
11926
12022
  camStreamId: string().nullable()
11927
12023
  });
11928
12024
  method(object({
12025
+ deviceId: number().int().nonnegative(),
12026
+ /** The provider's signal code. */
12027
+ code: string().min(1),
12028
+ /** Ms epoch. Absent ⇒ now. */
12029
+ at: number().optional()
12030
+ }), object({
12031
+ /** Whether the broker acted on it, and if not, why. */
12032
+ accepted: boolean(),
12033
+ reason: _enum([
12034
+ "woke",
12035
+ "hold-extended",
12036
+ "not-enabled",
12037
+ "no-consumer",
12038
+ "unknown-code"
12039
+ ])
12040
+ }), { kind: "mutation" }), method(object({
11929
12041
  deviceId: number().int().nonnegative(),
11930
12042
  camStreamId: string().min(1),
11931
12043
  kind: CamStreamKindSchema,
@@ -12180,6 +12292,16 @@ var PickStreamRequirementsSchema = object({
12180
12292
  acceptCodecs: array(StreamCodecSchema).readonly().optional(),
12181
12293
  /** Minimum vertical resolution. Streams shorter than this are dropped. */
12182
12294
  minHeight: number().int().positive().optional(),
12295
+ /**
12296
+ * Maximum vertical resolution. Streams TALLER than this are dropped.
12297
+ *
12298
+ * A consumer can have a ceiling as real as its floor: Alexa documents
12299
+ * 480p to 1080p, and a 4K stream is as unusable to an Echo as a 360p one.
12300
+ * Without this the ceiling had to be re-implemented by every caller — and
12301
+ * one caller implementing it privately is how a second scoring authority
12302
+ * gets born.
12303
+ */
12304
+ maxHeight: number().int().positive().optional(),
12183
12305
  /** Minimum horizontal resolution. */
12184
12306
  minWidth: number().int().positive().optional(),
12185
12307
  /**
@@ -12196,7 +12318,22 @@ var PickStreamRequirementsSchema = object({
12196
12318
  * transcoded" guard: if the device is already serving the consumer's
12197
12319
  * codec end-to-end, there's nothing to optimise.
12198
12320
  */
12199
- requireSiblingCodec: array(StreamCodecSchema).readonly().optional()
12321
+ requireSiblingCodec: array(StreamCodecSchema).readonly().optional(),
12322
+ /**
12323
+ * Whether a stream the consumer CANNOT decode may still be picked, on the
12324
+ * understanding that it will be transcoded.
12325
+ *
12326
+ * Default `false` — today's behaviour, and the right one for a bypass
12327
+ * question ("is there a stream I can forward untouched?"). Set `true` to
12328
+ * ask the larger question: "what is the best stream for me, transcoding if
12329
+ * I must?" A stream that satisfies `acceptCodecs` always outranks one that
12330
+ * does not, so a passthrough is never lost to a transcode; the answer says
12331
+ * which it is in {@link PickedCamStreamSchema.transcodes}.
12332
+ *
12333
+ * This is what lets one picker serve both the bypass and the full source
12334
+ * choice, instead of a consumer scoring privately when the bypass misses.
12335
+ */
12336
+ allowTranscode: boolean().optional()
12200
12337
  }).readonly();
12201
12338
  var PickStreamPreferencesSchema = object({
12202
12339
  /**
@@ -12210,12 +12347,32 @@ var PickStreamPreferencesSchema = object({
12210
12347
  * picks the tallest stream; `'lowest'` picks the shortest (used by
12211
12348
  * memory-constrained consumers / Apple Home guest sessions).
12212
12349
  */
12213
- resolutionPreference: _enum(["highest", "lowest"]).optional()
12350
+ resolutionPreference: _enum(["highest", "lowest"]).optional(),
12351
+ /**
12352
+ * The height the consumer actually wants to DELIVER.
12353
+ *
12354
+ * Not a constraint — an ordering. With it set, the SMALLEST stream at or
12355
+ * above the target wins, and only if nothing reaches it does the tallest
12356
+ * take over. Pulling 1296 lines to draw 720 on a 1280x800 Echo panel costs
12357
+ * a decode and buys nothing, and `resolutionPreference: 'highest'` cannot
12358
+ * express that: it says "as big as possible", which is a different wish.
12359
+ *
12360
+ * Ignored when absent, so every existing caller keeps its ordering.
12361
+ */
12362
+ targetHeight: number().int().positive().optional()
12214
12363
  }).readonly();
12215
12364
  var PickedCamStreamSchema = object({
12216
12365
  camStreamId: string(),
12217
12366
  codec: string().optional(),
12218
12367
  resolution: CamStreamResolutionSchema.optional(),
12368
+ /**
12369
+ * Whether serving this stream requires a decode + re-encode.
12370
+ *
12371
+ * `false` is a stream the consumer can take as it stands. Only ever `true`
12372
+ * when the caller asked for it with `allowTranscode`, so a caller that did
12373
+ * not ask cannot be handed a cost it never agreed to pay.
12374
+ */
12375
+ transcodes: boolean(),
12219
12376
  /** One-line explanation of why this stream won — for logs / debug UI. */
12220
12377
  reason: string()
12221
12378
  });
@@ -16732,6 +16889,8 @@ var NcSystemEventKindSchema = _enum([
16732
16889
  "device-enabled",
16733
16890
  "device-battery-low",
16734
16891
  "device-battery-normal",
16892
+ "device-consumable-low",
16893
+ "device-consumable-normal",
16735
16894
  "stream-online",
16736
16895
  "stream-offline",
16737
16896
  "node-online",
@@ -16750,6 +16909,7 @@ var NcSystemEventKindSchema = _enum([
16750
16909
  "addon-updated",
16751
16910
  "server-updated",
16752
16911
  "export-completed",
16912
+ "backup-completed",
16753
16913
  "camera-online",
16754
16914
  "camera-offline",
16755
16915
  "camera-disabled",
@@ -20186,13 +20346,109 @@ var SummariesQueryInput = object({
20186
20346
  deviceIds: array(number()).min(1),
20187
20347
  since: number().optional(),
20188
20348
  until: number().optional(),
20189
- limit: number().int().min(1).max(200).default(50)
20349
+ limit: number().int().min(1).max(200).default(50),
20350
+ /** The same member-wise filter {@link listRecentSummaries} takes — one
20351
+ * meaning of "dog" on every summary surface. */
20352
+ classes: array(string().min(1).max(60)).max(40).optional()
20190
20353
  });
20191
- var SummariesPageSchema = object({ summaries: array(SummarySchema).readonly() });
20192
20354
  var SummaryDetailSchema = object({
20193
20355
  summary: SummarySchema,
20194
- /** Member track ids, in absorption order. */
20195
- trackIds: array(string()).readonly()
20356
+ /** Members in absorption order, oldest join first. */
20357
+ members: array(object({
20358
+ trackId: string(),
20359
+ /**
20360
+ * The track's class at the time it JOINED, or `null` when it was unresolved
20361
+ * and the track no longer exists to fill it.
20362
+ *
20363
+ * The join, not the latest opinion: class voting can re-decide a track's
20364
+ * class afterwards, and a group's composition is the history of who came
20365
+ * together. A consumer counts these to badge a thumbnail — "two people and a
20366
+ * dog" — rather than being handed a second, denormalised tally that would
20367
+ * drift from the members it claims to describe.
20368
+ */
20369
+ className: string().nullable(),
20370
+ /** `primary` is the one member that carries the group's identity. */
20371
+ role: _enum([
20372
+ "primary",
20373
+ "sibling",
20374
+ "child"
20375
+ ]).nullable(),
20376
+ joinedAt: number(),
20377
+ /** Tier 1 — the sub-class (`dog`, `van`), resolved from the member's track
20378
+ * at read time. Absent when nothing resolved, never an empty string. */
20379
+ label: string().optional(),
20380
+ /** Tier 2 — the instance: a person's name, a plate. Absent when the pipeline
20381
+ * recognised nobody, and absent for a member whose track has been pruned —
20382
+ * a thumbnail that names the wrong person is worse than one naming nobody. */
20383
+ subLabel: string().optional()
20384
+ })).readonly()
20385
+ });
20386
+ /**
20387
+ * What a LIST of groups carries: the envelope plus what it is MADE OF.
20388
+ *
20389
+ * Coarse on purpose — the operator's rule is "only the rough data on the list,
20390
+ * we extend when we notice we need more". Enough to draw the card ("two people
20391
+ * and a dog") and no more. The MEMBERS, their names and the per-member links
20392
+ * are on {@link getSummary}: shipping every member of every group so a client
20393
+ * can count them turns a page of two hundred groups into a thousand records to
20394
+ * draw two hundred badges.
20395
+ */
20396
+ var SummaryListItemSchema = object({
20397
+ summary: SummarySchema,
20398
+ /** Class counts, most numerous first; `className: null` is a member whose
20399
+ * class never resolved, counted so the counts add up to `memberCount`. */
20400
+ classes: array(object({
20401
+ className: string().nullable(),
20402
+ count: number().int().positive()
20403
+ })).readonly()
20404
+ });
20405
+ var SummariesPageSchema = object({ summaries: array(SummaryListItemSchema).readonly() });
20406
+ /**
20407
+ * The paged feed, deliberately the SAME shape as {@link RecentTracksQueryInput}.
20408
+ *
20409
+ * The reel on the cameras page and the Events gallery both ride a cursor, so a
20410
+ * summaries feed that could only answer "the last N for these cameras"
20411
+ * (`listSummaries`) would make groups available in the timeline and nowhere
20412
+ * else. Two feeds with different ordering contracts would be two ideas of what
20413
+ * "newest" means, on one screen.
20414
+ */
20415
+ var RecentSummariesQueryInput = object({
20416
+ /** Devices to merge. An empty array yields an empty page. */
20417
+ deviceIds: array(number()),
20418
+ /** Window lower bound on `lastActiveAt` (inclusive). */
20419
+ since: number().optional(),
20420
+ /** Window upper bound on `lastActiveAt` (inclusive). */
20421
+ until: number().optional(),
20422
+ limit: number().int().min(1).max(500).default(100),
20423
+ /** Opaque continuation cursor from a previous page's `nextCursor`. */
20424
+ cursor: string().optional(),
20425
+ /**
20426
+ * Restrict to these classes — THE SAME FIELD `listRecentTracks` takes, and
20427
+ * deliberately the same name: the events filter tree emits one list of ticked
20428
+ * taxonomy nodes, and a summaries feed that called it something else would
20429
+ * make the operator's one filter component produce two shapes.
20430
+ *
20431
+ * A question about the MEMBERS: a group matches when ANY of them does. "Show
20432
+ * me the arrivals with a dog" has to return the group of four people who had
20433
+ * one with them; a filter on the group's own fields could only ever answer
20434
+ * about its primary.
20435
+ *
20436
+ * Matched against all THREE tiers of a member — the class (`animal`), the
20437
+ * sub-class (`dog`) and the instance (a name, a plate) — because which tier a
20438
+ * ticked node lives on is the taxonomy's business, not the caller's. `dog` is
20439
+ * an event kind in the tree and a tier-1 label on an `animal` track; a filter
20440
+ * that read only the class would answer "animal" and never "dog".
20441
+ *
20442
+ * ABSENT or EMPTY means no filter — absent is not a selection of none.
20443
+ */
20444
+ classes: array(string().min(1).max(60)).max(40).optional()
20445
+ });
20446
+ var RecentSummariesPageSchema = object({
20447
+ /** Ordered by (`lastActiveAt` DESC, id DESC). Same light item as
20448
+ * {@link listSummaries} — one list shape, so a card renders the same
20449
+ * whichever feed drew it. */
20450
+ summaries: array(SummaryListItemSchema).readonly(),
20451
+ nextCursor: string().nullable()
20196
20452
  });
20197
20453
  var RecentTracksPageSchema = object({
20198
20454
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
@@ -20606,7 +20862,7 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
20606
20862
  classes: array(string()).optional(),
20607
20863
  /** See {@link ExcludeSourcesDoc}. */
20608
20864
  excludeSources: array(TrackSourceSchema).optional()
20609
- }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20865
+ }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(RecentSummariesQueryInput, RecentSummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20610
20866
  kind: "mutation",
20611
20867
  auth: "admin"
20612
20868
  }), method(DeviceEventQueryInput, array(MotionEventSchema).readonly()), method(ObjectEventQueryInput, array(ObjectEventSchema).readonly()), method(DeviceEventQueryInput, array(AudioEventSchema).readonly()), method(object({ deviceId: number() }), array(EventKindDescriptorSchema).readonly()), method(object({ deviceIds: array(number()).min(1).max(200) }), array(EventKindsForDeviceSchema).readonly()), method(object({
@@ -24039,10 +24295,28 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
24039
24295
  }), boolean()), method(object({
24040
24296
  deviceId: number().int().nonnegative(),
24041
24297
  sessionId: string()
24042
- }), object({ pendingRenegotiation: object({
24043
- target: WebrtcStreamTargetSchema,
24044
- epoch: number()
24045
- }).nullable() }));
24298
+ }), object({
24299
+ pendingRenegotiation: object({
24300
+ target: WebrtcStreamTargetSchema,
24301
+ epoch: number()
24302
+ }).nullable(),
24303
+ /**
24304
+ * Whether the session still EXISTS.
24305
+ *
24306
+ * A consumer that holds a resource for the life of a session needs to
24307
+ * be able to ask, because a session does not always end the way it
24308
+ * began. Measured on this hub 2026-09-13: an Echo that got stuck never
24309
+ * sent `SessionDisconnected`, so the Alexa exporter's
24310
+ * `releaseEgressTranscode` never ran, and a 2304x1296 HEVC to 720p
24311
+ * H.264 transcode kept running for NOBODY for more than twenty
24312
+ * minutes. The WebRTC session had logged `WebRTC session closed`
24313
+ * minutes earlier — the broker knew; the holder had no way to ask.
24314
+ *
24315
+ * `false` for a session id the provider has never heard of, which is
24316
+ * the same answer as "it ended": either way nothing is holding it up.
24317
+ */
24318
+ alive: boolean()
24319
+ }));
24046
24320
  object({
24047
24321
  /** All accessory children of the parent. */
24048
24322
  childDeviceIds: array(number()).readonly(),
@@ -32471,7 +32745,29 @@ var LoggingSettingsPatchSchema = object({
32471
32745
  * disarmed the channels it did not mention would make the Levels page and
32472
32746
  * the Diagnostics page fight over the same value.
32473
32747
  */
32474
- channels: array(LogChannelWindowPatchSchema).readonly().optional()
32748
+ channels: array(LogChannelWindowPatchSchema).readonly().optional(),
32749
+ /**
32750
+ * How many days the analytics OPS LOG is kept — the audit trail of what
32751
+ * retention actually deleted.
32752
+ *
32753
+ * It lives HERE, on the logging document, and not on the analytics addon's
32754
+ * settings form, on the operator's instruction: every other log-ish window in
32755
+ * this system is configured through this one document, and a retention audit
32756
+ * configured somewhere else is a second place to look when the question is
32757
+ * "what happened to my data".
32758
+ *
32759
+ * That placement has a cost worth stating: this document ships in the
32760
+ * framework closure, so this knob needs a published `@camstack/server` while
32761
+ * the four windows beside it (D485) reach a node on `camstack deploy`.
32762
+ *
32763
+ * `retention-model.ts` argued this one must NOT follow a device window,
32764
+ * because the audit trail is the history of the SWEEP and not of the camera.
32765
+ * That argument stands and is untouched — what changes is that 30 days stops
32766
+ * being a constant nobody can reach. `0` keeps it forever. The floor is 1 day
32767
+ * rather than 0-as-delete: an audit log truncated to nothing is precisely the
32768
+ * state in which the next 9.5 GiB leak cannot be explained.
32769
+ */
32770
+ opsLogRetentionDays: number().int().min(0).max(3650).optional()
32475
32771
  });
32476
32772
  /**
32477
32773
  * Which LAYER of the hierarchy is addressed. Absent = the cluster layer.
@@ -32544,6 +32840,14 @@ var LoggingSettingsStateSchema = object({
32544
32840
  channels: array(LogChannelDescriptorSchema).readonly(),
32545
32841
  /** The channels ARMED right now, each with its deadline. */
32546
32842
  activeChannels: array(LogChannelWindowStateSchema).readonly(),
32843
+ /**
32844
+ * The ops-log window in days, as it is in force. `0` = kept forever.
32845
+ *
32846
+ * Reported rather than left to the caller's memory of what it wrote: this is
32847
+ * the value the analytics sweep will actually use, and an operator asking how
32848
+ * long their audit trail lives should not have to infer it from a default.
32849
+ */
32850
+ opsLogRetentionDays: number().int().min(0),
32547
32851
  persisted: boolean()
32548
32852
  });
32549
32853
  method(_void(), FeatureManifestSchema), method(_void(), HealthStatusSchema), method(_void(), FeatureManifestSchema), method(_void(), array(NetworkAddressSchema).readonly()), method(_void(), unknown().nullable(), { auth: "admin" }), method(record(string(), unknown()), _null(), {
@@ -33939,6 +34243,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
33939
34243
  smoke: smokeCapability,
33940
34244
  streamCatalog: streamCatalogCapability,
33941
34245
  streamParams: streamParamsCapability,
34246
+ streamSignals: streamSignalsCapability,
33942
34247
  switch: switchCapability,
33943
34248
  tamper: tamperCapability,
33944
34249
  temperatureSensor: temperatureSensorCapability,
@@ -38610,6 +38915,12 @@ Object.freeze({
38610
38915
  addonId: null,
38611
38916
  access: "view"
38612
38917
  },
38918
+ "pipelineAnalytics.listRecentSummaries": {
38919
+ capName: "pipeline-analytics",
38920
+ capScope: "device",
38921
+ addonId: null,
38922
+ access: "view"
38923
+ },
38613
38924
  "pipelineAnalytics.listRecentTracks": {
38614
38925
  capName: "pipeline-analytics",
38615
38926
  capScope: "device",
@@ -40572,6 +40883,12 @@ Object.freeze({
40572
40883
  addonId: null,
40573
40884
  access: "create"
40574
40885
  },
40886
+ "streamBroker.reportStreamSignal": {
40887
+ capName: "stream-broker",
40888
+ capScope: "system",
40889
+ addonId: null,
40890
+ access: "create"
40891
+ },
40575
40892
  "streamBroker.restartProfile": {
40576
40893
  capName: "stream-broker",
40577
40894
  capScope: "system",
@@ -40656,6 +40973,12 @@ Object.freeze({
40656
40973
  addonId: null,
40657
40974
  access: "create"
40658
40975
  },
40976
+ "streamSignals.listSignals": {
40977
+ capName: "stream-signals",
40978
+ capScope: "device",
40979
+ addonId: null,
40980
+ access: "view"
40981
+ },
40659
40982
  "switch.setState": {
40660
40983
  capName: "switch",
40661
40984
  capScope: "device",
@@ -42437,6 +42760,11 @@ Object.freeze({
42437
42760
  form: "single",
42438
42761
  optional: true
42439
42762
  }],
42763
+ "pipelineAnalytics.listRecentSummaries": [{
42764
+ name: "deviceIds",
42765
+ form: "array",
42766
+ optional: false
42767
+ }],
42440
42768
  "pipelineAnalytics.listRecentTracks": [{
42441
42769
  name: "deviceIds",
42442
42770
  form: "array",
@@ -43023,6 +43351,11 @@ Object.freeze({
43023
43351
  form: "single",
43024
43352
  optional: false
43025
43353
  }],
43354
+ "streamBroker.reportStreamSignal": [{
43355
+ name: "deviceId",
43356
+ form: "single",
43357
+ optional: false
43358
+ }],
43026
43359
  "streamBroker.restartProfile": [{
43027
43360
  name: "deviceId",
43028
43361
  form: "single",
package/dist/addon.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import net from "node:net";
2
- //#region ../types/dist/event-category-ZyX6jcse.mjs
2
+ //#region ../types/dist/event-category-BVDXG4tB.mjs
3
3
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
4
4
  EventCategory["SystemBoot"] = "system.boot";
5
5
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -616,6 +616,20 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
616
616
  * pull-reconcile from the provider's `getStatus` on reconnect. */
617
617
  EventCategory["MeshNetworkChanged"] = "network.mesh.changed";
618
618
  EventCategory["BackupCompleted"] = "backup.completed";
619
+ /**
620
+ * A whole backup RUN finished — every destination attempted, win or lose.
621
+ *
622
+ * `backup.completed` fires once per DESTINATION, which is the right grain for
623
+ * a progress UI and the wrong one for a notification: an operator with three
624
+ * destinations would be told three times. And a run where two of three
625
+ * destinations succeeded is not a clean success — a single "backup
626
+ * completed" that hid the failed one would be a lie, so the count of each is
627
+ * carried here and the message says both.
628
+ *
629
+ * Emitted by the backup orchestrator only after the destination loop, so a
630
+ * run that dies during the BUILD phase produces no completion at all.
631
+ */
632
+ EventCategory["BackupRunCompleted"] = "backup.run-completed";
619
633
  EventCategory["BackupRestored"] = "backup.restored";
620
634
  EventCategory["NotificationDispatched"] = "notification.dispatched";
621
635
  EventCategory["NotificationFailed"] = "notification.failed";
@@ -5346,7 +5360,7 @@ var ZodIssueCode = {
5346
5360
  var ZodFirstPartyTypeKind;
5347
5361
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5348
5362
  //#endregion
5349
- //#region ../types/dist/sleep-CnLyvg3w.mjs
5363
+ //#region ../types/dist/sleep-DEuj7E3j.mjs
5350
5364
  /**
5351
5365
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5352
5366
  * window to float samples (D455).
@@ -7375,7 +7389,23 @@ var EncodeProfileSchema = object({
7375
7389
  "zerolatency",
7376
7390
  "film",
7377
7391
  "animation"
7378
- ]).optional()
7392
+ ]).optional(),
7393
+ /**
7394
+ * ONE slice per access unit.
7395
+ *
7396
+ * `-tune zerolatency` turns on x264's sliced threads, and a frame then leaves
7397
+ * the encoder as five NAL slices that share one RTP timestamp and carry one
7398
+ * marker bit. A libwebrtc depacketiser sees five frame-starts and one
7399
+ * frame-end per frame: the first pictures render and the video then freezes
7400
+ * for good while the audio, on its own plane, plays on. Measured on this hub
7401
+ * 2026-09-13 against the Echo, and reduced to one slice by this flag alone.
7402
+ *
7403
+ * A NAMED field and not a raw flag, because {@link EgressEncodeSchema} omits
7404
+ * `outputArgs` on purpose: an opaque array is part of the sharing key, so two
7405
+ * consumers meaning the same thing spelled differently would stop sharing one
7406
+ * child. Absent means "whatever the encoder does" — today's behaviour.
7407
+ */
7408
+ singleSlicePerFrame: boolean().optional()
7379
7409
  }),
7380
7410
  audio: union([literal("passthrough"), object({
7381
7411
  codec: _enum([
@@ -7425,7 +7455,7 @@ var BASE_LIVE_EGRESS_PROFILE = {
7425
7455
  audio: "passthrough"
7426
7456
  };
7427
7457
  ({ ...BASE_LIVE_EGRESS_PROFILE }), { ...BASE_LIVE_EGRESS_PROFILE.video };
7428
- ({ ...BASE_LIVE_EGRESS_PROFILE });
7458
+ ({ ...BASE_LIVE_EGRESS_PROFILE }), { ...BASE_LIVE_EGRESS_PROFILE.video };
7429
7459
  /**
7430
7460
  * Deep wiring healthcheck — snapshot of active reachability probes across
7431
7461
  * every declared capability + widget of every installed plugin, on every
@@ -11506,6 +11536,72 @@ method(ListInputSchema, array(BrokerInfoSchema$1)), method(GetInputSchema, Broke
11506
11536
  auth: "admin"
11507
11537
  }), method(GetStateInputSchema, unknown().nullable()), method(_void(), RegistryStatusSchema);
11508
11538
  DeviceType.Camera;
11539
+ /**
11540
+ * The signals a device can emit to WAKE its own stream.
11541
+ *
11542
+ * A camera whose stream is built on demand sleeps until something asks for it,
11543
+ * and "something" cannot be a consumer that is merely attached — a Frigate-style
11544
+ * puller holds a session open for ever, and treating that as demand would keep
11545
+ * a battery camera awake for ever, which is the whole thing the battery is for
11546
+ * (D173). So the wake has to come from the CAMERA: an event it noticed by
11547
+ * itself, with no stream running.
11548
+ *
11549
+ * ## The vocabulary is the PROVIDER'S, not ours
11550
+ *
11551
+ * Like `consumables`, this cap declares no vocabulary of its own. A provider
11552
+ * names each signal with a `code` it chooses and a `label` an operator reads.
11553
+ * Reolink offers motion and camera-native detection; another provider may offer
11554
+ * a tamper, a doorbell press, a PIR, or something no camera in this fleet has
11555
+ * yet. A fixed enum here would mean every new signal is a framework release.
11556
+ *
11557
+ * It is deliberately NOT derived from the caps a device already binds. Whether
11558
+ * a camera CAN push firmware motion is expressed by `motionSources` containing
11559
+ * `'onboard'`, and whether it does AI on-camera by the `native-object-detection`
11560
+ * binding — but both answer "what drives the detection pipeline", which is a
11561
+ * different question from "what may wake a sleeping stream". A camera can do
11562
+ * the first and not be trusted with the second, and the operator picks per
11563
+ * camera. Two questions, two authorities.
11564
+ *
11565
+ * ## Availability is not permission
11566
+ *
11567
+ * `listSignals` says what the device CAN emit. Whether a given signal actually
11568
+ * wakes the stream is the operator's per-camera choice, held by the broker
11569
+ * alongside the cooldown — see the stream-broker cap's wake settings. A
11570
+ * provider declaring a signal is not a provider enabling it.
11571
+ */
11572
+ /** One signal a device can emit. */
11573
+ var StreamSignalSchema = object({
11574
+ /** Stable id chosen by the provider, e.g. `'motion'`, `'person'`, `'tamper'`. */
11575
+ code: string().min(1),
11576
+ /** What an operator reads in the picker. The provider's own wording. */
11577
+ label: string().min(1),
11578
+ /**
11579
+ * Whether the provider recommends this signal ON when a camera is first set
11580
+ * up. A provider knows which of its signals are cheap and reliable; an
11581
+ * operator should not have to discover that by trial. Reolink recommends
11582
+ * both of its own.
11583
+ */
11584
+ recommended: boolean()
11585
+ });
11586
+ var StreamSignalsStatusSchema = object({
11587
+ signals: array(StreamSignalSchema),
11588
+ lastFetchedAt: number()
11589
+ });
11590
+ var streamSignalsCapability = {
11591
+ name: "stream-signals",
11592
+ scope: "device",
11593
+ deviceNative: true,
11594
+ mode: "singleton",
11595
+ deviceTypes: Object.values(DeviceType),
11596
+ runtimeState: StreamSignalsStatusSchema,
11597
+ methods: {
11598
+ /**
11599
+ * What this device can emit. Empty is a valid and common answer — most
11600
+ * cameras have nothing to offer here, and an empty list is what makes the
11601
+ * broker's picker show nothing rather than a false choice.
11602
+ */
11603
+ listSignals: method(_void(), array(StreamSignalSchema).readonly()) }
11604
+ };
11509
11605
  /** Stream delivery format. (Relocated from the retired `streaming-engine` cap.) */
11510
11606
  var StreamFormatSchema = _enum([
11511
11607
  "webrtc",
@@ -11902,6 +11998,22 @@ var EgressTranscodeSchema = object({
11902
11998
  camStreamId: string().nullable()
11903
11999
  });
11904
12000
  method(object({
12001
+ deviceId: number().int().nonnegative(),
12002
+ /** The provider's signal code. */
12003
+ code: string().min(1),
12004
+ /** Ms epoch. Absent ⇒ now. */
12005
+ at: number().optional()
12006
+ }), object({
12007
+ /** Whether the broker acted on it, and if not, why. */
12008
+ accepted: boolean(),
12009
+ reason: _enum([
12010
+ "woke",
12011
+ "hold-extended",
12012
+ "not-enabled",
12013
+ "no-consumer",
12014
+ "unknown-code"
12015
+ ])
12016
+ }), { kind: "mutation" }), method(object({
11905
12017
  deviceId: number().int().nonnegative(),
11906
12018
  camStreamId: string().min(1),
11907
12019
  kind: CamStreamKindSchema,
@@ -12156,6 +12268,16 @@ var PickStreamRequirementsSchema = object({
12156
12268
  acceptCodecs: array(StreamCodecSchema).readonly().optional(),
12157
12269
  /** Minimum vertical resolution. Streams shorter than this are dropped. */
12158
12270
  minHeight: number().int().positive().optional(),
12271
+ /**
12272
+ * Maximum vertical resolution. Streams TALLER than this are dropped.
12273
+ *
12274
+ * A consumer can have a ceiling as real as its floor: Alexa documents
12275
+ * 480p to 1080p, and a 4K stream is as unusable to an Echo as a 360p one.
12276
+ * Without this the ceiling had to be re-implemented by every caller — and
12277
+ * one caller implementing it privately is how a second scoring authority
12278
+ * gets born.
12279
+ */
12280
+ maxHeight: number().int().positive().optional(),
12159
12281
  /** Minimum horizontal resolution. */
12160
12282
  minWidth: number().int().positive().optional(),
12161
12283
  /**
@@ -12172,7 +12294,22 @@ var PickStreamRequirementsSchema = object({
12172
12294
  * transcoded" guard: if the device is already serving the consumer's
12173
12295
  * codec end-to-end, there's nothing to optimise.
12174
12296
  */
12175
- requireSiblingCodec: array(StreamCodecSchema).readonly().optional()
12297
+ requireSiblingCodec: array(StreamCodecSchema).readonly().optional(),
12298
+ /**
12299
+ * Whether a stream the consumer CANNOT decode may still be picked, on the
12300
+ * understanding that it will be transcoded.
12301
+ *
12302
+ * Default `false` — today's behaviour, and the right one for a bypass
12303
+ * question ("is there a stream I can forward untouched?"). Set `true` to
12304
+ * ask the larger question: "what is the best stream for me, transcoding if
12305
+ * I must?" A stream that satisfies `acceptCodecs` always outranks one that
12306
+ * does not, so a passthrough is never lost to a transcode; the answer says
12307
+ * which it is in {@link PickedCamStreamSchema.transcodes}.
12308
+ *
12309
+ * This is what lets one picker serve both the bypass and the full source
12310
+ * choice, instead of a consumer scoring privately when the bypass misses.
12311
+ */
12312
+ allowTranscode: boolean().optional()
12176
12313
  }).readonly();
12177
12314
  var PickStreamPreferencesSchema = object({
12178
12315
  /**
@@ -12186,12 +12323,32 @@ var PickStreamPreferencesSchema = object({
12186
12323
  * picks the tallest stream; `'lowest'` picks the shortest (used by
12187
12324
  * memory-constrained consumers / Apple Home guest sessions).
12188
12325
  */
12189
- resolutionPreference: _enum(["highest", "lowest"]).optional()
12326
+ resolutionPreference: _enum(["highest", "lowest"]).optional(),
12327
+ /**
12328
+ * The height the consumer actually wants to DELIVER.
12329
+ *
12330
+ * Not a constraint — an ordering. With it set, the SMALLEST stream at or
12331
+ * above the target wins, and only if nothing reaches it does the tallest
12332
+ * take over. Pulling 1296 lines to draw 720 on a 1280x800 Echo panel costs
12333
+ * a decode and buys nothing, and `resolutionPreference: 'highest'` cannot
12334
+ * express that: it says "as big as possible", which is a different wish.
12335
+ *
12336
+ * Ignored when absent, so every existing caller keeps its ordering.
12337
+ */
12338
+ targetHeight: number().int().positive().optional()
12190
12339
  }).readonly();
12191
12340
  var PickedCamStreamSchema = object({
12192
12341
  camStreamId: string(),
12193
12342
  codec: string().optional(),
12194
12343
  resolution: CamStreamResolutionSchema.optional(),
12344
+ /**
12345
+ * Whether serving this stream requires a decode + re-encode.
12346
+ *
12347
+ * `false` is a stream the consumer can take as it stands. Only ever `true`
12348
+ * when the caller asked for it with `allowTranscode`, so a caller that did
12349
+ * not ask cannot be handed a cost it never agreed to pay.
12350
+ */
12351
+ transcodes: boolean(),
12195
12352
  /** One-line explanation of why this stream won — for logs / debug UI. */
12196
12353
  reason: string()
12197
12354
  });
@@ -16708,6 +16865,8 @@ var NcSystemEventKindSchema = _enum([
16708
16865
  "device-enabled",
16709
16866
  "device-battery-low",
16710
16867
  "device-battery-normal",
16868
+ "device-consumable-low",
16869
+ "device-consumable-normal",
16711
16870
  "stream-online",
16712
16871
  "stream-offline",
16713
16872
  "node-online",
@@ -16726,6 +16885,7 @@ var NcSystemEventKindSchema = _enum([
16726
16885
  "addon-updated",
16727
16886
  "server-updated",
16728
16887
  "export-completed",
16888
+ "backup-completed",
16729
16889
  "camera-online",
16730
16890
  "camera-offline",
16731
16891
  "camera-disabled",
@@ -20162,13 +20322,109 @@ var SummariesQueryInput = object({
20162
20322
  deviceIds: array(number()).min(1),
20163
20323
  since: number().optional(),
20164
20324
  until: number().optional(),
20165
- limit: number().int().min(1).max(200).default(50)
20325
+ limit: number().int().min(1).max(200).default(50),
20326
+ /** The same member-wise filter {@link listRecentSummaries} takes — one
20327
+ * meaning of "dog" on every summary surface. */
20328
+ classes: array(string().min(1).max(60)).max(40).optional()
20166
20329
  });
20167
- var SummariesPageSchema = object({ summaries: array(SummarySchema).readonly() });
20168
20330
  var SummaryDetailSchema = object({
20169
20331
  summary: SummarySchema,
20170
- /** Member track ids, in absorption order. */
20171
- trackIds: array(string()).readonly()
20332
+ /** Members in absorption order, oldest join first. */
20333
+ members: array(object({
20334
+ trackId: string(),
20335
+ /**
20336
+ * The track's class at the time it JOINED, or `null` when it was unresolved
20337
+ * and the track no longer exists to fill it.
20338
+ *
20339
+ * The join, not the latest opinion: class voting can re-decide a track's
20340
+ * class afterwards, and a group's composition is the history of who came
20341
+ * together. A consumer counts these to badge a thumbnail — "two people and a
20342
+ * dog" — rather than being handed a second, denormalised tally that would
20343
+ * drift from the members it claims to describe.
20344
+ */
20345
+ className: string().nullable(),
20346
+ /** `primary` is the one member that carries the group's identity. */
20347
+ role: _enum([
20348
+ "primary",
20349
+ "sibling",
20350
+ "child"
20351
+ ]).nullable(),
20352
+ joinedAt: number(),
20353
+ /** Tier 1 — the sub-class (`dog`, `van`), resolved from the member's track
20354
+ * at read time. Absent when nothing resolved, never an empty string. */
20355
+ label: string().optional(),
20356
+ /** Tier 2 — the instance: a person's name, a plate. Absent when the pipeline
20357
+ * recognised nobody, and absent for a member whose track has been pruned —
20358
+ * a thumbnail that names the wrong person is worse than one naming nobody. */
20359
+ subLabel: string().optional()
20360
+ })).readonly()
20361
+ });
20362
+ /**
20363
+ * What a LIST of groups carries: the envelope plus what it is MADE OF.
20364
+ *
20365
+ * Coarse on purpose — the operator's rule is "only the rough data on the list,
20366
+ * we extend when we notice we need more". Enough to draw the card ("two people
20367
+ * and a dog") and no more. The MEMBERS, their names and the per-member links
20368
+ * are on {@link getSummary}: shipping every member of every group so a client
20369
+ * can count them turns a page of two hundred groups into a thousand records to
20370
+ * draw two hundred badges.
20371
+ */
20372
+ var SummaryListItemSchema = object({
20373
+ summary: SummarySchema,
20374
+ /** Class counts, most numerous first; `className: null` is a member whose
20375
+ * class never resolved, counted so the counts add up to `memberCount`. */
20376
+ classes: array(object({
20377
+ className: string().nullable(),
20378
+ count: number().int().positive()
20379
+ })).readonly()
20380
+ });
20381
+ var SummariesPageSchema = object({ summaries: array(SummaryListItemSchema).readonly() });
20382
+ /**
20383
+ * The paged feed, deliberately the SAME shape as {@link RecentTracksQueryInput}.
20384
+ *
20385
+ * The reel on the cameras page and the Events gallery both ride a cursor, so a
20386
+ * summaries feed that could only answer "the last N for these cameras"
20387
+ * (`listSummaries`) would make groups available in the timeline and nowhere
20388
+ * else. Two feeds with different ordering contracts would be two ideas of what
20389
+ * "newest" means, on one screen.
20390
+ */
20391
+ var RecentSummariesQueryInput = object({
20392
+ /** Devices to merge. An empty array yields an empty page. */
20393
+ deviceIds: array(number()),
20394
+ /** Window lower bound on `lastActiveAt` (inclusive). */
20395
+ since: number().optional(),
20396
+ /** Window upper bound on `lastActiveAt` (inclusive). */
20397
+ until: number().optional(),
20398
+ limit: number().int().min(1).max(500).default(100),
20399
+ /** Opaque continuation cursor from a previous page's `nextCursor`. */
20400
+ cursor: string().optional(),
20401
+ /**
20402
+ * Restrict to these classes — THE SAME FIELD `listRecentTracks` takes, and
20403
+ * deliberately the same name: the events filter tree emits one list of ticked
20404
+ * taxonomy nodes, and a summaries feed that called it something else would
20405
+ * make the operator's one filter component produce two shapes.
20406
+ *
20407
+ * A question about the MEMBERS: a group matches when ANY of them does. "Show
20408
+ * me the arrivals with a dog" has to return the group of four people who had
20409
+ * one with them; a filter on the group's own fields could only ever answer
20410
+ * about its primary.
20411
+ *
20412
+ * Matched against all THREE tiers of a member — the class (`animal`), the
20413
+ * sub-class (`dog`) and the instance (a name, a plate) — because which tier a
20414
+ * ticked node lives on is the taxonomy's business, not the caller's. `dog` is
20415
+ * an event kind in the tree and a tier-1 label on an `animal` track; a filter
20416
+ * that read only the class would answer "animal" and never "dog".
20417
+ *
20418
+ * ABSENT or EMPTY means no filter — absent is not a selection of none.
20419
+ */
20420
+ classes: array(string().min(1).max(60)).max(40).optional()
20421
+ });
20422
+ var RecentSummariesPageSchema = object({
20423
+ /** Ordered by (`lastActiveAt` DESC, id DESC). Same light item as
20424
+ * {@link listSummaries} — one list shape, so a card renders the same
20425
+ * whichever feed drew it. */
20426
+ summaries: array(SummaryListItemSchema).readonly(),
20427
+ nextCursor: string().nullable()
20172
20428
  });
20173
20429
  var RecentTracksPageSchema = object({
20174
20430
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
@@ -20582,7 +20838,7 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
20582
20838
  classes: array(string()).optional(),
20583
20839
  /** See {@link ExcludeSourcesDoc}. */
20584
20840
  excludeSources: array(TrackSourceSchema).optional()
20585
- }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20841
+ }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(RecentSummariesQueryInput, RecentSummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20586
20842
  kind: "mutation",
20587
20843
  auth: "admin"
20588
20844
  }), method(DeviceEventQueryInput, array(MotionEventSchema).readonly()), method(ObjectEventQueryInput, array(ObjectEventSchema).readonly()), method(DeviceEventQueryInput, array(AudioEventSchema).readonly()), method(object({ deviceId: number() }), array(EventKindDescriptorSchema).readonly()), method(object({ deviceIds: array(number()).min(1).max(200) }), array(EventKindsForDeviceSchema).readonly()), method(object({
@@ -24015,10 +24271,28 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
24015
24271
  }), boolean()), method(object({
24016
24272
  deviceId: number().int().nonnegative(),
24017
24273
  sessionId: string()
24018
- }), object({ pendingRenegotiation: object({
24019
- target: WebrtcStreamTargetSchema,
24020
- epoch: number()
24021
- }).nullable() }));
24274
+ }), object({
24275
+ pendingRenegotiation: object({
24276
+ target: WebrtcStreamTargetSchema,
24277
+ epoch: number()
24278
+ }).nullable(),
24279
+ /**
24280
+ * Whether the session still EXISTS.
24281
+ *
24282
+ * A consumer that holds a resource for the life of a session needs to
24283
+ * be able to ask, because a session does not always end the way it
24284
+ * began. Measured on this hub 2026-09-13: an Echo that got stuck never
24285
+ * sent `SessionDisconnected`, so the Alexa exporter's
24286
+ * `releaseEgressTranscode` never ran, and a 2304x1296 HEVC to 720p
24287
+ * H.264 transcode kept running for NOBODY for more than twenty
24288
+ * minutes. The WebRTC session had logged `WebRTC session closed`
24289
+ * minutes earlier — the broker knew; the holder had no way to ask.
24290
+ *
24291
+ * `false` for a session id the provider has never heard of, which is
24292
+ * the same answer as "it ended": either way nothing is holding it up.
24293
+ */
24294
+ alive: boolean()
24295
+ }));
24022
24296
  object({
24023
24297
  /** All accessory children of the parent. */
24024
24298
  childDeviceIds: array(number()).readonly(),
@@ -32447,7 +32721,29 @@ var LoggingSettingsPatchSchema = object({
32447
32721
  * disarmed the channels it did not mention would make the Levels page and
32448
32722
  * the Diagnostics page fight over the same value.
32449
32723
  */
32450
- channels: array(LogChannelWindowPatchSchema).readonly().optional()
32724
+ channels: array(LogChannelWindowPatchSchema).readonly().optional(),
32725
+ /**
32726
+ * How many days the analytics OPS LOG is kept — the audit trail of what
32727
+ * retention actually deleted.
32728
+ *
32729
+ * It lives HERE, on the logging document, and not on the analytics addon's
32730
+ * settings form, on the operator's instruction: every other log-ish window in
32731
+ * this system is configured through this one document, and a retention audit
32732
+ * configured somewhere else is a second place to look when the question is
32733
+ * "what happened to my data".
32734
+ *
32735
+ * That placement has a cost worth stating: this document ships in the
32736
+ * framework closure, so this knob needs a published `@camstack/server` while
32737
+ * the four windows beside it (D485) reach a node on `camstack deploy`.
32738
+ *
32739
+ * `retention-model.ts` argued this one must NOT follow a device window,
32740
+ * because the audit trail is the history of the SWEEP and not of the camera.
32741
+ * That argument stands and is untouched — what changes is that 30 days stops
32742
+ * being a constant nobody can reach. `0` keeps it forever. The floor is 1 day
32743
+ * rather than 0-as-delete: an audit log truncated to nothing is precisely the
32744
+ * state in which the next 9.5 GiB leak cannot be explained.
32745
+ */
32746
+ opsLogRetentionDays: number().int().min(0).max(3650).optional()
32451
32747
  });
32452
32748
  /**
32453
32749
  * Which LAYER of the hierarchy is addressed. Absent = the cluster layer.
@@ -32520,6 +32816,14 @@ var LoggingSettingsStateSchema = object({
32520
32816
  channels: array(LogChannelDescriptorSchema).readonly(),
32521
32817
  /** The channels ARMED right now, each with its deadline. */
32522
32818
  activeChannels: array(LogChannelWindowStateSchema).readonly(),
32819
+ /**
32820
+ * The ops-log window in days, as it is in force. `0` = kept forever.
32821
+ *
32822
+ * Reported rather than left to the caller's memory of what it wrote: this is
32823
+ * the value the analytics sweep will actually use, and an operator asking how
32824
+ * long their audit trail lives should not have to infer it from a default.
32825
+ */
32826
+ opsLogRetentionDays: number().int().min(0),
32523
32827
  persisted: boolean()
32524
32828
  });
32525
32829
  method(_void(), FeatureManifestSchema), method(_void(), HealthStatusSchema), method(_void(), FeatureManifestSchema), method(_void(), array(NetworkAddressSchema).readonly()), method(_void(), unknown().nullable(), { auth: "admin" }), method(record(string(), unknown()), _null(), {
@@ -33915,6 +34219,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
33915
34219
  smoke: smokeCapability,
33916
34220
  streamCatalog: streamCatalogCapability,
33917
34221
  streamParams: streamParamsCapability,
34222
+ streamSignals: streamSignalsCapability,
33918
34223
  switch: switchCapability,
33919
34224
  tamper: tamperCapability,
33920
34225
  temperatureSensor: temperatureSensorCapability,
@@ -38586,6 +38891,12 @@ Object.freeze({
38586
38891
  addonId: null,
38587
38892
  access: "view"
38588
38893
  },
38894
+ "pipelineAnalytics.listRecentSummaries": {
38895
+ capName: "pipeline-analytics",
38896
+ capScope: "device",
38897
+ addonId: null,
38898
+ access: "view"
38899
+ },
38589
38900
  "pipelineAnalytics.listRecentTracks": {
38590
38901
  capName: "pipeline-analytics",
38591
38902
  capScope: "device",
@@ -40548,6 +40859,12 @@ Object.freeze({
40548
40859
  addonId: null,
40549
40860
  access: "create"
40550
40861
  },
40862
+ "streamBroker.reportStreamSignal": {
40863
+ capName: "stream-broker",
40864
+ capScope: "system",
40865
+ addonId: null,
40866
+ access: "create"
40867
+ },
40551
40868
  "streamBroker.restartProfile": {
40552
40869
  capName: "stream-broker",
40553
40870
  capScope: "system",
@@ -40632,6 +40949,12 @@ Object.freeze({
40632
40949
  addonId: null,
40633
40950
  access: "create"
40634
40951
  },
40952
+ "streamSignals.listSignals": {
40953
+ capName: "stream-signals",
40954
+ capScope: "device",
40955
+ addonId: null,
40956
+ access: "view"
40957
+ },
40635
40958
  "switch.setState": {
40636
40959
  capName: "switch",
40637
40960
  capScope: "device",
@@ -42413,6 +42736,11 @@ Object.freeze({
42413
42736
  form: "single",
42414
42737
  optional: true
42415
42738
  }],
42739
+ "pipelineAnalytics.listRecentSummaries": [{
42740
+ name: "deviceIds",
42741
+ form: "array",
42742
+ optional: false
42743
+ }],
42416
42744
  "pipelineAnalytics.listRecentTracks": [{
42417
42745
  name: "deviceIds",
42418
42746
  form: "array",
@@ -42999,6 +43327,11 @@ Object.freeze({
42999
43327
  form: "single",
43000
43328
  optional: false
43001
43329
  }],
43330
+ "streamBroker.reportStreamSignal": [{
43331
+ name: "deviceId",
43332
+ form: "single",
43333
+ optional: false
43334
+ }],
43002
43335
  "streamBroker.restartProfile": [{
43003
43336
  name: "deviceId",
43004
43337
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-rtsp",
3
- "version": "1.2.100",
3
+ "version": "1.2.102",
4
4
  "description": "Generic RTSP camera device provider addon for CamStack",
5
5
  "keywords": [
6
6
  "camstack",