@camstack/addon-agent-ui 1.2.158 → 1.2.160
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 +396 -194
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -11571,6 +11571,68 @@ method(object({
|
|
|
11571
11571
|
password: string()
|
|
11572
11572
|
}), AuthResultSchema.nullable(), { kind: "mutation" }), method(object({ state: string() }), string()), method(record(string(), string()), AuthResultSchema, { kind: "mutation" }), method(object({ token: string() }), AuthResultSchema.nullable());
|
|
11573
11573
|
/**
|
|
11574
|
+
* How long one snapshot may take end to end: the pinned copy of the whole
|
|
11575
|
+
* database plus `PRAGMA integrity_check` over the copy, on the hub's slowest
|
|
11576
|
+
* disk. ~800 MB at a pessimistic 10 MB/s is under 3 minutes; the bound is
|
|
11577
|
+
* generous because a timeout fails the whole backup run.
|
|
11578
|
+
*/
|
|
11579
|
+
var DATABASE_SNAPSHOT_TIMEOUT_MS = 30 * 6e4;
|
|
11580
|
+
/**
|
|
11581
|
+
* The databases an owner snapshots — declared by the OWNER, so a caller never
|
|
11582
|
+
* guesses which file is live from what sits beside it (a cleanly closed
|
|
11583
|
+
* database has no sidecars and is just as owned). Paths are absolute on the
|
|
11584
|
+
* owner's host.
|
|
11585
|
+
*/
|
|
11586
|
+
var DatabaseSnapshotTargetsSchema = object({ databases: array(object({ livePath: string() })) });
|
|
11587
|
+
/** One b-tree table of the snapshot and the rows it holds. */
|
|
11588
|
+
var DatabaseSnapshotTableSchema = object({
|
|
11589
|
+
name: string(),
|
|
11590
|
+
rows: number().int().nonnegative()
|
|
11591
|
+
});
|
|
11592
|
+
/**
|
|
11593
|
+
* What the owner wrote. Every path is ABSOLUTE on the owner's host — the
|
|
11594
|
+
* caller pins the call to its own node, so it can read the file; a caller
|
|
11595
|
+
* that finds the path outside its own data root refuses it rather than
|
|
11596
|
+
* archiving something it cannot place.
|
|
11597
|
+
*/
|
|
11598
|
+
var DatabaseSnapshotResultSchema = object({
|
|
11599
|
+
/** The live database the snapshot copies. Never to be copied as a file. */
|
|
11600
|
+
livePath: string(),
|
|
11601
|
+
/** The verified copy: `<livePath>` + {@link DATABASE_SNAPSHOT_SUFFIX}. */
|
|
11602
|
+
snapshotPath: string(),
|
|
11603
|
+
sizeBytes: number().int().nonnegative(),
|
|
11604
|
+
pageCount: number().int().nonnegative(),
|
|
11605
|
+
pageSize: number().int().positive(),
|
|
11606
|
+
/**
|
|
11607
|
+
* Every b-tree table with its row count. Read inside the SAME read
|
|
11608
|
+
* transaction the copy was taken from, and found EQUAL on the copy — so
|
|
11609
|
+
* this is the content of the snapshot, not an estimate of the source.
|
|
11610
|
+
*/
|
|
11611
|
+
tables: array(DatabaseSnapshotTableSchema),
|
|
11612
|
+
/** Wall time of the pinned copy (row counts included). */
|
|
11613
|
+
copyMs: number().nonnegative(),
|
|
11614
|
+
/** Wall time of the checks on the copy (`integrity_check`, row counts). */
|
|
11615
|
+
verifyMs: number().nonnegative(),
|
|
11616
|
+
/** When the pinned read transaction began (ms epoch) — the snapshot's instant. */
|
|
11617
|
+
takenAt: number()
|
|
11618
|
+
});
|
|
11619
|
+
/**
|
|
11620
|
+
* A snapshot as an ARCHIVE records it (`ArchiveManifest.sqliteSnapshots`):
|
|
11621
|
+
* the same facts, with both paths relative to the archive root (the node's
|
|
11622
|
+
* data dir), because an archive outlives the host that made it.
|
|
11623
|
+
*/
|
|
11624
|
+
var ArchiveSqliteSnapshotSchema = DatabaseSnapshotResultSchema.extend({
|
|
11625
|
+
/** Archive-relative path of the live database the archive does NOT carry. */
|
|
11626
|
+
livePath: string(),
|
|
11627
|
+
/** Archive-relative path of the verified copy it carries in its place. */
|
|
11628
|
+
snapshotPath: string()
|
|
11629
|
+
});
|
|
11630
|
+
method(object({}), DatabaseSnapshotTargetsSchema, { auth: "admin" }), method(object({}), DatabaseSnapshotResultSchema, {
|
|
11631
|
+
kind: "mutation",
|
|
11632
|
+
auth: "admin",
|
|
11633
|
+
timeoutMs: DATABASE_SNAPSHOT_TIMEOUT_MS
|
|
11634
|
+
});
|
|
11635
|
+
/**
|
|
11574
11636
|
* Orchestrator-side destination metadata. The orchestrator computes
|
|
11575
11637
|
* `id = <addonId>:<subId>` from its provider lookup so consumers
|
|
11576
11638
|
* (admin UI, restore flow) see one canonical key.
|
|
@@ -11681,7 +11743,12 @@ var ArchiveManifestSchema = object({
|
|
|
11681
11743
|
locations: array(string()),
|
|
11682
11744
|
entries: array(ArchiveEntrySchema),
|
|
11683
11745
|
totalBytes: number(),
|
|
11684
|
-
totalFiles: number()
|
|
11746
|
+
totalFiles: number(),
|
|
11747
|
+
/**
|
|
11748
|
+
* Live SQLite databases this archive carries as their OWNER's verified
|
|
11749
|
+
* snapshot instead of as files (D693). Absent on archives made before.
|
|
11750
|
+
*/
|
|
11751
|
+
sqliteSnapshots: array(ArchiveSqliteSnapshotSchema).optional()
|
|
11685
11752
|
});
|
|
11686
11753
|
var LocationStatSchema = object({
|
|
11687
11754
|
name: string(),
|
|
@@ -13105,6 +13172,52 @@ var CompositionBlockStateSchema = object({
|
|
|
13105
13172
|
reason: string().optional(),
|
|
13106
13173
|
fields: array(CompositionFieldStateSchema)
|
|
13107
13174
|
});
|
|
13175
|
+
var ComposerBlockSchema = object({
|
|
13176
|
+
id: string().min(1),
|
|
13177
|
+
name: string().min(1).max(120),
|
|
13178
|
+
enabled: boolean(),
|
|
13179
|
+
updatedAt: number(),
|
|
13180
|
+
composition: CompositionSchema
|
|
13181
|
+
});
|
|
13182
|
+
/**
|
|
13183
|
+
* A stored composition row that no longer PARSES — a schema a release
|
|
13184
|
+
* tightened, a row written by a newer build. Sent by id so the composer keeps
|
|
13185
|
+
* its device as a placeholder and reports the block `failed` naming the parse
|
|
13186
|
+
* error. Leaving it out would read, twice, exactly like a delete (D49).
|
|
13187
|
+
*/
|
|
13188
|
+
var ComposerUnreadableBlockSchema = object({
|
|
13189
|
+
id: string().min(1),
|
|
13190
|
+
/** The row's stored name column; null when even that is unreadable (the device keeps the name it has). */
|
|
13191
|
+
name: string().nullable(),
|
|
13192
|
+
/** The parse error, in the operator's words. */
|
|
13193
|
+
error: string()
|
|
13194
|
+
});
|
|
13195
|
+
method(object({
|
|
13196
|
+
/** The shared Blocks integration; null until `core-blocks` has reconciled it. */
|
|
13197
|
+
integrationId: string().nullable(),
|
|
13198
|
+
/** False when the `core_blocks` read failed: then nothing may be withdrawn (D49). */
|
|
13199
|
+
storeLoaded: boolean(),
|
|
13200
|
+
blocks: array(ComposerBlockSchema),
|
|
13201
|
+
/** Operator restarts: rebuild these runtimes and re-resolve their sources. Stores nothing (D62). */
|
|
13202
|
+
restartBlockIds: array(string()),
|
|
13203
|
+
/** Composition rows that exist but do not parse: held, never withdrawn, reported failed. */
|
|
13204
|
+
unreadableBlocks: array(ComposerUnreadableBlockSchema)
|
|
13205
|
+
}), object({
|
|
13206
|
+
blocks: array(object({
|
|
13207
|
+
blockId: string(),
|
|
13208
|
+
status: CompositionRunStatusSchema,
|
|
13209
|
+
reason: string().optional()
|
|
13210
|
+
})),
|
|
13211
|
+
/**
|
|
13212
|
+
* False when the composer declared and withdrew NOTHING (store not loaded,
|
|
13213
|
+
* integration unknown, its own rows unread or read empty once). An empty
|
|
13214
|
+
* apply the caller owes is paid off only by one the composer acted on (D49).
|
|
13215
|
+
*/
|
|
13216
|
+
acted: boolean()
|
|
13217
|
+
}), {
|
|
13218
|
+
kind: "mutation",
|
|
13219
|
+
auth: "admin"
|
|
13220
|
+
}), method(object({ blockIds: array(string()) }), object({ states: array(CompositionBlockStateSchema) }), { auth: "admin" });
|
|
13108
13221
|
var NUMBER = {
|
|
13109
13222
|
kind: "fixed",
|
|
13110
13223
|
result: ["number"]
|
|
@@ -13341,52 +13454,6 @@ method(object({}), object({ blocks: array(CoreBlockSchema) }), { auth: "admin" }
|
|
|
13341
13454
|
auth: "admin",
|
|
13342
13455
|
access: "view"
|
|
13343
13456
|
});
|
|
13344
|
-
var ComposerBlockSchema = object({
|
|
13345
|
-
id: string().min(1),
|
|
13346
|
-
name: string().min(1).max(120),
|
|
13347
|
-
enabled: boolean(),
|
|
13348
|
-
updatedAt: number(),
|
|
13349
|
-
composition: CompositionSchema
|
|
13350
|
-
});
|
|
13351
|
-
/**
|
|
13352
|
-
* A stored composition row that no longer PARSES — a schema a release
|
|
13353
|
-
* tightened, a row written by a newer build. Sent by id so the composer keeps
|
|
13354
|
-
* its device as a placeholder and reports the block `failed` naming the parse
|
|
13355
|
-
* error. Leaving it out would read, twice, exactly like a delete (D49).
|
|
13356
|
-
*/
|
|
13357
|
-
var ComposerUnreadableBlockSchema = object({
|
|
13358
|
-
id: string().min(1),
|
|
13359
|
-
/** The row's stored name column; null when even that is unreadable (the device keeps the name it has). */
|
|
13360
|
-
name: string().nullable(),
|
|
13361
|
-
/** The parse error, in the operator's words. */
|
|
13362
|
-
error: string()
|
|
13363
|
-
});
|
|
13364
|
-
method(object({
|
|
13365
|
-
/** The shared Blocks integration; null until `core-blocks` has reconciled it. */
|
|
13366
|
-
integrationId: string().nullable(),
|
|
13367
|
-
/** False when the `core_blocks` read failed: then nothing may be withdrawn (D49). */
|
|
13368
|
-
storeLoaded: boolean(),
|
|
13369
|
-
blocks: array(ComposerBlockSchema),
|
|
13370
|
-
/** Operator restarts: rebuild these runtimes and re-resolve their sources. Stores nothing (D62). */
|
|
13371
|
-
restartBlockIds: array(string()),
|
|
13372
|
-
/** Composition rows that exist but do not parse: held, never withdrawn, reported failed. */
|
|
13373
|
-
unreadableBlocks: array(ComposerUnreadableBlockSchema)
|
|
13374
|
-
}), object({
|
|
13375
|
-
blocks: array(object({
|
|
13376
|
-
blockId: string(),
|
|
13377
|
-
status: CompositionRunStatusSchema,
|
|
13378
|
-
reason: string().optional()
|
|
13379
|
-
})),
|
|
13380
|
-
/**
|
|
13381
|
-
* False when the composer declared and withdrew NOTHING (store not loaded,
|
|
13382
|
-
* integration unknown, its own rows unread or read empty once). An empty
|
|
13383
|
-
* apply the caller owes is paid off only by one the composer acted on (D49).
|
|
13384
|
-
*/
|
|
13385
|
-
acted: boolean()
|
|
13386
|
-
}), {
|
|
13387
|
-
kind: "mutation",
|
|
13388
|
-
auth: "admin"
|
|
13389
|
-
}), method(object({ blockIds: array(string()) }), object({ states: array(CompositionBlockStateSchema) }), { auth: "admin" });
|
|
13390
13457
|
/**
|
|
13391
13458
|
* `custom-model-registry` — collection cap exposing operator-registered
|
|
13392
13459
|
* custom detection models. Each provider (today: `addon-model-studio`)
|
|
@@ -15235,6 +15302,138 @@ method(object({
|
|
|
15235
15302
|
deviceIds: array(number()).readonly(),
|
|
15236
15303
|
caps: array(string()).readonly().optional()
|
|
15237
15304
|
}), record(string(), record(string(), unknown().nullable())));
|
|
15305
|
+
object({
|
|
15306
|
+
/** Ms epoch of the last press. null = never observed since this provider started. */
|
|
15307
|
+
lastPressedAt: number().nullable(),
|
|
15308
|
+
/** Counter since provider start. Resets on reboot. Useful for metrics/debug. */
|
|
15309
|
+
pressCountSinceStart: number()
|
|
15310
|
+
});
|
|
15311
|
+
object({
|
|
15312
|
+
deviceId: number(),
|
|
15313
|
+
timestamp: number()
|
|
15314
|
+
});
|
|
15315
|
+
/**
|
|
15316
|
+
* The `doorbell-source` extension slot's editable value (D648): the camera's
|
|
15317
|
+
* virtual-doorbell trigger devices, exactly what the wrapper's
|
|
15318
|
+
* `doorbellSources` persists (as `{ deviceId }` records).
|
|
15319
|
+
*/
|
|
15320
|
+
var DoorbellSourceSlotValueSchema = object({ deviceIds: array(number().int().positive()) });
|
|
15321
|
+
DeviceType.Camera;
|
|
15322
|
+
DeviceType.Button, DeviceType.Camera;
|
|
15323
|
+
var ExtensionSlotIdSchema = _enum(["doorbell-source", "linked-devices"]);
|
|
15324
|
+
DeviceType.Camera, DeviceType.Camera;
|
|
15325
|
+
/** A slot's editable value, discriminated on `slot`. */
|
|
15326
|
+
var ExtensionSlotValueSchema = discriminatedUnion("slot", [DoorbellSourceSlotValueSchema.extend({ slot: literal("doorbell-source") }), LinkedDevicesSlotValueSchema.extend({ slot: literal("linked-devices") })]);
|
|
15327
|
+
DeviceType.Camera;
|
|
15328
|
+
var ExtensionSourceAvailabilitySchema = discriminatedUnion("state", [object({ state: literal("ok") }), object({
|
|
15329
|
+
state: literal("unreachable"),
|
|
15330
|
+
reason: string()
|
|
15331
|
+
})]);
|
|
15332
|
+
/** One provider of slots — the D554 source-listing row. */
|
|
15333
|
+
var ExtensionSourceSchema = object({
|
|
15334
|
+
/** The routing prefix of every `slotRef` this provider serves. */
|
|
15335
|
+
source: string(),
|
|
15336
|
+
label: string(),
|
|
15337
|
+
/** Stamped by the dispatcher from the registry (D557). */
|
|
15338
|
+
addonId: string().optional(),
|
|
15339
|
+
availability: ExtensionSourceAvailabilitySchema
|
|
15340
|
+
});
|
|
15341
|
+
/**
|
|
15342
|
+
* How one picked source stands. `missing` — no such device (deleted, or an id
|
|
15343
|
+
* that never existed); `foreign` — a device the slot's owner cannot read from
|
|
15344
|
+
* (a source owned by another addon); `unavailable` — it exists but is not a
|
|
15345
|
+
* valid source now (a container, which is never a pick). A source in any of
|
|
15346
|
+
* these states is SHOWN, never silently dropped or re-pointed.
|
|
15347
|
+
*/
|
|
15348
|
+
var ExtensionSourceHealthSchema = _enum([
|
|
15349
|
+
"ok",
|
|
15350
|
+
"missing",
|
|
15351
|
+
"foreign",
|
|
15352
|
+
"unavailable"
|
|
15353
|
+
]);
|
|
15354
|
+
var ExtensionSlotSourceSchema = object({
|
|
15355
|
+
deviceId: number().int(),
|
|
15356
|
+
/** The device's name, or null when it could not be resolved (`missing`). */
|
|
15357
|
+
name: string().nullable(),
|
|
15358
|
+
health: ExtensionSourceHealthSchema,
|
|
15359
|
+
detail: string().optional()
|
|
15360
|
+
});
|
|
15361
|
+
/**
|
|
15362
|
+
* A DIFFERENT authority that gates whether the slot's sources do anything —
|
|
15363
|
+
* reported read-only, named, never written through this contract (D62). The
|
|
15364
|
+
* virtual doorbell's sources ring only while the wrapper is bound to the
|
|
15365
|
+
* camera, and that binding belongs to `deviceManager.setWrapperActive`.
|
|
15366
|
+
* `unknown` means the gate could not be read; it is not "inactive" (D315).
|
|
15367
|
+
*/
|
|
15368
|
+
var ExtensionSlotActivationSchema = object({
|
|
15369
|
+
state: _enum([
|
|
15370
|
+
"active",
|
|
15371
|
+
"inactive",
|
|
15372
|
+
"unknown"
|
|
15373
|
+
]),
|
|
15374
|
+
authority: string(),
|
|
15375
|
+
detail: string().optional()
|
|
15376
|
+
});
|
|
15377
|
+
var ExtensionSlotRowSchema = discriminatedUnion("state", [object({
|
|
15378
|
+
state: literal("ok"),
|
|
15379
|
+
/** `<source>:<slotId>` — the routing key for `listCandidates` / `setSlot`. */
|
|
15380
|
+
slotRef: string(),
|
|
15381
|
+
slot: ExtensionSlotIdSchema,
|
|
15382
|
+
/** Names the store written (D62), e.g. `virtual-doorbell:doorbellSources`. */
|
|
15383
|
+
authority: string(),
|
|
15384
|
+
activation: ExtensionSlotActivationSchema.nullable(),
|
|
15385
|
+
value: ExtensionSlotValueSchema,
|
|
15386
|
+
sources: array(ExtensionSlotSourceSchema),
|
|
15387
|
+
/**
|
|
15388
|
+
* Devices the owner links to the host ON ITS OWN, by structure, and that
|
|
15389
|
+
* are therefore not in `value` (D655): a camera's device-tree children, and
|
|
15390
|
+
* the child a picked container stands for (D356 — a container is never a
|
|
15391
|
+
* pick, its children are). Read-only; the editor shows them and may offer
|
|
15392
|
+
* per-device options on them (the linked-devices tracked-event opt-in).
|
|
15393
|
+
* Absent when the owner links nothing beyond the picks, and from an owner
|
|
15394
|
+
* older than D655.
|
|
15395
|
+
*/
|
|
15396
|
+
impliedSources: array(ExtensionSlotSourceSchema).optional()
|
|
15397
|
+
}), object({
|
|
15398
|
+
state: literal("unreachable"),
|
|
15399
|
+
addonId: string(),
|
|
15400
|
+
reason: string()
|
|
15401
|
+
})]);
|
|
15402
|
+
var ExtensionCandidatesSchema = object({ candidates: array(object({
|
|
15403
|
+
deviceId: number().int(),
|
|
15404
|
+
name: string(),
|
|
15405
|
+
type: string(),
|
|
15406
|
+
location: string().nullable(),
|
|
15407
|
+
/** The container a child belongs to — "Spotlight 2" alone does not say which. */
|
|
15408
|
+
parentName: string().nullable(),
|
|
15409
|
+
/** Pre-marked by the owner's suggestion rule. NEVER saved on its own (D356). */
|
|
15410
|
+
suggested: boolean(),
|
|
15411
|
+
/** Why it is suggested ("same location"), null when it is not. */
|
|
15412
|
+
reason: string().nullable()
|
|
15413
|
+
})) });
|
|
15414
|
+
/**
|
|
15415
|
+
* What a write did. `none` — applied in place. `host` / `parent` — the owner
|
|
15416
|
+
* reloaded the host (or, for an accessory child, its parent) because the
|
|
15417
|
+
* write changed what the host REGISTERS. A slot never adds a capability to its
|
|
15418
|
+
* host — that is a composition (D663) — so today's owners answer `none`.
|
|
15419
|
+
*/
|
|
15420
|
+
var ExtensionSetResultSchema = object({
|
|
15421
|
+
applied: literal(true),
|
|
15422
|
+
reload: _enum([
|
|
15423
|
+
"none",
|
|
15424
|
+
"host",
|
|
15425
|
+
"parent"
|
|
15426
|
+
])
|
|
15427
|
+
});
|
|
15428
|
+
var ExtensionSlotRefInputSchema = object({
|
|
15429
|
+
deviceId: number().int(),
|
|
15430
|
+
slotRef: string().min(1)
|
|
15431
|
+
});
|
|
15432
|
+
var ExtensionSetSlotInputSchema = ExtensionSlotRefInputSchema.extend({ value: ExtensionSlotValueSchema });
|
|
15433
|
+
method(object({ deviceId: number().int() }), array(ExtensionSourceSchema)), method(object({ deviceId: number().int() }), array(ExtensionSlotRowSchema)), method(ExtensionSlotRefInputSchema, ExtensionCandidatesSchema), method(ExtensionSetSlotInputSchema, ExtensionSetResultSchema, {
|
|
15434
|
+
kind: "mutation",
|
|
15435
|
+
auth: "admin"
|
|
15436
|
+
});
|
|
15238
15437
|
/**
|
|
15239
15438
|
* Per-field ownership (D663). A composition may CLAIM fields of a native
|
|
15240
15439
|
* cap's runtime-state slice on an existing device: `replace` overlays the
|
|
@@ -18207,17 +18406,25 @@ var NcScheduleSchema = object({
|
|
|
18207
18406
|
*/
|
|
18208
18407
|
var NcSystemEventDeliveryModeSchema = _enum(["instant", "summary"]);
|
|
18209
18408
|
/**
|
|
18409
|
+
* How a summary window is SENT (D698): `rule` (absent) = ONE notification with
|
|
18410
|
+
* every section; `section` = one notification per section with something to
|
|
18411
|
+
* say (an unavailable section included), each titled by its section.
|
|
18412
|
+
*/
|
|
18413
|
+
var NcStateSummarySplitSchema = _enum(["rule", "section"]);
|
|
18414
|
+
/**
|
|
18210
18415
|
* `summary`: the rule sends NOTHING per event. When a window of `schedule`
|
|
18211
18416
|
* CLOSES, it sends one notification with the current state of its kinds
|
|
18212
18417
|
* (low batteries, consumables to replace, devices offline, updates
|
|
18213
|
-
* available, ...), after its own filters
|
|
18418
|
+
* available, ...), after its own filters — or, with `split: 'section'`
|
|
18419
|
+
* (D698), one notification per section. Nothing to report sends nothing.
|
|
18214
18420
|
* The schedule is the ordinary `NcSchedule` (weekly windows, IANA timezone,
|
|
18215
18421
|
* midnight crossing); the send time is each window's END. Refused on the
|
|
18216
18422
|
* `alarm` family, which stays instant (`systemEventDeliveryProblems`).
|
|
18217
18423
|
*/
|
|
18218
18424
|
var NcSystemEventDeliverySchema = discriminatedUnion("mode", [object({ mode: literal("instant") }), object({
|
|
18219
18425
|
mode: literal("summary"),
|
|
18220
|
-
schedule: NcScheduleSchema
|
|
18426
|
+
schedule: NcScheduleSchema,
|
|
18427
|
+
split: NcStateSummarySplitSchema.optional()
|
|
18221
18428
|
})]);
|
|
18222
18429
|
/** Fuzzy plate matcher — OCR noise makes exact match useless (spec row 12/13). */
|
|
18223
18430
|
var NcPlateMatcherSchema = object({
|
|
@@ -18357,8 +18564,14 @@ var NcSensorTransitionSchema = _enum(["raised", "cleared"]);
|
|
|
18357
18564
|
/** Admin-zone membership condition (zone IDs as stamped by the ZoneEngine). */
|
|
18358
18565
|
var NcZoneConditionSchema = object({
|
|
18359
18566
|
ids: array(string().min(1)).min(1),
|
|
18360
|
-
/**
|
|
18361
|
-
|
|
18567
|
+
/**
|
|
18568
|
+
* LEGACY quantifier over `ids`. Absent = `any` (at least one visited), which
|
|
18569
|
+
* is what both editors mean and all they write since D690: "all of" was
|
|
18570
|
+
* removed from the editors because on an immediate rule it asked one
|
|
18571
|
+
* detection to stand in every zone at once. Still ACCEPTED, and `all` still
|
|
18572
|
+
* evaluated, so a stored rule keeps parsing and meaning what it meant.
|
|
18573
|
+
*/
|
|
18574
|
+
match: _enum(["any", "all"]).optional()
|
|
18362
18575
|
});
|
|
18363
18576
|
/**
|
|
18364
18577
|
* The P1 condition set — a flat AND of groups; absent group = pass;
|
|
@@ -18862,10 +19075,12 @@ var NcMediaPolicySchema = object({
|
|
|
18862
19075
|
/**
|
|
18863
19076
|
* Cooldown GRANULARITY over the subject's class — how much a fired
|
|
18864
19077
|
* notification suppresses.
|
|
18865
|
-
* - `
|
|
18866
|
-
*
|
|
18867
|
-
*
|
|
18868
|
-
*
|
|
19078
|
+
* - `per-class` (default, and the absent value since 2026-10-01 — D36) — an
|
|
19079
|
+
* independent window per detected class: cat→dog fires at once, cat→cat
|
|
19080
|
+
* still waits.
|
|
19081
|
+
* - `shared` — one window for the whole rule/scope: a cat silences the next
|
|
19082
|
+
* dog for `cooldownSec`. Only written when an operator picks it; it is no
|
|
19083
|
+
* longer what an unset rule means.
|
|
18869
19084
|
*
|
|
18870
19085
|
* AUDIO subjects are ALWAYS per-class regardless of this setting: a scream
|
|
18871
19086
|
* must not be swallowed by a bark's window (the precedent this generalizes —
|
|
@@ -18880,8 +19095,11 @@ var NcThrottleSchema = object({
|
|
|
18880
19095
|
/**
|
|
18881
19096
|
* Class granularity of the cooldown key. Optional rather than defaulted:
|
|
18882
19097
|
* a Zod default does NOT run on the addon→addon cap path, so a persisted
|
|
18883
|
-
* rule authored before this field simply carries none
|
|
18884
|
-
*
|
|
19098
|
+
* rule authored before this field simply carries none. The engine used to
|
|
19099
|
+
* read absent as `shared` (D36); since 2026-10-01 it reads absent as
|
|
19100
|
+
* `per-class` — the operator's default — and only an explicit `shared`
|
|
19101
|
+
* still means `shared`. See `cooldownKey` / `keysPerClass` in the rule
|
|
19102
|
+
* engine, and D36's dated note.
|
|
18885
19103
|
*/
|
|
18886
19104
|
granularity: NcThrottleGranularitySchema.optional()
|
|
18887
19105
|
});
|
|
@@ -19205,11 +19423,23 @@ var NcStateSummaryPreviewSectionSchema = object({
|
|
|
19205
19423
|
reason: string().optional()
|
|
19206
19424
|
});
|
|
19207
19425
|
/**
|
|
19426
|
+
* One notification a previewed summary would send (D698): the whole summary on
|
|
19427
|
+
* a `rule` split (no `section`), one section's on a `section` split.
|
|
19428
|
+
*/
|
|
19429
|
+
var NcStateSummaryPreviewRowSchema = object({
|
|
19430
|
+
section: string().optional(),
|
|
19431
|
+
/** The section's name on a per-section row; every reported section's, joined, on a combined one. */
|
|
19432
|
+
title: string(),
|
|
19433
|
+
text: string(),
|
|
19434
|
+
count: number().int().nonnegative()
|
|
19435
|
+
});
|
|
19436
|
+
/**
|
|
19208
19437
|
* The summary a rule would send now. `empty` = nothing to report and every
|
|
19209
19438
|
* section read: such a summary is NOT sent. `dropped` counts the open states
|
|
19210
19439
|
* the rule's own filters (or a camera mute) left out, by reason.
|
|
19211
19440
|
* `excludedGroups` names the kind groups selected that have no state to report
|
|
19212
|
-
* (backups & exports).
|
|
19441
|
+
* (backups & exports). `split` and `rows` (D698) say how it would be sent —
|
|
19442
|
+
* optional, so an older hub's answer still parses.
|
|
19213
19443
|
*/
|
|
19214
19444
|
var NcStateSummaryPreviewSchema = object({
|
|
19215
19445
|
empty: boolean(),
|
|
@@ -19217,7 +19447,9 @@ var NcStateSummaryPreviewSchema = object({
|
|
|
19217
19447
|
text: string(),
|
|
19218
19448
|
sections: array(NcStateSummaryPreviewSectionSchema),
|
|
19219
19449
|
dropped: record(string(), number().int().nonnegative()),
|
|
19220
|
-
excludedGroups: array(string())
|
|
19450
|
+
excludedGroups: array(string()),
|
|
19451
|
+
split: NcStateSummarySplitSchema.optional(),
|
|
19452
|
+
rows: array(NcStateSummaryPreviewRowSchema).optional()
|
|
19221
19453
|
});
|
|
19222
19454
|
var NcTestResultSchema = object({
|
|
19223
19455
|
recordId: string(),
|
|
@@ -22138,7 +22370,8 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
|
|
|
22138
22370
|
trackIds: array(string()).min(1)
|
|
22139
22371
|
}), object({
|
|
22140
22372
|
deleted: number().int(),
|
|
22141
|
-
failed: array(string()).readonly()
|
|
22373
|
+
failed: array(string()).readonly(),
|
|
22374
|
+
sparedMediaIds: array(number().int()).readonly().optional()
|
|
22142
22375
|
}), {
|
|
22143
22376
|
kind: "mutation",
|
|
22144
22377
|
auth: "admin"
|
|
@@ -24327,7 +24560,42 @@ var SetCameraSensorsInputSchema = object({
|
|
|
24327
24560
|
/** `null` removes the attachment: the camera goes back to `not-configured`. */
|
|
24328
24561
|
config: CameraSensorsConfigSchema.nullable()
|
|
24329
24562
|
});
|
|
24330
|
-
|
|
24563
|
+
/**
|
|
24564
|
+
* Why an early occupancy look (D691) was not scheduled.
|
|
24565
|
+
*
|
|
24566
|
+
* - `unknown-camera` — no session was ever dispatched for it, so there is no
|
|
24567
|
+
* node and no config to attach a burst with.
|
|
24568
|
+
* - `out-of-range` — the ask is negative or further out than the orchestrator
|
|
24569
|
+
* will hold a timer for; the parked-object cadence is the answer there.
|
|
24570
|
+
* - `no-burst-producer` — this build has no burst producer at all.
|
|
24571
|
+
* - `already-looked` — this camera's ONE early look since its last session has
|
|
24572
|
+
* been spent. A look's own burst can re-arm a flickering flip, and a look
|
|
24573
|
+
* per arm would chain a burst every ~30 s forever (review H2); the next
|
|
24574
|
+
* real session re-arms the budget.
|
|
24575
|
+
*/
|
|
24576
|
+
var OccupancyLookRefusalSchema = _enum([
|
|
24577
|
+
"unknown-camera",
|
|
24578
|
+
"out-of-range",
|
|
24579
|
+
"no-burst-producer",
|
|
24580
|
+
"already-looked"
|
|
24581
|
+
]);
|
|
24582
|
+
method(object({
|
|
24583
|
+
deviceId: number().int().nonnegative(),
|
|
24584
|
+
/** How long from NOW until the pending flip's sustain window ends. RELATIVE,
|
|
24585
|
+
* so the caller's clock and the orchestrator's never have to agree. */
|
|
24586
|
+
afterMs: number().finite(),
|
|
24587
|
+
/** Why, for the log. */
|
|
24588
|
+
reason: string()
|
|
24589
|
+
}), object({
|
|
24590
|
+
scheduled: boolean(),
|
|
24591
|
+
/** When `scheduled`: how long until the burst is dialled. */
|
|
24592
|
+
dueInMs: number().optional(),
|
|
24593
|
+
/** When not `scheduled`: why. */
|
|
24594
|
+
refusedBecause: OccupancyLookRefusalSchema.optional()
|
|
24595
|
+
}), {
|
|
24596
|
+
kind: "mutation",
|
|
24597
|
+
auth: "admin"
|
|
24598
|
+
}), method(StorageMigrationLeaseInputSchema, object({ paused: literal(true) }), {
|
|
24331
24599
|
kind: "mutation",
|
|
24332
24600
|
auth: "admin"
|
|
24333
24601
|
}), method(StorageMigrationLeaseInputSchema, object({ resumed: literal(true) }), {
|
|
@@ -26660,138 +26928,6 @@ DeviceType.Camera, method(object({
|
|
|
26660
26928
|
kind: "query",
|
|
26661
26929
|
auth: "protected"
|
|
26662
26930
|
});
|
|
26663
|
-
object({
|
|
26664
|
-
/** Ms epoch of the last press. null = never observed since this provider started. */
|
|
26665
|
-
lastPressedAt: number().nullable(),
|
|
26666
|
-
/** Counter since provider start. Resets on reboot. Useful for metrics/debug. */
|
|
26667
|
-
pressCountSinceStart: number()
|
|
26668
|
-
});
|
|
26669
|
-
object({
|
|
26670
|
-
deviceId: number(),
|
|
26671
|
-
timestamp: number()
|
|
26672
|
-
});
|
|
26673
|
-
/**
|
|
26674
|
-
* The `doorbell-source` extension slot's editable value (D648): the camera's
|
|
26675
|
-
* virtual-doorbell trigger devices, exactly what the wrapper's
|
|
26676
|
-
* `doorbellSources` persists (as `{ deviceId }` records).
|
|
26677
|
-
*/
|
|
26678
|
-
var DoorbellSourceSlotValueSchema = object({ deviceIds: array(number().int().positive()) });
|
|
26679
|
-
DeviceType.Camera;
|
|
26680
|
-
DeviceType.Button, DeviceType.Camera;
|
|
26681
|
-
var ExtensionSlotIdSchema = _enum(["doorbell-source", "linked-devices"]);
|
|
26682
|
-
DeviceType.Camera, DeviceType.Camera;
|
|
26683
|
-
/** A slot's editable value, discriminated on `slot`. */
|
|
26684
|
-
var ExtensionSlotValueSchema = discriminatedUnion("slot", [DoorbellSourceSlotValueSchema.extend({ slot: literal("doorbell-source") }), LinkedDevicesSlotValueSchema.extend({ slot: literal("linked-devices") })]);
|
|
26685
|
-
DeviceType.Camera;
|
|
26686
|
-
var ExtensionSourceAvailabilitySchema = discriminatedUnion("state", [object({ state: literal("ok") }), object({
|
|
26687
|
-
state: literal("unreachable"),
|
|
26688
|
-
reason: string()
|
|
26689
|
-
})]);
|
|
26690
|
-
/** One provider of slots — the D554 source-listing row. */
|
|
26691
|
-
var ExtensionSourceSchema = object({
|
|
26692
|
-
/** The routing prefix of every `slotRef` this provider serves. */
|
|
26693
|
-
source: string(),
|
|
26694
|
-
label: string(),
|
|
26695
|
-
/** Stamped by the dispatcher from the registry (D557). */
|
|
26696
|
-
addonId: string().optional(),
|
|
26697
|
-
availability: ExtensionSourceAvailabilitySchema
|
|
26698
|
-
});
|
|
26699
|
-
/**
|
|
26700
|
-
* How one picked source stands. `missing` — no such device (deleted, or an id
|
|
26701
|
-
* that never existed); `foreign` — a device the slot's owner cannot read from
|
|
26702
|
-
* (a source owned by another addon); `unavailable` — it exists but is not a
|
|
26703
|
-
* valid source now (a container, which is never a pick). A source in any of
|
|
26704
|
-
* these states is SHOWN, never silently dropped or re-pointed.
|
|
26705
|
-
*/
|
|
26706
|
-
var ExtensionSourceHealthSchema = _enum([
|
|
26707
|
-
"ok",
|
|
26708
|
-
"missing",
|
|
26709
|
-
"foreign",
|
|
26710
|
-
"unavailable"
|
|
26711
|
-
]);
|
|
26712
|
-
var ExtensionSlotSourceSchema = object({
|
|
26713
|
-
deviceId: number().int(),
|
|
26714
|
-
/** The device's name, or null when it could not be resolved (`missing`). */
|
|
26715
|
-
name: string().nullable(),
|
|
26716
|
-
health: ExtensionSourceHealthSchema,
|
|
26717
|
-
detail: string().optional()
|
|
26718
|
-
});
|
|
26719
|
-
/**
|
|
26720
|
-
* A DIFFERENT authority that gates whether the slot's sources do anything —
|
|
26721
|
-
* reported read-only, named, never written through this contract (D62). The
|
|
26722
|
-
* virtual doorbell's sources ring only while the wrapper is bound to the
|
|
26723
|
-
* camera, and that binding belongs to `deviceManager.setWrapperActive`.
|
|
26724
|
-
* `unknown` means the gate could not be read; it is not "inactive" (D315).
|
|
26725
|
-
*/
|
|
26726
|
-
var ExtensionSlotActivationSchema = object({
|
|
26727
|
-
state: _enum([
|
|
26728
|
-
"active",
|
|
26729
|
-
"inactive",
|
|
26730
|
-
"unknown"
|
|
26731
|
-
]),
|
|
26732
|
-
authority: string(),
|
|
26733
|
-
detail: string().optional()
|
|
26734
|
-
});
|
|
26735
|
-
var ExtensionSlotRowSchema = discriminatedUnion("state", [object({
|
|
26736
|
-
state: literal("ok"),
|
|
26737
|
-
/** `<source>:<slotId>` — the routing key for `listCandidates` / `setSlot`. */
|
|
26738
|
-
slotRef: string(),
|
|
26739
|
-
slot: ExtensionSlotIdSchema,
|
|
26740
|
-
/** Names the store written (D62), e.g. `virtual-doorbell:doorbellSources`. */
|
|
26741
|
-
authority: string(),
|
|
26742
|
-
activation: ExtensionSlotActivationSchema.nullable(),
|
|
26743
|
-
value: ExtensionSlotValueSchema,
|
|
26744
|
-
sources: array(ExtensionSlotSourceSchema),
|
|
26745
|
-
/**
|
|
26746
|
-
* Devices the owner links to the host ON ITS OWN, by structure, and that
|
|
26747
|
-
* are therefore not in `value` (D655): a camera's device-tree children, and
|
|
26748
|
-
* the child a picked container stands for (D356 — a container is never a
|
|
26749
|
-
* pick, its children are). Read-only; the editor shows them and may offer
|
|
26750
|
-
* per-device options on them (the linked-devices tracked-event opt-in).
|
|
26751
|
-
* Absent when the owner links nothing beyond the picks, and from an owner
|
|
26752
|
-
* older than D655.
|
|
26753
|
-
*/
|
|
26754
|
-
impliedSources: array(ExtensionSlotSourceSchema).optional()
|
|
26755
|
-
}), object({
|
|
26756
|
-
state: literal("unreachable"),
|
|
26757
|
-
addonId: string(),
|
|
26758
|
-
reason: string()
|
|
26759
|
-
})]);
|
|
26760
|
-
var ExtensionCandidatesSchema = object({ candidates: array(object({
|
|
26761
|
-
deviceId: number().int(),
|
|
26762
|
-
name: string(),
|
|
26763
|
-
type: string(),
|
|
26764
|
-
location: string().nullable(),
|
|
26765
|
-
/** The container a child belongs to — "Spotlight 2" alone does not say which. */
|
|
26766
|
-
parentName: string().nullable(),
|
|
26767
|
-
/** Pre-marked by the owner's suggestion rule. NEVER saved on its own (D356). */
|
|
26768
|
-
suggested: boolean(),
|
|
26769
|
-
/** Why it is suggested ("same location"), null when it is not. */
|
|
26770
|
-
reason: string().nullable()
|
|
26771
|
-
})) });
|
|
26772
|
-
/**
|
|
26773
|
-
* What a write did. `none` — applied in place. `host` / `parent` — the owner
|
|
26774
|
-
* reloaded the host (or, for an accessory child, its parent) because the
|
|
26775
|
-
* write changed what the host REGISTERS. A slot never adds a capability to its
|
|
26776
|
-
* host — that is a composition (D663) — so today's owners answer `none`.
|
|
26777
|
-
*/
|
|
26778
|
-
var ExtensionSetResultSchema = object({
|
|
26779
|
-
applied: literal(true),
|
|
26780
|
-
reload: _enum([
|
|
26781
|
-
"none",
|
|
26782
|
-
"host",
|
|
26783
|
-
"parent"
|
|
26784
|
-
])
|
|
26785
|
-
});
|
|
26786
|
-
var ExtensionSlotRefInputSchema = object({
|
|
26787
|
-
deviceId: number().int(),
|
|
26788
|
-
slotRef: string().min(1)
|
|
26789
|
-
});
|
|
26790
|
-
var ExtensionSetSlotInputSchema = ExtensionSlotRefInputSchema.extend({ value: ExtensionSlotValueSchema });
|
|
26791
|
-
method(object({ deviceId: number().int() }), array(ExtensionSourceSchema)), method(object({ deviceId: number().int() }), array(ExtensionSlotRowSchema)), method(ExtensionSlotRefInputSchema, ExtensionCandidatesSchema), method(ExtensionSetSlotInputSchema, ExtensionSetResultSchema, {
|
|
26792
|
-
kind: "mutation",
|
|
26793
|
-
auth: "admin"
|
|
26794
|
-
});
|
|
26795
26931
|
/**
|
|
26796
26932
|
* Optional client-side hints sent at session creation to help the provider
|
|
26797
26933
|
* pick the best native source. All fields optional — a viewer that knows
|
|
@@ -37891,6 +38027,18 @@ Object.freeze({
|
|
|
37891
38027
|
addonId: null,
|
|
37892
38028
|
access: "view"
|
|
37893
38029
|
},
|
|
38030
|
+
"databaseSnapshot.listDatabases": {
|
|
38031
|
+
capName: "database-snapshot",
|
|
38032
|
+
capScope: "system",
|
|
38033
|
+
addonId: null,
|
|
38034
|
+
access: "view"
|
|
38035
|
+
},
|
|
38036
|
+
"databaseSnapshot.writeSnapshot": {
|
|
38037
|
+
capName: "database-snapshot",
|
|
38038
|
+
capScope: "system",
|
|
38039
|
+
addonId: null,
|
|
38040
|
+
access: "create"
|
|
38041
|
+
},
|
|
37894
38042
|
"dataStoreProvider.aggregate": {
|
|
37895
38043
|
capName: "data-store-provider",
|
|
37896
38044
|
capScope: "system",
|
|
@@ -41455,6 +41603,12 @@ Object.freeze({
|
|
|
41455
41603
|
addonId: null,
|
|
41456
41604
|
access: "delete"
|
|
41457
41605
|
},
|
|
41606
|
+
"pipelineOrchestrator.requestOccupancyLook": {
|
|
41607
|
+
capName: "pipeline-orchestrator",
|
|
41608
|
+
capScope: "system",
|
|
41609
|
+
addonId: null,
|
|
41610
|
+
access: "create"
|
|
41611
|
+
},
|
|
41458
41612
|
"pipelineOrchestrator.resetNodePipelineDefaults": {
|
|
41459
41613
|
capName: "pipeline-orchestrator",
|
|
41460
41614
|
capScope: "system",
|
|
@@ -45247,6 +45401,11 @@ Object.freeze({
|
|
|
45247
45401
|
form: "single",
|
|
45248
45402
|
optional: false
|
|
45249
45403
|
}],
|
|
45404
|
+
"pipelineOrchestrator.requestOccupancyLook": [{
|
|
45405
|
+
name: "deviceId",
|
|
45406
|
+
form: "single",
|
|
45407
|
+
optional: false
|
|
45408
|
+
}],
|
|
45250
45409
|
"pipelineOrchestrator.resolvePipeline": [{
|
|
45251
45410
|
name: "deviceId",
|
|
45252
45411
|
form: "single",
|
|
@@ -46408,6 +46567,18 @@ var STATE_SUMMARY_VARS = [
|
|
|
46408
46567
|
systemEventKinds: [...SUMMARISABLE],
|
|
46409
46568
|
systemEventDeliveries: ["summary"]
|
|
46410
46569
|
},
|
|
46570
|
+
{
|
|
46571
|
+
name: "summarySection",
|
|
46572
|
+
label: "Summary: this section",
|
|
46573
|
+
description: "The section a per-section summary row is about (D698); on a summary sent as one message, every section it reports, comma-separated.",
|
|
46574
|
+
example: "Batterie scariche",
|
|
46575
|
+
group: "system",
|
|
46576
|
+
families: ["rule"],
|
|
46577
|
+
fields: [...RULE_TEXT],
|
|
46578
|
+
kinds: ["system"],
|
|
46579
|
+
systemEventKinds: [...SUMMARISABLE],
|
|
46580
|
+
systemEventDeliveries: ["summary"]
|
|
46581
|
+
},
|
|
46411
46582
|
...STATE_SUMMARY_SECTION_VARS.map((v) => ({
|
|
46412
46583
|
name: v.name,
|
|
46413
46584
|
label: v.label,
|
|
@@ -46484,6 +46655,37 @@ var STATE_SUMMARY_VARS = [
|
|
|
46484
46655
|
[...RULE_TEXT],
|
|
46485
46656
|
...STATE_SUMMARY_VARS
|
|
46486
46657
|
];
|
|
46658
|
+
new Set([
|
|
46659
|
+
"disarmed",
|
|
46660
|
+
"armed_home",
|
|
46661
|
+
"armed_away",
|
|
46662
|
+
"armed_night",
|
|
46663
|
+
"armed_vacation",
|
|
46664
|
+
"armed_custom_bypass",
|
|
46665
|
+
"arming",
|
|
46666
|
+
"disarming",
|
|
46667
|
+
"pending",
|
|
46668
|
+
"triggered",
|
|
46669
|
+
"open",
|
|
46670
|
+
"opening",
|
|
46671
|
+
"closing",
|
|
46672
|
+
"closed",
|
|
46673
|
+
"stopped",
|
|
46674
|
+
"locked",
|
|
46675
|
+
"unlocked",
|
|
46676
|
+
"locking",
|
|
46677
|
+
"unlocking",
|
|
46678
|
+
"jammed",
|
|
46679
|
+
"on",
|
|
46680
|
+
"off",
|
|
46681
|
+
"home",
|
|
46682
|
+
"not_home",
|
|
46683
|
+
"matched",
|
|
46684
|
+
"diverged",
|
|
46685
|
+
"unknown",
|
|
46686
|
+
"latched",
|
|
46687
|
+
"live"
|
|
46688
|
+
]);
|
|
46487
46689
|
/**
|
|
46488
46690
|
* TimelapseRule — the STANDALONE scheduled timelapse producer's rule model.
|
|
46489
46691
|
*
|
|
@@ -46918,7 +47120,7 @@ var AgentUIAddon = class extends BaseAddon {
|
|
|
46918
47120
|
capability: adminUiCapability,
|
|
46919
47121
|
provider: {
|
|
46920
47122
|
getStaticDir: async () => ({ staticDir: path.resolve(__dirname) }),
|
|
46921
|
-
getVersion: async () => ({ version: "1.2.
|
|
47123
|
+
getVersion: async () => ({ version: "1.2.160" })
|
|
46922
47124
|
}
|
|
46923
47125
|
}];
|
|
46924
47126
|
}
|