@camstack/addon-provider-rtsp 1.2.90 → 1.2.93
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/addon.js +246 -22
- package/dist/addon.mjs +246 -22
- 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-
|
|
26
|
+
//#region ../types/dist/event-category-DAXzJeTX.mjs
|
|
27
27
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
28
28
|
EventCategory["SystemBoot"] = "system.boot";
|
|
29
29
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -615,7 +615,6 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
615
615
|
* issue. Payload `PipelineAnalyticsPlateGalleryChangedPayload`.
|
|
616
616
|
*/
|
|
617
617
|
EventCategory["PipelineAnalyticsPlateGalleryChanged"] = "pipeline-analytics.plate-gallery-changed";
|
|
618
|
-
EventCategory["FrigateLiveEvent"] = "frigate.live-event";
|
|
619
618
|
EventCategory["CameraStreamsProfileSlotsChanged"] = "camera-streams.onProfileSlotsChanged";
|
|
620
619
|
/**
|
|
621
620
|
* Stream-broker health watchdog. Per-broker (deviceId/profile) emission.
|
|
@@ -12681,7 +12680,7 @@ DeviceType.Camera;
|
|
|
12681
12680
|
var SourceInfoSchema = object({
|
|
12682
12681
|
/** Live dispatch key — mutable when the source system allows rename. */
|
|
12683
12682
|
id: string(),
|
|
12684
|
-
/** Source system tag — e.g. 'homeassistant' | 'reolink' | '
|
|
12683
|
+
/** Source system tag — e.g. 'homeassistant' | 'reolink' | 'onvif'. */
|
|
12685
12684
|
system: string(),
|
|
12686
12685
|
/** Immutable upstream identifier when available (HA `unique_id`, … ).
|
|
12687
12686
|
* Used to detect rename when `id` changes. */
|
|
@@ -12694,7 +12693,7 @@ var SourceInfoSchema = object({
|
|
|
12694
12693
|
/**
|
|
12695
12694
|
* Build the synthetic SourceInfo every existing provider falls back to
|
|
12696
12695
|
* when no upstream value has been persisted. Keeps non-migrated providers
|
|
12697
|
-
* (Reolink / Hikvision / ONVIF /
|
|
12696
|
+
* (Reolink / Hikvision / ONVIF / RTSP) functional without code
|
|
12698
12697
|
* changes — `id` reuses the CamStack stableId, `system` reuses the addon
|
|
12699
12698
|
* id. Real upstream identity replaces this once a provider migrates and
|
|
12700
12699
|
* calls `updateSourceInfo()` with concrete values.
|
|
@@ -13356,7 +13355,7 @@ var deviceProviderCapability = {
|
|
|
13356
13355
|
* - `device-management.router.ts` (deleted in Phase 2)
|
|
13357
13356
|
* - `device-ops.router.ts` (compat layer — deleted; device-provider ops absorbed here)
|
|
13358
13357
|
*
|
|
13359
|
-
* All device provider addons (rtsp, onvif,
|
|
13358
|
+
* All device provider addons (rtsp, onvif, …) are hub-local: they may
|
|
13360
13359
|
* fork into separate processes but never run on remote cluster agents. Therefore:
|
|
13361
13360
|
* - No nodeId routing needed — this is a pure hub singleton.
|
|
13362
13361
|
* - The hub's DeviceRegistry is the single source of truth for all live devices.
|
|
@@ -17404,7 +17403,7 @@ var NcRuleInputSchema = object({
|
|
|
17404
17403
|
* The measured seven-person arrival on device 590 spans 110 s with every
|
|
17405
17404
|
* internal gap under 30 s. A 12 s fixed window cuts it into three groups; an
|
|
17406
17405
|
* idle cutoff holds it as one and ends it when the arrival actually ends.
|
|
17407
|
-
* 30 is
|
|
17406
|
+
* 30 s is a widely shipped value for the same decision.
|
|
17408
17407
|
*
|
|
17409
17408
|
* ### What it replaces
|
|
17410
17409
|
*
|
|
@@ -19486,6 +19485,13 @@ var ZoneCrossingSchema = object({
|
|
|
19486
19485
|
/** Zone display name at crossing time (falls back to the id). */
|
|
19487
19486
|
zoneName: string().optional()
|
|
19488
19487
|
});
|
|
19488
|
+
/** One zone a box was stamped with, and how much of the BOX fell inside it. */
|
|
19489
|
+
var ZoneOverlapSchema = object({
|
|
19490
|
+
zoneId: string(),
|
|
19491
|
+
zoneName: string().optional(),
|
|
19492
|
+
/** Percentage of the BOX area inside the zone, 0–100. */
|
|
19493
|
+
overlapPct: number()
|
|
19494
|
+
});
|
|
19489
19495
|
var ObjectEventSchema = object({
|
|
19490
19496
|
...BaseEventFields,
|
|
19491
19497
|
kind: literal("object"),
|
|
@@ -19510,6 +19516,35 @@ var ObjectEventSchema = object({
|
|
|
19510
19516
|
bbox: BoundingBoxSchema.optional(),
|
|
19511
19517
|
/** Heavy JSON — omitted in slim projection. */
|
|
19512
19518
|
zones: array(string()).readonly().optional(),
|
|
19519
|
+
/**
|
|
19520
|
+
* How far inside each stamped zone the box actually was, as a percentage of
|
|
19521
|
+
* the BOX area.
|
|
19522
|
+
*
|
|
19523
|
+
* Membership alone cannot express "at least a third of it inside", which is
|
|
19524
|
+
* the bar an operator argues with — and the number already existed: the
|
|
19525
|
+
* engine computed it, the pipeline logged it, and then discarded it. It
|
|
19526
|
+
* matters most on the events that carry no track, where a rule has nothing
|
|
19527
|
+
* else to judge by.
|
|
19528
|
+
*/
|
|
19529
|
+
zoneOverlaps: array(ZoneOverlapSchema).readonly().optional(),
|
|
19530
|
+
/**
|
|
19531
|
+
* Present when this event describes a detection the TRACKER refused, so it
|
|
19532
|
+
* has no track and never will.
|
|
19533
|
+
*
|
|
19534
|
+
* A zone-scoped immediate rule asks "is there an animal in the flowerbed
|
|
19535
|
+
* NOW?"; tracking answers a different question ("is this the same subject as
|
|
19536
|
+
* before?") whose confirmation threshold presumes continuity. On 2026-09-09 a
|
|
19537
|
+
* dog at 0.7729, 100% inside a watched zone, was refused three times in six
|
|
19538
|
+
* seconds with three different candidate ids — seven analysed frames in the
|
|
19539
|
+
* window, the subject in a handful of them, metres apart — and produced no
|
|
19540
|
+
* event at all.
|
|
19541
|
+
*
|
|
19542
|
+
* It is NAMED rather than merely implied by a missing `trackId`: an event
|
|
19543
|
+
* with no track and no reason is indistinguishable from a track whose media
|
|
19544
|
+
* went missing, and a consumer that asks this one for a best shot or a
|
|
19545
|
+
* history is asking for something that never existed.
|
|
19546
|
+
*/
|
|
19547
|
+
spawnRefused: string().optional(),
|
|
19513
19548
|
/** Omitted in slim projection. */
|
|
19514
19549
|
state: TrackStateSchema.optional(),
|
|
19515
19550
|
/**
|
|
@@ -19936,7 +19971,17 @@ var EventDensityBucketSchema = object({
|
|
|
19936
19971
|
bucketStart: number(),
|
|
19937
19972
|
motion: number().int(),
|
|
19938
19973
|
object: number().int(),
|
|
19939
|
-
audio: number().int()
|
|
19974
|
+
audio: number().int(),
|
|
19975
|
+
/**
|
|
19976
|
+
* Energy-weighted mean dBFS of the audio events in this bucket — the LEVEL,
|
|
19977
|
+
* as opposed to `audio`, which is their COUNT (D431).
|
|
19978
|
+
*
|
|
19979
|
+
* ABSENT when the bucket holds no audio event. Absence means "nothing was
|
|
19980
|
+
* measured", which is not the same claim as silence, and a lane that cannot
|
|
19981
|
+
* tell them apart paints a quiet hour at full scale — which is exactly what
|
|
19982
|
+
* the count-on-a-level-meter did.
|
|
19983
|
+
*/
|
|
19984
|
+
audioDbfs: number().optional()
|
|
19940
19985
|
});
|
|
19941
19986
|
/**
|
|
19942
19987
|
* One camera's row in a `getEventDensityBatch` answer.
|
|
@@ -20583,6 +20628,60 @@ var NativeCropResultSchema = object({
|
|
|
20583
20628
|
*/
|
|
20584
20629
|
tier: _enum(["native", "ram-fullframe"]).optional()
|
|
20585
20630
|
});
|
|
20631
|
+
/**
|
|
20632
|
+
* What a PARKED frame is for — the `kind` half of the `(deviceId, trackId,
|
|
20633
|
+
* kind)` key ([D422](../../../docs/decisions/adr-0422-a-relevant-frame-is-parked-when-it-becomes-relevant.md)).
|
|
20634
|
+
*
|
|
20635
|
+
* - `keyFrame` — the track's clean best FULL frame at native width (capped by
|
|
20636
|
+
* the caller's `maxWidth`). What `keyFrame` + `keyFrameSmall` are written
|
|
20637
|
+
* from, and what the detail plane's full-frame rung cuts from.
|
|
20638
|
+
* - `thumbnail` — the best-shot subject slab: the caller's 16:9 central-square
|
|
20639
|
+
* window, cut by the runner at uncapped native resolution.
|
|
20640
|
+
*
|
|
20641
|
+
* The runner never interprets `trackId`; it is an opaque key the hub owns.
|
|
20642
|
+
*/
|
|
20643
|
+
var ParkedFrameKindSchema = _enum(["keyFrame", "thumbnail"]);
|
|
20644
|
+
/**
|
|
20645
|
+
* Why a park did NOT happen. Every one is logged on the runner with
|
|
20646
|
+
* `tags: { deviceId }` and the handle's measured age, because a handle already
|
|
20647
|
+
* gone at park time IS the defect the 150–500 ms window exists to prevent —
|
|
20648
|
+
* never a reason to retry in a loop.
|
|
20649
|
+
*
|
|
20650
|
+
* - `handle-gone` — the native surface no longer resolves this handle (never
|
|
20651
|
+
* registered, past the lease bound, or the worker released it). `detail`
|
|
20652
|
+
* carries the runner's own miss reason.
|
|
20653
|
+
* - `encode-failed` — pixels resolved and the JPEG encode threw.
|
|
20654
|
+
*/
|
|
20655
|
+
var ParkRefusalSchema = _enum(["handle-gone", "encode-failed"]);
|
|
20656
|
+
/** Answer to `parkTrackFrame` — a discriminated union, so "not parked" always names why. */
|
|
20657
|
+
var ParkTrackFrameResultSchema = discriminatedUnion("parked", [object({
|
|
20658
|
+
parked: literal(true),
|
|
20659
|
+
/** The node holding the parcel — what a later retrieval must be pinned to. */
|
|
20660
|
+
nodeId: string(),
|
|
20661
|
+
width: number().int().positive(),
|
|
20662
|
+
height: number().int().positive(),
|
|
20663
|
+
/** JPEG bytes the parcel costs on the node. */
|
|
20664
|
+
bytes: number().int().nonnegative(),
|
|
20665
|
+
/** Whether this park replaced a parcel already held for the key. */
|
|
20666
|
+
replaced: boolean()
|
|
20667
|
+
}), object({
|
|
20668
|
+
parked: literal(false),
|
|
20669
|
+
nodeId: string(),
|
|
20670
|
+
reason: ParkRefusalSchema,
|
|
20671
|
+
/** Age of the handle at the park, on the runner's clock; null if unknown. */
|
|
20672
|
+
handleAgeMs: number().nullable(),
|
|
20673
|
+
detail: string().optional()
|
|
20674
|
+
})]);
|
|
20675
|
+
/** A retrieved parcel — the runner's own JPEG, base64 for the wire. */
|
|
20676
|
+
var ParkedTrackFrameSchema = object({
|
|
20677
|
+
jpeg: string(),
|
|
20678
|
+
width: number().int().positive(),
|
|
20679
|
+
height: number().int().positive(),
|
|
20680
|
+
/** The frame instant the parcel shows (the caller's clock, echoed back). */
|
|
20681
|
+
timestamp: number(),
|
|
20682
|
+
/** When the node stored it (the node's clock). */
|
|
20683
|
+
parkedAt: number()
|
|
20684
|
+
});
|
|
20586
20685
|
/** Parent detection context passed to `runDetailSubtree` — the crop's
|
|
20587
20686
|
* originating detection, in FRAME-space coordinates. Reuses
|
|
20588
20687
|
* `NativeCropBboxSchema`'s `{x,y,w,h}` shape (same numeric fields; here
|
|
@@ -20972,7 +21071,7 @@ var RunnerCameraConfigSchema = object({
|
|
|
20972
21071
|
* - `analyzer`: ML/frame-diff motion detection (motion-wasm or other
|
|
20973
21072
|
* analyzer providers) running on decoded frames in this runner.
|
|
20974
21073
|
* - `onboard`: camera-native motion pushes (Reolink Baichuan, ONVIF
|
|
20975
|
-
* analytics
|
|
21074
|
+
* analytics). The provider emits ProviderMotion
|
|
20976
21075
|
* events; the orchestrator forwards to `reportMotion`.
|
|
20977
21076
|
*/
|
|
20978
21077
|
motionSources: MotionSourcesSchema.default(["analyzer"]),
|
|
@@ -21214,7 +21313,26 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
|
|
|
21214
21313
|
className: string(),
|
|
21215
21314
|
/** Camera the pixels came from. Diagnostics + log tags ONLY — never routing. */
|
|
21216
21315
|
sourceDeviceId: number()
|
|
21217
|
-
}), RunStatelessStepResultSchema, { kind: "mutation" })
|
|
21316
|
+
}), RunStatelessStepResultSchema, { kind: "mutation" }), method(object({
|
|
21317
|
+
deviceId: number(),
|
|
21318
|
+
/** Opaque to the runner — the hub's track id. */
|
|
21319
|
+
trackId: string(),
|
|
21320
|
+
kind: ParkedFrameKindSchema,
|
|
21321
|
+
handle: FrameHandleSchema,
|
|
21322
|
+
/** Normalized [0,1] window to cut. `{0,0,1,1}` for a full frame. */
|
|
21323
|
+
bbox: NativeCropBboxSchema,
|
|
21324
|
+
/** Width cap for a full-frame park (the `keyFrame` native cap). */
|
|
21325
|
+
maxWidth: number().int().positive().optional(),
|
|
21326
|
+
/** The frame instant (caller's clock) — orders parks for one key. */
|
|
21327
|
+
timestamp: number()
|
|
21328
|
+
}), ParkTrackFrameResultSchema, { kind: "mutation" }), method(object({
|
|
21329
|
+
deviceId: number(),
|
|
21330
|
+
trackId: string(),
|
|
21331
|
+
kind: ParkedFrameKindSchema
|
|
21332
|
+
}), ParkedTrackFrameSchema.nullable()), method(object({
|
|
21333
|
+
deviceId: number(),
|
|
21334
|
+
trackId: string()
|
|
21335
|
+
}), object({ released: number().int().nonnegative() }), { kind: "mutation" });
|
|
21218
21336
|
var CameraPipelineConfigSchema = object({
|
|
21219
21337
|
engine: PipelineEngineChoiceSchema.optional(),
|
|
21220
21338
|
steps: array(PipelineStepInputSchema).readonly(),
|
|
@@ -24388,8 +24506,8 @@ onStatusChanged: { data: object({
|
|
|
24388
24506
|
/**
|
|
24389
24507
|
* Runtime-state slice — every provider that registers this cap
|
|
24390
24508
|
* stores the same shape under `device.runtimeState[battery]`.
|
|
24391
|
-
* Cross-provider uniformity: a Reolink Argus, a
|
|
24392
|
-
*
|
|
24509
|
+
* Cross-provider uniformity: a Reolink Argus, a sensor proxy,
|
|
24510
|
+
* an ONVIF battery cam all read/write the same keys.
|
|
24393
24511
|
* Consumers (BatteryBadge, snapshot wrapper sleep gate) read once
|
|
24394
24512
|
* via `device.runtimeState.getCapState('battery')` regardless of
|
|
24395
24513
|
* the underlying driver.
|
|
@@ -24522,7 +24640,7 @@ DeviceType.Button, method(object({ deviceId: number().int().nonnegative() }), _v
|
|
|
24522
24640
|
*
|
|
24523
24641
|
* Implementations:
|
|
24524
24642
|
* - Each camera-providing addon registers this cap natively per
|
|
24525
|
-
* device (Reolink, Hikvision, RTSP,
|
|
24643
|
+
* device (Reolink, Hikvision, RTSP, ONVIF self).
|
|
24526
24644
|
* - Returns a snapshot from the persisted device config blob — no
|
|
24527
24645
|
* extra round-trip to the camera, no probing.
|
|
24528
24646
|
* - The cap is admin-only (`auth: 'admin'`) — credentials must not
|
|
@@ -26622,7 +26740,7 @@ var AvailableIntegrationTypeSchema = object({
|
|
|
26622
26740
|
* Which integration-marker cap the addon declared, so the wizard can
|
|
26623
26741
|
* branch on CAP — never on addon name. `device-adoption` integrations
|
|
26624
26742
|
* (Home Assistant, …) route through the broker step (Approach A);
|
|
26625
|
-
* `device-provider` integrations (Reolink/
|
|
26743
|
+
* `device-provider` integrations (Reolink/ONVIF) keep the
|
|
26626
26744
|
* legacy config → discovery flow.
|
|
26627
26745
|
*/
|
|
26628
26746
|
kind: _enum(["device-adoption", "device-provider"]),
|
|
@@ -29990,7 +30108,23 @@ var RecordingRangeSchema = object({
|
|
|
29990
30108
|
});
|
|
29991
30109
|
var RecordingAvailabilitySchema = object({
|
|
29992
30110
|
deviceId: number(),
|
|
29993
|
-
ranges: array(RecordingRangeSchema)
|
|
30111
|
+
ranges: array(RecordingRangeSchema),
|
|
30112
|
+
/**
|
|
30113
|
+
* Every profile this camera has footage in — not only the one `ranges`
|
|
30114
|
+
* describes (D433).
|
|
30115
|
+
*
|
|
30116
|
+
* `ranges` answers for ONE profile by design: the timeline is a single bar,
|
|
30117
|
+
* and enumerating all of them triples the directory reads for a bar that
|
|
30118
|
+
* would look identical. But the answer used to say nothing about that, so a
|
|
30119
|
+
* caller asking "what can I export?" read the single preferred profile as
|
|
30120
|
+
* the only one that exists — on this deployment every camera records `high`
|
|
30121
|
+
* AND `low`, the low tree holding 14 GB for camera 615 alone, and the export
|
|
30122
|
+
* UI could not see it.
|
|
30123
|
+
*
|
|
30124
|
+
* Cheap: it is the same shallow directory read the profile CHOICE already
|
|
30125
|
+
* makes. Ask for a specific profile's ranges with the `profile` input.
|
|
30126
|
+
*/
|
|
30127
|
+
profilesWithFootage: array(string())
|
|
29994
30128
|
});
|
|
29995
30129
|
var RecordingDaysSchema = object({
|
|
29996
30130
|
deviceId: number(),
|
|
@@ -30016,7 +30150,11 @@ var RecordingDaysSchema = object({
|
|
|
30016
30150
|
var RecordingAvailabilityForDeviceSchema = object({
|
|
30017
30151
|
deviceId: number(),
|
|
30018
30152
|
read: _enum(["read", "unreadable"]),
|
|
30019
|
-
ranges: array(RecordingRangeSchema).readonly()
|
|
30153
|
+
ranges: array(RecordingRangeSchema).readonly(),
|
|
30154
|
+
/** Same field, same meaning, as the singular answer (D433). A row that
|
|
30155
|
+
* dropped it would tell a grid caller the archive holds one profile.
|
|
30156
|
+
* Empty on an `'unreadable'` row: nobody looked. */
|
|
30157
|
+
profilesWithFootage: array(string()).readonly()
|
|
30020
30158
|
});
|
|
30021
30159
|
/**
|
|
30022
30160
|
* One camera's row in a `getDaysWithRecordingsBatch` answer. Same rule as
|
|
@@ -30046,13 +30184,31 @@ var RecordingManifestSchema = object({
|
|
|
30046
30184
|
*/
|
|
30047
30185
|
playbackEndpoints: array(string())
|
|
30048
30186
|
});
|
|
30049
|
-
/**
|
|
30050
|
-
*
|
|
30187
|
+
/**
|
|
30188
|
+
* Recording storage usage for one camera — what the ARCHIVE holds for it,
|
|
30189
|
+
* across every profile and every resolvable location on this node.
|
|
30190
|
+
*
|
|
30191
|
+
* ## Archive vs residency, which is the whole point of this shape (D418)
|
|
30192
|
+
*
|
|
30193
|
+
* `usedBytes` / `oldestMs` / `segments` are the durable hour ledger's numbers:
|
|
30194
|
+
* the same quantity `RecordingLocationUsage.usedBytes` reports for the volume
|
|
30195
|
+
* this camera writes to, so the two can be added up and compared.
|
|
30196
|
+
*
|
|
30197
|
+
* They were not always. Until D418 this row came from the recorder's in-RAM
|
|
30198
|
+
* `RecordingIndex`, which since D287 holds only the live tail plus the hours
|
|
30199
|
+
* somebody hydrated — so a hub with 1.9 TB and 3.3 days of footage reported
|
|
30200
|
+
* 60.5 GB and "oldest: three hours ago" on the same page as the volume row
|
|
30201
|
+
* that said otherwise, and two people read it as retention eating recent
|
|
30202
|
+
* footage. Residency is still reported, under `residentBytes` /
|
|
30203
|
+
* `residentOldestMs`, which answer a different question and say so.
|
|
30204
|
+
*/
|
|
30051
30205
|
var RecordingDeviceUsageSchema = object({
|
|
30052
30206
|
deviceId: number(),
|
|
30207
|
+
/** Bytes the ARCHIVE holds for this camera on this node's resolvable
|
|
30208
|
+
* recordings locations. */
|
|
30053
30209
|
usedBytes: number(),
|
|
30054
30210
|
/**
|
|
30055
|
-
* Start of this camera's OLDEST
|
|
30211
|
+
* Start of this camera's OLDEST ARCHIVED segment, across every profile and
|
|
30056
30212
|
* location — the "Oldest footage" column in Recordings → Storage, and the
|
|
30057
30213
|
* only honest answer to "is retention actually holding?" per camera.
|
|
30058
30214
|
*
|
|
@@ -30062,7 +30218,24 @@ var RecordingDeviceUsageSchema = object({
|
|
|
30062
30218
|
* (types) and the addon ship on different trains, and the addon is usually
|
|
30063
30219
|
* the later of the two.
|
|
30064
30220
|
*/
|
|
30065
|
-
oldestMs: number().nullable().optional()
|
|
30221
|
+
oldestMs: number().nullable().optional(),
|
|
30222
|
+
/** Segments the archive holds for this camera — the "M" beside `usedBytes`.
|
|
30223
|
+
* OPTIONAL for the same train-skew reason as `oldestMs`. */
|
|
30224
|
+
segments: number().optional(),
|
|
30225
|
+
/**
|
|
30226
|
+
* RESIDENCY, not the archive: bytes the recorder process currently holds in
|
|
30227
|
+
* its RAM index — the live tail plus the hours a reader hydrated.
|
|
30228
|
+
*
|
|
30229
|
+
* It answers "what can be served without touching the disk", never "how much
|
|
30230
|
+
* footage this camera has". A UI that renders it must label it as such, and
|
|
30231
|
+
* must never total it as storage. OPTIONAL: a recorder predating D418 omits
|
|
30232
|
+
* it, and so does a node whose ledger could not answer.
|
|
30233
|
+
*/
|
|
30234
|
+
residentBytes: number().optional(),
|
|
30235
|
+
/** The residency counterpart of `oldestMs` — the oldest segment currently in
|
|
30236
|
+
* RAM, which on a healthy recorder is minutes ago and means nothing about
|
|
30237
|
+
* retention. `null` = nothing resident. */
|
|
30238
|
+
residentOldestMs: number().nullable().optional()
|
|
30066
30239
|
});
|
|
30067
30240
|
/** Recording storage usage + capacity for one storage location. */
|
|
30068
30241
|
var RecordingLocationUsageSchema = object({
|
|
@@ -30100,6 +30273,17 @@ var RecordingStorageUsageSchema = object({
|
|
|
30100
30273
|
totalUsedBytes: number(),
|
|
30101
30274
|
devices: array(RecordingDeviceUsageSchema),
|
|
30102
30275
|
/**
|
|
30276
|
+
* WHERE `devices[]` came from, so an empty table is never mistaken for empty
|
|
30277
|
+
* disks (D418).
|
|
30278
|
+
*
|
|
30279
|
+
* `archive` = the durable hour ledger answered. `unavailable` = this node
|
|
30280
|
+
* declared no ledger and the recorder REFUSED rather than answering the
|
|
30281
|
+
* question with the resident index (D295 rule 3) — the rows are UNKNOWN, not
|
|
30282
|
+
* zero, and a UI must say so. OPTIONAL: a recorder predating D418 omits it,
|
|
30283
|
+
* and its rows are residency.
|
|
30284
|
+
*/
|
|
30285
|
+
devicesRead: _enum(["archive", "unavailable"]).optional(),
|
|
30286
|
+
/**
|
|
30103
30287
|
* Per-physical-volume capacity. OPTIONAL, and consumers must render the rest
|
|
30104
30288
|
* of the payload without it: the hub serves this method through a BAKED
|
|
30105
30289
|
* router, so a hub whose framework train predates a change to this array
|
|
@@ -30260,7 +30444,14 @@ var ReadWindowBytesResultSchema = discriminatedUnion("kind", [object({
|
|
|
30260
30444
|
method(object({
|
|
30261
30445
|
deviceId: number(),
|
|
30262
30446
|
fromMs: number(),
|
|
30263
|
-
toMs: number()
|
|
30447
|
+
toMs: number(),
|
|
30448
|
+
/**
|
|
30449
|
+
* Answer for THIS profile instead of the preferred one (D433). Absent
|
|
30450
|
+
* keeps the timeline's behaviour — one bar, one profile, one set of
|
|
30451
|
+
* reads. `profilesWithFootage` on the answer says what may be asked
|
|
30452
|
+
* for.
|
|
30453
|
+
*/
|
|
30454
|
+
profile: string().optional()
|
|
30264
30455
|
}), RecordingAvailabilitySchema, {
|
|
30265
30456
|
kind: "query",
|
|
30266
30457
|
auth: "protected"
|
|
@@ -33979,7 +34170,7 @@ function toDeviceSummary(device, addonId) {
|
|
|
33979
34170
|
};
|
|
33980
34171
|
}
|
|
33981
34172
|
/**
|
|
33982
|
-
* Base class for device-provider addons (rtsp, onvif
|
|
34173
|
+
* Base class for device-provider addons (rtsp, onvif).
|
|
33983
34174
|
*
|
|
33984
34175
|
* Provides default implementations for the common device-provider cap
|
|
33985
34176
|
* methods (`start`, `stop`, `getStatus`, `getDevices`, `supportsDiscovery`,
|
|
@@ -38701,6 +38892,24 @@ Object.freeze({
|
|
|
38701
38892
|
addonId: null,
|
|
38702
38893
|
access: "view"
|
|
38703
38894
|
},
|
|
38895
|
+
"pipelineRunner.getParkedTrackFrame": {
|
|
38896
|
+
capName: "pipeline-runner",
|
|
38897
|
+
capScope: "system",
|
|
38898
|
+
addonId: null,
|
|
38899
|
+
access: "view"
|
|
38900
|
+
},
|
|
38901
|
+
"pipelineRunner.parkTrackFrame": {
|
|
38902
|
+
capName: "pipeline-runner",
|
|
38903
|
+
capScope: "system",
|
|
38904
|
+
addonId: null,
|
|
38905
|
+
access: "create"
|
|
38906
|
+
},
|
|
38907
|
+
"pipelineRunner.releaseParkedTrackFrames": {
|
|
38908
|
+
capName: "pipeline-runner",
|
|
38909
|
+
capScope: "system",
|
|
38910
|
+
addonId: null,
|
|
38911
|
+
access: "create"
|
|
38912
|
+
},
|
|
38704
38913
|
"pipelineRunner.reportMotion": {
|
|
38705
38914
|
capName: "pipeline-runner",
|
|
38706
38915
|
capScope: "system",
|
|
@@ -41978,6 +42187,21 @@ Object.freeze({
|
|
|
41978
42187
|
form: "single",
|
|
41979
42188
|
optional: false
|
|
41980
42189
|
}],
|
|
42190
|
+
"pipelineRunner.getParkedTrackFrame": [{
|
|
42191
|
+
name: "deviceId",
|
|
42192
|
+
form: "single",
|
|
42193
|
+
optional: false
|
|
42194
|
+
}],
|
|
42195
|
+
"pipelineRunner.parkTrackFrame": [{
|
|
42196
|
+
name: "deviceId",
|
|
42197
|
+
form: "single",
|
|
42198
|
+
optional: false
|
|
42199
|
+
}],
|
|
42200
|
+
"pipelineRunner.releaseParkedTrackFrames": [{
|
|
42201
|
+
name: "deviceId",
|
|
42202
|
+
form: "single",
|
|
42203
|
+
optional: false
|
|
42204
|
+
}],
|
|
41981
42205
|
"pipelineRunner.reportMotion": [{
|
|
41982
42206
|
name: "deviceId",
|
|
41983
42207
|
form: "single",
|
|
@@ -42669,7 +42893,7 @@ var PreviewTextField = string().max(200);
|
|
|
42669
42893
|
* Whether the notification's preview is a STILL or a short animation.
|
|
42670
42894
|
*
|
|
42671
42895
|
* The operator's ask, verbatim: *"inviato come gif o video (come per le altre
|
|
42672
|
-
* rule)"* —
|
|
42896
|
+
* rule)"* — the other rules already offer an animated preview, and a ten-hour
|
|
42673
42897
|
* night reads better as three seconds of motion than as one frame of it. Both
|
|
42674
42898
|
* modes get the SAME treatment (blurred frame, large centred title); `'gif'`
|
|
42675
42899
|
* simply applies it to a dozen frames sampled across the render and assembles
|
package/dist/addon.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import net from "node:net";
|
|
2
|
-
//#region ../types/dist/event-category-
|
|
2
|
+
//#region ../types/dist/event-category-DAXzJeTX.mjs
|
|
3
3
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
4
4
|
EventCategory["SystemBoot"] = "system.boot";
|
|
5
5
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -591,7 +591,6 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
591
591
|
* issue. Payload `PipelineAnalyticsPlateGalleryChangedPayload`.
|
|
592
592
|
*/
|
|
593
593
|
EventCategory["PipelineAnalyticsPlateGalleryChanged"] = "pipeline-analytics.plate-gallery-changed";
|
|
594
|
-
EventCategory["FrigateLiveEvent"] = "frigate.live-event";
|
|
595
594
|
EventCategory["CameraStreamsProfileSlotsChanged"] = "camera-streams.onProfileSlotsChanged";
|
|
596
595
|
/**
|
|
597
596
|
* Stream-broker health watchdog. Per-broker (deviceId/profile) emission.
|
|
@@ -12657,7 +12656,7 @@ DeviceType.Camera;
|
|
|
12657
12656
|
var SourceInfoSchema = object({
|
|
12658
12657
|
/** Live dispatch key — mutable when the source system allows rename. */
|
|
12659
12658
|
id: string(),
|
|
12660
|
-
/** Source system tag — e.g. 'homeassistant' | 'reolink' | '
|
|
12659
|
+
/** Source system tag — e.g. 'homeassistant' | 'reolink' | 'onvif'. */
|
|
12661
12660
|
system: string(),
|
|
12662
12661
|
/** Immutable upstream identifier when available (HA `unique_id`, … ).
|
|
12663
12662
|
* Used to detect rename when `id` changes. */
|
|
@@ -12670,7 +12669,7 @@ var SourceInfoSchema = object({
|
|
|
12670
12669
|
/**
|
|
12671
12670
|
* Build the synthetic SourceInfo every existing provider falls back to
|
|
12672
12671
|
* when no upstream value has been persisted. Keeps non-migrated providers
|
|
12673
|
-
* (Reolink / Hikvision / ONVIF /
|
|
12672
|
+
* (Reolink / Hikvision / ONVIF / RTSP) functional without code
|
|
12674
12673
|
* changes — `id` reuses the CamStack stableId, `system` reuses the addon
|
|
12675
12674
|
* id. Real upstream identity replaces this once a provider migrates and
|
|
12676
12675
|
* calls `updateSourceInfo()` with concrete values.
|
|
@@ -13332,7 +13331,7 @@ var deviceProviderCapability = {
|
|
|
13332
13331
|
* - `device-management.router.ts` (deleted in Phase 2)
|
|
13333
13332
|
* - `device-ops.router.ts` (compat layer — deleted; device-provider ops absorbed here)
|
|
13334
13333
|
*
|
|
13335
|
-
* All device provider addons (rtsp, onvif,
|
|
13334
|
+
* All device provider addons (rtsp, onvif, …) are hub-local: they may
|
|
13336
13335
|
* fork into separate processes but never run on remote cluster agents. Therefore:
|
|
13337
13336
|
* - No nodeId routing needed — this is a pure hub singleton.
|
|
13338
13337
|
* - The hub's DeviceRegistry is the single source of truth for all live devices.
|
|
@@ -17380,7 +17379,7 @@ var NcRuleInputSchema = object({
|
|
|
17380
17379
|
* The measured seven-person arrival on device 590 spans 110 s with every
|
|
17381
17380
|
* internal gap under 30 s. A 12 s fixed window cuts it into three groups; an
|
|
17382
17381
|
* idle cutoff holds it as one and ends it when the arrival actually ends.
|
|
17383
|
-
* 30 is
|
|
17382
|
+
* 30 s is a widely shipped value for the same decision.
|
|
17384
17383
|
*
|
|
17385
17384
|
* ### What it replaces
|
|
17386
17385
|
*
|
|
@@ -19462,6 +19461,13 @@ var ZoneCrossingSchema = object({
|
|
|
19462
19461
|
/** Zone display name at crossing time (falls back to the id). */
|
|
19463
19462
|
zoneName: string().optional()
|
|
19464
19463
|
});
|
|
19464
|
+
/** One zone a box was stamped with, and how much of the BOX fell inside it. */
|
|
19465
|
+
var ZoneOverlapSchema = object({
|
|
19466
|
+
zoneId: string(),
|
|
19467
|
+
zoneName: string().optional(),
|
|
19468
|
+
/** Percentage of the BOX area inside the zone, 0–100. */
|
|
19469
|
+
overlapPct: number()
|
|
19470
|
+
});
|
|
19465
19471
|
var ObjectEventSchema = object({
|
|
19466
19472
|
...BaseEventFields,
|
|
19467
19473
|
kind: literal("object"),
|
|
@@ -19486,6 +19492,35 @@ var ObjectEventSchema = object({
|
|
|
19486
19492
|
bbox: BoundingBoxSchema.optional(),
|
|
19487
19493
|
/** Heavy JSON — omitted in slim projection. */
|
|
19488
19494
|
zones: array(string()).readonly().optional(),
|
|
19495
|
+
/**
|
|
19496
|
+
* How far inside each stamped zone the box actually was, as a percentage of
|
|
19497
|
+
* the BOX area.
|
|
19498
|
+
*
|
|
19499
|
+
* Membership alone cannot express "at least a third of it inside", which is
|
|
19500
|
+
* the bar an operator argues with — and the number already existed: the
|
|
19501
|
+
* engine computed it, the pipeline logged it, and then discarded it. It
|
|
19502
|
+
* matters most on the events that carry no track, where a rule has nothing
|
|
19503
|
+
* else to judge by.
|
|
19504
|
+
*/
|
|
19505
|
+
zoneOverlaps: array(ZoneOverlapSchema).readonly().optional(),
|
|
19506
|
+
/**
|
|
19507
|
+
* Present when this event describes a detection the TRACKER refused, so it
|
|
19508
|
+
* has no track and never will.
|
|
19509
|
+
*
|
|
19510
|
+
* A zone-scoped immediate rule asks "is there an animal in the flowerbed
|
|
19511
|
+
* NOW?"; tracking answers a different question ("is this the same subject as
|
|
19512
|
+
* before?") whose confirmation threshold presumes continuity. On 2026-09-09 a
|
|
19513
|
+
* dog at 0.7729, 100% inside a watched zone, was refused three times in six
|
|
19514
|
+
* seconds with three different candidate ids — seven analysed frames in the
|
|
19515
|
+
* window, the subject in a handful of them, metres apart — and produced no
|
|
19516
|
+
* event at all.
|
|
19517
|
+
*
|
|
19518
|
+
* It is NAMED rather than merely implied by a missing `trackId`: an event
|
|
19519
|
+
* with no track and no reason is indistinguishable from a track whose media
|
|
19520
|
+
* went missing, and a consumer that asks this one for a best shot or a
|
|
19521
|
+
* history is asking for something that never existed.
|
|
19522
|
+
*/
|
|
19523
|
+
spawnRefused: string().optional(),
|
|
19489
19524
|
/** Omitted in slim projection. */
|
|
19490
19525
|
state: TrackStateSchema.optional(),
|
|
19491
19526
|
/**
|
|
@@ -19912,7 +19947,17 @@ var EventDensityBucketSchema = object({
|
|
|
19912
19947
|
bucketStart: number(),
|
|
19913
19948
|
motion: number().int(),
|
|
19914
19949
|
object: number().int(),
|
|
19915
|
-
audio: number().int()
|
|
19950
|
+
audio: number().int(),
|
|
19951
|
+
/**
|
|
19952
|
+
* Energy-weighted mean dBFS of the audio events in this bucket — the LEVEL,
|
|
19953
|
+
* as opposed to `audio`, which is their COUNT (D431).
|
|
19954
|
+
*
|
|
19955
|
+
* ABSENT when the bucket holds no audio event. Absence means "nothing was
|
|
19956
|
+
* measured", which is not the same claim as silence, and a lane that cannot
|
|
19957
|
+
* tell them apart paints a quiet hour at full scale — which is exactly what
|
|
19958
|
+
* the count-on-a-level-meter did.
|
|
19959
|
+
*/
|
|
19960
|
+
audioDbfs: number().optional()
|
|
19916
19961
|
});
|
|
19917
19962
|
/**
|
|
19918
19963
|
* One camera's row in a `getEventDensityBatch` answer.
|
|
@@ -20559,6 +20604,60 @@ var NativeCropResultSchema = object({
|
|
|
20559
20604
|
*/
|
|
20560
20605
|
tier: _enum(["native", "ram-fullframe"]).optional()
|
|
20561
20606
|
});
|
|
20607
|
+
/**
|
|
20608
|
+
* What a PARKED frame is for — the `kind` half of the `(deviceId, trackId,
|
|
20609
|
+
* kind)` key ([D422](../../../docs/decisions/adr-0422-a-relevant-frame-is-parked-when-it-becomes-relevant.md)).
|
|
20610
|
+
*
|
|
20611
|
+
* - `keyFrame` — the track's clean best FULL frame at native width (capped by
|
|
20612
|
+
* the caller's `maxWidth`). What `keyFrame` + `keyFrameSmall` are written
|
|
20613
|
+
* from, and what the detail plane's full-frame rung cuts from.
|
|
20614
|
+
* - `thumbnail` — the best-shot subject slab: the caller's 16:9 central-square
|
|
20615
|
+
* window, cut by the runner at uncapped native resolution.
|
|
20616
|
+
*
|
|
20617
|
+
* The runner never interprets `trackId`; it is an opaque key the hub owns.
|
|
20618
|
+
*/
|
|
20619
|
+
var ParkedFrameKindSchema = _enum(["keyFrame", "thumbnail"]);
|
|
20620
|
+
/**
|
|
20621
|
+
* Why a park did NOT happen. Every one is logged on the runner with
|
|
20622
|
+
* `tags: { deviceId }` and the handle's measured age, because a handle already
|
|
20623
|
+
* gone at park time IS the defect the 150–500 ms window exists to prevent —
|
|
20624
|
+
* never a reason to retry in a loop.
|
|
20625
|
+
*
|
|
20626
|
+
* - `handle-gone` — the native surface no longer resolves this handle (never
|
|
20627
|
+
* registered, past the lease bound, or the worker released it). `detail`
|
|
20628
|
+
* carries the runner's own miss reason.
|
|
20629
|
+
* - `encode-failed` — pixels resolved and the JPEG encode threw.
|
|
20630
|
+
*/
|
|
20631
|
+
var ParkRefusalSchema = _enum(["handle-gone", "encode-failed"]);
|
|
20632
|
+
/** Answer to `parkTrackFrame` — a discriminated union, so "not parked" always names why. */
|
|
20633
|
+
var ParkTrackFrameResultSchema = discriminatedUnion("parked", [object({
|
|
20634
|
+
parked: literal(true),
|
|
20635
|
+
/** The node holding the parcel — what a later retrieval must be pinned to. */
|
|
20636
|
+
nodeId: string(),
|
|
20637
|
+
width: number().int().positive(),
|
|
20638
|
+
height: number().int().positive(),
|
|
20639
|
+
/** JPEG bytes the parcel costs on the node. */
|
|
20640
|
+
bytes: number().int().nonnegative(),
|
|
20641
|
+
/** Whether this park replaced a parcel already held for the key. */
|
|
20642
|
+
replaced: boolean()
|
|
20643
|
+
}), object({
|
|
20644
|
+
parked: literal(false),
|
|
20645
|
+
nodeId: string(),
|
|
20646
|
+
reason: ParkRefusalSchema,
|
|
20647
|
+
/** Age of the handle at the park, on the runner's clock; null if unknown. */
|
|
20648
|
+
handleAgeMs: number().nullable(),
|
|
20649
|
+
detail: string().optional()
|
|
20650
|
+
})]);
|
|
20651
|
+
/** A retrieved parcel — the runner's own JPEG, base64 for the wire. */
|
|
20652
|
+
var ParkedTrackFrameSchema = object({
|
|
20653
|
+
jpeg: string(),
|
|
20654
|
+
width: number().int().positive(),
|
|
20655
|
+
height: number().int().positive(),
|
|
20656
|
+
/** The frame instant the parcel shows (the caller's clock, echoed back). */
|
|
20657
|
+
timestamp: number(),
|
|
20658
|
+
/** When the node stored it (the node's clock). */
|
|
20659
|
+
parkedAt: number()
|
|
20660
|
+
});
|
|
20562
20661
|
/** Parent detection context passed to `runDetailSubtree` — the crop's
|
|
20563
20662
|
* originating detection, in FRAME-space coordinates. Reuses
|
|
20564
20663
|
* `NativeCropBboxSchema`'s `{x,y,w,h}` shape (same numeric fields; here
|
|
@@ -20948,7 +21047,7 @@ var RunnerCameraConfigSchema = object({
|
|
|
20948
21047
|
* - `analyzer`: ML/frame-diff motion detection (motion-wasm or other
|
|
20949
21048
|
* analyzer providers) running on decoded frames in this runner.
|
|
20950
21049
|
* - `onboard`: camera-native motion pushes (Reolink Baichuan, ONVIF
|
|
20951
|
-
* analytics
|
|
21050
|
+
* analytics). The provider emits ProviderMotion
|
|
20952
21051
|
* events; the orchestrator forwards to `reportMotion`.
|
|
20953
21052
|
*/
|
|
20954
21053
|
motionSources: MotionSourcesSchema.default(["analyzer"]),
|
|
@@ -21190,7 +21289,26 @@ method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mu
|
|
|
21190
21289
|
className: string(),
|
|
21191
21290
|
/** Camera the pixels came from. Diagnostics + log tags ONLY — never routing. */
|
|
21192
21291
|
sourceDeviceId: number()
|
|
21193
|
-
}), RunStatelessStepResultSchema, { kind: "mutation" })
|
|
21292
|
+
}), RunStatelessStepResultSchema, { kind: "mutation" }), method(object({
|
|
21293
|
+
deviceId: number(),
|
|
21294
|
+
/** Opaque to the runner — the hub's track id. */
|
|
21295
|
+
trackId: string(),
|
|
21296
|
+
kind: ParkedFrameKindSchema,
|
|
21297
|
+
handle: FrameHandleSchema,
|
|
21298
|
+
/** Normalized [0,1] window to cut. `{0,0,1,1}` for a full frame. */
|
|
21299
|
+
bbox: NativeCropBboxSchema,
|
|
21300
|
+
/** Width cap for a full-frame park (the `keyFrame` native cap). */
|
|
21301
|
+
maxWidth: number().int().positive().optional(),
|
|
21302
|
+
/** The frame instant (caller's clock) — orders parks for one key. */
|
|
21303
|
+
timestamp: number()
|
|
21304
|
+
}), ParkTrackFrameResultSchema, { kind: "mutation" }), method(object({
|
|
21305
|
+
deviceId: number(),
|
|
21306
|
+
trackId: string(),
|
|
21307
|
+
kind: ParkedFrameKindSchema
|
|
21308
|
+
}), ParkedTrackFrameSchema.nullable()), method(object({
|
|
21309
|
+
deviceId: number(),
|
|
21310
|
+
trackId: string()
|
|
21311
|
+
}), object({ released: number().int().nonnegative() }), { kind: "mutation" });
|
|
21194
21312
|
var CameraPipelineConfigSchema = object({
|
|
21195
21313
|
engine: PipelineEngineChoiceSchema.optional(),
|
|
21196
21314
|
steps: array(PipelineStepInputSchema).readonly(),
|
|
@@ -24364,8 +24482,8 @@ onStatusChanged: { data: object({
|
|
|
24364
24482
|
/**
|
|
24365
24483
|
* Runtime-state slice — every provider that registers this cap
|
|
24366
24484
|
* stores the same shape under `device.runtimeState[battery]`.
|
|
24367
|
-
* Cross-provider uniformity: a Reolink Argus, a
|
|
24368
|
-
*
|
|
24485
|
+
* Cross-provider uniformity: a Reolink Argus, a sensor proxy,
|
|
24486
|
+
* an ONVIF battery cam all read/write the same keys.
|
|
24369
24487
|
* Consumers (BatteryBadge, snapshot wrapper sleep gate) read once
|
|
24370
24488
|
* via `device.runtimeState.getCapState('battery')` regardless of
|
|
24371
24489
|
* the underlying driver.
|
|
@@ -24498,7 +24616,7 @@ DeviceType.Button, method(object({ deviceId: number().int().nonnegative() }), _v
|
|
|
24498
24616
|
*
|
|
24499
24617
|
* Implementations:
|
|
24500
24618
|
* - Each camera-providing addon registers this cap natively per
|
|
24501
|
-
* device (Reolink, Hikvision, RTSP,
|
|
24619
|
+
* device (Reolink, Hikvision, RTSP, ONVIF self).
|
|
24502
24620
|
* - Returns a snapshot from the persisted device config blob — no
|
|
24503
24621
|
* extra round-trip to the camera, no probing.
|
|
24504
24622
|
* - The cap is admin-only (`auth: 'admin'`) — credentials must not
|
|
@@ -26598,7 +26716,7 @@ var AvailableIntegrationTypeSchema = object({
|
|
|
26598
26716
|
* Which integration-marker cap the addon declared, so the wizard can
|
|
26599
26717
|
* branch on CAP — never on addon name. `device-adoption` integrations
|
|
26600
26718
|
* (Home Assistant, …) route through the broker step (Approach A);
|
|
26601
|
-
* `device-provider` integrations (Reolink/
|
|
26719
|
+
* `device-provider` integrations (Reolink/ONVIF) keep the
|
|
26602
26720
|
* legacy config → discovery flow.
|
|
26603
26721
|
*/
|
|
26604
26722
|
kind: _enum(["device-adoption", "device-provider"]),
|
|
@@ -29966,7 +30084,23 @@ var RecordingRangeSchema = object({
|
|
|
29966
30084
|
});
|
|
29967
30085
|
var RecordingAvailabilitySchema = object({
|
|
29968
30086
|
deviceId: number(),
|
|
29969
|
-
ranges: array(RecordingRangeSchema)
|
|
30087
|
+
ranges: array(RecordingRangeSchema),
|
|
30088
|
+
/**
|
|
30089
|
+
* Every profile this camera has footage in — not only the one `ranges`
|
|
30090
|
+
* describes (D433).
|
|
30091
|
+
*
|
|
30092
|
+
* `ranges` answers for ONE profile by design: the timeline is a single bar,
|
|
30093
|
+
* and enumerating all of them triples the directory reads for a bar that
|
|
30094
|
+
* would look identical. But the answer used to say nothing about that, so a
|
|
30095
|
+
* caller asking "what can I export?" read the single preferred profile as
|
|
30096
|
+
* the only one that exists — on this deployment every camera records `high`
|
|
30097
|
+
* AND `low`, the low tree holding 14 GB for camera 615 alone, and the export
|
|
30098
|
+
* UI could not see it.
|
|
30099
|
+
*
|
|
30100
|
+
* Cheap: it is the same shallow directory read the profile CHOICE already
|
|
30101
|
+
* makes. Ask for a specific profile's ranges with the `profile` input.
|
|
30102
|
+
*/
|
|
30103
|
+
profilesWithFootage: array(string())
|
|
29970
30104
|
});
|
|
29971
30105
|
var RecordingDaysSchema = object({
|
|
29972
30106
|
deviceId: number(),
|
|
@@ -29992,7 +30126,11 @@ var RecordingDaysSchema = object({
|
|
|
29992
30126
|
var RecordingAvailabilityForDeviceSchema = object({
|
|
29993
30127
|
deviceId: number(),
|
|
29994
30128
|
read: _enum(["read", "unreadable"]),
|
|
29995
|
-
ranges: array(RecordingRangeSchema).readonly()
|
|
30129
|
+
ranges: array(RecordingRangeSchema).readonly(),
|
|
30130
|
+
/** Same field, same meaning, as the singular answer (D433). A row that
|
|
30131
|
+
* dropped it would tell a grid caller the archive holds one profile.
|
|
30132
|
+
* Empty on an `'unreadable'` row: nobody looked. */
|
|
30133
|
+
profilesWithFootage: array(string()).readonly()
|
|
29996
30134
|
});
|
|
29997
30135
|
/**
|
|
29998
30136
|
* One camera's row in a `getDaysWithRecordingsBatch` answer. Same rule as
|
|
@@ -30022,13 +30160,31 @@ var RecordingManifestSchema = object({
|
|
|
30022
30160
|
*/
|
|
30023
30161
|
playbackEndpoints: array(string())
|
|
30024
30162
|
});
|
|
30025
|
-
/**
|
|
30026
|
-
*
|
|
30163
|
+
/**
|
|
30164
|
+
* Recording storage usage for one camera — what the ARCHIVE holds for it,
|
|
30165
|
+
* across every profile and every resolvable location on this node.
|
|
30166
|
+
*
|
|
30167
|
+
* ## Archive vs residency, which is the whole point of this shape (D418)
|
|
30168
|
+
*
|
|
30169
|
+
* `usedBytes` / `oldestMs` / `segments` are the durable hour ledger's numbers:
|
|
30170
|
+
* the same quantity `RecordingLocationUsage.usedBytes` reports for the volume
|
|
30171
|
+
* this camera writes to, so the two can be added up and compared.
|
|
30172
|
+
*
|
|
30173
|
+
* They were not always. Until D418 this row came from the recorder's in-RAM
|
|
30174
|
+
* `RecordingIndex`, which since D287 holds only the live tail plus the hours
|
|
30175
|
+
* somebody hydrated — so a hub with 1.9 TB and 3.3 days of footage reported
|
|
30176
|
+
* 60.5 GB and "oldest: three hours ago" on the same page as the volume row
|
|
30177
|
+
* that said otherwise, and two people read it as retention eating recent
|
|
30178
|
+
* footage. Residency is still reported, under `residentBytes` /
|
|
30179
|
+
* `residentOldestMs`, which answer a different question and say so.
|
|
30180
|
+
*/
|
|
30027
30181
|
var RecordingDeviceUsageSchema = object({
|
|
30028
30182
|
deviceId: number(),
|
|
30183
|
+
/** Bytes the ARCHIVE holds for this camera on this node's resolvable
|
|
30184
|
+
* recordings locations. */
|
|
30029
30185
|
usedBytes: number(),
|
|
30030
30186
|
/**
|
|
30031
|
-
* Start of this camera's OLDEST
|
|
30187
|
+
* Start of this camera's OLDEST ARCHIVED segment, across every profile and
|
|
30032
30188
|
* location — the "Oldest footage" column in Recordings → Storage, and the
|
|
30033
30189
|
* only honest answer to "is retention actually holding?" per camera.
|
|
30034
30190
|
*
|
|
@@ -30038,7 +30194,24 @@ var RecordingDeviceUsageSchema = object({
|
|
|
30038
30194
|
* (types) and the addon ship on different trains, and the addon is usually
|
|
30039
30195
|
* the later of the two.
|
|
30040
30196
|
*/
|
|
30041
|
-
oldestMs: number().nullable().optional()
|
|
30197
|
+
oldestMs: number().nullable().optional(),
|
|
30198
|
+
/** Segments the archive holds for this camera — the "M" beside `usedBytes`.
|
|
30199
|
+
* OPTIONAL for the same train-skew reason as `oldestMs`. */
|
|
30200
|
+
segments: number().optional(),
|
|
30201
|
+
/**
|
|
30202
|
+
* RESIDENCY, not the archive: bytes the recorder process currently holds in
|
|
30203
|
+
* its RAM index — the live tail plus the hours a reader hydrated.
|
|
30204
|
+
*
|
|
30205
|
+
* It answers "what can be served without touching the disk", never "how much
|
|
30206
|
+
* footage this camera has". A UI that renders it must label it as such, and
|
|
30207
|
+
* must never total it as storage. OPTIONAL: a recorder predating D418 omits
|
|
30208
|
+
* it, and so does a node whose ledger could not answer.
|
|
30209
|
+
*/
|
|
30210
|
+
residentBytes: number().optional(),
|
|
30211
|
+
/** The residency counterpart of `oldestMs` — the oldest segment currently in
|
|
30212
|
+
* RAM, which on a healthy recorder is minutes ago and means nothing about
|
|
30213
|
+
* retention. `null` = nothing resident. */
|
|
30214
|
+
residentOldestMs: number().nullable().optional()
|
|
30042
30215
|
});
|
|
30043
30216
|
/** Recording storage usage + capacity for one storage location. */
|
|
30044
30217
|
var RecordingLocationUsageSchema = object({
|
|
@@ -30076,6 +30249,17 @@ var RecordingStorageUsageSchema = object({
|
|
|
30076
30249
|
totalUsedBytes: number(),
|
|
30077
30250
|
devices: array(RecordingDeviceUsageSchema),
|
|
30078
30251
|
/**
|
|
30252
|
+
* WHERE `devices[]` came from, so an empty table is never mistaken for empty
|
|
30253
|
+
* disks (D418).
|
|
30254
|
+
*
|
|
30255
|
+
* `archive` = the durable hour ledger answered. `unavailable` = this node
|
|
30256
|
+
* declared no ledger and the recorder REFUSED rather than answering the
|
|
30257
|
+
* question with the resident index (D295 rule 3) — the rows are UNKNOWN, not
|
|
30258
|
+
* zero, and a UI must say so. OPTIONAL: a recorder predating D418 omits it,
|
|
30259
|
+
* and its rows are residency.
|
|
30260
|
+
*/
|
|
30261
|
+
devicesRead: _enum(["archive", "unavailable"]).optional(),
|
|
30262
|
+
/**
|
|
30079
30263
|
* Per-physical-volume capacity. OPTIONAL, and consumers must render the rest
|
|
30080
30264
|
* of the payload without it: the hub serves this method through a BAKED
|
|
30081
30265
|
* router, so a hub whose framework train predates a change to this array
|
|
@@ -30236,7 +30420,14 @@ var ReadWindowBytesResultSchema = discriminatedUnion("kind", [object({
|
|
|
30236
30420
|
method(object({
|
|
30237
30421
|
deviceId: number(),
|
|
30238
30422
|
fromMs: number(),
|
|
30239
|
-
toMs: number()
|
|
30423
|
+
toMs: number(),
|
|
30424
|
+
/**
|
|
30425
|
+
* Answer for THIS profile instead of the preferred one (D433). Absent
|
|
30426
|
+
* keeps the timeline's behaviour — one bar, one profile, one set of
|
|
30427
|
+
* reads. `profilesWithFootage` on the answer says what may be asked
|
|
30428
|
+
* for.
|
|
30429
|
+
*/
|
|
30430
|
+
profile: string().optional()
|
|
30240
30431
|
}), RecordingAvailabilitySchema, {
|
|
30241
30432
|
kind: "query",
|
|
30242
30433
|
auth: "protected"
|
|
@@ -33955,7 +34146,7 @@ function toDeviceSummary(device, addonId) {
|
|
|
33955
34146
|
};
|
|
33956
34147
|
}
|
|
33957
34148
|
/**
|
|
33958
|
-
* Base class for device-provider addons (rtsp, onvif
|
|
34149
|
+
* Base class for device-provider addons (rtsp, onvif).
|
|
33959
34150
|
*
|
|
33960
34151
|
* Provides default implementations for the common device-provider cap
|
|
33961
34152
|
* methods (`start`, `stop`, `getStatus`, `getDevices`, `supportsDiscovery`,
|
|
@@ -38677,6 +38868,24 @@ Object.freeze({
|
|
|
38677
38868
|
addonId: null,
|
|
38678
38869
|
access: "view"
|
|
38679
38870
|
},
|
|
38871
|
+
"pipelineRunner.getParkedTrackFrame": {
|
|
38872
|
+
capName: "pipeline-runner",
|
|
38873
|
+
capScope: "system",
|
|
38874
|
+
addonId: null,
|
|
38875
|
+
access: "view"
|
|
38876
|
+
},
|
|
38877
|
+
"pipelineRunner.parkTrackFrame": {
|
|
38878
|
+
capName: "pipeline-runner",
|
|
38879
|
+
capScope: "system",
|
|
38880
|
+
addonId: null,
|
|
38881
|
+
access: "create"
|
|
38882
|
+
},
|
|
38883
|
+
"pipelineRunner.releaseParkedTrackFrames": {
|
|
38884
|
+
capName: "pipeline-runner",
|
|
38885
|
+
capScope: "system",
|
|
38886
|
+
addonId: null,
|
|
38887
|
+
access: "create"
|
|
38888
|
+
},
|
|
38680
38889
|
"pipelineRunner.reportMotion": {
|
|
38681
38890
|
capName: "pipeline-runner",
|
|
38682
38891
|
capScope: "system",
|
|
@@ -41954,6 +42163,21 @@ Object.freeze({
|
|
|
41954
42163
|
form: "single",
|
|
41955
42164
|
optional: false
|
|
41956
42165
|
}],
|
|
42166
|
+
"pipelineRunner.getParkedTrackFrame": [{
|
|
42167
|
+
name: "deviceId",
|
|
42168
|
+
form: "single",
|
|
42169
|
+
optional: false
|
|
42170
|
+
}],
|
|
42171
|
+
"pipelineRunner.parkTrackFrame": [{
|
|
42172
|
+
name: "deviceId",
|
|
42173
|
+
form: "single",
|
|
42174
|
+
optional: false
|
|
42175
|
+
}],
|
|
42176
|
+
"pipelineRunner.releaseParkedTrackFrames": [{
|
|
42177
|
+
name: "deviceId",
|
|
42178
|
+
form: "single",
|
|
42179
|
+
optional: false
|
|
42180
|
+
}],
|
|
41957
42181
|
"pipelineRunner.reportMotion": [{
|
|
41958
42182
|
name: "deviceId",
|
|
41959
42183
|
form: "single",
|
|
@@ -42645,7 +42869,7 @@ var PreviewTextField = string().max(200);
|
|
|
42645
42869
|
* Whether the notification's preview is a STILL or a short animation.
|
|
42646
42870
|
*
|
|
42647
42871
|
* The operator's ask, verbatim: *"inviato come gif o video (come per le altre
|
|
42648
|
-
* rule)"* —
|
|
42872
|
+
* rule)"* — the other rules already offer an animated preview, and a ten-hour
|
|
42649
42873
|
* night reads better as three seconds of motion than as one frame of it. Both
|
|
42650
42874
|
* modes get the SAME treatment (blurred frame, large centred title); `'gif'`
|
|
42651
42875
|
* simply applies it to a dozen frames sampled across the render and assembles
|