@camstack/addon-export-alexa 1.2.159 → 1.2.161

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.
@@ -34,7 +34,7 @@ let node_path = require("node:path");
34
34
  node_path = __toESM(node_path, 1);
35
35
  require("node:child_process");
36
36
  require("node:zlib");
37
- //#region ../types/dist/event-category-DOl51-Ij.mjs
37
+ //#region ../types/dist/event-category-BfJwUd2S.mjs
38
38
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
39
39
  EventCategory["SystemBoot"] = "system.boot";
40
40
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -351,6 +351,15 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
351
351
  */
352
352
  EventCategory["PipelineDetectionBlind"] = "pipeline.detection-blind";
353
353
  /**
354
+ * A camera's motion source has fired constantly with no subject for an hour
355
+ * (motion duty or session count over the bar, zero detections) — it is not
356
+ * blind, its motion zones or sensitivity want tuning (D907). Paired with
357
+ * {@link PipelineMotionCalm}.
358
+ */
359
+ EventCategory["PipelineMotionNoisy"] = "pipeline.motion-noisy";
360
+ /** The recovery edge of {@link PipelineMotionNoisy}: the motion fell back, or a detection arrived. */
361
+ EventCategory["PipelineMotionCalm"] = "pipeline.motion-calm";
362
+ /**
354
363
  * Per-camera pipeline config was mutated by the orchestrator
355
364
  * (3-level settings change via `setAgentAddonDefaults` /
356
365
  * `setCameraStepToggle` / `setCameraPipelineForAgent` or a
@@ -722,6 +731,14 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
722
731
  EventCategory["BackupRestored"] = "backup.restored";
723
732
  EventCategory["NotificationDispatched"] = "notification.dispatched";
724
733
  EventCategory["NotificationFailed"] = "notification.failed";
734
+ /**
735
+ * A notification rule that cannot work (D905): its stored row does not load,
736
+ * or it still names a device / delivery target the prune CONFIRMED deleted.
737
+ * One edge per rule per distinct set of reasons; never on an unanswered read.
738
+ */
739
+ EventCategory["NotificationRuleBroken"] = "notification.rule-broken";
740
+ /** The clear of {@link NotificationRuleBroken}: the rule loads and names nothing deleted. */
741
+ EventCategory["NotificationRuleRepaired"] = "notification.rule-repaired";
725
742
  EventCategory["DeviceUpdated"] = "device.updated";
726
743
  /**
727
744
  * Transport-level connectivity. Emitted by the device driver when
@@ -5449,7 +5466,7 @@ var ZodIssueCode = {
5449
5466
  var ZodFirstPartyTypeKind;
5450
5467
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5451
5468
  //#endregion
5452
- //#region ../types/dist/sleep-_sV1BE2f.mjs
5469
+ //#region ../types/dist/sleep-DJFUfKvA.mjs
5453
5470
  /**
5454
5471
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5455
5472
  * window to float samples (D455).
@@ -7911,7 +7928,7 @@ var EntryDescriptorSchema = object({
7911
7928
  /** JSON Schema of the entry body; `secret: true` marks a password field. */
7912
7929
  fields: record(string(), unknown())
7913
7930
  }).strict();
7914
- /** What crosses the wire and sits in the engine's catalog: JSON only, no Zod. */
7931
+ /** What crosses the wire from an addon: JSON only, no Zod. An unknown key is refused. */
7915
7932
  var RecordKindDeclarationSchema = object({
7916
7933
  database: _enum(RECORD_DATABASES).default("settings"),
7917
7934
  class: _enum(RECORD_CLASSES),
@@ -7930,14 +7947,6 @@ var RecordKindDeclarationSchema = object({
7930
7947
  secretPaths: array(string().min(1)).default([]),
7931
7948
  /** The id key of each array that carries a secret (`{ headers: 'name' }`). */
7932
7949
  secretArrayKeys: record(string(), string()).default({}),
7933
- /**
7934
- * RETIRED (D900): the legacy table a kind adopted from during the records
7935
- * migration. Nothing declares it any more and nothing reads it; the schema
7936
- * still ACCEPTS it because the catalog rows the migration wrote carry it
7937
- * (an orphaned kind is never redeclared) and an addon built before the
7938
- * removal still sends it. Never set it.
7939
- */
7940
- adoptsFrom: string().min(1).optional(),
7941
7950
  /** Kinds that must agree through `transact` sit in one file under one family name. */
7942
7951
  transactFamily: string().min(1).optional(),
7943
7952
  entry: EntryDescriptorSchema.optional()
@@ -12897,17 +12906,6 @@ object({
12897
12906
  createdAt: number(),
12898
12907
  updatedAt: number()
12899
12908
  });
12900
- object({
12901
- id: string(),
12902
- label: string(),
12903
- isAdmin: boolean().default(false),
12904
- allowedProviders: AllowedProviderSchema,
12905
- allowedDevices: AllowedDevicesSchema,
12906
- tokenHash: string(),
12907
- tokenPrefix: string(),
12908
- createdAt: number(),
12909
- lastUsedAt: number().optional()
12910
- });
12911
12909
  object({
12912
12910
  id: string(),
12913
12911
  userId: string(),
@@ -16802,16 +16800,36 @@ var RecordKindStateSchema = _enum([
16802
16800
  var DeclareKindResultSchema = object({
16803
16801
  kindId: number().int(),
16804
16802
  state: RecordKindStateSchema,
16805
- createdIndexes: array(string()),
16806
- /**
16807
- * RETIRED (D900): always `null`. It carried the records-migration boot guard;
16808
- * it stays on the wire, null, because an addon built before the removal reads
16809
- * an ABSENT field as "adoption pending" and refuses to start.
16810
- */
16811
- adoptionPending: _null()
16803
+ createdIndexes: array(string())
16812
16804
  });
16813
16805
  /** Keychain refs a write released (the old marker is gone from the row): the owner deletes the values. */
16814
16806
  var SecretRefsList = array(string());
16807
+ /**
16808
+ * One op of a `transact`: the single-row writes, each on a kind of the caller.
16809
+ * All ops of one call share ONE database file and ONE `transactFamily`.
16810
+ */
16811
+ var RecordTransactOpSchema = discriminatedUnion("op", [
16812
+ object({
16813
+ op: literal("put"),
16814
+ kind: RecordKindNameSchema,
16815
+ record: RecordInputSchema,
16816
+ ifRev: number().int().min(0).optional()
16817
+ }),
16818
+ object({
16819
+ op: literal("patch"),
16820
+ kind: RecordKindNameSchema,
16821
+ id: RecordIdSchema,
16822
+ data: RecordBodySchema,
16823
+ at: number().int().nullable().optional(),
16824
+ expiresAt: number().int().nullable().optional(),
16825
+ ifRev: number().int().min(1).optional()
16826
+ }),
16827
+ object({
16828
+ op: literal("delete"),
16829
+ kind: RecordKindNameSchema,
16830
+ id: RecordIdSchema
16831
+ })
16832
+ ]);
16815
16833
  var RecordSecretRefsSchema = record(string(), record(string(), string()));
16816
16834
  method(object({ kinds: record(RecordKindNameSchema, RecordKindDeclarationSchema) }), object({ kinds: record(string(), DeclareKindResultSchema) }), {
16817
16835
  kind: "mutation",
@@ -16918,6 +16936,16 @@ method(object({ kinds: record(RecordKindNameSchema, RecordKindDeclarationSchema)
16918
16936
  }), {
16919
16937
  kind: "mutation",
16920
16938
  auth: "admin"
16939
+ }), method(object({ ops: array(RecordTransactOpSchema).min(1).max(RECORD_BATCH_MAX) }), object({
16940
+ results: array(object({
16941
+ rev: number().int().nullable(),
16942
+ deleted: boolean()
16943
+ })),
16944
+ releasedRefs: SecretRefsList,
16945
+ secretRefs: SecretRefsList
16946
+ }), {
16947
+ kind: "mutation",
16948
+ auth: "admin"
16921
16949
  }), method(object({
16922
16950
  deviceId: number().int(),
16923
16951
  kinds: array(RecordKindNameSchema).optional()
@@ -42301,9 +42329,13 @@ var NcSystemEventKindSchema = _enum([
42301
42329
  "node-updating",
42302
42330
  "node-inference-unavailable",
42303
42331
  "detection-blind",
42332
+ "motion-noisy",
42333
+ "motion-calm",
42304
42334
  "recording-stalled",
42305
42335
  "recording-healthy",
42306
42336
  "recording-degraded",
42337
+ "device-attention-required",
42338
+ "device-attention-resolved",
42307
42339
  "storage-location-low",
42308
42340
  "storage-location-critical",
42309
42341
  "storage-location-ok",
@@ -42327,6 +42359,8 @@ var NcSystemEventKindSchema = _enum([
42327
42359
  "alert-critical",
42328
42360
  "alert-error",
42329
42361
  "alert-critical-resolved",
42362
+ "rule-broken",
42363
+ "rule-repaired",
42330
42364
  "camera-online",
42331
42365
  "camera-offline",
42332
42366
  "camera-disabled",
@@ -54798,6 +54832,16 @@ object({
54798
54832
  powerState: string().nullable(),
54799
54833
  saltLevel: DishwasherConsumableLevelSchema.nullable(),
54800
54834
  rinseAidLevel: DishwasherConsumableLevelSchema.nullable(),
54835
+ /**
54836
+ * True while the appliance asks for its filter to be cleaned (smart-filter, filter-system or
54837
+ * combined care-and-filter reminder raised); false when every such reminder reads clear; null
54838
+ * when none is reported. A cleared reminder is not an unknown one.
54839
+ */
54840
+ filterCleaningDue: boolean().nullable(),
54841
+ /** True while the machine-care (descaling / cleaning-program) reminder is raised; false when clear; null when not reported. */
54842
+ machineCareDue: boolean().nullable(),
54843
+ /** Program runs left before the machine-care reminder is due; null when the appliance does not say. */
54844
+ machineCareRemainingRuns: number().int().nonnegative().nullable(),
54801
54845
  /** Option states: null when the appliance does not expose the option or has not said. */
54802
54846
  halfLoad: boolean().nullable(),
54803
54847
  hygienePlus: boolean().nullable(),
@@ -61446,16 +61490,6 @@ var UpdateUserInputSchema = object({
61446
61490
  allowedDevices: record(string(), union([array(string()), literal("*")])).optional(),
61447
61491
  scopes: array(TokenScopeSchema).optional()
61448
61492
  });
61449
- var ApiKeySummarySchema = object({
61450
- id: string(),
61451
- label: string(),
61452
- isAdmin: boolean().default(false),
61453
- allowedProviders: union([array(string()), literal("*")]).optional(),
61454
- allowedDevices: record(string(), union([array(string()), literal("*")])).optional(),
61455
- tokenPrefix: string(),
61456
- createdAt: number(),
61457
- lastUsedAt: number().optional()
61458
- });
61459
61493
  var OauthSessionSummarySchema = object({
61460
61494
  id: string(),
61461
61495
  userId: string(),
@@ -61477,8 +61511,7 @@ var TotpStatusSchema = object({
61477
61511
  confirmedAt: number().nullable()
61478
61512
  });
61479
61513
  /**
61480
- * user-management — singleton capability for user accounts and the
61481
- * legacy API-key rows.
61514
+ * user-management — singleton capability for user accounts.
61482
61515
  *
61483
61516
  * v2 model: every method gated by `auth: 'admin'`. Admin-only delegation
61484
61517
  * — the subset check on `setUserScopes` is moot
@@ -61534,10 +61567,6 @@ method(_void(), array(UserSummarySchema), { auth: "admin" }), method(CreateUserI
61534
61567
  }), UserSummarySchema.extend({ passwordHash: string() }).nullable(), {
61535
61568
  kind: "mutation",
61536
61569
  access: "view"
61537
- }), method(_void(), array(ApiKeySummarySchema), { auth: "admin" }), method(object({ id: string() }), object({ success: literal(true) }), {
61538
- kind: "mutation",
61539
- auth: "admin",
61540
- access: "delete"
61541
61570
  }), method(object({ userId: string() }), TotpSetupResultSchema, {
61542
61571
  kind: "mutation",
61543
61572
  auth: "admin",
@@ -69050,6 +69079,12 @@ Object.freeze({
69050
69079
  addonId: null,
69051
69080
  access: "view"
69052
69081
  },
69082
+ "records.transact": {
69083
+ capName: "records",
69084
+ capScope: "system",
69085
+ addonId: null,
69086
+ access: "create"
69087
+ },
69053
69088
  "sceneMonitor.captureReference": {
69054
69089
  capName: "scene-monitor",
69055
69090
  capScope: "device",
@@ -70382,12 +70417,6 @@ Object.freeze({
70382
70417
  addonId: null,
70383
70418
  access: "view"
70384
70419
  },
70385
- "userManagement.listApiKeys": {
70386
- capName: "user-management",
70387
- capScope: "system",
70388
- addonId: null,
70389
- access: "view"
70390
- },
70391
70420
  "userManagement.listExternalIdentities": {
70392
70421
  capName: "user-management",
70393
70422
  capScope: "system",
@@ -70442,12 +70471,6 @@ Object.freeze({
70442
70471
  addonId: null,
70443
70472
  access: "create"
70444
70473
  },
70445
- "userManagement.revokeApiKey": {
70446
- capName: "user-management",
70447
- capScope: "system",
70448
- addonId: null,
70449
- access: "delete"
70450
- },
70451
70474
  "userManagement.revokeOauthSession": {
70452
70475
  capName: "user-management",
70453
70476
  capScope: "system",
@@ -73812,9 +73835,13 @@ new Map(Object.entries({
73812
73835
  "stream-online": "device-events",
73813
73836
  "stream-offline": "device-events",
73814
73837
  "detection-blind": "device-events",
73838
+ "motion-noisy": "device-events",
73839
+ "motion-calm": "device-events",
73815
73840
  "recording-stalled": "device-events",
73816
73841
  "recording-healthy": "device-events",
73817
73842
  "recording-degraded": "device-events",
73843
+ "device-attention-required": "device-events",
73844
+ "device-attention-resolved": "device-events",
73818
73845
  "node-online": "system",
73819
73846
  "node-offline": "system",
73820
73847
  "node-restarting": "system",
@@ -73831,6 +73858,8 @@ new Map(Object.entries({
73831
73858
  "alert-critical": "system",
73832
73859
  "alert-error": "system",
73833
73860
  "alert-critical-resolved": "system",
73861
+ "rule-broken": "system",
73862
+ "rule-repaired": "system",
73834
73863
  "storage-location-low": "system",
73835
73864
  "storage-location-critical": "system",
73836
73865
  "storage-location-ok": "system",
@@ -73895,6 +73924,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
73895
73924
  label: "Detecting nothing",
73896
73925
  kinds: ["detection-blind"]
73897
73926
  },
73927
+ {
73928
+ id: "motion-noise",
73929
+ family: "device-events",
73930
+ label: "Motion without a subject",
73931
+ kinds: ["motion-noisy", "motion-calm"]
73932
+ },
73898
73933
  {
73899
73934
  id: "recording",
73900
73935
  family: "device-events",
@@ -73905,6 +73940,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
73905
73940
  "recording-degraded"
73906
73941
  ]
73907
73942
  },
73943
+ {
73944
+ id: "device-attention",
73945
+ family: "device-events",
73946
+ label: "Needs attention",
73947
+ kinds: ["device-attention-required", "device-attention-resolved"]
73948
+ },
73908
73949
  {
73909
73950
  id: "nodes",
73910
73951
  family: "system",
@@ -73965,6 +74006,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
73965
74006
  "alert-critical-resolved"
73966
74007
  ]
73967
74008
  },
74009
+ {
74010
+ id: "rule-health",
74011
+ family: "system",
74012
+ label: "Notification rules",
74013
+ kinds: ["rule-broken", "rule-repaired"]
74014
+ },
73968
74015
  {
73969
74016
  id: "alarm",
73970
74017
  family: "alarm",
@@ -74038,6 +74085,7 @@ var ALERT_EPISODE = [
74038
74085
  "alert-error",
74039
74086
  "alert-critical-resolved"
74040
74087
  ];
74088
+ var DEVICE_ATTENTION = ["device-attention-required", "device-attention-resolved"];
74041
74089
  var UPDATES = [
74042
74090
  "addon-update-available",
74043
74091
  "server-update-available",
@@ -74067,9 +74115,12 @@ var DEVICE_EVENTS = [
74067
74115
  "stream-online",
74068
74116
  "stream-offline",
74069
74117
  "detection-blind",
74118
+ "motion-noisy",
74119
+ "motion-calm",
74070
74120
  "recording-stalled",
74071
74121
  "recording-healthy",
74072
74122
  "recording-degraded",
74123
+ ...DEVICE_ATTENTION,
74073
74124
  ...ALARM
74074
74125
  ];
74075
74126
  /** Every kind a summary may speak about — the two summarisable families. */
@@ -74237,7 +74288,13 @@ var STATE_SUMMARY_VARS = [
74237
74288
  [...RULE_TEXT],
74238
74289
  [...RULE_TEXT],
74239
74290
  [...RULE_TEXT],
74240
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74291
+ [...RULE_TEXT],
74292
+ [...RULE_TEXT],
74293
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74294
+ [...RULE_TEXT],
74295
+ [...RULE_TEXT],
74296
+ [...RULE_TEXT],
74297
+ [...RULE_TEXT],
74241
74298
  [...RULE_TEXT],
74242
74299
  [...RULE_TEXT],
74243
74300
  [...RULE_TEXT],
@@ -74255,11 +74312,11 @@ var STATE_SUMMARY_VARS = [
74255
74312
  [...RULE_TEXT],
74256
74313
  [...RULE_TEXT],
74257
74314
  [...RULE_TEXT],
74315
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74258
74316
  ([...RULE_TEXT], [...ALERT_EPISODE]),
74317
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74259
74318
  ([...RULE_TEXT], [...ALERT_EPISODE]),
74260
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74261
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74262
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74319
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74263
74320
  [...RULE_TEXT],
74264
74321
  [...RULE_TEXT],
74265
74322
  [...RULE_TEXT],
@@ -74280,6 +74337,125 @@ var STATE_SUMMARY_VARS = [
74280
74337
  [...RULE_TEXT],
74281
74338
  ...STATE_SUMMARY_VARS
74282
74339
  ];
74340
+ new Map([
74341
+ {
74342
+ id: "device-connectivity",
74343
+ family: "device-events",
74344
+ label: "Device connectivity (offline / back online)",
74345
+ bad: ["device-offline"],
74346
+ recovery: ["device-online"],
74347
+ snapshotLabel: "Devices offline now",
74348
+ snapshotSection: "device-state"
74349
+ },
74350
+ {
74351
+ id: "device-switch",
74352
+ family: "device-events",
74353
+ label: "Device switched off / back on",
74354
+ bad: ["device-disabled"],
74355
+ recovery: ["device-enabled"],
74356
+ snapshotLabel: "Devices switched off now",
74357
+ snapshotSection: "device-state"
74358
+ },
74359
+ {
74360
+ id: "stream-connectivity",
74361
+ family: "device-events",
74362
+ label: "Stream connectivity (offline / back online)",
74363
+ bad: ["stream-offline"],
74364
+ recovery: ["stream-online"],
74365
+ snapshotLabel: "Streams offline now",
74366
+ snapshotSection: "streams"
74367
+ },
74368
+ {
74369
+ id: "battery",
74370
+ family: "device-events",
74371
+ label: "Battery (low / back to normal)",
74372
+ bad: ["device-battery-low"],
74373
+ recovery: ["device-battery-normal"],
74374
+ snapshotLabel: "Batteries low now",
74375
+ snapshotSection: "battery"
74376
+ },
74377
+ {
74378
+ id: "consumables",
74379
+ family: "device-events",
74380
+ label: "Consumables (low / replaced)",
74381
+ bad: ["device-consumable-low"],
74382
+ recovery: ["device-consumable-normal"],
74383
+ snapshotLabel: "Consumables low now",
74384
+ snapshotSection: "consumables"
74385
+ },
74386
+ {
74387
+ id: "tanks",
74388
+ family: "device-events",
74389
+ label: "Tanks (low or full / back to normal)",
74390
+ bad: ["device-tank-low", "device-tank-full"],
74391
+ recovery: ["device-tank-normal"],
74392
+ snapshotLabel: "Tanks low or full now",
74393
+ snapshotSection: "tanks"
74394
+ },
74395
+ {
74396
+ id: "motion-noise",
74397
+ family: "device-events",
74398
+ label: "Motion without a subject (constant / calm again)",
74399
+ bad: ["motion-noisy"],
74400
+ recovery: ["motion-calm"],
74401
+ snapshotLabel: "Cameras with constant motion now",
74402
+ snapshotSection: null
74403
+ },
74404
+ {
74405
+ id: "recording-health",
74406
+ family: "device-events",
74407
+ label: "Recording health (stalled or degraded / recording again)",
74408
+ bad: ["recording-stalled", "recording-degraded"],
74409
+ recovery: ["recording-healthy"],
74410
+ snapshotLabel: "Recordings stalled now",
74411
+ snapshotSection: null
74412
+ },
74413
+ {
74414
+ id: "device-attention",
74415
+ family: "device-events",
74416
+ label: "Device needs attention (raised / resolved)",
74417
+ bad: ["device-attention-required"],
74418
+ recovery: ["device-attention-resolved"],
74419
+ snapshotLabel: "Devices needing attention now",
74420
+ snapshotSection: null
74421
+ },
74422
+ {
74423
+ id: "node-connectivity",
74424
+ family: "system",
74425
+ label: "Node connectivity (offline / back online)",
74426
+ bad: ["node-offline"],
74427
+ recovery: ["node-online"],
74428
+ snapshotLabel: "Nodes offline now",
74429
+ snapshotSection: "nodes"
74430
+ },
74431
+ {
74432
+ id: "storage-space",
74433
+ family: "system",
74434
+ label: "Storage space (low or critical / ok again)",
74435
+ bad: ["storage-location-low", "storage-location-critical"],
74436
+ recovery: ["storage-location-ok"],
74437
+ snapshotLabel: "Storage locations low now",
74438
+ snapshotSection: null
74439
+ },
74440
+ {
74441
+ id: "critical-alerts",
74442
+ family: "system",
74443
+ label: "Critical alerts (raised / resolved)",
74444
+ bad: ["alert-critical"],
74445
+ recovery: ["alert-critical-resolved"],
74446
+ snapshotLabel: "Critical alerts open now",
74447
+ snapshotSection: null
74448
+ },
74449
+ {
74450
+ id: "rule-health",
74451
+ family: "system",
74452
+ label: "Rule health (broken / repaired)",
74453
+ bad: ["rule-broken"],
74454
+ recovery: ["rule-repaired"],
74455
+ snapshotLabel: "Notification rules broken now",
74456
+ snapshotSection: null
74457
+ }
74458
+ ].flatMap((spec) => [...spec.bad, ...spec.recovery].map((kind) => [kind, spec])));
74283
74459
  new Set([
74284
74460
  "disarmed",
74285
74461
  "armed_home",
@@ -5,7 +5,7 @@ import "node:fs";
5
5
  import "node:path";
6
6
  import "node:child_process";
7
7
  import "node:zlib";
8
- //#region ../types/dist/event-category-DOl51-Ij.mjs
8
+ //#region ../types/dist/event-category-BfJwUd2S.mjs
9
9
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
10
10
  EventCategory["SystemBoot"] = "system.boot";
11
11
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -322,6 +322,15 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
322
322
  */
323
323
  EventCategory["PipelineDetectionBlind"] = "pipeline.detection-blind";
324
324
  /**
325
+ * A camera's motion source has fired constantly with no subject for an hour
326
+ * (motion duty or session count over the bar, zero detections) — it is not
327
+ * blind, its motion zones or sensitivity want tuning (D907). Paired with
328
+ * {@link PipelineMotionCalm}.
329
+ */
330
+ EventCategory["PipelineMotionNoisy"] = "pipeline.motion-noisy";
331
+ /** The recovery edge of {@link PipelineMotionNoisy}: the motion fell back, or a detection arrived. */
332
+ EventCategory["PipelineMotionCalm"] = "pipeline.motion-calm";
333
+ /**
325
334
  * Per-camera pipeline config was mutated by the orchestrator
326
335
  * (3-level settings change via `setAgentAddonDefaults` /
327
336
  * `setCameraStepToggle` / `setCameraPipelineForAgent` or a
@@ -693,6 +702,14 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
693
702
  EventCategory["BackupRestored"] = "backup.restored";
694
703
  EventCategory["NotificationDispatched"] = "notification.dispatched";
695
704
  EventCategory["NotificationFailed"] = "notification.failed";
705
+ /**
706
+ * A notification rule that cannot work (D905): its stored row does not load,
707
+ * or it still names a device / delivery target the prune CONFIRMED deleted.
708
+ * One edge per rule per distinct set of reasons; never on an unanswered read.
709
+ */
710
+ EventCategory["NotificationRuleBroken"] = "notification.rule-broken";
711
+ /** The clear of {@link NotificationRuleBroken}: the rule loads and names nothing deleted. */
712
+ EventCategory["NotificationRuleRepaired"] = "notification.rule-repaired";
696
713
  EventCategory["DeviceUpdated"] = "device.updated";
697
714
  /**
698
715
  * Transport-level connectivity. Emitted by the device driver when
@@ -5420,7 +5437,7 @@ var ZodIssueCode = {
5420
5437
  var ZodFirstPartyTypeKind;
5421
5438
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5422
5439
  //#endregion
5423
- //#region ../types/dist/sleep-_sV1BE2f.mjs
5440
+ //#region ../types/dist/sleep-DJFUfKvA.mjs
5424
5441
  /**
5425
5442
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5426
5443
  * window to float samples (D455).
@@ -7882,7 +7899,7 @@ var EntryDescriptorSchema = object({
7882
7899
  /** JSON Schema of the entry body; `secret: true` marks a password field. */
7883
7900
  fields: record(string(), unknown())
7884
7901
  }).strict();
7885
- /** What crosses the wire and sits in the engine's catalog: JSON only, no Zod. */
7902
+ /** What crosses the wire from an addon: JSON only, no Zod. An unknown key is refused. */
7886
7903
  var RecordKindDeclarationSchema = object({
7887
7904
  database: _enum(RECORD_DATABASES).default("settings"),
7888
7905
  class: _enum(RECORD_CLASSES),
@@ -7901,14 +7918,6 @@ var RecordKindDeclarationSchema = object({
7901
7918
  secretPaths: array(string().min(1)).default([]),
7902
7919
  /** The id key of each array that carries a secret (`{ headers: 'name' }`). */
7903
7920
  secretArrayKeys: record(string(), string()).default({}),
7904
- /**
7905
- * RETIRED (D900): the legacy table a kind adopted from during the records
7906
- * migration. Nothing declares it any more and nothing reads it; the schema
7907
- * still ACCEPTS it because the catalog rows the migration wrote carry it
7908
- * (an orphaned kind is never redeclared) and an addon built before the
7909
- * removal still sends it. Never set it.
7910
- */
7911
- adoptsFrom: string().min(1).optional(),
7912
7921
  /** Kinds that must agree through `transact` sit in one file under one family name. */
7913
7922
  transactFamily: string().min(1).optional(),
7914
7923
  entry: EntryDescriptorSchema.optional()
@@ -12868,17 +12877,6 @@ object({
12868
12877
  createdAt: number(),
12869
12878
  updatedAt: number()
12870
12879
  });
12871
- object({
12872
- id: string(),
12873
- label: string(),
12874
- isAdmin: boolean().default(false),
12875
- allowedProviders: AllowedProviderSchema,
12876
- allowedDevices: AllowedDevicesSchema,
12877
- tokenHash: string(),
12878
- tokenPrefix: string(),
12879
- createdAt: number(),
12880
- lastUsedAt: number().optional()
12881
- });
12882
12880
  object({
12883
12881
  id: string(),
12884
12882
  userId: string(),
@@ -16773,16 +16771,36 @@ var RecordKindStateSchema = _enum([
16773
16771
  var DeclareKindResultSchema = object({
16774
16772
  kindId: number().int(),
16775
16773
  state: RecordKindStateSchema,
16776
- createdIndexes: array(string()),
16777
- /**
16778
- * RETIRED (D900): always `null`. It carried the records-migration boot guard;
16779
- * it stays on the wire, null, because an addon built before the removal reads
16780
- * an ABSENT field as "adoption pending" and refuses to start.
16781
- */
16782
- adoptionPending: _null()
16774
+ createdIndexes: array(string())
16783
16775
  });
16784
16776
  /** Keychain refs a write released (the old marker is gone from the row): the owner deletes the values. */
16785
16777
  var SecretRefsList = array(string());
16778
+ /**
16779
+ * One op of a `transact`: the single-row writes, each on a kind of the caller.
16780
+ * All ops of one call share ONE database file and ONE `transactFamily`.
16781
+ */
16782
+ var RecordTransactOpSchema = discriminatedUnion("op", [
16783
+ object({
16784
+ op: literal("put"),
16785
+ kind: RecordKindNameSchema,
16786
+ record: RecordInputSchema,
16787
+ ifRev: number().int().min(0).optional()
16788
+ }),
16789
+ object({
16790
+ op: literal("patch"),
16791
+ kind: RecordKindNameSchema,
16792
+ id: RecordIdSchema,
16793
+ data: RecordBodySchema,
16794
+ at: number().int().nullable().optional(),
16795
+ expiresAt: number().int().nullable().optional(),
16796
+ ifRev: number().int().min(1).optional()
16797
+ }),
16798
+ object({
16799
+ op: literal("delete"),
16800
+ kind: RecordKindNameSchema,
16801
+ id: RecordIdSchema
16802
+ })
16803
+ ]);
16786
16804
  var RecordSecretRefsSchema = record(string(), record(string(), string()));
16787
16805
  method(object({ kinds: record(RecordKindNameSchema, RecordKindDeclarationSchema) }), object({ kinds: record(string(), DeclareKindResultSchema) }), {
16788
16806
  kind: "mutation",
@@ -16889,6 +16907,16 @@ method(object({ kinds: record(RecordKindNameSchema, RecordKindDeclarationSchema)
16889
16907
  }), {
16890
16908
  kind: "mutation",
16891
16909
  auth: "admin"
16910
+ }), method(object({ ops: array(RecordTransactOpSchema).min(1).max(RECORD_BATCH_MAX) }), object({
16911
+ results: array(object({
16912
+ rev: number().int().nullable(),
16913
+ deleted: boolean()
16914
+ })),
16915
+ releasedRefs: SecretRefsList,
16916
+ secretRefs: SecretRefsList
16917
+ }), {
16918
+ kind: "mutation",
16919
+ auth: "admin"
16892
16920
  }), method(object({
16893
16921
  deviceId: number().int(),
16894
16922
  kinds: array(RecordKindNameSchema).optional()
@@ -42272,9 +42300,13 @@ var NcSystemEventKindSchema = _enum([
42272
42300
  "node-updating",
42273
42301
  "node-inference-unavailable",
42274
42302
  "detection-blind",
42303
+ "motion-noisy",
42304
+ "motion-calm",
42275
42305
  "recording-stalled",
42276
42306
  "recording-healthy",
42277
42307
  "recording-degraded",
42308
+ "device-attention-required",
42309
+ "device-attention-resolved",
42278
42310
  "storage-location-low",
42279
42311
  "storage-location-critical",
42280
42312
  "storage-location-ok",
@@ -42298,6 +42330,8 @@ var NcSystemEventKindSchema = _enum([
42298
42330
  "alert-critical",
42299
42331
  "alert-error",
42300
42332
  "alert-critical-resolved",
42333
+ "rule-broken",
42334
+ "rule-repaired",
42301
42335
  "camera-online",
42302
42336
  "camera-offline",
42303
42337
  "camera-disabled",
@@ -54769,6 +54803,16 @@ object({
54769
54803
  powerState: string().nullable(),
54770
54804
  saltLevel: DishwasherConsumableLevelSchema.nullable(),
54771
54805
  rinseAidLevel: DishwasherConsumableLevelSchema.nullable(),
54806
+ /**
54807
+ * True while the appliance asks for its filter to be cleaned (smart-filter, filter-system or
54808
+ * combined care-and-filter reminder raised); false when every such reminder reads clear; null
54809
+ * when none is reported. A cleared reminder is not an unknown one.
54810
+ */
54811
+ filterCleaningDue: boolean().nullable(),
54812
+ /** True while the machine-care (descaling / cleaning-program) reminder is raised; false when clear; null when not reported. */
54813
+ machineCareDue: boolean().nullable(),
54814
+ /** Program runs left before the machine-care reminder is due; null when the appliance does not say. */
54815
+ machineCareRemainingRuns: number().int().nonnegative().nullable(),
54772
54816
  /** Option states: null when the appliance does not expose the option or has not said. */
54773
54817
  halfLoad: boolean().nullable(),
54774
54818
  hygienePlus: boolean().nullable(),
@@ -61417,16 +61461,6 @@ var UpdateUserInputSchema = object({
61417
61461
  allowedDevices: record(string(), union([array(string()), literal("*")])).optional(),
61418
61462
  scopes: array(TokenScopeSchema).optional()
61419
61463
  });
61420
- var ApiKeySummarySchema = object({
61421
- id: string(),
61422
- label: string(),
61423
- isAdmin: boolean().default(false),
61424
- allowedProviders: union([array(string()), literal("*")]).optional(),
61425
- allowedDevices: record(string(), union([array(string()), literal("*")])).optional(),
61426
- tokenPrefix: string(),
61427
- createdAt: number(),
61428
- lastUsedAt: number().optional()
61429
- });
61430
61464
  var OauthSessionSummarySchema = object({
61431
61465
  id: string(),
61432
61466
  userId: string(),
@@ -61448,8 +61482,7 @@ var TotpStatusSchema = object({
61448
61482
  confirmedAt: number().nullable()
61449
61483
  });
61450
61484
  /**
61451
- * user-management — singleton capability for user accounts and the
61452
- * legacy API-key rows.
61485
+ * user-management — singleton capability for user accounts.
61453
61486
  *
61454
61487
  * v2 model: every method gated by `auth: 'admin'`. Admin-only delegation
61455
61488
  * — the subset check on `setUserScopes` is moot
@@ -61505,10 +61538,6 @@ method(_void(), array(UserSummarySchema), { auth: "admin" }), method(CreateUserI
61505
61538
  }), UserSummarySchema.extend({ passwordHash: string() }).nullable(), {
61506
61539
  kind: "mutation",
61507
61540
  access: "view"
61508
- }), method(_void(), array(ApiKeySummarySchema), { auth: "admin" }), method(object({ id: string() }), object({ success: literal(true) }), {
61509
- kind: "mutation",
61510
- auth: "admin",
61511
- access: "delete"
61512
61541
  }), method(object({ userId: string() }), TotpSetupResultSchema, {
61513
61542
  kind: "mutation",
61514
61543
  auth: "admin",
@@ -69021,6 +69050,12 @@ Object.freeze({
69021
69050
  addonId: null,
69022
69051
  access: "view"
69023
69052
  },
69053
+ "records.transact": {
69054
+ capName: "records",
69055
+ capScope: "system",
69056
+ addonId: null,
69057
+ access: "create"
69058
+ },
69024
69059
  "sceneMonitor.captureReference": {
69025
69060
  capName: "scene-monitor",
69026
69061
  capScope: "device",
@@ -70353,12 +70388,6 @@ Object.freeze({
70353
70388
  addonId: null,
70354
70389
  access: "view"
70355
70390
  },
70356
- "userManagement.listApiKeys": {
70357
- capName: "user-management",
70358
- capScope: "system",
70359
- addonId: null,
70360
- access: "view"
70361
- },
70362
70391
  "userManagement.listExternalIdentities": {
70363
70392
  capName: "user-management",
70364
70393
  capScope: "system",
@@ -70413,12 +70442,6 @@ Object.freeze({
70413
70442
  addonId: null,
70414
70443
  access: "create"
70415
70444
  },
70416
- "userManagement.revokeApiKey": {
70417
- capName: "user-management",
70418
- capScope: "system",
70419
- addonId: null,
70420
- access: "delete"
70421
- },
70422
70445
  "userManagement.revokeOauthSession": {
70423
70446
  capName: "user-management",
70424
70447
  capScope: "system",
@@ -73783,9 +73806,13 @@ new Map(Object.entries({
73783
73806
  "stream-online": "device-events",
73784
73807
  "stream-offline": "device-events",
73785
73808
  "detection-blind": "device-events",
73809
+ "motion-noisy": "device-events",
73810
+ "motion-calm": "device-events",
73786
73811
  "recording-stalled": "device-events",
73787
73812
  "recording-healthy": "device-events",
73788
73813
  "recording-degraded": "device-events",
73814
+ "device-attention-required": "device-events",
73815
+ "device-attention-resolved": "device-events",
73789
73816
  "node-online": "system",
73790
73817
  "node-offline": "system",
73791
73818
  "node-restarting": "system",
@@ -73802,6 +73829,8 @@ new Map(Object.entries({
73802
73829
  "alert-critical": "system",
73803
73830
  "alert-error": "system",
73804
73831
  "alert-critical-resolved": "system",
73832
+ "rule-broken": "system",
73833
+ "rule-repaired": "system",
73805
73834
  "storage-location-low": "system",
73806
73835
  "storage-location-critical": "system",
73807
73836
  "storage-location-ok": "system",
@@ -73866,6 +73895,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
73866
73895
  label: "Detecting nothing",
73867
73896
  kinds: ["detection-blind"]
73868
73897
  },
73898
+ {
73899
+ id: "motion-noise",
73900
+ family: "device-events",
73901
+ label: "Motion without a subject",
73902
+ kinds: ["motion-noisy", "motion-calm"]
73903
+ },
73869
73904
  {
73870
73905
  id: "recording",
73871
73906
  family: "device-events",
@@ -73876,6 +73911,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
73876
73911
  "recording-degraded"
73877
73912
  ]
73878
73913
  },
73914
+ {
73915
+ id: "device-attention",
73916
+ family: "device-events",
73917
+ label: "Needs attention",
73918
+ kinds: ["device-attention-required", "device-attention-resolved"]
73919
+ },
73879
73920
  {
73880
73921
  id: "nodes",
73881
73922
  family: "system",
@@ -73936,6 +73977,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
73936
73977
  "alert-critical-resolved"
73937
73978
  ]
73938
73979
  },
73980
+ {
73981
+ id: "rule-health",
73982
+ family: "system",
73983
+ label: "Notification rules",
73984
+ kinds: ["rule-broken", "rule-repaired"]
73985
+ },
73939
73986
  {
73940
73987
  id: "alarm",
73941
73988
  family: "alarm",
@@ -74009,6 +74056,7 @@ var ALERT_EPISODE = [
74009
74056
  "alert-error",
74010
74057
  "alert-critical-resolved"
74011
74058
  ];
74059
+ var DEVICE_ATTENTION = ["device-attention-required", "device-attention-resolved"];
74012
74060
  var UPDATES = [
74013
74061
  "addon-update-available",
74014
74062
  "server-update-available",
@@ -74038,9 +74086,12 @@ var DEVICE_EVENTS = [
74038
74086
  "stream-online",
74039
74087
  "stream-offline",
74040
74088
  "detection-blind",
74089
+ "motion-noisy",
74090
+ "motion-calm",
74041
74091
  "recording-stalled",
74042
74092
  "recording-healthy",
74043
74093
  "recording-degraded",
74094
+ ...DEVICE_ATTENTION,
74044
74095
  ...ALARM
74045
74096
  ];
74046
74097
  /** Every kind a summary may speak about — the two summarisable families. */
@@ -74208,7 +74259,13 @@ var STATE_SUMMARY_VARS = [
74208
74259
  [...RULE_TEXT],
74209
74260
  [...RULE_TEXT],
74210
74261
  [...RULE_TEXT],
74211
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74262
+ [...RULE_TEXT],
74263
+ [...RULE_TEXT],
74264
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74265
+ [...RULE_TEXT],
74266
+ [...RULE_TEXT],
74267
+ [...RULE_TEXT],
74268
+ [...RULE_TEXT],
74212
74269
  [...RULE_TEXT],
74213
74270
  [...RULE_TEXT],
74214
74271
  [...RULE_TEXT],
@@ -74226,11 +74283,11 @@ var STATE_SUMMARY_VARS = [
74226
74283
  [...RULE_TEXT],
74227
74284
  [...RULE_TEXT],
74228
74285
  [...RULE_TEXT],
74286
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74229
74287
  ([...RULE_TEXT], [...ALERT_EPISODE]),
74288
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74230
74289
  ([...RULE_TEXT], [...ALERT_EPISODE]),
74231
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74232
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74233
- ([...RULE_TEXT], [...ALERT_EPISODE]),
74290
+ ([...RULE_TEXT], [...DEVICE_ATTENTION, ...ALERT_EPISODE]),
74234
74291
  [...RULE_TEXT],
74235
74292
  [...RULE_TEXT],
74236
74293
  [...RULE_TEXT],
@@ -74251,6 +74308,125 @@ var STATE_SUMMARY_VARS = [
74251
74308
  [...RULE_TEXT],
74252
74309
  ...STATE_SUMMARY_VARS
74253
74310
  ];
74311
+ new Map([
74312
+ {
74313
+ id: "device-connectivity",
74314
+ family: "device-events",
74315
+ label: "Device connectivity (offline / back online)",
74316
+ bad: ["device-offline"],
74317
+ recovery: ["device-online"],
74318
+ snapshotLabel: "Devices offline now",
74319
+ snapshotSection: "device-state"
74320
+ },
74321
+ {
74322
+ id: "device-switch",
74323
+ family: "device-events",
74324
+ label: "Device switched off / back on",
74325
+ bad: ["device-disabled"],
74326
+ recovery: ["device-enabled"],
74327
+ snapshotLabel: "Devices switched off now",
74328
+ snapshotSection: "device-state"
74329
+ },
74330
+ {
74331
+ id: "stream-connectivity",
74332
+ family: "device-events",
74333
+ label: "Stream connectivity (offline / back online)",
74334
+ bad: ["stream-offline"],
74335
+ recovery: ["stream-online"],
74336
+ snapshotLabel: "Streams offline now",
74337
+ snapshotSection: "streams"
74338
+ },
74339
+ {
74340
+ id: "battery",
74341
+ family: "device-events",
74342
+ label: "Battery (low / back to normal)",
74343
+ bad: ["device-battery-low"],
74344
+ recovery: ["device-battery-normal"],
74345
+ snapshotLabel: "Batteries low now",
74346
+ snapshotSection: "battery"
74347
+ },
74348
+ {
74349
+ id: "consumables",
74350
+ family: "device-events",
74351
+ label: "Consumables (low / replaced)",
74352
+ bad: ["device-consumable-low"],
74353
+ recovery: ["device-consumable-normal"],
74354
+ snapshotLabel: "Consumables low now",
74355
+ snapshotSection: "consumables"
74356
+ },
74357
+ {
74358
+ id: "tanks",
74359
+ family: "device-events",
74360
+ label: "Tanks (low or full / back to normal)",
74361
+ bad: ["device-tank-low", "device-tank-full"],
74362
+ recovery: ["device-tank-normal"],
74363
+ snapshotLabel: "Tanks low or full now",
74364
+ snapshotSection: "tanks"
74365
+ },
74366
+ {
74367
+ id: "motion-noise",
74368
+ family: "device-events",
74369
+ label: "Motion without a subject (constant / calm again)",
74370
+ bad: ["motion-noisy"],
74371
+ recovery: ["motion-calm"],
74372
+ snapshotLabel: "Cameras with constant motion now",
74373
+ snapshotSection: null
74374
+ },
74375
+ {
74376
+ id: "recording-health",
74377
+ family: "device-events",
74378
+ label: "Recording health (stalled or degraded / recording again)",
74379
+ bad: ["recording-stalled", "recording-degraded"],
74380
+ recovery: ["recording-healthy"],
74381
+ snapshotLabel: "Recordings stalled now",
74382
+ snapshotSection: null
74383
+ },
74384
+ {
74385
+ id: "device-attention",
74386
+ family: "device-events",
74387
+ label: "Device needs attention (raised / resolved)",
74388
+ bad: ["device-attention-required"],
74389
+ recovery: ["device-attention-resolved"],
74390
+ snapshotLabel: "Devices needing attention now",
74391
+ snapshotSection: null
74392
+ },
74393
+ {
74394
+ id: "node-connectivity",
74395
+ family: "system",
74396
+ label: "Node connectivity (offline / back online)",
74397
+ bad: ["node-offline"],
74398
+ recovery: ["node-online"],
74399
+ snapshotLabel: "Nodes offline now",
74400
+ snapshotSection: "nodes"
74401
+ },
74402
+ {
74403
+ id: "storage-space",
74404
+ family: "system",
74405
+ label: "Storage space (low or critical / ok again)",
74406
+ bad: ["storage-location-low", "storage-location-critical"],
74407
+ recovery: ["storage-location-ok"],
74408
+ snapshotLabel: "Storage locations low now",
74409
+ snapshotSection: null
74410
+ },
74411
+ {
74412
+ id: "critical-alerts",
74413
+ family: "system",
74414
+ label: "Critical alerts (raised / resolved)",
74415
+ bad: ["alert-critical"],
74416
+ recovery: ["alert-critical-resolved"],
74417
+ snapshotLabel: "Critical alerts open now",
74418
+ snapshotSection: null
74419
+ },
74420
+ {
74421
+ id: "rule-health",
74422
+ family: "system",
74423
+ label: "Rule health (broken / repaired)",
74424
+ bad: ["rule-broken"],
74425
+ recovery: ["rule-repaired"],
74426
+ snapshotLabel: "Notification rules broken now",
74427
+ snapshotSection: null
74428
+ }
74429
+ ].flatMap((spec) => [...spec.bad, ...spec.recovery].map((kind) => [kind, spec])));
74254
74430
  new Set([
74255
74431
  "disarmed",
74256
74432
  "armed_home",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-export-alexa",
3
- "version": "1.2.159",
3
+ "version": "1.2.161",
4
4
  "description": "Alexa Smart Home Skill export — hub-side OAuth provider + directive handler. The companion AWS Lambda forwards Alexa directives to this addon's /addon/export-alexa/directive endpoint.",
5
5
  "keywords": [
6
6
  "camstack",