@camstack/addon-notifiers 1.2.61 → 1.2.63

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/addon.js CHANGED
@@ -10679,6 +10679,89 @@ var LocationStatSchema = object({
10679
10679
  fileCount: number(),
10680
10680
  present: boolean()
10681
10681
  });
10682
+ /** Lifecycle of a backup run. Terminal states: succeeded / failed / cancelled. */
10683
+ var BackupRunStateSchema = _enum([
10684
+ "queued",
10685
+ "running",
10686
+ "succeeded",
10687
+ "failed",
10688
+ "cancelled"
10689
+ ]);
10690
+ /**
10691
+ * Where a running backup currently is. `queued` before it starts,
10692
+ * `building` while the tar.gz is being staged, `uploading` during the
10693
+ * per-destination fan-out, `done` once terminal.
10694
+ */
10695
+ var BackupRunPhaseSchema = _enum([
10696
+ "queued",
10697
+ "building",
10698
+ "uploading",
10699
+ "done"
10700
+ ]);
10701
+ /**
10702
+ * Observable state of one backup run — readable WHILE it runs via
10703
+ * `backup.listRuns`. This is what makes the execution queue and
10704
+ * `backup.cancel` usable: the 2026-09-04 incident (two concurrent
10705
+ * multi-GB builds, staging 5.1 GB → 18 GB, load 62) was only
10706
+ * diagnosable with `du` because nothing reported that runs existed or
10707
+ * how large the staged archive had grown.
10708
+ */
10709
+ var BackupRunSchema = object({
10710
+ /** Stable run id — the handle `backup.cancel` takes. */
10711
+ id: string(),
10712
+ state: BackupRunStateSchema,
10713
+ phase: BackupRunPhaseSchema,
10714
+ /**
10715
+ * Resolved destination location ids. Empty while queued (targets are
10716
+ * resolved when the run starts, against the then-current policies).
10717
+ */
10718
+ destinationIds: array(string()).readonly(),
10719
+ label: string().optional(),
10720
+ /** ms-epoch when the run was submitted (trigger call / schedule fire). */
10721
+ requestedAt: number(),
10722
+ /** ms-epoch when the run left the queue and started building. */
10723
+ startedAt: number().optional(),
10724
+ /** ms-epoch when the run reached a terminal state. */
10725
+ finishedAt: number().optional(),
10726
+ /** Compressed bytes of the staging archive written so far. */
10727
+ stagedBytes: number(),
10728
+ /** Final staged archive size, once the build phase completes. */
10729
+ archiveSizeBytes: number().optional(),
10730
+ /** Bytes pushed to the destination currently uploading. */
10731
+ uploadedBytes: number(),
10732
+ /** Destinations where the archive fully landed (uploaded + indexed). */
10733
+ completedDestinationIds: array(string()).readonly(),
10734
+ /** Destinations that failed during the fan-out. */
10735
+ failedDestinationIds: array(string()).readonly(),
10736
+ /** Failure message when `state === 'failed'`. */
10737
+ error: string().optional(),
10738
+ /**
10739
+ * 1-based place in the execution queue — 1 = runs next. Present only
10740
+ * while `state === 'queued'`. Stamped by the orchestrator from the
10741
+ * queue's OWN pending order, never derived from timestamps, so the
10742
+ * UI cannot show an order the executor will not honour.
10743
+ */
10744
+ queuePosition: number().int().min(1).optional()
10745
+ });
10746
+ /**
10747
+ * Result of `backup.trigger`. The call still resolves when the run
10748
+ * terminates (compat with schedule-driven runs and the admin UI), but
10749
+ * it now names the run and says whether it had to WAIT: a trigger that
10750
+ * arrives while another run is in flight is enqueued (or joined onto
10751
+ * an identical already-queued run), never started concurrently.
10752
+ */
10753
+ var BackupTriggerResultSchema = object({
10754
+ /** The run this trigger mapped to — poll it via `listRuns`, stop it via `cancel`. */
10755
+ runId: string(),
10756
+ /** True when the run waited behind an in-flight run instead of starting immediately. */
10757
+ queued: boolean(),
10758
+ /** True when this trigger was coalesced onto an identical already-queued run. */
10759
+ joined: boolean(),
10760
+ /** True when the run was cancelled before completing every destination. */
10761
+ cancelled: boolean(),
10762
+ /** One entry per destination the archive landed at (partial on cancel). */
10763
+ entries: array(BackupEntrySchema).readonly()
10764
+ });
10682
10765
  /**
10683
10766
  * A backup schedule — the N:M "entry" that binds one cron cadence to a
10684
10767
  * SET of destination locations. Supersedes the per-location cron on
@@ -10726,7 +10809,10 @@ method(_void(), array(BackupDestinationInfoSchema).readonly(), { auth: "admin" }
10726
10809
  * retention (manual runs).
10727
10810
  */
10728
10811
  retentionCount: number().int().min(1).max(1e3).optional()
10729
- }).optional(), array(BackupEntrySchema).readonly(), {
10812
+ }).optional(), BackupTriggerResultSchema, {
10813
+ kind: "mutation",
10814
+ auth: "admin"
10815
+ }), method(_void(), array(BackupRunSchema).readonly(), { auth: "admin" }), method(object({ runId: string() }), object({ cancelled: boolean() }), {
10730
10816
  kind: "mutation",
10731
10817
  auth: "admin"
10732
10818
  }), method(_void(), array(BackupEntrySchema).readonly(), { auth: "admin" }), method(_void(), array(LocationStatSchema).readonly(), { auth: "admin" }), method(object({
@@ -11443,6 +11529,14 @@ method(object({
11443
11529
  }), object({ success: literal(true) }), {
11444
11530
  kind: "mutation",
11445
11531
  auth: "admin"
11532
+ }), method(object({ deviceId: number().int().nonnegative() }), object({
11533
+ derivedStreamsDeleted: array(string()).readonly(),
11534
+ assignmentsPurged: boolean(),
11535
+ probeSnapshotsDropped: number().int().nonnegative(),
11536
+ rtspTokenRowsDeleted: number().int().nonnegative()
11537
+ }), {
11538
+ kind: "mutation",
11539
+ auth: "admin"
11446
11540
  }), method(object({
11447
11541
  deviceId: number(),
11448
11542
  /** Absent = the LOWEST assigned profile — a notification attachment is
@@ -19029,7 +19123,20 @@ var RecentTracksQueryInput = object({
19029
19123
  projection: TrackProjectionSchema.optional(),
19030
19124
  /** Include stationary-promoted rows (parked objects). Default false: the
19031
19125
  * feed lists passages; parking records live on the stationary registry. */
19032
- includeStationary: boolean().optional()
19126
+ includeStationary: boolean().optional(),
19127
+ /**
19128
+ * Restrict to these track classes. ABSENT or EMPTY means no filter.
19129
+ *
19130
+ * The same filter `listTracks` takes, because the timeline's class chips must
19131
+ * mean the same thing whether the scope is one camera or twelve. Until this
19132
+ * existed the scoped feed downloaded a page and narrowed it on the phone
19133
+ * while the single-camera path narrowed the read — one filter, two costs.
19134
+ *
19135
+ * A SUPERSET prefilter on `classes[]`, like its single-camera twin: rows
19136
+ * whose class list is unreadable are kept, and the client's rule stays the
19137
+ * exact one.
19138
+ */
19139
+ classes: array(string()).optional()
19033
19140
  });
19034
19141
  var RecentTracksPageSchema = object({
19035
19142
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
@@ -23067,8 +23174,22 @@ DeviceType.Automation, method(object({ deviceId: number().int().nonnegative() })
23067
23174
  * threshold.
23068
23175
  */
23069
23176
  var BatteryStatusSchema = object({
23070
- /** 0..100 inclusive. Firmware-reported. */
23071
- percentage: number().min(0).max(100),
23177
+ /**
23178
+ * 0..100 inclusive, firmware-reported. **`null` means NOT YET KNOWN** — the
23179
+ * provider has registered the capability but no reading has landed.
23180
+ *
23181
+ * It is nullable because it was not, and the only value a provider could
23182
+ * seed with was `0`. A battery camera behind an NVR therefore announced
23183
+ * itself at 0% on every start and corrected itself a moment later, which is
23184
+ * indistinguishable from a real flat battery: it fires the low-battery alert
23185
+ * every time the hub restarts. Unknown is not empty (D315), and on a battery
23186
+ * reading the difference is an alarm.
23187
+ *
23188
+ * `vacuum-control` and `lawn-mower-control` already model it this way.
23189
+ * Consumers must SKIP a null rather than coerce it — `battery-band` already
23190
+ * declines to band a non-finite reading, which is the correct shape.
23191
+ */
23192
+ percentage: number().min(0).max(100).nullable(),
23072
23193
  /**
23073
23194
  * Charging source. `'dc'` covers wall/USB adapters; `'solar'` is
23074
23195
  * Reolink-specific for the Solar Panel 2 accessory (will become
@@ -29547,6 +29668,12 @@ Object.freeze({
29547
29668
  addonId: null,
29548
29669
  access: "create"
29549
29670
  },
29671
+ "backup.cancel": {
29672
+ capName: "backup",
29673
+ capScope: "system",
29674
+ addonId: null,
29675
+ access: "create"
29676
+ },
29550
29677
  "backup.delete": {
29551
29678
  capName: "backup",
29552
29679
  capScope: "system",
@@ -29589,6 +29716,12 @@ Object.freeze({
29589
29716
  addonId: null,
29590
29717
  access: "view"
29591
29718
  },
29719
+ "backup.listRuns": {
29720
+ capName: "backup",
29721
+ capScope: "system",
29722
+ addonId: null,
29723
+ access: "view"
29724
+ },
29592
29725
  "backup.listSchedules": {
29593
29726
  capName: "backup",
29594
29727
  capScope: "system",
@@ -34155,6 +34288,12 @@ Object.freeze({
34155
34288
  addonId: null,
34156
34289
  access: "create"
34157
34290
  },
34291
+ "streamBroker.forgetDeviceHardware": {
34292
+ capName: "stream-broker",
34293
+ capScope: "system",
34294
+ addonId: null,
34295
+ access: "delete"
34296
+ },
34158
34297
  "streamBroker.getAllRtspEntries": {
34159
34298
  capName: "stream-broker",
34160
34299
  capScope: "system",
@@ -36613,6 +36752,11 @@ Object.freeze({
36613
36752
  form: "single",
36614
36753
  optional: false
36615
36754
  }],
36755
+ "streamBroker.forgetDeviceHardware": [{
36756
+ name: "deviceId",
36757
+ form: "single",
36758
+ optional: false
36759
+ }],
36616
36760
  "streamBroker.getDeviceAudioMute": [{
36617
36761
  name: "deviceId",
36618
36762
  form: "single",
package/dist/addon.mjs CHANGED
@@ -10652,6 +10652,89 @@ var LocationStatSchema = object({
10652
10652
  fileCount: number(),
10653
10653
  present: boolean()
10654
10654
  });
10655
+ /** Lifecycle of a backup run. Terminal states: succeeded / failed / cancelled. */
10656
+ var BackupRunStateSchema = _enum([
10657
+ "queued",
10658
+ "running",
10659
+ "succeeded",
10660
+ "failed",
10661
+ "cancelled"
10662
+ ]);
10663
+ /**
10664
+ * Where a running backup currently is. `queued` before it starts,
10665
+ * `building` while the tar.gz is being staged, `uploading` during the
10666
+ * per-destination fan-out, `done` once terminal.
10667
+ */
10668
+ var BackupRunPhaseSchema = _enum([
10669
+ "queued",
10670
+ "building",
10671
+ "uploading",
10672
+ "done"
10673
+ ]);
10674
+ /**
10675
+ * Observable state of one backup run — readable WHILE it runs via
10676
+ * `backup.listRuns`. This is what makes the execution queue and
10677
+ * `backup.cancel` usable: the 2026-09-04 incident (two concurrent
10678
+ * multi-GB builds, staging 5.1 GB → 18 GB, load 62) was only
10679
+ * diagnosable with `du` because nothing reported that runs existed or
10680
+ * how large the staged archive had grown.
10681
+ */
10682
+ var BackupRunSchema = object({
10683
+ /** Stable run id — the handle `backup.cancel` takes. */
10684
+ id: string(),
10685
+ state: BackupRunStateSchema,
10686
+ phase: BackupRunPhaseSchema,
10687
+ /**
10688
+ * Resolved destination location ids. Empty while queued (targets are
10689
+ * resolved when the run starts, against the then-current policies).
10690
+ */
10691
+ destinationIds: array(string()).readonly(),
10692
+ label: string().optional(),
10693
+ /** ms-epoch when the run was submitted (trigger call / schedule fire). */
10694
+ requestedAt: number(),
10695
+ /** ms-epoch when the run left the queue and started building. */
10696
+ startedAt: number().optional(),
10697
+ /** ms-epoch when the run reached a terminal state. */
10698
+ finishedAt: number().optional(),
10699
+ /** Compressed bytes of the staging archive written so far. */
10700
+ stagedBytes: number(),
10701
+ /** Final staged archive size, once the build phase completes. */
10702
+ archiveSizeBytes: number().optional(),
10703
+ /** Bytes pushed to the destination currently uploading. */
10704
+ uploadedBytes: number(),
10705
+ /** Destinations where the archive fully landed (uploaded + indexed). */
10706
+ completedDestinationIds: array(string()).readonly(),
10707
+ /** Destinations that failed during the fan-out. */
10708
+ failedDestinationIds: array(string()).readonly(),
10709
+ /** Failure message when `state === 'failed'`. */
10710
+ error: string().optional(),
10711
+ /**
10712
+ * 1-based place in the execution queue — 1 = runs next. Present only
10713
+ * while `state === 'queued'`. Stamped by the orchestrator from the
10714
+ * queue's OWN pending order, never derived from timestamps, so the
10715
+ * UI cannot show an order the executor will not honour.
10716
+ */
10717
+ queuePosition: number().int().min(1).optional()
10718
+ });
10719
+ /**
10720
+ * Result of `backup.trigger`. The call still resolves when the run
10721
+ * terminates (compat with schedule-driven runs and the admin UI), but
10722
+ * it now names the run and says whether it had to WAIT: a trigger that
10723
+ * arrives while another run is in flight is enqueued (or joined onto
10724
+ * an identical already-queued run), never started concurrently.
10725
+ */
10726
+ var BackupTriggerResultSchema = object({
10727
+ /** The run this trigger mapped to — poll it via `listRuns`, stop it via `cancel`. */
10728
+ runId: string(),
10729
+ /** True when the run waited behind an in-flight run instead of starting immediately. */
10730
+ queued: boolean(),
10731
+ /** True when this trigger was coalesced onto an identical already-queued run. */
10732
+ joined: boolean(),
10733
+ /** True when the run was cancelled before completing every destination. */
10734
+ cancelled: boolean(),
10735
+ /** One entry per destination the archive landed at (partial on cancel). */
10736
+ entries: array(BackupEntrySchema).readonly()
10737
+ });
10655
10738
  /**
10656
10739
  * A backup schedule — the N:M "entry" that binds one cron cadence to a
10657
10740
  * SET of destination locations. Supersedes the per-location cron on
@@ -10699,7 +10782,10 @@ method(_void(), array(BackupDestinationInfoSchema).readonly(), { auth: "admin" }
10699
10782
  * retention (manual runs).
10700
10783
  */
10701
10784
  retentionCount: number().int().min(1).max(1e3).optional()
10702
- }).optional(), array(BackupEntrySchema).readonly(), {
10785
+ }).optional(), BackupTriggerResultSchema, {
10786
+ kind: "mutation",
10787
+ auth: "admin"
10788
+ }), method(_void(), array(BackupRunSchema).readonly(), { auth: "admin" }), method(object({ runId: string() }), object({ cancelled: boolean() }), {
10703
10789
  kind: "mutation",
10704
10790
  auth: "admin"
10705
10791
  }), method(_void(), array(BackupEntrySchema).readonly(), { auth: "admin" }), method(_void(), array(LocationStatSchema).readonly(), { auth: "admin" }), method(object({
@@ -11416,6 +11502,14 @@ method(object({
11416
11502
  }), object({ success: literal(true) }), {
11417
11503
  kind: "mutation",
11418
11504
  auth: "admin"
11505
+ }), method(object({ deviceId: number().int().nonnegative() }), object({
11506
+ derivedStreamsDeleted: array(string()).readonly(),
11507
+ assignmentsPurged: boolean(),
11508
+ probeSnapshotsDropped: number().int().nonnegative(),
11509
+ rtspTokenRowsDeleted: number().int().nonnegative()
11510
+ }), {
11511
+ kind: "mutation",
11512
+ auth: "admin"
11419
11513
  }), method(object({
11420
11514
  deviceId: number(),
11421
11515
  /** Absent = the LOWEST assigned profile — a notification attachment is
@@ -19002,7 +19096,20 @@ var RecentTracksQueryInput = object({
19002
19096
  projection: TrackProjectionSchema.optional(),
19003
19097
  /** Include stationary-promoted rows (parked objects). Default false: the
19004
19098
  * feed lists passages; parking records live on the stationary registry. */
19005
- includeStationary: boolean().optional()
19099
+ includeStationary: boolean().optional(),
19100
+ /**
19101
+ * Restrict to these track classes. ABSENT or EMPTY means no filter.
19102
+ *
19103
+ * The same filter `listTracks` takes, because the timeline's class chips must
19104
+ * mean the same thing whether the scope is one camera or twelve. Until this
19105
+ * existed the scoped feed downloaded a page and narrowed it on the phone
19106
+ * while the single-camera path narrowed the read — one filter, two costs.
19107
+ *
19108
+ * A SUPERSET prefilter on `classes[]`, like its single-camera twin: rows
19109
+ * whose class list is unreadable are kept, and the client's rule stays the
19110
+ * exact one.
19111
+ */
19112
+ classes: array(string()).optional()
19006
19113
  });
19007
19114
  var RecentTracksPageSchema = object({
19008
19115
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
@@ -23040,8 +23147,22 @@ DeviceType.Automation, method(object({ deviceId: number().int().nonnegative() })
23040
23147
  * threshold.
23041
23148
  */
23042
23149
  var BatteryStatusSchema = object({
23043
- /** 0..100 inclusive. Firmware-reported. */
23044
- percentage: number().min(0).max(100),
23150
+ /**
23151
+ * 0..100 inclusive, firmware-reported. **`null` means NOT YET KNOWN** — the
23152
+ * provider has registered the capability but no reading has landed.
23153
+ *
23154
+ * It is nullable because it was not, and the only value a provider could
23155
+ * seed with was `0`. A battery camera behind an NVR therefore announced
23156
+ * itself at 0% on every start and corrected itself a moment later, which is
23157
+ * indistinguishable from a real flat battery: it fires the low-battery alert
23158
+ * every time the hub restarts. Unknown is not empty (D315), and on a battery
23159
+ * reading the difference is an alarm.
23160
+ *
23161
+ * `vacuum-control` and `lawn-mower-control` already model it this way.
23162
+ * Consumers must SKIP a null rather than coerce it — `battery-band` already
23163
+ * declines to band a non-finite reading, which is the correct shape.
23164
+ */
23165
+ percentage: number().min(0).max(100).nullable(),
23045
23166
  /**
23046
23167
  * Charging source. `'dc'` covers wall/USB adapters; `'solar'` is
23047
23168
  * Reolink-specific for the Solar Panel 2 accessory (will become
@@ -29520,6 +29641,12 @@ Object.freeze({
29520
29641
  addonId: null,
29521
29642
  access: "create"
29522
29643
  },
29644
+ "backup.cancel": {
29645
+ capName: "backup",
29646
+ capScope: "system",
29647
+ addonId: null,
29648
+ access: "create"
29649
+ },
29523
29650
  "backup.delete": {
29524
29651
  capName: "backup",
29525
29652
  capScope: "system",
@@ -29562,6 +29689,12 @@ Object.freeze({
29562
29689
  addonId: null,
29563
29690
  access: "view"
29564
29691
  },
29692
+ "backup.listRuns": {
29693
+ capName: "backup",
29694
+ capScope: "system",
29695
+ addonId: null,
29696
+ access: "view"
29697
+ },
29565
29698
  "backup.listSchedules": {
29566
29699
  capName: "backup",
29567
29700
  capScope: "system",
@@ -34128,6 +34261,12 @@ Object.freeze({
34128
34261
  addonId: null,
34129
34262
  access: "create"
34130
34263
  },
34264
+ "streamBroker.forgetDeviceHardware": {
34265
+ capName: "stream-broker",
34266
+ capScope: "system",
34267
+ addonId: null,
34268
+ access: "delete"
34269
+ },
34131
34270
  "streamBroker.getAllRtspEntries": {
34132
34271
  capName: "stream-broker",
34133
34272
  capScope: "system",
@@ -36586,6 +36725,11 @@ Object.freeze({
36586
36725
  form: "single",
36587
36726
  optional: false
36588
36727
  }],
36728
+ "streamBroker.forgetDeviceHardware": [{
36729
+ name: "deviceId",
36730
+ form: "single",
36731
+ optional: false
36732
+ }],
36589
36733
  "streamBroker.getDeviceAudioMute": [{
36590
36734
  name: "deviceId",
36591
36735
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-notifiers",
3
- "version": "1.2.61",
3
+ "version": "1.2.63",
4
4
  "description": "System notifiers addon for CamStack — a `notification-output` collection provider hosting per-kind notifier adapters (ntfy, pushover, gotify, telegram, discord, webhook, zentik).",
5
5
  "keywords": [
6
6
  "camstack",