@camstack/addon-auth 1.2.141 → 1.2.142

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.
@@ -32,7 +32,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
32
32
  }) : target, mod));
33
33
  var __toCommonJS = (mod) => __hasOwnProp.call(mod, "module.exports") ? mod["module.exports"] : __copyProps(__defProp({}, "__esModule", { value: true }), mod);
34
34
  require("node:crypto");
35
- //#region ../types/dist/event-category-DaIZi00R.mjs
35
+ //#region ../types/dist/event-category-C4hVnRo8.mjs
36
36
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
37
37
  EventCategory["SystemBoot"] = "system.boot";
38
38
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -251,7 +251,17 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
251
251
  EventCategory["RecordingStopped"] = "recording.stopped";
252
252
  EventCategory["RecordingError"] = "recording.error";
253
253
  EventCategory["RecordingHealthDegraded"] = "recording.health.degraded";
254
+ /** Recording enabled but no segment finalized for the NC stall window. */
255
+ EventCategory["RecordingHealthStalled"] = "recording.health.stalled";
256
+ /** Recovery from {@link RecordingHealthStalled}. */
257
+ EventCategory["RecordingHealthOk"] = "recording.health.ok";
254
258
  EventCategory["RecordingStorageCritical"] = "recording.storage.critical";
259
+ /** Free space on a storage location crossed the warn bar. */
260
+ EventCategory["StorageLocationLow"] = "storage.location.low";
261
+ /** Free space at/under the critical bar, or capacity probe failed (`null`). */
262
+ EventCategory["StorageLocationCritical"] = "storage.location.critical";
263
+ /** Recovery from low/critical on a storage location. */
264
+ EventCategory["StorageLocationOk"] = "storage.location.ok";
255
265
  EventCategory["RecordingSegmentWritten"] = "recording.segment.written";
256
266
  EventCategory["RecordingPolicyFallback"] = "recording.policy.fallback";
257
267
  EventCategory["RecordingRetentionCompleted"] = "recording.retention.completed";
@@ -5410,7 +5420,7 @@ var ZodIssueCode = {
5410
5420
  var ZodFirstPartyTypeKind;
5411
5421
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5412
5422
  //#endregion
5413
- //#region ../types/dist/sleep-DwAQ9sqX.mjs
5423
+ //#region ../types/dist/sleep-BBF1iXUi.mjs
5414
5424
  /**
5415
5425
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5416
5426
  * window to float samples (D455).
@@ -8011,6 +8021,21 @@ var ProfileRtspEntrySchema = object({
8011
8021
  codec: string().optional(),
8012
8022
  resolution: CamStreamResolutionSchema.optional()
8013
8023
  });
8024
+ /**
8025
+ * The model weight formats a catalog entry can ship. Schema-free on purpose:
8026
+ * `types/models.ts` builds Zod schemas from it, but a runner-closure consumer
8027
+ * (the model downloader in `@camstack/system`) needs only the list and must
8028
+ * reach it through `@camstack/types/addon` without building the cap schema
8029
+ * graph (D28).
8030
+ */
8031
+ var MODEL_FORMATS = [
8032
+ "onnx",
8033
+ "coreml",
8034
+ "openvino",
8035
+ "tflite",
8036
+ "pt",
8037
+ "gguf"
8038
+ ];
8014
8039
  object({
8015
8040
  field: string().min(1),
8016
8041
  on: literal("advance")
@@ -8494,7 +8519,7 @@ function errMsg(err) {
8494
8519
  return String(err);
8495
8520
  }
8496
8521
  //#endregion
8497
- //#region ../types/dist/composition-Bzr7GwgP.mjs
8522
+ //#region ../types/dist/composition-C-WpVYTX.mjs
8498
8523
  /**
8499
8524
  * The ffmpeg build every CamStack node downloads, per platform and arch.
8500
8525
  *
@@ -8546,7 +8571,7 @@ var BASE = `https://github.com/jellyfin/jellyfin-ffmpeg/releases/download/v${FFM
8546
8571
  function portable(target) {
8547
8572
  return `${BASE}/jellyfin-ffmpeg_${FFMPEG_RELEASE}_portable_${target}-gpl.tar.xz`;
8548
8573
  }
8549
- portable("linux64"), portable("linuxarm64"), portable("macarm64"), portable("mac64");
8574
+ portable("linux64"), portable("linuxarm64"), portable("macarm64"), portable("mac64"), `${BASE}${FFMPEG_RELEASE}`;
8550
8575
  /**
8551
8576
  * THE table "which boolean of this device type counts as HIGH", and the
8552
8577
  * pure evaluator of its EDGE.
@@ -10238,6 +10263,15 @@ discriminatedUnion("type", [
10238
10263
  message: string()
10239
10264
  })
10240
10265
  ]);
10266
+ /** Every status, in the order a summary lists them. */
10267
+ var RETRAIN_REVIEW_STATUSES = [
10268
+ "unchanged",
10269
+ "adjusted",
10270
+ "reclassified",
10271
+ "added",
10272
+ "removed",
10273
+ "model-error"
10274
+ ];
10241
10275
  /**
10242
10276
  * What the gate decided about a birth, from the CALLER's point of view.
10243
10277
  *
@@ -11855,14 +11889,6 @@ var MASK_SUPPLY_STEP_IDS = ["segmentation"];
11855
11889
  ...CROP_SUPPLY_STEP_IDS,
11856
11890
  ...MASK_SUPPLY_STEP_IDS
11857
11891
  ];
11858
- var MODEL_FORMATS = [
11859
- "onnx",
11860
- "coreml",
11861
- "openvino",
11862
- "tflite",
11863
- "pt",
11864
- "gguf"
11865
- ];
11866
11892
  /**
11867
11893
  * Multi-file format payload.
11868
11894
  *
@@ -13205,6 +13231,329 @@ var authProviderCapability = {
13205
13231
  mount: { kind: "skip" }
13206
13232
  };
13207
13233
  /**
13234
+ * Query filter for settings-store collections.
13235
+ */
13236
+ var QueryFilterSchema = object({
13237
+ where: record(string(), unknown()).optional(),
13238
+ whereIn: record(string(), array(unknown())).optional(),
13239
+ whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
13240
+ /** NULL-safe exclusion: matches rows whose field is NULL OR != the value. */
13241
+ whereNot: record(string(), unknown()).optional(),
13242
+ /** NULL-safe exclusion of a SET — `whereNot` for more than one value. An
13243
+ * empty list excludes nothing. See `QueryFilter.whereNotIn`. */
13244
+ whereNotIn: record(string(), array(unknown())).optional(),
13245
+ orderBy: object({
13246
+ field: string(),
13247
+ direction: _enum(["asc", "desc"])
13248
+ }).optional(),
13249
+ limit: number().optional(),
13250
+ offset: number().optional()
13251
+ });
13252
+ /**
13253
+ * The predicate half of a filter, for BULK MUTATIONS.
13254
+ *
13255
+ * Deliberately not `QueryFilterSchema`: `orderBy` / `limit` / `offset` have no
13256
+ * meaning for a statement that rewrites a set, and accepting them would invite
13257
+ * a caller to believe `limit` bounds the damage. Every field is optional here
13258
+ * only so the shape stays composable — the implementation REJECTS a filter
13259
+ * that compiles to no predicate, because that is the whole collection.
13260
+ */
13261
+ var MutationFilterSchema = object({
13262
+ where: record(string(), unknown()).optional(),
13263
+ whereIn: record(string(), array(unknown())).optional(),
13264
+ whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
13265
+ whereNot: record(string(), unknown()).optional(),
13266
+ whereNotIn: record(string(), array(unknown())).optional()
13267
+ });
13268
+ /**
13269
+ * One scalar an {@link settingsStoreCapability.methods.aggregate} call asks for.
13270
+ *
13271
+ * `as` names the slot in the result, so the SAME column may be asked twice with
13272
+ * two operations (`MIN(startMs)` and `MAX(startMs)` in one round trip) — which
13273
+ * a `Record<column, op>` shape could not express.
13274
+ */
13275
+ var AggregateFieldSchema = object({
13276
+ /** Result key. */
13277
+ as: string().min(1),
13278
+ /** Column to aggregate. Must be a real column of a declared collection. */
13279
+ field: string().min(1),
13280
+ op: _enum([
13281
+ "sum",
13282
+ "min",
13283
+ "max"
13284
+ ])
13285
+ });
13286
+ /**
13287
+ * `COUNT(*)` plus one number per requested field.
13288
+ *
13289
+ * `null` means NO ROW MATCHED, never zero: a `SUM` over an empty set and a sum
13290
+ * that really is 0 are different facts, and an accounting caller that renders
13291
+ * "0 bytes, oldest = 0" for "nothing here" reports a lie about a disk.
13292
+ */
13293
+ var AggregateResultSchema = object({
13294
+ count: number().int(),
13295
+ values: record(string(), number().nullable())
13296
+ });
13297
+ /** A single stored record: `{ id, data }`. */
13298
+ var SettingsRecordSchema = object({
13299
+ id: string(),
13300
+ data: record(string(), unknown())
13301
+ });
13302
+ /**
13303
+ * One record of a BULK insert — {@link SettingsRecordSchema} with the id made
13304
+ * optional.
13305
+ *
13306
+ * A separate schema rather than loosening the shared one: every other method
13307
+ * on this cap addresses a row BY its id, and making that field optional
13308
+ * everywhere would turn a forgotten key into a silently generated one on
13309
+ * `update` and `delete` as well.
13310
+ */
13311
+ var BulkRecordSchema = object({
13312
+ id: string().optional(),
13313
+ data: record(string(), unknown())
13314
+ });
13315
+ /**
13316
+ * The database FILES one `sqlite-settings` engine process owns (D851).
13317
+ * Closed on purpose: a file is a thing the engine opens, backs up and gives a
13318
+ * serving thread, so a new one is a code change, never a string a caller
13319
+ * invents. `settings` is `camstack.db` and the default for every collection
13320
+ * that names no file.
13321
+ */
13322
+ var DataStoreDatabaseSchema = _enum([
13323
+ "settings",
13324
+ "events",
13325
+ "history"
13326
+ ]);
13327
+ DataStoreDatabaseSchema.options;
13328
+ /**
13329
+ * One write inside a {@link settingsStoreCapability.methods.transact} call.
13330
+ * The three that a "replace this set, bump that revision" write needs, plus
13331
+ * the batched upsert a rollup writer needs.
13332
+ */
13333
+ var TransactOpSchema = discriminatedUnion("op", [
13334
+ object({
13335
+ op: literal("deleteWhere"),
13336
+ collection: string(),
13337
+ filter: MutationFilterSchema
13338
+ }),
13339
+ object({
13340
+ op: literal("insertMany"),
13341
+ collection: string(),
13342
+ records: array(BulkRecordSchema).readonly()
13343
+ }),
13344
+ object({
13345
+ op: literal("update"),
13346
+ collection: string(),
13347
+ id: string(),
13348
+ data: record(string(), unknown())
13349
+ }),
13350
+ object({
13351
+ op: literal("upsertMany"),
13352
+ collection: string(),
13353
+ conflict: array(string()).readonly(),
13354
+ records: array(BulkRecordSchema).readonly()
13355
+ })
13356
+ ]);
13357
+ /**
13358
+ * The precondition of a transaction: the row `key` of `collection` must hold
13359
+ * `equals` in `column`, read INSIDE the transaction.
13360
+ */
13361
+ var TransactGuardSchema = object({
13362
+ collection: string(),
13363
+ key: string(),
13364
+ column: string(),
13365
+ equals: unknown()
13366
+ });
13367
+ /**
13368
+ * Column declaration for a structured (SQL-backed) collection.
13369
+ *
13370
+ * Logical types — the backend translates each to the matching SQLite
13371
+ * storage class and handles per-type marshaling:
13372
+ * - `TEXT` / `INTEGER` / `REAL` — native SQLite types, pass-through
13373
+ * - `JSON` — TEXT under the hood; serialised on write, parsed on read
13374
+ * - `BOOLEAN` — INTEGER 0/1 under the hood; coerced both directions
13375
+ */
13376
+ var CollectionColumnSchema = object({
13377
+ name: string(),
13378
+ type: _enum([
13379
+ "TEXT",
13380
+ "INTEGER",
13381
+ "REAL",
13382
+ "JSON",
13383
+ "BOOLEAN"
13384
+ ]),
13385
+ primaryKey: boolean().optional(),
13386
+ notNull: boolean().optional(),
13387
+ unique: boolean().optional(),
13388
+ /**
13389
+ * Column DEFAULT. Required for B2: the four `ensureTable` consumers declare
13390
+ * columns like `enabled INTEGER NOT NULL DEFAULT 1`, and without this the
13391
+ * collection surface simply cannot express their existing tables — which is
13392
+ * why they were still on the uncapped `table*` API.
13393
+ */
13394
+ defaultValue: union([
13395
+ string(),
13396
+ number(),
13397
+ boolean()
13398
+ ]).optional()
13399
+ });
13400
+ var CollectionIndexSchema = object({
13401
+ name: string(),
13402
+ columns: array(string()).readonly(),
13403
+ unique: boolean().optional()
13404
+ });
13405
+ /**
13406
+ * The input of `declareCollection` — ONE schema for the door and for the
13407
+ * engine behind it, so the two surfaces cannot drift (the dispatcher forwards
13408
+ * the payload untouched).
13409
+ *
13410
+ * - `database` — the file the collection lives in (D851). Absent means
13411
+ * `settings`. A declaration naming a file other than the one the table is
13412
+ * already in is REFUSED by the engine, never moved.
13413
+ * - `primaryKey` — a COMPOSITE key, as column names. A single name is the same
13414
+ * as `primaryKey: true` on that column. A composite-keyed collection has no
13415
+ * `id`: it is written with `insertMany` / `upsertMany` / `transact` and read
13416
+ * with `query` / `count` / `aggregate` / `deleteWhere`; the calls that
13417
+ * address one row by id are refused.
13418
+ * - `withoutRowid` — emit `WITHOUT ROWID`. Requires a primary key.
13419
+ */
13420
+ var DeclareCollectionInputSchema = object({
13421
+ namespace: string().optional(),
13422
+ collection: string(),
13423
+ columns: array(CollectionColumnSchema).readonly(),
13424
+ indexes: array(CollectionIndexSchema).readonly().optional(),
13425
+ database: DataStoreDatabaseSchema.optional(),
13426
+ primaryKey: array(string()).readonly().optional(),
13427
+ withoutRowid: boolean().optional()
13428
+ });
13429
+ method(object({
13430
+ namespace: string().optional(),
13431
+ collection: string(),
13432
+ key: string()
13433
+ }), unknown(), { auth: "admin" }), method(object({
13434
+ namespace: string().optional(),
13435
+ collection: string(),
13436
+ key: string(),
13437
+ value: unknown()
13438
+ }), _void(), {
13439
+ kind: "mutation",
13440
+ auth: "admin"
13441
+ }), method(object({
13442
+ namespace: string().optional(),
13443
+ collection: string(),
13444
+ filter: QueryFilterSchema.optional(),
13445
+ columns: array(string()).readonly().optional()
13446
+ }), array(SettingsRecordSchema).readonly(), { auth: "admin" }), method(object({
13447
+ namespace: string().optional(),
13448
+ collection: string(),
13449
+ /** Declared columns identifying the slot; must be covered by a UNIQUE
13450
+ * index on the collection. Never empty. */
13451
+ conflict: array(string()).readonly(),
13452
+ record: BulkRecordSchema
13453
+ }), object({
13454
+ /** The id the row HAS: assigned by SQLite on an insert, or the existing
13455
+ * row's own id on an update. */
13456
+ id: union([string(), number()]) }), {
13457
+ kind: "mutation",
13458
+ auth: "admin"
13459
+ }), method(object({
13460
+ namespace: string().optional(),
13461
+ collection: string(),
13462
+ conflict: array(string()).readonly(),
13463
+ records: array(BulkRecordSchema).readonly()
13464
+ }), object({ upserted: number().int() }), {
13465
+ kind: "mutation",
13466
+ auth: "admin"
13467
+ }), method(object({
13468
+ namespace: string().optional(),
13469
+ collection: string(),
13470
+ record: object({
13471
+ id: string().optional(),
13472
+ data: record(string(), unknown())
13473
+ })
13474
+ }), object({
13475
+ /**
13476
+ * The id the row ACTUALLY got (D473): the one supplied, the UUID minted
13477
+ * for an absent one, or the ROWID SQLite assigned on an `INTEGER`
13478
+ * primary key — which is the only place an auto key is knowable.
13479
+ */
13480
+ id: union([string(), number()]) }), {
13481
+ kind: "mutation",
13482
+ auth: "admin"
13483
+ }), method(object({
13484
+ namespace: string().optional(),
13485
+ collection: string(),
13486
+ records: array(BulkRecordSchema).readonly()
13487
+ }), object({ inserted: number().int() }), {
13488
+ kind: "mutation",
13489
+ auth: "admin"
13490
+ }), method(object({
13491
+ namespace: string().optional(),
13492
+ guard: TransactGuardSchema.optional(),
13493
+ ops: array(TransactOpSchema).readonly()
13494
+ }), object({
13495
+ applied: boolean(),
13496
+ current: unknown().optional()
13497
+ }), {
13498
+ kind: "mutation",
13499
+ auth: "admin"
13500
+ }), method(object({
13501
+ namespace: string().optional(),
13502
+ collection: string(),
13503
+ id: string(),
13504
+ data: record(string(), unknown())
13505
+ }), _void(), {
13506
+ kind: "mutation",
13507
+ auth: "admin"
13508
+ }), method(object({
13509
+ namespace: string().optional(),
13510
+ collection: string(),
13511
+ key: string()
13512
+ }), _void(), {
13513
+ kind: "mutation",
13514
+ auth: "admin"
13515
+ }), method(object({
13516
+ namespace: string().optional(),
13517
+ collection: string(),
13518
+ filter: MutationFilterSchema
13519
+ }), object({ deleted: number().int() }), {
13520
+ kind: "mutation",
13521
+ auth: "admin"
13522
+ }), method(object({
13523
+ namespace: string().optional(),
13524
+ collection: string(),
13525
+ filter: MutationFilterSchema,
13526
+ data: record(string(), unknown())
13527
+ }), object({ updated: number().int() }), {
13528
+ kind: "mutation",
13529
+ auth: "admin"
13530
+ }), method(object({
13531
+ namespace: string().optional(),
13532
+ collection: string(),
13533
+ filter: QueryFilterSchema.optional()
13534
+ }), number(), { auth: "admin" }), method(object({
13535
+ namespace: string().optional(),
13536
+ collection: string(),
13537
+ fields: array(AggregateFieldSchema).readonly(),
13538
+ filter: QueryFilterSchema.optional()
13539
+ }), AggregateResultSchema, { auth: "admin" }), method(object({
13540
+ namespace: string().optional(),
13541
+ collection: string(),
13542
+ field: string(),
13543
+ bucketSize: number().int().positive(),
13544
+ origin: number().int(),
13545
+ filter: QueryFilterSchema.optional()
13546
+ }), array(object({
13547
+ bucket: number().int(),
13548
+ count: number().int()
13549
+ })).readonly(), { auth: "admin" }), method(object({
13550
+ namespace: string().optional(),
13551
+ collection: string()
13552
+ }), boolean(), { auth: "admin" }), method(DeclareCollectionInputSchema, _void(), {
13553
+ kind: "mutation",
13554
+ auth: "admin"
13555
+ });
13556
+ /**
13208
13557
  * How long one snapshot may take end to end: the pinned copy of the whole
13209
13558
  * database plus `PRAGMA integrity_check` over the copy, on the hub's slowest
13210
13559
  * disk. ~800 MB at a pessimistic 10 MB/s is under 3 minutes; the bound is
@@ -13217,7 +13566,11 @@ var DATABASE_SNAPSHOT_TIMEOUT_MS = 30 * 6e4;
13217
13566
  * database has no sidecars and is just as owned). Paths are absolute on the
13218
13567
  * owner's host.
13219
13568
  */
13220
- var DatabaseSnapshotTargetsSchema = object({ databases: array(object({ livePath: string() })) });
13569
+ var DatabaseSnapshotTargetsSchema = object({ databases: array(object({
13570
+ /** Which owned file this is — the handle `writeSnapshot` takes. */
13571
+ databaseId: DataStoreDatabaseSchema,
13572
+ livePath: string()
13573
+ })) });
13221
13574
  /** One b-tree table of the snapshot and the rows it holds. */
13222
13575
  var DatabaseSnapshotTableSchema = object({
13223
13576
  name: string(),
@@ -13250,6 +13603,10 @@ var DatabaseSnapshotResultSchema = object({
13250
13603
  /** When the pinned read transaction began (ms epoch) — the snapshot's instant. */
13251
13604
  takenAt: number()
13252
13605
  });
13606
+ /** A snapshot the owner wrote, with the file it belongs to. */
13607
+ var DatabaseSnapshotWrittenSchema = DatabaseSnapshotResultSchema.extend({ databaseId: DataStoreDatabaseSchema });
13608
+ /** Which database `writeSnapshot` copies. Required: an unstated ask is not guessed. */
13609
+ var DatabaseSnapshotRequestSchema = object({ databaseId: DataStoreDatabaseSchema });
13253
13610
  /**
13254
13611
  * A snapshot as an ARCHIVE records it (`ArchiveManifest.sqliteSnapshots`):
13255
13612
  * the same facts, with both paths relative to the archive root (the node's
@@ -13259,9 +13616,11 @@ var ArchiveSqliteSnapshotSchema = DatabaseSnapshotResultSchema.extend({
13259
13616
  /** Archive-relative path of the live database the archive does NOT carry. */
13260
13617
  livePath: string(),
13261
13618
  /** Archive-relative path of the verified copy it carries in its place. */
13262
- snapshotPath: string()
13619
+ snapshotPath: string(),
13620
+ /** Absent on an archive made before several files were owned: that was `settings`. */
13621
+ databaseId: DataStoreDatabaseSchema.optional()
13263
13622
  });
13264
- method(object({}), DatabaseSnapshotTargetsSchema, { auth: "admin" }), method(object({}), DatabaseSnapshotResultSchema, {
13623
+ method(object({}), DatabaseSnapshotTargetsSchema, { auth: "admin" }), method(DatabaseSnapshotRequestSchema, DatabaseSnapshotWrittenSchema, {
13265
13624
  kind: "mutation",
13266
13625
  auth: "admin",
13267
13626
  timeoutMs: DATABASE_SNAPSHOT_TIMEOUT_MS
@@ -13382,7 +13741,12 @@ var BackupArchiveEntrySchema = object({
13382
13741
  /** Top-level locations included in the archive (db, addons, tls, …). */
13383
13742
  locations: array(string()).readonly(),
13384
13743
  /** Present when the archive is encrypted; restore then needs that key. */
13385
- encryption: BackupArchiveEncryptionSchema.optional()
13744
+ encryption: BackupArchiveEncryptionSchema.optional(),
13745
+ /**
13746
+ * The databases the run asked to carry (its retention class). Absent on an
13747
+ * archive made before several files were owned: that was `['settings']`.
13748
+ */
13749
+ databases: array(DataStoreDatabaseSchema).readonly().optional()
13386
13750
  });
13387
13751
  var BackupEntrySchema = object({
13388
13752
  id: string(),
@@ -13416,7 +13780,12 @@ var ArchiveManifestSchema = object({
13416
13780
  * Live SQLite databases this archive carries as their OWNER's verified
13417
13781
  * snapshot instead of as files (D693). Absent on archives made before.
13418
13782
  */
13419
- sqliteSnapshots: array(ArchiveSqliteSnapshotSchema).optional()
13783
+ sqliteSnapshots: array(ArchiveSqliteSnapshotSchema).optional(),
13784
+ /**
13785
+ * Owned database files the run did NOT carry (not selected): left out of the
13786
+ * tar and the entry list alike. Absent when every owned file was carried.
13787
+ */
13788
+ omittedDatabases: array(DataStoreDatabaseSchema).optional()
13420
13789
  });
13421
13790
  var LocationStatSchema = object({
13422
13791
  name: string(),
@@ -13538,6 +13907,12 @@ var BackupScheduleSchema = object({
13538
13907
  /** Optional subset of source locations to include; omitted = all. */
13539
13908
  dataSources: array(string()).readonly().optional(),
13540
13909
  /**
13910
+ * Which database files this schedule carries. Absent = `['settings']`
13911
+ * (an unstated ask is the minimum, D382). Events and history run weekly,
13912
+ * settings nightly (D852).
13913
+ */
13914
+ databases: array(DataStoreDatabaseSchema).readonly().optional(),
13915
+ /**
13541
13916
  * ms-epoch of the last tick that FIRED this schedule. Stamped before the
13542
13917
  * archive runs (it is the dedupe anchor), so it says "attempted", never
13543
13918
  * "succeeded" — a run refused by every destination stamps it too.
@@ -13561,7 +13936,9 @@ method(_void(), array(BackupDestinationInfoSchema).readonly(), { auth: "admin" }
13561
13936
  * retention). Omitted = each destination's own policy
13562
13937
  * retention (manual runs).
13563
13938
  */
13564
- retentionCount: number().int().min(1).max(1e3).optional()
13939
+ retentionCount: number().int().min(1).max(1e3).optional(),
13940
+ /** Database files to carry; omitted = `['settings']`. */
13941
+ databases: array(DataStoreDatabaseSchema).optional()
13565
13942
  }).optional(), BackupTriggerResultSchema, {
13566
13943
  kind: "mutation",
13567
13944
  auth: "admin"
@@ -13636,14 +14013,18 @@ method(_void(), array(BackupDestinationInfoSchema).readonly(), { auth: "admin" }
13636
14013
  ok: boolean(),
13637
14014
  error: string().optional(),
13638
14015
  nextRuns: array(number()).readonly()
13639
- })), method(_void(), array(BackupScheduleSchema).readonly(), { auth: "admin" }), method(object({
14016
+ })), method(_void(), array(BackupScheduleSchema).readonly(), { auth: "admin" }), method(_void(), object({
14017
+ answered: boolean(),
14018
+ databases: array(DataStoreDatabaseSchema).readonly()
14019
+ }), { auth: "admin" }), method(object({
13640
14020
  id: string().optional(),
13641
14021
  label: string(),
13642
14022
  cron: string(),
13643
14023
  enabled: boolean(),
13644
14024
  locationIds: array(string()).readonly(),
13645
14025
  retentionCount: number().int().min(1).max(1e3),
13646
- dataSources: array(string()).readonly().optional()
14026
+ dataSources: array(string()).readonly().optional(),
14027
+ databases: array(DataStoreDatabaseSchema).readonly().optional()
13647
14028
  }), BackupScheduleSchema, {
13648
14029
  kind: "mutation",
13649
14030
  auth: "admin"
@@ -14074,6 +14455,16 @@ var BrokerClientsSchema = object({
14074
14455
  /** Total encoded + raw-RTP callback subscriber count (sum of `encoded[].length`). */
14075
14456
  encodedSubscribers: number()
14076
14457
  });
14458
+ /**
14459
+ * How many people are watching one camera LIVE right now — see
14460
+ * `getLiveViewerCounts`. A camera with nobody watching is absent from the list
14461
+ * (so `viewers` is always at least 1): the listing carries the cameras that
14462
+ * have viewers, never a row of zeros.
14463
+ */
14464
+ var LiveViewerCountSchema = object({
14465
+ deviceId: number().int().nonnegative(),
14466
+ viewers: number().int().positive()
14467
+ });
14077
14468
  _enum([
14078
14469
  "reconnecting",
14079
14470
  "sleeping",
@@ -14434,7 +14825,7 @@ method(object({
14434
14825
  }), {
14435
14826
  kind: "mutation",
14436
14827
  auth: "admin"
14437
- }), method(object({ brokerId: string() }), BrokerClientsSchema), method(object({
14828
+ }), method(object({ brokerId: string() }), BrokerClientsSchema), method(_void(), array(LiveViewerCountSchema).readonly()), method(object({
14438
14829
  brokerId: string(),
14439
14830
  channel: _enum(["rtsp", "audio"]),
14440
14831
  handle: string()
@@ -15300,240 +15691,6 @@ method(_void(), array(CustomModelDescriptorSchema).readonly(), { auth: "admin" }
15300
15691
  timeoutMs: 30 * 6e4
15301
15692
  });
15302
15693
  /**
15303
- * Query filter for settings-store collections.
15304
- */
15305
- var QueryFilterSchema = object({
15306
- where: record(string(), unknown()).optional(),
15307
- whereIn: record(string(), array(unknown())).optional(),
15308
- whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
15309
- /** NULL-safe exclusion: matches rows whose field is NULL OR != the value. */
15310
- whereNot: record(string(), unknown()).optional(),
15311
- /** NULL-safe exclusion of a SET — `whereNot` for more than one value. An
15312
- * empty list excludes nothing. See `QueryFilter.whereNotIn`. */
15313
- whereNotIn: record(string(), array(unknown())).optional(),
15314
- orderBy: object({
15315
- field: string(),
15316
- direction: _enum(["asc", "desc"])
15317
- }).optional(),
15318
- limit: number().optional(),
15319
- offset: number().optional()
15320
- });
15321
- /**
15322
- * The predicate half of a filter, for BULK MUTATIONS.
15323
- *
15324
- * Deliberately not `QueryFilterSchema`: `orderBy` / `limit` / `offset` have no
15325
- * meaning for a statement that rewrites a set, and accepting them would invite
15326
- * a caller to believe `limit` bounds the damage. Every field is optional here
15327
- * only so the shape stays composable — the implementation REJECTS a filter
15328
- * that compiles to no predicate, because that is the whole collection.
15329
- */
15330
- var MutationFilterSchema = object({
15331
- where: record(string(), unknown()).optional(),
15332
- whereIn: record(string(), array(unknown())).optional(),
15333
- whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
15334
- whereNot: record(string(), unknown()).optional(),
15335
- whereNotIn: record(string(), array(unknown())).optional()
15336
- });
15337
- /**
15338
- * One scalar an {@link settingsStoreCapability.methods.aggregate} call asks for.
15339
- *
15340
- * `as` names the slot in the result, so the SAME column may be asked twice with
15341
- * two operations (`MIN(startMs)` and `MAX(startMs)` in one round trip) — which
15342
- * a `Record<column, op>` shape could not express.
15343
- */
15344
- var AggregateFieldSchema = object({
15345
- /** Result key. */
15346
- as: string().min(1),
15347
- /** Column to aggregate. Must be a real column of a declared collection. */
15348
- field: string().min(1),
15349
- op: _enum([
15350
- "sum",
15351
- "min",
15352
- "max"
15353
- ])
15354
- });
15355
- /**
15356
- * `COUNT(*)` plus one number per requested field.
15357
- *
15358
- * `null` means NO ROW MATCHED, never zero: a `SUM` over an empty set and a sum
15359
- * that really is 0 are different facts, and an accounting caller that renders
15360
- * "0 bytes, oldest = 0" for "nothing here" reports a lie about a disk.
15361
- */
15362
- var AggregateResultSchema = object({
15363
- count: number().int(),
15364
- values: record(string(), number().nullable())
15365
- });
15366
- /** A single stored record: `{ id, data }`. */
15367
- var SettingsRecordSchema = object({
15368
- id: string(),
15369
- data: record(string(), unknown())
15370
- });
15371
- /**
15372
- * One record of a BULK insert — {@link SettingsRecordSchema} with the id made
15373
- * optional.
15374
- *
15375
- * A separate schema rather than loosening the shared one: every other method
15376
- * on this cap addresses a row BY its id, and making that field optional
15377
- * everywhere would turn a forgotten key into a silently generated one on
15378
- * `update` and `delete` as well.
15379
- */
15380
- var BulkRecordSchema = object({
15381
- id: string().optional(),
15382
- data: record(string(), unknown())
15383
- });
15384
- /**
15385
- * Column declaration for a structured (SQL-backed) collection.
15386
- *
15387
- * Logical types — the backend translates each to the matching SQLite
15388
- * storage class and handles per-type marshaling:
15389
- * - `TEXT` / `INTEGER` / `REAL` — native SQLite types, pass-through
15390
- * - `JSON` — TEXT under the hood; serialised on write, parsed on read
15391
- * - `BOOLEAN` — INTEGER 0/1 under the hood; coerced both directions
15392
- */
15393
- var CollectionColumnSchema = object({
15394
- name: string(),
15395
- type: _enum([
15396
- "TEXT",
15397
- "INTEGER",
15398
- "REAL",
15399
- "JSON",
15400
- "BOOLEAN"
15401
- ]),
15402
- primaryKey: boolean().optional(),
15403
- notNull: boolean().optional(),
15404
- unique: boolean().optional(),
15405
- /**
15406
- * Column DEFAULT. Required for B2: the four `ensureTable` consumers declare
15407
- * columns like `enabled INTEGER NOT NULL DEFAULT 1`, and without this the
15408
- * collection surface simply cannot express their existing tables — which is
15409
- * why they were still on the uncapped `table*` API.
15410
- */
15411
- defaultValue: union([
15412
- string(),
15413
- number(),
15414
- boolean()
15415
- ]).optional()
15416
- });
15417
- var CollectionIndexSchema = object({
15418
- name: string(),
15419
- columns: array(string()).readonly(),
15420
- unique: boolean().optional()
15421
- });
15422
- method(object({
15423
- namespace: string().optional(),
15424
- collection: string(),
15425
- key: string()
15426
- }), unknown(), { auth: "admin" }), method(object({
15427
- namespace: string().optional(),
15428
- collection: string(),
15429
- key: string(),
15430
- value: unknown()
15431
- }), _void(), {
15432
- kind: "mutation",
15433
- auth: "admin"
15434
- }), method(object({
15435
- namespace: string().optional(),
15436
- collection: string(),
15437
- filter: QueryFilterSchema.optional(),
15438
- columns: array(string()).readonly().optional()
15439
- }), array(SettingsRecordSchema).readonly(), { auth: "admin" }), method(object({
15440
- namespace: string().optional(),
15441
- collection: string(),
15442
- /** Declared columns identifying the slot; must be covered by a UNIQUE
15443
- * index on the collection. Never empty. */
15444
- conflict: array(string()).readonly(),
15445
- record: BulkRecordSchema
15446
- }), object({
15447
- /** The id the row HAS: assigned by SQLite on an insert, or the existing
15448
- * row's own id on an update. */
15449
- id: union([string(), number()]) }), {
15450
- kind: "mutation",
15451
- auth: "admin"
15452
- }), method(object({
15453
- namespace: string().optional(),
15454
- collection: string(),
15455
- record: object({
15456
- id: string().optional(),
15457
- data: record(string(), unknown())
15458
- })
15459
- }), object({
15460
- /**
15461
- * The id the row ACTUALLY got (D473): the one supplied, the UUID minted
15462
- * for an absent one, or the ROWID SQLite assigned on an `INTEGER`
15463
- * primary key — which is the only place an auto key is knowable.
15464
- */
15465
- id: union([string(), number()]) }), {
15466
- kind: "mutation",
15467
- auth: "admin"
15468
- }), method(object({
15469
- namespace: string().optional(),
15470
- collection: string(),
15471
- records: array(BulkRecordSchema).readonly()
15472
- }), object({ inserted: number().int() }), {
15473
- kind: "mutation",
15474
- auth: "admin"
15475
- }), method(object({
15476
- namespace: string().optional(),
15477
- collection: string(),
15478
- id: string(),
15479
- data: record(string(), unknown())
15480
- }), _void(), {
15481
- kind: "mutation",
15482
- auth: "admin"
15483
- }), method(object({
15484
- namespace: string().optional(),
15485
- collection: string(),
15486
- key: string()
15487
- }), _void(), {
15488
- kind: "mutation",
15489
- auth: "admin"
15490
- }), method(object({
15491
- namespace: string().optional(),
15492
- collection: string(),
15493
- filter: MutationFilterSchema
15494
- }), object({ deleted: number().int() }), {
15495
- kind: "mutation",
15496
- auth: "admin"
15497
- }), method(object({
15498
- namespace: string().optional(),
15499
- collection: string(),
15500
- filter: MutationFilterSchema,
15501
- data: record(string(), unknown())
15502
- }), object({ updated: number().int() }), {
15503
- kind: "mutation",
15504
- auth: "admin"
15505
- }), method(object({
15506
- namespace: string().optional(),
15507
- collection: string(),
15508
- filter: QueryFilterSchema.optional()
15509
- }), number(), { auth: "admin" }), method(object({
15510
- namespace: string().optional(),
15511
- collection: string(),
15512
- fields: array(AggregateFieldSchema).readonly(),
15513
- filter: QueryFilterSchema.optional()
15514
- }), AggregateResultSchema, { auth: "admin" }), method(object({
15515
- namespace: string().optional(),
15516
- collection: string(),
15517
- field: string(),
15518
- bucketSize: number().int().positive(),
15519
- origin: number().int(),
15520
- filter: QueryFilterSchema.optional()
15521
- }), array(object({
15522
- bucket: number().int(),
15523
- count: number().int()
15524
- })).readonly(), { auth: "admin" }), method(object({
15525
- namespace: string().optional(),
15526
- collection: string()
15527
- }), boolean(), { auth: "admin" }), method(object({
15528
- namespace: string().optional(),
15529
- collection: string(),
15530
- columns: array(CollectionColumnSchema).readonly(),
15531
- indexes: array(CollectionIndexSchema).readonly().optional()
15532
- }), _void(), {
15533
- kind: "mutation",
15534
- auth: "admin"
15535
- });
15536
- /**
15537
15694
  * What one engine says about itself. The orchestrator uses `kind` to pick
15538
15695
  * a registrant for a collection; `engineId` is what a log line names when
15539
15696
  * a call is routed or refused.
@@ -15613,6 +15770,14 @@ id: union([string(), number()]) }), {
15613
15770
  }), object({ id: union([string(), number()]) }), {
15614
15771
  kind: "mutation",
15615
15772
  auth: "admin"
15773
+ }), method(object({
15774
+ namespace: string().optional(),
15775
+ collection: string(),
15776
+ conflict: array(string()).readonly(),
15777
+ records: array(BulkRecordSchema).readonly()
15778
+ }), object({ upserted: number().int() }), {
15779
+ kind: "mutation",
15780
+ auth: "admin"
15616
15781
  }), method(object({
15617
15782
  namespace: string().optional(),
15618
15783
  collection: string(),
@@ -15620,6 +15785,16 @@ id: union([string(), number()]) }), {
15620
15785
  }), object({ inserted: number().int() }), {
15621
15786
  kind: "mutation",
15622
15787
  auth: "admin"
15788
+ }), method(object({
15789
+ namespace: string().optional(),
15790
+ guard: TransactGuardSchema.optional(),
15791
+ ops: array(TransactOpSchema).readonly()
15792
+ }), object({
15793
+ applied: boolean(),
15794
+ current: unknown().optional()
15795
+ }), {
15796
+ kind: "mutation",
15797
+ auth: "admin"
15623
15798
  }), method(object({
15624
15799
  namespace: string().optional(),
15625
15800
  collection: string(),
@@ -15672,12 +15847,7 @@ id: union([string(), number()]) }), {
15672
15847
  })).readonly(), { auth: "admin" }), method(object({
15673
15848
  namespace: string().optional(),
15674
15849
  collection: string()
15675
- }), boolean(), { auth: "admin" }), method(object({
15676
- namespace: string().optional(),
15677
- collection: string(),
15678
- columns: array(CollectionColumnSchema).readonly(),
15679
- indexes: array(CollectionIndexSchema).readonly().optional()
15680
- }), _void(), {
15850
+ }), boolean(), { auth: "admin" }), method(DeclareCollectionInputSchema, _void(), {
15681
15851
  kind: "mutation",
15682
15852
  auth: "admin"
15683
15853
  });
@@ -20379,6 +20549,12 @@ var NcSystemEventKindSchema = _enum([
20379
20549
  "node-updating",
20380
20550
  "node-inference-unavailable",
20381
20551
  "detection-blind",
20552
+ "recording-stalled",
20553
+ "recording-healthy",
20554
+ "recording-degraded",
20555
+ "storage-location-low",
20556
+ "storage-location-critical",
20557
+ "storage-location-ok",
20382
20558
  "addon-crash-loop",
20383
20559
  "addon-update-available",
20384
20560
  "server-update-available",
@@ -24050,6 +24226,58 @@ var RetrainBboxSchema = object({
24050
24226
  h: number()
24051
24227
  });
24052
24228
  /**
24229
+ * What a box LOOKED LIKE when it was offered, snapshotted at the moment the
24230
+ * operator accepted it. The saved row keeps only the final rectangle; this is
24231
+ * the other half of the pair, and the pair is what says whether the operator
24232
+ * accepted, nudged, relabelled or replaced a proposal (`retrain-review.ts`).
24233
+ *
24234
+ * `ref` names the proposal inside its frame: `pipeline:<trackId>` for a box the
24235
+ * live pipeline drew, `assist:<n>` for the n-th box of a detector or LLM run,
24236
+ * and anything unique for an operator-drawn box (`operator:<n>`). Re-derived
24237
+ * pipeline boxes carry the same ref every time, which is what lets a dismissal
24238
+ * stay dismissed.
24239
+ */
24240
+ var RetrainOriginSchema = object({
24241
+ source: RetrainAnnotationSourceSchema,
24242
+ ref: string().min(1),
24243
+ bbox: RetrainBboxSchema,
24244
+ macroClass: RetrainMacroClassSchema,
24245
+ label: string().optional(),
24246
+ score: number().optional(),
24247
+ modelId: string().optional()
24248
+ });
24249
+ /**
24250
+ * A proposal the operator deleted. Durable on the frame, so a deleted pipeline
24251
+ * box does not come back as a draft every time the frame is reopened, and so
24252
+ * the deletion itself is a recorded fact rather than an absence.
24253
+ */
24254
+ var RetrainDismissedSchema = object({
24255
+ ref: string().min(1),
24256
+ snapshot: RetrainOriginSchema
24257
+ });
24258
+ /** What the operator did with a proposal (see `retrain-review.ts`). */
24259
+ var RetrainReviewStatusSchema = _enum(RETRAIN_REVIEW_STATUSES);
24260
+ var RetrainFrameReviewSchema = object({
24261
+ boxes: array(object({
24262
+ ref: string(),
24263
+ savedId: string().optional(),
24264
+ status: RetrainReviewStatusSchema,
24265
+ /** The baseline was re-derived, not snapshotted (a pre-origin row). */
24266
+ approximate: boolean(),
24267
+ origin: RetrainOriginSchema.optional(),
24268
+ /** The class / label the box carries NOW (a removed box: its origin's). Absent on an older hub. */
24269
+ macroClass: RetrainMacroClassSchema.optional(),
24270
+ label: string().optional(),
24271
+ iou: number().optional()
24272
+ })).readonly(),
24273
+ summary: object({
24274
+ counts: record(RetrainReviewStatusSchema, number().int()),
24275
+ total: number().int(),
24276
+ changed: number().int(),
24277
+ approximate: boolean()
24278
+ })
24279
+ });
24280
+ /**
24053
24281
  * One annotated subject.
24054
24282
  *
24055
24283
  * `bbox` is normalised against the full frame, ALWAYS. The per-model shapes
@@ -24073,6 +24301,9 @@ var RetrainAnnotationSchema = object({
24073
24301
  /** Which model proposed this box — or, on a `model_error`, drew the phantom. */
24074
24302
  assistModelId: string().optional(),
24075
24303
  assistScore: number().optional(),
24304
+ /** The proposal this box started from, snapshotted at accept time. `null` on
24305
+ * a row saved before origins existed; absent on a draft nobody snapshotted. */
24306
+ origin: RetrainOriginSchema.nullable().optional(),
24076
24307
  exportedInBatch: string().optional(),
24077
24308
  createdAt: number()
24078
24309
  });
@@ -24165,7 +24396,19 @@ var RetrainFrameSchema = object({
24165
24396
  * empty when nothing the track store holds can be placed on it. */
24166
24397
  pipelineBoxes: array(RetrainPipelineBoxSchema).readonly().optional(),
24167
24398
  /** The named collections this frame belongs to. Present on list answers. */
24168
- collectionIds: array(string()).readonly().optional()
24399
+ collectionIds: array(string()).readonly().optional(),
24400
+ /** Bumped by every annotation save. A save that names a stale
24401
+ * `expectedRevision` is refused, so two surfaces cannot overwrite each other. */
24402
+ revision: number().int().optional(),
24403
+ /** Proposals the operator deleted — never re-seeded as drafts. */
24404
+ dismissed: array(RetrainDismissedSchema).readonly().optional(),
24405
+ /** What the operator did with the proposals, computed by the server. */
24406
+ review: RetrainFrameReviewSchema.optional(),
24407
+ /** The frame's pixels over the admin data plane (full size). Fetch with the
24408
+ * admin bearer token; relative to the hub root. */
24409
+ imageUrl: string().optional(),
24410
+ /** The same, as a ~480 px thumbnail for grids. */
24411
+ thumbnailUrl: string().optional()
24169
24412
  });
24170
24413
  /** Why a copy-on-select could not be honoured — named, never a silent skip. */
24171
24414
  var RetrainCopyRefusalSchema = _enum([
@@ -25244,10 +25487,33 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25244
25487
  /** The frame's track, when it has one — checked against the frame. */
25245
25488
  trackId: string().optional(),
25246
25489
  frameId: string(),
25247
- annotations: array(RetrainAnnotationDraftSchema)
25490
+ annotations: array(RetrainAnnotationDraftSchema),
25491
+ /** The frame's `revision` the caller saw. A different current revision
25492
+ * refuses the save with a `retrain-revision-conflict` error
25493
+ * (`parseRetrainRevisionConflict`). Absent ⇒ last write wins. */
25494
+ expectedRevision: number().int().optional(),
25495
+ /** The proposals the operator deleted. Absent ⇒ keep the frame's
25496
+ * current set; present ⇒ replace it (an empty array un-dismisses). */
25497
+ dismissed: array(RetrainDismissedSchema).optional()
25248
25498
  }), array(RetrainAnnotationSchema).readonly(), {
25249
25499
  kind: "mutation",
25250
25500
  auth: "admin"
25501
+ }), method(object({
25502
+ deviceId: number(),
25503
+ trackId: string().optional(),
25504
+ frameId: string(),
25505
+ expectedRevision: number().int().optional(),
25506
+ origins: array(object({
25507
+ annotationId: string(),
25508
+ origin: RetrainOriginSchema
25509
+ })).min(1).max(500)
25510
+ }), object({
25511
+ updated: number().int(),
25512
+ skipped: number().int(),
25513
+ revision: number().int()
25514
+ }), {
25515
+ kind: "mutation",
25516
+ auth: "admin"
25251
25517
  }), method(object({
25252
25518
  deviceId: number(),
25253
25519
  trackId: string()
@@ -27863,6 +28129,12 @@ var CameraStepOverridePatchSchema = object({
27863
28129
  settings: record(string(), unknown()).readonly().optional()
27864
28130
  });
27865
28131
  var CameraStepSettingsSchema = record(string(), record(string(), unknown()).readonly());
28132
+ /** The three root-detector choices a camera has (D507: at most one root). */
28133
+ var CameraDetectionSourceSchema = _enum([
28134
+ "pipeline",
28135
+ "onboard",
28136
+ "none"
28137
+ ]);
27866
28138
  var CameraPipelineSettingsSchema = object({
27867
28139
  stepToggles: record(string(), boolean()).optional(),
27868
28140
  stepSettings: CameraStepSettingsSchema.optional(),
@@ -28440,6 +28712,26 @@ method(object({
28440
28712
  }), object({ success: literal(true) }), {
28441
28713
  kind: "mutation",
28442
28714
  auth: "admin"
28715
+ }), method(object({ deviceId: number() }), object({
28716
+ source: CameraDetectionSourceSchema,
28717
+ explicit: boolean(),
28718
+ onboard: object({
28719
+ /** The camera has an onboard detector this system can read. */
28720
+ available: boolean(),
28721
+ /** What its detections carry — a camera with no box cannot be a root step. */
28722
+ geometry: _enum([
28723
+ "boxed",
28724
+ "while-streaming",
28725
+ "flag-only",
28726
+ "unknown"
28727
+ ])
28728
+ })
28729
+ })), method(object({
28730
+ deviceId: number(),
28731
+ source: CameraDetectionSourceSchema
28732
+ }), object({ success: literal(true) }), {
28733
+ kind: "mutation",
28734
+ auth: "admin"
28443
28735
  }), method(object({ deviceId: number() }), record(string(), record(string(), record(string(), CameraStepOverridePatchSchema))).nullable()), method(object({
28444
28736
  deviceId: number(),
28445
28737
  agentNodeId: string(),
@@ -31806,6 +32098,17 @@ var BatteryStatusSchema = object({
31806
32098
  */
31807
32099
  lastContactAt: number().optional(),
31808
32100
  /**
32101
+ * Ms epoch of the last COMPLETE scheduled refresh — every fact the provider
32102
+ * holds for the device (level, charging, link, device info, state slices) and
32103
+ * its cached snapshot, read together. Absent = never since this slice was
32104
+ * born. Unlike `lastUpdated` (any write, even a push of one field) this is
32105
+ * the staleness an operator can trust: the provider owns the device fact and
32106
+ * so owns the window on its age (D224, D847). Not a clock in the
32107
+ * runtime-state-durability sense: it moves once per window and must survive
32108
+ * a restart, or every restart would owe the camera a wake.
32109
+ */
32110
+ lastFullRefreshAt: number().optional(),
32111
+ /**
31809
32112
  * True when the source is a BINARY low-battery indicator (HA
31810
32113
  * `binary_sensor` device_class=battery / `LOW_BAT`) that has no real
31811
32114
  * charge level — `percentage` is then a coarse stand-in (100 = normal,
@@ -31869,6 +32172,18 @@ var CalendarInfoSchema = object({
31869
32172
  source: CalendarSourceKindSchema,
31870
32173
  enabled: boolean()
31871
32174
  });
32175
+ /**
32176
+ * Time contract of {@link CalendarEvent}.
32177
+ *
32178
+ * - Timed event: `startMs` / `endMs` are real instants; `endMs` is exclusive.
32179
+ * - All-day event (`allDay: true`): the event is a run of calendar DATES, not
32180
+ * instants. `startMs` is UTC midnight of the first date and `endMs` is UTC
32181
+ * midnight of the day AFTER the last date (RFC 5545 exclusive DTEND), so a
32182
+ * one-day event spans exactly 24 h. Every provider produces that and no
32183
+ * consumer may read the instants in a local timezone: use
32184
+ * {@link calendarEventLocalSpan}. Reading UTC midnight as local time put an
32185
+ * all-day event on the following day for any viewer ahead of UTC.
32186
+ */
31872
32187
  var CalendarEventSchema = object({
31873
32188
  id: string().min(1),
31874
32189
  calendarId: string().min(1),
@@ -34011,7 +34326,15 @@ var HubAddressBookSchema = object({
34011
34326
  publicEndpoint: HubAddressRoleResolutionSchema
34012
34327
  }),
34013
34328
  /** The `hub=` an app link carries (D709), or null. */
34014
- appLinkHub: string().nullable()
34329
+ appLinkHub: string().nullable(),
34330
+ /**
34331
+ * Every origin a browser can really reach this hub at, in the scheme each
34332
+ * listener serves: `https://<lan>:<httpsPort>`, and `http://<lan>:<httpPort>`
34333
+ * while LAN HTTP is on, plus the public and custom addresses. Distinct from
34334
+ * `rows`, which show `http://` only while LAN HTTP is on. Never loopback,
34335
+ * never the app link. Absent on a hub older than D794's amendment.
34336
+ */
34337
+ listenerOrigins: array(string()).readonly().optional()
34015
34338
  });
34016
34339
  var AllowedAddressesSchema = object({
34017
34340
  /**
@@ -35021,7 +35344,14 @@ var TopologyNodeSchema = object({
35021
35344
  * completed a mutual-TLS handshake, `clear` otherwise. Absent for the hub,
35022
35345
  * for offline rows and when the hub cannot tell.
35023
35346
  */
35024
- meshTransport: _enum(["tls", "clear"]).optional()
35347
+ meshTransport: _enum(["tls", "clear"]).optional(),
35348
+ /**
35349
+ * Whether the hub holds this online AGENT's capability registration (its
35350
+ * `registerNode` manifest). `false` = online in the mesh but not ready: the
35351
+ * hub dropped the registration on a disconnect only it saw and the agent has
35352
+ * not re-sent it. Absent for the hub and offline rows.
35353
+ */
35354
+ capabilitiesRegistered: boolean().optional()
35025
35355
  });
35026
35356
  var CapUsageEdgeSchema = object({
35027
35357
  callerAddonId: string(),
@@ -40863,6 +41193,12 @@ Object.freeze({
40863
41193
  addonId: null,
40864
41194
  access: "view"
40865
41195
  },
41196
+ "backup.listAvailableDatabases": {
41197
+ capName: "backup",
41198
+ capScope: "system",
41199
+ addonId: null,
41200
+ access: "view"
41201
+ },
40866
41202
  "backup.listDestinations": {
40867
41203
  capName: "backup",
40868
41204
  capScope: "system",
@@ -41559,6 +41895,12 @@ Object.freeze({
41559
41895
  addonId: null,
41560
41896
  access: "create"
41561
41897
  },
41898
+ "dataStoreProvider.transact": {
41899
+ capName: "data-store-provider",
41900
+ capScope: "system",
41901
+ addonId: null,
41902
+ access: "create"
41903
+ },
41562
41904
  "dataStoreProvider.update": {
41563
41905
  capName: "data-store-provider",
41564
41906
  capScope: "system",
@@ -41577,6 +41919,12 @@ Object.freeze({
41577
41919
  addonId: null,
41578
41920
  access: "create"
41579
41921
  },
41922
+ "dataStoreProvider.upsertMany": {
41923
+ capName: "data-store-provider",
41924
+ capScope: "system",
41925
+ addonId: null,
41926
+ access: "create"
41927
+ },
41580
41928
  "dayNight.getOptions": {
41581
41929
  capName: "day-night",
41582
41930
  capScope: "device",
@@ -44403,6 +44751,12 @@ Object.freeze({
44403
44751
  addonId: null,
44404
44752
  access: "create"
44405
44753
  },
44754
+ "pipelineAnalytics.backfillRetrainOrigins": {
44755
+ capName: "pipeline-analytics",
44756
+ capScope: "device",
44757
+ addonId: null,
44758
+ access: "create"
44759
+ },
44406
44760
  "pipelineAnalytics.cancelRelocateMedia": {
44407
44761
  capName: "pipeline-analytics",
44408
44762
  capScope: "device",
@@ -45183,6 +45537,12 @@ Object.freeze({
45183
45537
  addonId: null,
45184
45538
  access: "view"
45185
45539
  },
45540
+ "pipelineOrchestrator.getCameraDetectionSource": {
45541
+ capName: "pipeline-orchestrator",
45542
+ capScope: "system",
45543
+ addonId: null,
45544
+ access: "view"
45545
+ },
45186
45546
  "pipelineOrchestrator.getCameraMetrics": {
45187
45547
  capName: "pipeline-orchestrator",
45188
45548
  capScope: "system",
@@ -45411,6 +45771,12 @@ Object.freeze({
45411
45771
  addonId: null,
45412
45772
  access: "create"
45413
45773
  },
45774
+ "pipelineOrchestrator.setCameraDetectionSource": {
45775
+ capName: "pipeline-orchestrator",
45776
+ capScope: "system",
45777
+ addonId: null,
45778
+ access: "create"
45779
+ },
45414
45780
  "pipelineOrchestrator.setCameraPipelineForAgent": {
45415
45781
  capName: "pipeline-orchestrator",
45416
45782
  capScope: "system",
@@ -46383,6 +46749,12 @@ Object.freeze({
46383
46749
  addonId: null,
46384
46750
  access: "create"
46385
46751
  },
46752
+ "settingsStore.transact": {
46753
+ capName: "settings-store",
46754
+ capScope: "system",
46755
+ addonId: null,
46756
+ access: "create"
46757
+ },
46386
46758
  "settingsStore.update": {
46387
46759
  capName: "settings-store",
46388
46760
  capScope: "system",
@@ -46401,6 +46773,12 @@ Object.freeze({
46401
46773
  addonId: null,
46402
46774
  access: "create"
46403
46775
  },
46776
+ "settingsStore.upsertMany": {
46777
+ capName: "settings-store",
46778
+ capScope: "system",
46779
+ addonId: null,
46780
+ access: "create"
46781
+ },
46404
46782
  "smoke.getStatus": {
46405
46783
  capName: "smoke",
46406
46784
  capScope: "device",
@@ -46863,6 +47241,12 @@ Object.freeze({
46863
47241
  addonId: null,
46864
47242
  access: "view"
46865
47243
  },
47244
+ "streamBroker.getLiveViewerCounts": {
47245
+ capName: "stream-broker",
47246
+ capScope: "system",
47247
+ addonId: null,
47248
+ access: "view"
47249
+ },
46866
47250
  "streamBroker.getPreBufferInfo": {
46867
47251
  capName: "stream-broker",
46868
47252
  capScope: "system",
@@ -50707,6 +51091,11 @@ Object.freeze({
50707
51091
  form: "single",
50708
51092
  optional: false
50709
51093
  }],
51094
+ "pipelineAnalytics.backfillRetrainOrigins": [{
51095
+ name: "deviceId",
51096
+ form: "single",
51097
+ optional: false
51098
+ }],
50710
51099
  "pipelineAnalytics.clearTrackRelation": [{
50711
51100
  name: "deviceId",
50712
51101
  form: "single",
@@ -51012,6 +51401,11 @@ Object.freeze({
51012
51401
  form: "single",
51013
51402
  optional: false
51014
51403
  }],
51404
+ "pipelineOrchestrator.getCameraDetectionSource": [{
51405
+ name: "deviceId",
51406
+ form: "single",
51407
+ optional: false
51408
+ }],
51015
51409
  "pipelineOrchestrator.getCameraMetrics": [{
51016
51410
  name: "deviceId",
51017
51411
  form: "single",
@@ -51072,6 +51466,11 @@ Object.freeze({
51072
51466
  form: "single",
51073
51467
  optional: false
51074
51468
  }],
51469
+ "pipelineOrchestrator.setCameraDetectionSource": [{
51470
+ name: "deviceId",
51471
+ form: "single",
51472
+ optional: false
51473
+ }],
51075
51474
  "pipelineOrchestrator.setCameraPipelineForAgent": [{
51076
51475
  name: "deviceId",
51077
51476
  form: "single",
@@ -52101,6 +52500,9 @@ new Map(Object.entries({
52101
52500
  "stream-online": "device-events",
52102
52501
  "stream-offline": "device-events",
52103
52502
  "detection-blind": "device-events",
52503
+ "recording-stalled": "device-events",
52504
+ "recording-healthy": "device-events",
52505
+ "recording-degraded": "device-events",
52104
52506
  "node-online": "system",
52105
52507
  "node-offline": "system",
52106
52508
  "node-restarting": "system",
@@ -52114,6 +52516,9 @@ new Map(Object.entries({
52114
52516
  "wrapper-update-available": "system",
52115
52517
  "backup-completed": "system",
52116
52518
  "export-completed": "system",
52519
+ "storage-location-low": "system",
52520
+ "storage-location-critical": "system",
52521
+ "storage-location-ok": "system",
52117
52522
  "alarm-triggered": "alarm",
52118
52523
  "alarm-armed": "alarm",
52119
52524
  "alarm-disarmed": "alarm",
@@ -52175,6 +52580,16 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
52175
52580
  label: "Detecting nothing",
52176
52581
  kinds: ["detection-blind"]
52177
52582
  },
52583
+ {
52584
+ id: "recording",
52585
+ family: "device-events",
52586
+ label: "Recording",
52587
+ kinds: [
52588
+ "recording-stalled",
52589
+ "recording-healthy",
52590
+ "recording-degraded"
52591
+ ]
52592
+ },
52178
52593
  {
52179
52594
  id: "nodes",
52180
52595
  family: "system",
@@ -52215,6 +52630,16 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
52215
52630
  label: "Backups & exports",
52216
52631
  kinds: ["backup-completed", "export-completed"]
52217
52632
  },
52633
+ {
52634
+ id: "storage",
52635
+ family: "system",
52636
+ label: "Storage locations",
52637
+ kinds: [
52638
+ "storage-location-low",
52639
+ "storage-location-critical",
52640
+ "storage-location-ok"
52641
+ ]
52642
+ },
52218
52643
  {
52219
52644
  id: "alarm",
52220
52645
  family: "alarm",
@@ -52297,6 +52722,9 @@ var DEVICE_EVENTS = [
52297
52722
  "stream-online",
52298
52723
  "stream-offline",
52299
52724
  "detection-blind",
52725
+ "recording-stalled",
52726
+ "recording-healthy",
52727
+ "recording-degraded",
52300
52728
  ...ALARM
52301
52729
  ];
52302
52730
  /** Every kind a summary may speak about — the two summarisable families. */
@@ -52464,6 +52892,11 @@ var STATE_SUMMARY_VARS = [
52464
52892
  [...RULE_TEXT],
52465
52893
  [...RULE_TEXT],
52466
52894
  [...RULE_TEXT],
52895
+ [...RULE_TEXT],
52896
+ [...RULE_TEXT],
52897
+ [...RULE_TEXT],
52898
+ [...RULE_TEXT],
52899
+ [...RULE_TEXT],
52467
52900
  ([...RULE_TEXT], [...UPDATES]),
52468
52901
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),
52469
52902
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),