@camstack/addon-provider-onvif 1.2.99 → 1.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.
Files changed (3) hide show
  1. package/dist/addon.js +334 -16
  2. package/dist/addon.mjs +334 -16
  3. package/package.json +1 -1
package/dist/addon.js CHANGED
@@ -2,7 +2,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  //#region \0rolldown/runtime.js
3
3
  var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
4
4
  //#endregion
5
- //#region ../types/dist/event-category-ZyX6jcse.mjs
5
+ //#region ../types/dist/event-category-BVDXG4tB.mjs
6
6
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
7
7
  EventCategory["SystemBoot"] = "system.boot";
8
8
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -619,6 +619,20 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
619
619
  * pull-reconcile from the provider's `getStatus` on reconnect. */
620
620
  EventCategory["MeshNetworkChanged"] = "network.mesh.changed";
621
621
  EventCategory["BackupCompleted"] = "backup.completed";
622
+ /**
623
+ * A whole backup RUN finished — every destination attempted, win or lose.
624
+ *
625
+ * `backup.completed` fires once per DESTINATION, which is the right grain for
626
+ * a progress UI and the wrong one for a notification: an operator with three
627
+ * destinations would be told three times. And a run where two of three
628
+ * destinations succeeded is not a clean success — a single "backup
629
+ * completed" that hid the failed one would be a lie, so the count of each is
630
+ * carried here and the message says both.
631
+ *
632
+ * Emitted by the backup orchestrator only after the destination loop, so a
633
+ * run that dies during the BUILD phase produces no completion at all.
634
+ */
635
+ EventCategory["BackupRunCompleted"] = "backup.run-completed";
622
636
  EventCategory["BackupRestored"] = "backup.restored";
623
637
  EventCategory["NotificationDispatched"] = "notification.dispatched";
624
638
  EventCategory["NotificationFailed"] = "notification.failed";
@@ -5349,7 +5363,7 @@ var ZodIssueCode = {
5349
5363
  var ZodFirstPartyTypeKind;
5350
5364
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5351
5365
  //#endregion
5352
- //#region ../types/dist/sleep-CnLyvg3w.mjs
5366
+ //#region ../types/dist/sleep-DEuj7E3j.mjs
5353
5367
  /**
5354
5368
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5355
5369
  * window to float samples (D455).
@@ -7374,7 +7388,23 @@ var EncodeProfileSchema = object({
7374
7388
  "zerolatency",
7375
7389
  "film",
7376
7390
  "animation"
7377
- ]).optional()
7391
+ ]).optional(),
7392
+ /**
7393
+ * ONE slice per access unit.
7394
+ *
7395
+ * `-tune zerolatency` turns on x264's sliced threads, and a frame then leaves
7396
+ * the encoder as five NAL slices that share one RTP timestamp and carry one
7397
+ * marker bit. A libwebrtc depacketiser sees five frame-starts and one
7398
+ * frame-end per frame: the first pictures render and the video then freezes
7399
+ * for good while the audio, on its own plane, plays on. Measured on this hub
7400
+ * 2026-09-13 against the Echo, and reduced to one slice by this flag alone.
7401
+ *
7402
+ * A NAMED field and not a raw flag, because {@link EgressEncodeSchema} omits
7403
+ * `outputArgs` on purpose: an opaque array is part of the sharing key, so two
7404
+ * consumers meaning the same thing spelled differently would stop sharing one
7405
+ * child. Absent means "whatever the encoder does" — today's behaviour.
7406
+ */
7407
+ singleSlicePerFrame: boolean().optional()
7378
7408
  }),
7379
7409
  audio: union([literal("passthrough"), object({
7380
7410
  codec: _enum([
@@ -7424,7 +7454,7 @@ var BASE_LIVE_EGRESS_PROFILE = {
7424
7454
  audio: "passthrough"
7425
7455
  };
7426
7456
  ({ ...BASE_LIVE_EGRESS_PROFILE }), { ...BASE_LIVE_EGRESS_PROFILE.video };
7427
- ({ ...BASE_LIVE_EGRESS_PROFILE });
7457
+ ({ ...BASE_LIVE_EGRESS_PROFILE }), { ...BASE_LIVE_EGRESS_PROFILE.video };
7428
7458
  /**
7429
7459
  * Deep wiring healthcheck — snapshot of active reachability probes across
7430
7460
  * every declared capability + widget of every installed plugin, on every
@@ -11473,6 +11503,58 @@ method(ListInputSchema, array(BrokerInfoSchema$1)), method(GetInputSchema, Broke
11473
11503
  auth: "admin"
11474
11504
  }), method(GetStateInputSchema, unknown().nullable()), method(_void(), RegistryStatusSchema);
11475
11505
  DeviceType.Camera;
11506
+ /**
11507
+ * The signals a device can emit to WAKE its own stream.
11508
+ *
11509
+ * A camera whose stream is built on demand sleeps until something asks for it,
11510
+ * and "something" cannot be a consumer that is merely attached — a Frigate-style
11511
+ * puller holds a session open for ever, and treating that as demand would keep
11512
+ * a battery camera awake for ever, which is the whole thing the battery is for
11513
+ * (D173). So the wake has to come from the CAMERA: an event it noticed by
11514
+ * itself, with no stream running.
11515
+ *
11516
+ * ## The vocabulary is the PROVIDER'S, not ours
11517
+ *
11518
+ * Like `consumables`, this cap declares no vocabulary of its own. A provider
11519
+ * names each signal with a `code` it chooses and a `label` an operator reads.
11520
+ * Reolink offers motion and camera-native detection; another provider may offer
11521
+ * a tamper, a doorbell press, a PIR, or something no camera in this fleet has
11522
+ * yet. A fixed enum here would mean every new signal is a framework release.
11523
+ *
11524
+ * It is deliberately NOT derived from the caps a device already binds. Whether
11525
+ * a camera CAN push firmware motion is expressed by `motionSources` containing
11526
+ * `'onboard'`, and whether it does AI on-camera by the `native-object-detection`
11527
+ * binding — but both answer "what drives the detection pipeline", which is a
11528
+ * different question from "what may wake a sleeping stream". A camera can do
11529
+ * the first and not be trusted with the second, and the operator picks per
11530
+ * camera. Two questions, two authorities.
11531
+ *
11532
+ * ## Availability is not permission
11533
+ *
11534
+ * `listSignals` says what the device CAN emit. Whether a given signal actually
11535
+ * wakes the stream is the operator's per-camera choice, held by the broker
11536
+ * alongside the cooldown — see the stream-broker cap's wake settings. A
11537
+ * provider declaring a signal is not a provider enabling it.
11538
+ */
11539
+ /** One signal a device can emit. */
11540
+ var StreamSignalSchema = object({
11541
+ /** Stable id chosen by the provider, e.g. `'motion'`, `'person'`, `'tamper'`. */
11542
+ code: string().min(1),
11543
+ /** What an operator reads in the picker. The provider's own wording. */
11544
+ label: string().min(1),
11545
+ /**
11546
+ * Whether the provider recommends this signal ON when a camera is first set
11547
+ * up. A provider knows which of its signals are cheap and reliable; an
11548
+ * operator should not have to discover that by trial. Reolink recommends
11549
+ * both of its own.
11550
+ */
11551
+ recommended: boolean()
11552
+ });
11553
+ object({
11554
+ signals: array(StreamSignalSchema),
11555
+ lastFetchedAt: number()
11556
+ });
11557
+ Object.values(DeviceType), method(_void(), array(StreamSignalSchema).readonly());
11476
11558
  /** Stream delivery format. (Relocated from the retired `streaming-engine` cap.) */
11477
11559
  var StreamFormatSchema = _enum([
11478
11560
  "webrtc",
@@ -11869,6 +11951,22 @@ var EgressTranscodeSchema = object({
11869
11951
  camStreamId: string().nullable()
11870
11952
  });
11871
11953
  method(object({
11954
+ deviceId: number().int().nonnegative(),
11955
+ /** The provider's signal code. */
11956
+ code: string().min(1),
11957
+ /** Ms epoch. Absent ⇒ now. */
11958
+ at: number().optional()
11959
+ }), object({
11960
+ /** Whether the broker acted on it, and if not, why. */
11961
+ accepted: boolean(),
11962
+ reason: _enum([
11963
+ "woke",
11964
+ "hold-extended",
11965
+ "not-enabled",
11966
+ "no-consumer",
11967
+ "unknown-code"
11968
+ ])
11969
+ }), { kind: "mutation" }), method(object({
11872
11970
  deviceId: number().int().nonnegative(),
11873
11971
  camStreamId: string().min(1),
11874
11972
  kind: CamStreamKindSchema,
@@ -12123,6 +12221,16 @@ var PickStreamRequirementsSchema = object({
12123
12221
  acceptCodecs: array(StreamCodecSchema).readonly().optional(),
12124
12222
  /** Minimum vertical resolution. Streams shorter than this are dropped. */
12125
12223
  minHeight: number().int().positive().optional(),
12224
+ /**
12225
+ * Maximum vertical resolution. Streams TALLER than this are dropped.
12226
+ *
12227
+ * A consumer can have a ceiling as real as its floor: Alexa documents
12228
+ * 480p to 1080p, and a 4K stream is as unusable to an Echo as a 360p one.
12229
+ * Without this the ceiling had to be re-implemented by every caller — and
12230
+ * one caller implementing it privately is how a second scoring authority
12231
+ * gets born.
12232
+ */
12233
+ maxHeight: number().int().positive().optional(),
12126
12234
  /** Minimum horizontal resolution. */
12127
12235
  minWidth: number().int().positive().optional(),
12128
12236
  /**
@@ -12139,7 +12247,22 @@ var PickStreamRequirementsSchema = object({
12139
12247
  * transcoded" guard: if the device is already serving the consumer's
12140
12248
  * codec end-to-end, there's nothing to optimise.
12141
12249
  */
12142
- requireSiblingCodec: array(StreamCodecSchema).readonly().optional()
12250
+ requireSiblingCodec: array(StreamCodecSchema).readonly().optional(),
12251
+ /**
12252
+ * Whether a stream the consumer CANNOT decode may still be picked, on the
12253
+ * understanding that it will be transcoded.
12254
+ *
12255
+ * Default `false` — today's behaviour, and the right one for a bypass
12256
+ * question ("is there a stream I can forward untouched?"). Set `true` to
12257
+ * ask the larger question: "what is the best stream for me, transcoding if
12258
+ * I must?" A stream that satisfies `acceptCodecs` always outranks one that
12259
+ * does not, so a passthrough is never lost to a transcode; the answer says
12260
+ * which it is in {@link PickedCamStreamSchema.transcodes}.
12261
+ *
12262
+ * This is what lets one picker serve both the bypass and the full source
12263
+ * choice, instead of a consumer scoring privately when the bypass misses.
12264
+ */
12265
+ allowTranscode: boolean().optional()
12143
12266
  }).readonly();
12144
12267
  var PickStreamPreferencesSchema = object({
12145
12268
  /**
@@ -12153,12 +12276,32 @@ var PickStreamPreferencesSchema = object({
12153
12276
  * picks the tallest stream; `'lowest'` picks the shortest (used by
12154
12277
  * memory-constrained consumers / Apple Home guest sessions).
12155
12278
  */
12156
- resolutionPreference: _enum(["highest", "lowest"]).optional()
12279
+ resolutionPreference: _enum(["highest", "lowest"]).optional(),
12280
+ /**
12281
+ * The height the consumer actually wants to DELIVER.
12282
+ *
12283
+ * Not a constraint — an ordering. With it set, the SMALLEST stream at or
12284
+ * above the target wins, and only if nothing reaches it does the tallest
12285
+ * take over. Pulling 1296 lines to draw 720 on a 1280x800 Echo panel costs
12286
+ * a decode and buys nothing, and `resolutionPreference: 'highest'` cannot
12287
+ * express that: it says "as big as possible", which is a different wish.
12288
+ *
12289
+ * Ignored when absent, so every existing caller keeps its ordering.
12290
+ */
12291
+ targetHeight: number().int().positive().optional()
12157
12292
  }).readonly();
12158
12293
  var PickedCamStreamSchema = object({
12159
12294
  camStreamId: string(),
12160
12295
  codec: string().optional(),
12161
12296
  resolution: CamStreamResolutionSchema.optional(),
12297
+ /**
12298
+ * Whether serving this stream requires a decode + re-encode.
12299
+ *
12300
+ * `false` is a stream the consumer can take as it stands. Only ever `true`
12301
+ * when the caller asked for it with `allowTranscode`, so a caller that did
12302
+ * not ask cannot be handed a cost it never agreed to pay.
12303
+ */
12304
+ transcodes: boolean(),
12162
12305
  /** One-line explanation of why this stream won — for logs / debug UI. */
12163
12306
  reason: string()
12164
12307
  });
@@ -16428,6 +16571,8 @@ var NcSystemEventKindSchema = _enum([
16428
16571
  "device-enabled",
16429
16572
  "device-battery-low",
16430
16573
  "device-battery-normal",
16574
+ "device-consumable-low",
16575
+ "device-consumable-normal",
16431
16576
  "stream-online",
16432
16577
  "stream-offline",
16433
16578
  "node-online",
@@ -16446,6 +16591,7 @@ var NcSystemEventKindSchema = _enum([
16446
16591
  "addon-updated",
16447
16592
  "server-updated",
16448
16593
  "export-completed",
16594
+ "backup-completed",
16449
16595
  "camera-online",
16450
16596
  "camera-offline",
16451
16597
  "camera-disabled",
@@ -19842,13 +19988,109 @@ var SummariesQueryInput = object({
19842
19988
  deviceIds: array(number()).min(1),
19843
19989
  since: number().optional(),
19844
19990
  until: number().optional(),
19845
- limit: number().int().min(1).max(200).default(50)
19991
+ limit: number().int().min(1).max(200).default(50),
19992
+ /** The same member-wise filter {@link listRecentSummaries} takes — one
19993
+ * meaning of "dog" on every summary surface. */
19994
+ classes: array(string().min(1).max(60)).max(40).optional()
19846
19995
  });
19847
- var SummariesPageSchema = object({ summaries: array(SummarySchema).readonly() });
19848
19996
  var SummaryDetailSchema = object({
19849
19997
  summary: SummarySchema,
19850
- /** Member track ids, in absorption order. */
19851
- trackIds: array(string()).readonly()
19998
+ /** Members in absorption order, oldest join first. */
19999
+ members: array(object({
20000
+ trackId: string(),
20001
+ /**
20002
+ * The track's class at the time it JOINED, or `null` when it was unresolved
20003
+ * and the track no longer exists to fill it.
20004
+ *
20005
+ * The join, not the latest opinion: class voting can re-decide a track's
20006
+ * class afterwards, and a group's composition is the history of who came
20007
+ * together. A consumer counts these to badge a thumbnail — "two people and a
20008
+ * dog" — rather than being handed a second, denormalised tally that would
20009
+ * drift from the members it claims to describe.
20010
+ */
20011
+ className: string().nullable(),
20012
+ /** `primary` is the one member that carries the group's identity. */
20013
+ role: _enum([
20014
+ "primary",
20015
+ "sibling",
20016
+ "child"
20017
+ ]).nullable(),
20018
+ joinedAt: number(),
20019
+ /** Tier 1 — the sub-class (`dog`, `van`), resolved from the member's track
20020
+ * at read time. Absent when nothing resolved, never an empty string. */
20021
+ label: string().optional(),
20022
+ /** Tier 2 — the instance: a person's name, a plate. Absent when the pipeline
20023
+ * recognised nobody, and absent for a member whose track has been pruned —
20024
+ * a thumbnail that names the wrong person is worse than one naming nobody. */
20025
+ subLabel: string().optional()
20026
+ })).readonly()
20027
+ });
20028
+ /**
20029
+ * What a LIST of groups carries: the envelope plus what it is MADE OF.
20030
+ *
20031
+ * Coarse on purpose — the operator's rule is "only the rough data on the list,
20032
+ * we extend when we notice we need more". Enough to draw the card ("two people
20033
+ * and a dog") and no more. The MEMBERS, their names and the per-member links
20034
+ * are on {@link getSummary}: shipping every member of every group so a client
20035
+ * can count them turns a page of two hundred groups into a thousand records to
20036
+ * draw two hundred badges.
20037
+ */
20038
+ var SummaryListItemSchema = object({
20039
+ summary: SummarySchema,
20040
+ /** Class counts, most numerous first; `className: null` is a member whose
20041
+ * class never resolved, counted so the counts add up to `memberCount`. */
20042
+ classes: array(object({
20043
+ className: string().nullable(),
20044
+ count: number().int().positive()
20045
+ })).readonly()
20046
+ });
20047
+ var SummariesPageSchema = object({ summaries: array(SummaryListItemSchema).readonly() });
20048
+ /**
20049
+ * The paged feed, deliberately the SAME shape as {@link RecentTracksQueryInput}.
20050
+ *
20051
+ * The reel on the cameras page and the Events gallery both ride a cursor, so a
20052
+ * summaries feed that could only answer "the last N for these cameras"
20053
+ * (`listSummaries`) would make groups available in the timeline and nowhere
20054
+ * else. Two feeds with different ordering contracts would be two ideas of what
20055
+ * "newest" means, on one screen.
20056
+ */
20057
+ var RecentSummariesQueryInput = object({
20058
+ /** Devices to merge. An empty array yields an empty page. */
20059
+ deviceIds: array(number()),
20060
+ /** Window lower bound on `lastActiveAt` (inclusive). */
20061
+ since: number().optional(),
20062
+ /** Window upper bound on `lastActiveAt` (inclusive). */
20063
+ until: number().optional(),
20064
+ limit: number().int().min(1).max(500).default(100),
20065
+ /** Opaque continuation cursor from a previous page's `nextCursor`. */
20066
+ cursor: string().optional(),
20067
+ /**
20068
+ * Restrict to these classes — THE SAME FIELD `listRecentTracks` takes, and
20069
+ * deliberately the same name: the events filter tree emits one list of ticked
20070
+ * taxonomy nodes, and a summaries feed that called it something else would
20071
+ * make the operator's one filter component produce two shapes.
20072
+ *
20073
+ * A question about the MEMBERS: a group matches when ANY of them does. "Show
20074
+ * me the arrivals with a dog" has to return the group of four people who had
20075
+ * one with them; a filter on the group's own fields could only ever answer
20076
+ * about its primary.
20077
+ *
20078
+ * Matched against all THREE tiers of a member — the class (`animal`), the
20079
+ * sub-class (`dog`) and the instance (a name, a plate) — because which tier a
20080
+ * ticked node lives on is the taxonomy's business, not the caller's. `dog` is
20081
+ * an event kind in the tree and a tier-1 label on an `animal` track; a filter
20082
+ * that read only the class would answer "animal" and never "dog".
20083
+ *
20084
+ * ABSENT or EMPTY means no filter — absent is not a selection of none.
20085
+ */
20086
+ classes: array(string().min(1).max(60)).max(40).optional()
20087
+ });
20088
+ var RecentSummariesPageSchema = object({
20089
+ /** Ordered by (`lastActiveAt` DESC, id DESC). Same light item as
20090
+ * {@link listSummaries} — one list shape, so a card renders the same
20091
+ * whichever feed drew it. */
20092
+ summaries: array(SummaryListItemSchema).readonly(),
20093
+ nextCursor: string().nullable()
19852
20094
  });
19853
20095
  var RecentTracksPageSchema = object({
19854
20096
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
@@ -20262,7 +20504,7 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
20262
20504
  classes: array(string()).optional(),
20263
20505
  /** See {@link ExcludeSourcesDoc}. */
20264
20506
  excludeSources: array(TrackSourceSchema).optional()
20265
- }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20507
+ }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(RecentSummariesQueryInput, RecentSummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20266
20508
  kind: "mutation",
20267
20509
  auth: "admin"
20268
20510
  }), 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({
@@ -23695,10 +23937,28 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
23695
23937
  }), boolean()), method(object({
23696
23938
  deviceId: number().int().nonnegative(),
23697
23939
  sessionId: string()
23698
- }), object({ pendingRenegotiation: object({
23699
- target: WebrtcStreamTargetSchema,
23700
- epoch: number()
23701
- }).nullable() }));
23940
+ }), object({
23941
+ pendingRenegotiation: object({
23942
+ target: WebrtcStreamTargetSchema,
23943
+ epoch: number()
23944
+ }).nullable(),
23945
+ /**
23946
+ * Whether the session still EXISTS.
23947
+ *
23948
+ * A consumer that holds a resource for the life of a session needs to
23949
+ * be able to ask, because a session does not always end the way it
23950
+ * began. Measured on this hub 2026-09-13: an Echo that got stuck never
23951
+ * sent `SessionDisconnected`, so the Alexa exporter's
23952
+ * `releaseEgressTranscode` never ran, and a 2304x1296 HEVC to 720p
23953
+ * H.264 transcode kept running for NOBODY for more than twenty
23954
+ * minutes. The WebRTC session had logged `WebRTC session closed`
23955
+ * minutes earlier — the broker knew; the holder had no way to ask.
23956
+ *
23957
+ * `false` for a session id the provider has never heard of, which is
23958
+ * the same answer as "it ended": either way nothing is holding it up.
23959
+ */
23960
+ alive: boolean()
23961
+ }));
23702
23962
  object({
23703
23963
  /** All accessory children of the parent. */
23704
23964
  childDeviceIds: array(number()).readonly(),
@@ -30014,7 +30274,29 @@ var LoggingSettingsPatchSchema = object({
30014
30274
  * disarmed the channels it did not mention would make the Levels page and
30015
30275
  * the Diagnostics page fight over the same value.
30016
30276
  */
30017
- channels: array(LogChannelWindowPatchSchema).readonly().optional()
30277
+ channels: array(LogChannelWindowPatchSchema).readonly().optional(),
30278
+ /**
30279
+ * How many days the analytics OPS LOG is kept — the audit trail of what
30280
+ * retention actually deleted.
30281
+ *
30282
+ * It lives HERE, on the logging document, and not on the analytics addon's
30283
+ * settings form, on the operator's instruction: every other log-ish window in
30284
+ * this system is configured through this one document, and a retention audit
30285
+ * configured somewhere else is a second place to look when the question is
30286
+ * "what happened to my data".
30287
+ *
30288
+ * That placement has a cost worth stating: this document ships in the
30289
+ * framework closure, so this knob needs a published `@camstack/server` while
30290
+ * the four windows beside it (D485) reach a node on `camstack deploy`.
30291
+ *
30292
+ * `retention-model.ts` argued this one must NOT follow a device window,
30293
+ * because the audit trail is the history of the SWEEP and not of the camera.
30294
+ * That argument stands and is untouched — what changes is that 30 days stops
30295
+ * being a constant nobody can reach. `0` keeps it forever. The floor is 1 day
30296
+ * rather than 0-as-delete: an audit log truncated to nothing is precisely the
30297
+ * state in which the next 9.5 GiB leak cannot be explained.
30298
+ */
30299
+ opsLogRetentionDays: number().int().min(0).max(3650).optional()
30018
30300
  });
30019
30301
  /**
30020
30302
  * Which LAYER of the hierarchy is addressed. Absent = the cluster layer.
@@ -30087,6 +30369,14 @@ var LoggingSettingsStateSchema = object({
30087
30369
  channels: array(LogChannelDescriptorSchema).readonly(),
30088
30370
  /** The channels ARMED right now, each with its deadline. */
30089
30371
  activeChannels: array(LogChannelWindowStateSchema).readonly(),
30372
+ /**
30373
+ * The ops-log window in days, as it is in force. `0` = kept forever.
30374
+ *
30375
+ * Reported rather than left to the caller's memory of what it wrote: this is
30376
+ * the value the analytics sweep will actually use, and an operator asking how
30377
+ * long their audit trail lives should not have to infer it from a default.
30378
+ */
30379
+ opsLogRetentionDays: number().int().min(0),
30090
30380
  persisted: boolean()
30091
30381
  });
30092
30382
  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(), {
@@ -35072,6 +35362,12 @@ Object.freeze({
35072
35362
  addonId: null,
35073
35363
  access: "view"
35074
35364
  },
35365
+ "pipelineAnalytics.listRecentSummaries": {
35366
+ capName: "pipeline-analytics",
35367
+ capScope: "device",
35368
+ addonId: null,
35369
+ access: "view"
35370
+ },
35075
35371
  "pipelineAnalytics.listRecentTracks": {
35076
35372
  capName: "pipeline-analytics",
35077
35373
  capScope: "device",
@@ -37034,6 +37330,12 @@ Object.freeze({
37034
37330
  addonId: null,
37035
37331
  access: "create"
37036
37332
  },
37333
+ "streamBroker.reportStreamSignal": {
37334
+ capName: "stream-broker",
37335
+ capScope: "system",
37336
+ addonId: null,
37337
+ access: "create"
37338
+ },
37037
37339
  "streamBroker.restartProfile": {
37038
37340
  capName: "stream-broker",
37039
37341
  capScope: "system",
@@ -37118,6 +37420,12 @@ Object.freeze({
37118
37420
  addonId: null,
37119
37421
  access: "create"
37120
37422
  },
37423
+ "streamSignals.listSignals": {
37424
+ capName: "stream-signals",
37425
+ capScope: "device",
37426
+ addonId: null,
37427
+ access: "view"
37428
+ },
37121
37429
  "switch.setState": {
37122
37430
  capName: "switch",
37123
37431
  capScope: "device",
@@ -38899,6 +39207,11 @@ Object.freeze({
38899
39207
  form: "single",
38900
39208
  optional: true
38901
39209
  }],
39210
+ "pipelineAnalytics.listRecentSummaries": [{
39211
+ name: "deviceIds",
39212
+ form: "array",
39213
+ optional: false
39214
+ }],
38902
39215
  "pipelineAnalytics.listRecentTracks": [{
38903
39216
  name: "deviceIds",
38904
39217
  form: "array",
@@ -39485,6 +39798,11 @@ Object.freeze({
39485
39798
  form: "single",
39486
39799
  optional: false
39487
39800
  }],
39801
+ "streamBroker.reportStreamSignal": [{
39802
+ name: "deviceId",
39803
+ form: "single",
39804
+ optional: false
39805
+ }],
39488
39806
  "streamBroker.restartProfile": [{
39489
39807
  name: "deviceId",
39490
39808
  form: "single",
package/dist/addon.mjs CHANGED
@@ -3,7 +3,7 @@ import { createRequire } from "node:module";
3
3
  var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
4
4
  var __require = /* @__PURE__ */ createRequire(import.meta.url);
5
5
  //#endregion
6
- //#region ../types/dist/event-category-ZyX6jcse.mjs
6
+ //#region ../types/dist/event-category-BVDXG4tB.mjs
7
7
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
8
8
  EventCategory["SystemBoot"] = "system.boot";
9
9
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -620,6 +620,20 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
620
620
  * pull-reconcile from the provider's `getStatus` on reconnect. */
621
621
  EventCategory["MeshNetworkChanged"] = "network.mesh.changed";
622
622
  EventCategory["BackupCompleted"] = "backup.completed";
623
+ /**
624
+ * A whole backup RUN finished — every destination attempted, win or lose.
625
+ *
626
+ * `backup.completed` fires once per DESTINATION, which is the right grain for
627
+ * a progress UI and the wrong one for a notification: an operator with three
628
+ * destinations would be told three times. And a run where two of three
629
+ * destinations succeeded is not a clean success — a single "backup
630
+ * completed" that hid the failed one would be a lie, so the count of each is
631
+ * carried here and the message says both.
632
+ *
633
+ * Emitted by the backup orchestrator only after the destination loop, so a
634
+ * run that dies during the BUILD phase produces no completion at all.
635
+ */
636
+ EventCategory["BackupRunCompleted"] = "backup.run-completed";
623
637
  EventCategory["BackupRestored"] = "backup.restored";
624
638
  EventCategory["NotificationDispatched"] = "notification.dispatched";
625
639
  EventCategory["NotificationFailed"] = "notification.failed";
@@ -5350,7 +5364,7 @@ var ZodIssueCode = {
5350
5364
  var ZodFirstPartyTypeKind;
5351
5365
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5352
5366
  //#endregion
5353
- //#region ../types/dist/sleep-CnLyvg3w.mjs
5367
+ //#region ../types/dist/sleep-DEuj7E3j.mjs
5354
5368
  /**
5355
5369
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5356
5370
  * 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
@@ -11474,6 +11504,58 @@ method(ListInputSchema, array(BrokerInfoSchema$1)), method(GetInputSchema, Broke
11474
11504
  auth: "admin"
11475
11505
  }), method(GetStateInputSchema, unknown().nullable()), method(_void(), RegistryStatusSchema);
11476
11506
  DeviceType.Camera;
11507
+ /**
11508
+ * The signals a device can emit to WAKE its own stream.
11509
+ *
11510
+ * A camera whose stream is built on demand sleeps until something asks for it,
11511
+ * and "something" cannot be a consumer that is merely attached — a Frigate-style
11512
+ * puller holds a session open for ever, and treating that as demand would keep
11513
+ * a battery camera awake for ever, which is the whole thing the battery is for
11514
+ * (D173). So the wake has to come from the CAMERA: an event it noticed by
11515
+ * itself, with no stream running.
11516
+ *
11517
+ * ## The vocabulary is the PROVIDER'S, not ours
11518
+ *
11519
+ * Like `consumables`, this cap declares no vocabulary of its own. A provider
11520
+ * names each signal with a `code` it chooses and a `label` an operator reads.
11521
+ * Reolink offers motion and camera-native detection; another provider may offer
11522
+ * a tamper, a doorbell press, a PIR, or something no camera in this fleet has
11523
+ * yet. A fixed enum here would mean every new signal is a framework release.
11524
+ *
11525
+ * It is deliberately NOT derived from the caps a device already binds. Whether
11526
+ * a camera CAN push firmware motion is expressed by `motionSources` containing
11527
+ * `'onboard'`, and whether it does AI on-camera by the `native-object-detection`
11528
+ * binding — but both answer "what drives the detection pipeline", which is a
11529
+ * different question from "what may wake a sleeping stream". A camera can do
11530
+ * the first and not be trusted with the second, and the operator picks per
11531
+ * camera. Two questions, two authorities.
11532
+ *
11533
+ * ## Availability is not permission
11534
+ *
11535
+ * `listSignals` says what the device CAN emit. Whether a given signal actually
11536
+ * wakes the stream is the operator's per-camera choice, held by the broker
11537
+ * alongside the cooldown — see the stream-broker cap's wake settings. A
11538
+ * provider declaring a signal is not a provider enabling it.
11539
+ */
11540
+ /** One signal a device can emit. */
11541
+ var StreamSignalSchema = object({
11542
+ /** Stable id chosen by the provider, e.g. `'motion'`, `'person'`, `'tamper'`. */
11543
+ code: string().min(1),
11544
+ /** What an operator reads in the picker. The provider's own wording. */
11545
+ label: string().min(1),
11546
+ /**
11547
+ * Whether the provider recommends this signal ON when a camera is first set
11548
+ * up. A provider knows which of its signals are cheap and reliable; an
11549
+ * operator should not have to discover that by trial. Reolink recommends
11550
+ * both of its own.
11551
+ */
11552
+ recommended: boolean()
11553
+ });
11554
+ object({
11555
+ signals: array(StreamSignalSchema),
11556
+ lastFetchedAt: number()
11557
+ });
11558
+ Object.values(DeviceType), method(_void(), array(StreamSignalSchema).readonly());
11477
11559
  /** Stream delivery format. (Relocated from the retired `streaming-engine` cap.) */
11478
11560
  var StreamFormatSchema = _enum([
11479
11561
  "webrtc",
@@ -11870,6 +11952,22 @@ var EgressTranscodeSchema = object({
11870
11952
  camStreamId: string().nullable()
11871
11953
  });
11872
11954
  method(object({
11955
+ deviceId: number().int().nonnegative(),
11956
+ /** The provider's signal code. */
11957
+ code: string().min(1),
11958
+ /** Ms epoch. Absent ⇒ now. */
11959
+ at: number().optional()
11960
+ }), object({
11961
+ /** Whether the broker acted on it, and if not, why. */
11962
+ accepted: boolean(),
11963
+ reason: _enum([
11964
+ "woke",
11965
+ "hold-extended",
11966
+ "not-enabled",
11967
+ "no-consumer",
11968
+ "unknown-code"
11969
+ ])
11970
+ }), { kind: "mutation" }), method(object({
11873
11971
  deviceId: number().int().nonnegative(),
11874
11972
  camStreamId: string().min(1),
11875
11973
  kind: CamStreamKindSchema,
@@ -12124,6 +12222,16 @@ var PickStreamRequirementsSchema = object({
12124
12222
  acceptCodecs: array(StreamCodecSchema).readonly().optional(),
12125
12223
  /** Minimum vertical resolution. Streams shorter than this are dropped. */
12126
12224
  minHeight: number().int().positive().optional(),
12225
+ /**
12226
+ * Maximum vertical resolution. Streams TALLER than this are dropped.
12227
+ *
12228
+ * A consumer can have a ceiling as real as its floor: Alexa documents
12229
+ * 480p to 1080p, and a 4K stream is as unusable to an Echo as a 360p one.
12230
+ * Without this the ceiling had to be re-implemented by every caller — and
12231
+ * one caller implementing it privately is how a second scoring authority
12232
+ * gets born.
12233
+ */
12234
+ maxHeight: number().int().positive().optional(),
12127
12235
  /** Minimum horizontal resolution. */
12128
12236
  minWidth: number().int().positive().optional(),
12129
12237
  /**
@@ -12140,7 +12248,22 @@ var PickStreamRequirementsSchema = object({
12140
12248
  * transcoded" guard: if the device is already serving the consumer's
12141
12249
  * codec end-to-end, there's nothing to optimise.
12142
12250
  */
12143
- requireSiblingCodec: array(StreamCodecSchema).readonly().optional()
12251
+ requireSiblingCodec: array(StreamCodecSchema).readonly().optional(),
12252
+ /**
12253
+ * Whether a stream the consumer CANNOT decode may still be picked, on the
12254
+ * understanding that it will be transcoded.
12255
+ *
12256
+ * Default `false` — today's behaviour, and the right one for a bypass
12257
+ * question ("is there a stream I can forward untouched?"). Set `true` to
12258
+ * ask the larger question: "what is the best stream for me, transcoding if
12259
+ * I must?" A stream that satisfies `acceptCodecs` always outranks one that
12260
+ * does not, so a passthrough is never lost to a transcode; the answer says
12261
+ * which it is in {@link PickedCamStreamSchema.transcodes}.
12262
+ *
12263
+ * This is what lets one picker serve both the bypass and the full source
12264
+ * choice, instead of a consumer scoring privately when the bypass misses.
12265
+ */
12266
+ allowTranscode: boolean().optional()
12144
12267
  }).readonly();
12145
12268
  var PickStreamPreferencesSchema = object({
12146
12269
  /**
@@ -12154,12 +12277,32 @@ var PickStreamPreferencesSchema = object({
12154
12277
  * picks the tallest stream; `'lowest'` picks the shortest (used by
12155
12278
  * memory-constrained consumers / Apple Home guest sessions).
12156
12279
  */
12157
- resolutionPreference: _enum(["highest", "lowest"]).optional()
12280
+ resolutionPreference: _enum(["highest", "lowest"]).optional(),
12281
+ /**
12282
+ * The height the consumer actually wants to DELIVER.
12283
+ *
12284
+ * Not a constraint — an ordering. With it set, the SMALLEST stream at or
12285
+ * above the target wins, and only if nothing reaches it does the tallest
12286
+ * take over. Pulling 1296 lines to draw 720 on a 1280x800 Echo panel costs
12287
+ * a decode and buys nothing, and `resolutionPreference: 'highest'` cannot
12288
+ * express that: it says "as big as possible", which is a different wish.
12289
+ *
12290
+ * Ignored when absent, so every existing caller keeps its ordering.
12291
+ */
12292
+ targetHeight: number().int().positive().optional()
12158
12293
  }).readonly();
12159
12294
  var PickedCamStreamSchema = object({
12160
12295
  camStreamId: string(),
12161
12296
  codec: string().optional(),
12162
12297
  resolution: CamStreamResolutionSchema.optional(),
12298
+ /**
12299
+ * Whether serving this stream requires a decode + re-encode.
12300
+ *
12301
+ * `false` is a stream the consumer can take as it stands. Only ever `true`
12302
+ * when the caller asked for it with `allowTranscode`, so a caller that did
12303
+ * not ask cannot be handed a cost it never agreed to pay.
12304
+ */
12305
+ transcodes: boolean(),
12163
12306
  /** One-line explanation of why this stream won — for logs / debug UI. */
12164
12307
  reason: string()
12165
12308
  });
@@ -16429,6 +16572,8 @@ var NcSystemEventKindSchema = _enum([
16429
16572
  "device-enabled",
16430
16573
  "device-battery-low",
16431
16574
  "device-battery-normal",
16575
+ "device-consumable-low",
16576
+ "device-consumable-normal",
16432
16577
  "stream-online",
16433
16578
  "stream-offline",
16434
16579
  "node-online",
@@ -16447,6 +16592,7 @@ var NcSystemEventKindSchema = _enum([
16447
16592
  "addon-updated",
16448
16593
  "server-updated",
16449
16594
  "export-completed",
16595
+ "backup-completed",
16450
16596
  "camera-online",
16451
16597
  "camera-offline",
16452
16598
  "camera-disabled",
@@ -19843,13 +19989,109 @@ var SummariesQueryInput = object({
19843
19989
  deviceIds: array(number()).min(1),
19844
19990
  since: number().optional(),
19845
19991
  until: number().optional(),
19846
- limit: number().int().min(1).max(200).default(50)
19992
+ limit: number().int().min(1).max(200).default(50),
19993
+ /** The same member-wise filter {@link listRecentSummaries} takes — one
19994
+ * meaning of "dog" on every summary surface. */
19995
+ classes: array(string().min(1).max(60)).max(40).optional()
19847
19996
  });
19848
- var SummariesPageSchema = object({ summaries: array(SummarySchema).readonly() });
19849
19997
  var SummaryDetailSchema = object({
19850
19998
  summary: SummarySchema,
19851
- /** Member track ids, in absorption order. */
19852
- trackIds: array(string()).readonly()
19999
+ /** Members in absorption order, oldest join first. */
20000
+ members: array(object({
20001
+ trackId: string(),
20002
+ /**
20003
+ * The track's class at the time it JOINED, or `null` when it was unresolved
20004
+ * and the track no longer exists to fill it.
20005
+ *
20006
+ * The join, not the latest opinion: class voting can re-decide a track's
20007
+ * class afterwards, and a group's composition is the history of who came
20008
+ * together. A consumer counts these to badge a thumbnail — "two people and a
20009
+ * dog" — rather than being handed a second, denormalised tally that would
20010
+ * drift from the members it claims to describe.
20011
+ */
20012
+ className: string().nullable(),
20013
+ /** `primary` is the one member that carries the group's identity. */
20014
+ role: _enum([
20015
+ "primary",
20016
+ "sibling",
20017
+ "child"
20018
+ ]).nullable(),
20019
+ joinedAt: number(),
20020
+ /** Tier 1 — the sub-class (`dog`, `van`), resolved from the member's track
20021
+ * at read time. Absent when nothing resolved, never an empty string. */
20022
+ label: string().optional(),
20023
+ /** Tier 2 — the instance: a person's name, a plate. Absent when the pipeline
20024
+ * recognised nobody, and absent for a member whose track has been pruned —
20025
+ * a thumbnail that names the wrong person is worse than one naming nobody. */
20026
+ subLabel: string().optional()
20027
+ })).readonly()
20028
+ });
20029
+ /**
20030
+ * What a LIST of groups carries: the envelope plus what it is MADE OF.
20031
+ *
20032
+ * Coarse on purpose — the operator's rule is "only the rough data on the list,
20033
+ * we extend when we notice we need more". Enough to draw the card ("two people
20034
+ * and a dog") and no more. The MEMBERS, their names and the per-member links
20035
+ * are on {@link getSummary}: shipping every member of every group so a client
20036
+ * can count them turns a page of two hundred groups into a thousand records to
20037
+ * draw two hundred badges.
20038
+ */
20039
+ var SummaryListItemSchema = object({
20040
+ summary: SummarySchema,
20041
+ /** Class counts, most numerous first; `className: null` is a member whose
20042
+ * class never resolved, counted so the counts add up to `memberCount`. */
20043
+ classes: array(object({
20044
+ className: string().nullable(),
20045
+ count: number().int().positive()
20046
+ })).readonly()
20047
+ });
20048
+ var SummariesPageSchema = object({ summaries: array(SummaryListItemSchema).readonly() });
20049
+ /**
20050
+ * The paged feed, deliberately the SAME shape as {@link RecentTracksQueryInput}.
20051
+ *
20052
+ * The reel on the cameras page and the Events gallery both ride a cursor, so a
20053
+ * summaries feed that could only answer "the last N for these cameras"
20054
+ * (`listSummaries`) would make groups available in the timeline and nowhere
20055
+ * else. Two feeds with different ordering contracts would be two ideas of what
20056
+ * "newest" means, on one screen.
20057
+ */
20058
+ var RecentSummariesQueryInput = object({
20059
+ /** Devices to merge. An empty array yields an empty page. */
20060
+ deviceIds: array(number()),
20061
+ /** Window lower bound on `lastActiveAt` (inclusive). */
20062
+ since: number().optional(),
20063
+ /** Window upper bound on `lastActiveAt` (inclusive). */
20064
+ until: number().optional(),
20065
+ limit: number().int().min(1).max(500).default(100),
20066
+ /** Opaque continuation cursor from a previous page's `nextCursor`. */
20067
+ cursor: string().optional(),
20068
+ /**
20069
+ * Restrict to these classes — THE SAME FIELD `listRecentTracks` takes, and
20070
+ * deliberately the same name: the events filter tree emits one list of ticked
20071
+ * taxonomy nodes, and a summaries feed that called it something else would
20072
+ * make the operator's one filter component produce two shapes.
20073
+ *
20074
+ * A question about the MEMBERS: a group matches when ANY of them does. "Show
20075
+ * me the arrivals with a dog" has to return the group of four people who had
20076
+ * one with them; a filter on the group's own fields could only ever answer
20077
+ * about its primary.
20078
+ *
20079
+ * Matched against all THREE tiers of a member — the class (`animal`), the
20080
+ * sub-class (`dog`) and the instance (a name, a plate) — because which tier a
20081
+ * ticked node lives on is the taxonomy's business, not the caller's. `dog` is
20082
+ * an event kind in the tree and a tier-1 label on an `animal` track; a filter
20083
+ * that read only the class would answer "animal" and never "dog".
20084
+ *
20085
+ * ABSENT or EMPTY means no filter — absent is not a selection of none.
20086
+ */
20087
+ classes: array(string().min(1).max(60)).max(40).optional()
20088
+ });
20089
+ var RecentSummariesPageSchema = object({
20090
+ /** Ordered by (`lastActiveAt` DESC, id DESC). Same light item as
20091
+ * {@link listSummaries} — one list shape, so a card renders the same
20092
+ * whichever feed drew it. */
20093
+ summaries: array(SummaryListItemSchema).readonly(),
20094
+ nextCursor: string().nullable()
19853
20095
  });
19854
20096
  var RecentTracksPageSchema = object({
19855
20097
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
@@ -20263,7 +20505,7 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
20263
20505
  classes: array(string()).optional(),
20264
20506
  /** See {@link ExcludeSourcesDoc}. */
20265
20507
  excludeSources: array(TrackSourceSchema).optional()
20266
- }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20508
+ }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(RecentSummariesQueryInput, RecentSummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
20267
20509
  kind: "mutation",
20268
20510
  auth: "admin"
20269
20511
  }), 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({
@@ -23696,10 +23938,28 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
23696
23938
  }), boolean()), method(object({
23697
23939
  deviceId: number().int().nonnegative(),
23698
23940
  sessionId: string()
23699
- }), object({ pendingRenegotiation: object({
23700
- target: WebrtcStreamTargetSchema,
23701
- epoch: number()
23702
- }).nullable() }));
23941
+ }), object({
23942
+ pendingRenegotiation: object({
23943
+ target: WebrtcStreamTargetSchema,
23944
+ epoch: number()
23945
+ }).nullable(),
23946
+ /**
23947
+ * Whether the session still EXISTS.
23948
+ *
23949
+ * A consumer that holds a resource for the life of a session needs to
23950
+ * be able to ask, because a session does not always end the way it
23951
+ * began. Measured on this hub 2026-09-13: an Echo that got stuck never
23952
+ * sent `SessionDisconnected`, so the Alexa exporter's
23953
+ * `releaseEgressTranscode` never ran, and a 2304x1296 HEVC to 720p
23954
+ * H.264 transcode kept running for NOBODY for more than twenty
23955
+ * minutes. The WebRTC session had logged `WebRTC session closed`
23956
+ * minutes earlier — the broker knew; the holder had no way to ask.
23957
+ *
23958
+ * `false` for a session id the provider has never heard of, which is
23959
+ * the same answer as "it ended": either way nothing is holding it up.
23960
+ */
23961
+ alive: boolean()
23962
+ }));
23703
23963
  object({
23704
23964
  /** All accessory children of the parent. */
23705
23965
  childDeviceIds: array(number()).readonly(),
@@ -30015,7 +30275,29 @@ var LoggingSettingsPatchSchema = object({
30015
30275
  * disarmed the channels it did not mention would make the Levels page and
30016
30276
  * the Diagnostics page fight over the same value.
30017
30277
  */
30018
- channels: array(LogChannelWindowPatchSchema).readonly().optional()
30278
+ channels: array(LogChannelWindowPatchSchema).readonly().optional(),
30279
+ /**
30280
+ * How many days the analytics OPS LOG is kept — the audit trail of what
30281
+ * retention actually deleted.
30282
+ *
30283
+ * It lives HERE, on the logging document, and not on the analytics addon's
30284
+ * settings form, on the operator's instruction: every other log-ish window in
30285
+ * this system is configured through this one document, and a retention audit
30286
+ * configured somewhere else is a second place to look when the question is
30287
+ * "what happened to my data".
30288
+ *
30289
+ * That placement has a cost worth stating: this document ships in the
30290
+ * framework closure, so this knob needs a published `@camstack/server` while
30291
+ * the four windows beside it (D485) reach a node on `camstack deploy`.
30292
+ *
30293
+ * `retention-model.ts` argued this one must NOT follow a device window,
30294
+ * because the audit trail is the history of the SWEEP and not of the camera.
30295
+ * That argument stands and is untouched — what changes is that 30 days stops
30296
+ * being a constant nobody can reach. `0` keeps it forever. The floor is 1 day
30297
+ * rather than 0-as-delete: an audit log truncated to nothing is precisely the
30298
+ * state in which the next 9.5 GiB leak cannot be explained.
30299
+ */
30300
+ opsLogRetentionDays: number().int().min(0).max(3650).optional()
30019
30301
  });
30020
30302
  /**
30021
30303
  * Which LAYER of the hierarchy is addressed. Absent = the cluster layer.
@@ -30088,6 +30370,14 @@ var LoggingSettingsStateSchema = object({
30088
30370
  channels: array(LogChannelDescriptorSchema).readonly(),
30089
30371
  /** The channels ARMED right now, each with its deadline. */
30090
30372
  activeChannels: array(LogChannelWindowStateSchema).readonly(),
30373
+ /**
30374
+ * The ops-log window in days, as it is in force. `0` = kept forever.
30375
+ *
30376
+ * Reported rather than left to the caller's memory of what it wrote: this is
30377
+ * the value the analytics sweep will actually use, and an operator asking how
30378
+ * long their audit trail lives should not have to infer it from a default.
30379
+ */
30380
+ opsLogRetentionDays: number().int().min(0),
30091
30381
  persisted: boolean()
30092
30382
  });
30093
30383
  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(), {
@@ -35073,6 +35363,12 @@ Object.freeze({
35073
35363
  addonId: null,
35074
35364
  access: "view"
35075
35365
  },
35366
+ "pipelineAnalytics.listRecentSummaries": {
35367
+ capName: "pipeline-analytics",
35368
+ capScope: "device",
35369
+ addonId: null,
35370
+ access: "view"
35371
+ },
35076
35372
  "pipelineAnalytics.listRecentTracks": {
35077
35373
  capName: "pipeline-analytics",
35078
35374
  capScope: "device",
@@ -37035,6 +37331,12 @@ Object.freeze({
37035
37331
  addonId: null,
37036
37332
  access: "create"
37037
37333
  },
37334
+ "streamBroker.reportStreamSignal": {
37335
+ capName: "stream-broker",
37336
+ capScope: "system",
37337
+ addonId: null,
37338
+ access: "create"
37339
+ },
37038
37340
  "streamBroker.restartProfile": {
37039
37341
  capName: "stream-broker",
37040
37342
  capScope: "system",
@@ -37119,6 +37421,12 @@ Object.freeze({
37119
37421
  addonId: null,
37120
37422
  access: "create"
37121
37423
  },
37424
+ "streamSignals.listSignals": {
37425
+ capName: "stream-signals",
37426
+ capScope: "device",
37427
+ addonId: null,
37428
+ access: "view"
37429
+ },
37122
37430
  "switch.setState": {
37123
37431
  capName: "switch",
37124
37432
  capScope: "device",
@@ -38900,6 +39208,11 @@ Object.freeze({
38900
39208
  form: "single",
38901
39209
  optional: true
38902
39210
  }],
39211
+ "pipelineAnalytics.listRecentSummaries": [{
39212
+ name: "deviceIds",
39213
+ form: "array",
39214
+ optional: false
39215
+ }],
38903
39216
  "pipelineAnalytics.listRecentTracks": [{
38904
39217
  name: "deviceIds",
38905
39218
  form: "array",
@@ -39486,6 +39799,11 @@ Object.freeze({
39486
39799
  form: "single",
39487
39800
  optional: false
39488
39801
  }],
39802
+ "streamBroker.reportStreamSignal": [{
39803
+ name: "deviceId",
39804
+ form: "single",
39805
+ optional: false
39806
+ }],
39489
39807
  "streamBroker.restartProfile": [{
39490
39808
  name: "deviceId",
39491
39809
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-onvif",
3
- "version": "1.2.99",
3
+ "version": "1.2.101",
4
4
  "description": "ONVIF camera device provider addon for CamStack",
5
5
  "keywords": [
6
6
  "camstack",