@camstack/addon-provider-unraid 0.2.148 → 0.2.150

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.mjs CHANGED
@@ -1,4 +1,4 @@
1
- //#region ../types/dist/event-category-DHXxB8t9.mjs
1
+ //#region ../types/dist/event-category-CT-hz5Rb.mjs
2
2
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
3
3
  EventCategory["SystemBoot"] = "system.boot";
4
4
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -324,6 +324,14 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
324
324
  /** The recovery edge of {@link PipelineMotionNoisy}: the motion fell back, or a detection arrived. */
325
325
  EventCategory["PipelineMotionCalm"] = "pipeline.motion-calm";
326
326
  /**
327
+ * A camera's package LLM confirm has failed closed three times in a row
328
+ * (D931, 2026-10-26). One edge per camera until
329
+ * {@link PipelinePackageLlmAnswered}.
330
+ */
331
+ EventCategory["PipelinePackageLlmSilent"] = "pipeline.package-llm-silent";
332
+ /** The recovery edge of {@link PipelinePackageLlmSilent}: a confirm returned yes or no. */
333
+ EventCategory["PipelinePackageLlmAnswered"] = "pipeline.package-llm-answered";
334
+ /**
327
335
  * Per-camera pipeline config was mutated by the orchestrator
328
336
  * (a settings change via `setAgentInferenceDevices` /
329
337
  * `setCameraStepToggle` / `setCameraStepSettings`). Orchestrator
@@ -5433,7 +5441,7 @@ var ZodIssueCode = {
5433
5441
  var ZodFirstPartyTypeKind;
5434
5442
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5435
5443
  //#endregion
5436
- //#region ../types/dist/sleep-CARd6wZF.mjs
5444
+ //#region ../types/dist/sleep--jXS9hWo.mjs
5437
5445
  /**
5438
5446
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5439
5447
  * window to float samples (D455).
@@ -8026,6 +8034,53 @@ var READING_QUANTITIES = [
8026
8034
  ];
8027
8035
  var ReadingQuantitySchema = _enum(READING_QUANTITIES);
8028
8036
  new Set(READING_QUANTITIES);
8037
+ /**
8038
+ * Stored unit symbol for a quantity. `none` means the number is dimensionless
8039
+ * (or an index / ratio / count). `device` means the cap has no single unit.
8040
+ */
8041
+ var QUANTITY_BASE = {
8042
+ temperature: "°C",
8043
+ pressure: "hPa",
8044
+ speed: "m/s",
8045
+ precipitation: "mm",
8046
+ "precipitation-rate": "mm/h",
8047
+ length: "m",
8048
+ area: "m²",
8049
+ illuminance: "lx",
8050
+ irradiance: "W/m²",
8051
+ power: "W",
8052
+ energy: "kWh",
8053
+ voltage: "V",
8054
+ current: "A",
8055
+ "apparent-power": "VA",
8056
+ humidity: "%",
8057
+ percentage: "%",
8058
+ "concentration-volume": "ppm",
8059
+ "concentration-mass": "µg/m³",
8060
+ "concentration-ppb": "ppb",
8061
+ volume: "L",
8062
+ duration: "s",
8063
+ "duration-ms": "ms",
8064
+ information: "B",
8065
+ "sound-level": "dBFS",
8066
+ "signal-level": "dBm",
8067
+ "colour-temperature": "mired",
8068
+ angle: "°",
8069
+ bitrate: "kbps",
8070
+ rate: "fps",
8071
+ mass: "kg",
8072
+ index: "none",
8073
+ ratio: "none",
8074
+ count: "none",
8075
+ none: "none",
8076
+ device: "device"
8077
+ };
8078
+ /** The stored unit, or `undefined` when the quantity has no unit symbol. */
8079
+ function baseUnitOf(quantity) {
8080
+ const symbol = QUANTITY_BASE[quantity];
8081
+ if (symbol === "none" || symbol === "device") return void 0;
8082
+ return symbol;
8083
+ }
8029
8084
  function readingMeta(quantity, extras) {
8030
8085
  return {
8031
8086
  quantity,
@@ -8579,6 +8634,9 @@ var CAP_NAMES = Object.freeze([
8579
8634
  "filesystem-browse",
8580
8635
  "flood",
8581
8636
  "gas",
8637
+ "group-active",
8638
+ "group-commands",
8639
+ "group-status",
8582
8640
  "heating-valve",
8583
8641
  "humidifier",
8584
8642
  "humidity-sensor",
@@ -8599,6 +8657,7 @@ var CAP_NAMES = Object.freeze([
8599
8657
  "login-method",
8600
8658
  "media-player",
8601
8659
  "mesh-network",
8660
+ "meter",
8602
8661
  "metrics-provider",
8603
8662
  "model-convert",
8604
8663
  "model-distributor",
@@ -9397,6 +9456,24 @@ Object.freeze({
9397
9456
  "path": "detected",
9398
9457
  "valueType": "boolean"
9399
9458
  }],
9459
+ "group-active": [{
9460
+ "path": "active",
9461
+ "valueType": "boolean"
9462
+ }],
9463
+ "group-status": [
9464
+ {
9465
+ "path": "included",
9466
+ "valueType": "number"
9467
+ },
9468
+ {
9469
+ "path": "excluded",
9470
+ "valueType": "number"
9471
+ },
9472
+ {
9473
+ "path": "total",
9474
+ "valueType": "number"
9475
+ }
9476
+ ],
9400
9477
  "heating-valve": [{
9401
9478
  "path": "position",
9402
9479
  "valueType": "number"
@@ -9642,6 +9719,10 @@ Object.freeze({
9642
9719
  ]
9643
9720
  }
9644
9721
  ],
9722
+ "meter": [{
9723
+ "path": "value",
9724
+ "valueType": "number"
9725
+ }],
9645
9726
  "motion": [
9646
9727
  {
9647
9728
  "path": "detected",
@@ -10399,7 +10480,7 @@ function userError(code, params, englishFallback) {
10399
10480
  return new CamstackError(code, params, englishFallback);
10400
10481
  }
10401
10482
  //#endregion
10402
- //#region ../types/dist/err-msg-BXKzRBwg.mjs
10483
+ //#region ../types/dist/err-msg-DIorGYeC.mjs
10403
10484
  var DeviceType = /* @__PURE__ */ function(DeviceType) {
10404
10485
  DeviceType["Camera"] = "camera";
10405
10486
  DeviceType["Hub"] = "hub";
@@ -10493,8 +10574,14 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
10493
10574
  DeviceType["PetFeeder"] = "pet-feeder";
10494
10575
  /** Built-in dishwasher — program lifecycle, door / remote-start gates,
10495
10576
  * salt and rinse-aid levels. Installed with the `dishwasher` cap.
10496
- * Sources: native Bosch Home Connect, reusable by similar integrations. */
10577
+ * Sources: native Bosch Home Connect, reusable by similar integrations.
10578
+ * A plug-built dishwasher carries running-state and power instead. */
10497
10579
  DeviceType["Dishwasher"] = "dishwasher";
10580
+ /** Washing machine. A plug-built one is running while its power stays
10581
+ * above a threshold. No program cap — that surface is the dishwasher's. */
10582
+ DeviceType["Washer"] = "washer";
10583
+ /** Tumble dryer. Same plug-built running surface as {@link Washer}. */
10584
+ DeviceType["Dryer"] = "dryer";
10498
10585
  return DeviceType;
10499
10586
  }({});
10500
10587
  var DeviceFeature = /* @__PURE__ */ function(DeviceFeature) {
@@ -10752,7 +10839,7 @@ function errMsg(err) {
10752
10839
  return String(err);
10753
10840
  }
10754
10841
  //#endregion
10755
- //#region ../types/dist/composition-kEl9mevu.mjs
10842
+ //#region ../types/dist/composition-Bb8iwHEJ.mjs
10756
10843
  /**
10757
10844
  * The ffmpeg build every CamStack node downloads, per platform and arch.
10758
10845
  *
@@ -11067,6 +11154,13 @@ var table = {
11067
11154
  apply: () => {
11068
11155
  throw new ExpressionEvalError("latchedAt: stateful evaluation context is required");
11069
11156
  }
11157
+ },
11158
+ schmitt: {
11159
+ minArgs: 3,
11160
+ maxArgs: 5,
11161
+ apply: () => {
11162
+ throw new ExpressionEvalError("schmitt: stateful evaluation context is required");
11163
+ }
11070
11164
  }
11071
11165
  };
11072
11166
  Object.freeze(Object.assign(Object.create(null), table));
@@ -11507,15 +11601,232 @@ function validateExpressionSource(src) {
11507
11601
  }
11508
11602
  return null;
11509
11603
  }
11510
- /** A composed device's stableId is this prefix plus the block id. */
11511
- var COMPOSED_DEVICE_STABLE_ID_PREFIX = "composed-";
11512
- /** Longest snippet a `code` source may carry (slice 4). */
11513
- var MAX_COMPOSITION_CODE_LENGTH = 2e4;
11604
+ /**
11605
+ * One power reading becomes a washer, dryer or dishwasher (D944 helper).
11606
+ *
11607
+ * Standby of the control board is under 5 W; a motor or a heater is far
11608
+ * above that, so 5 W is the line. A door lock or a short pump spike is not
11609
+ * a cycle, so running starts only after 30 s above the line.
11610
+ *
11611
+ * A wash, dry or dishwasher pause (soak, heat-wait, heater off between
11612
+ * bursts) lasts several minutes. Ending the cycle on the first dip would
11613
+ * report "finished" in the middle of the program, so the stop dwell is
11614
+ * 10 minutes on every type. The number is stored per type so one machine
11615
+ * can move later without moving the others.
11616
+ */
11617
+ var APPLIANCE_TEMPLATE_ID = "appliance";
11618
+ var APPLIANCE_KINDS = [
11619
+ "washer",
11620
+ "dryer",
11621
+ "dishwasher"
11622
+ ];
11623
+ DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
11624
+ /**
11625
+ * Statistics and integrals over a history read (D944).
11626
+ *
11627
+ * Pure: the same points always give the same answer, so a restart recomputes
11628
+ * rather than trusting a buffer. A gauge mean is time-weighted (value × ms),
11629
+ * never the mean of the samples. A hole with no held value is not integrated
11630
+ * as zero. A truncated read is not published.
11631
+ */
11632
+ var STATISTIC_STATS = [
11633
+ "min",
11634
+ "max",
11635
+ "mean",
11636
+ "sum",
11637
+ "count",
11638
+ "change"
11639
+ ];
11640
+ /**
11641
+ * The range a statistics or integral helper asks history for (D944).
11642
+ *
11643
+ * Calendar edges are the hub's timezone, never UTC midnight: a day is 23, 24
11644
+ * or 25 hours across a DST change. A tier is eligible only when its retention
11645
+ * is strictly longer than the longest that range can be. Forever qualifies.
11646
+ * Equal to a tier's retention is a refusal, not a short answer.
11647
+ */
11648
+ var MINUTE_MS = 6e4;
11649
+ var HOUR_MS = 60 * MINUTE_MS;
11650
+ var DAY_MS = 24 * HOUR_MS;
11651
+ var ROLLING_SPANS = [
11652
+ "1h",
11653
+ "24h",
11654
+ "2d",
11655
+ "7d",
11656
+ "30d",
11657
+ "custom"
11658
+ ];
11659
+ var CALENDAR_PERIODS = [
11660
+ "today",
11661
+ "yesterday",
11662
+ "this-week",
11663
+ "this-month"
11664
+ ];
11665
+ var RESET_PERIODS = [
11666
+ "never",
11667
+ "daily",
11668
+ "weekly",
11669
+ "monthly"
11670
+ ];
11671
+ 5 * MINUTE_MS;
11672
+ 24 * HOUR_MS, 2 * DAY_MS, 7 * DAY_MS, 30 * DAY_MS;
11673
+ 7 * DAY_MS, 30 * DAY_MS, 365 * DAY_MS;
11674
+ var rollingWindowObject = object({
11675
+ kind: literal("rolling"),
11676
+ span: _enum(ROLLING_SPANS),
11677
+ customMinutes: number().int().min(5).optional()
11678
+ }).check((payload) => {
11679
+ if (payload.value.span === "custom" && payload.value.customMinutes === void 0) payload.issues.push({
11680
+ code: "custom",
11681
+ message: "a custom range needs a duration in minutes",
11682
+ path: ["customMinutes"],
11683
+ input: payload.value
11684
+ });
11685
+ if (payload.value.span !== "custom" && payload.value.customMinutes !== void 0) payload.issues.push({
11686
+ code: "custom",
11687
+ message: "only a custom range carries a duration",
11688
+ path: ["customMinutes"],
11689
+ input: payload.value
11690
+ });
11691
+ });
11692
+ var RollingWindowSchema = rollingWindowObject;
11693
+ var StatisticWindowSchema = discriminatedUnion("kind", [rollingWindowObject, object({
11694
+ kind: literal("calendar"),
11695
+ period: _enum(CALENDAR_PERIODS)
11696
+ })]);
11697
+ /**
11698
+ * A composition source identity: `(addonId, stableId)`, never a numeric device
11699
+ * id. Split out so helper schemas can name it without a cycle through
11700
+ * `composition.ts` (D659).
11701
+ */
11514
11702
  var CompositionSourceRefSchema = object({
11515
11703
  /** The owning addon; `stableId` is unique only within it. */
11516
11704
  addonId: string().min(1),
11517
11705
  stableId: string().min(1)
11518
11706
  });
11707
+ var GROUP_TEMPLATE_IDS = [
11708
+ "temperature",
11709
+ "humidity",
11710
+ "pressure",
11711
+ "illuminance",
11712
+ "power",
11713
+ "energy",
11714
+ "battery",
11715
+ "numeric",
11716
+ "motion",
11717
+ "contact",
11718
+ "leak",
11719
+ "smoke",
11720
+ "occupancy",
11721
+ "binary",
11722
+ "switch",
11723
+ "light",
11724
+ "fan",
11725
+ "cover",
11726
+ "valve",
11727
+ "lock",
11728
+ "media-player",
11729
+ "climate"
11730
+ ];
11731
+ var NUMERIC_AGGREGATES = [
11732
+ "mean",
11733
+ "median",
11734
+ "min",
11735
+ "max",
11736
+ "sum"
11737
+ ];
11738
+ var BINARY_AGGREGATES = ["any", "all"];
11739
+ /** How an actuator group decides it is on. Unknown members never count as off. */
11740
+ var ACTIVE_CRITERIA = ["at-least-one", "all"];
11741
+ var AGGREGATE_REDUCERS = [
11742
+ "mean",
11743
+ "median",
11744
+ "min",
11745
+ "max",
11746
+ "sum",
11747
+ "any",
11748
+ "all"
11749
+ ];
11750
+ var GroupTemplateIdSchema = _enum(GROUP_TEMPLATE_IDS);
11751
+ var AggregateReducerSchema = _enum(AGGREGATE_REDUCERS);
11752
+ var ActiveCriterionSchema = _enum(ACTIVE_CRITERIA);
11753
+ /** One member. The field is stored so occupancy can name motion or binary. */
11754
+ var HelperMemberSchema = object({
11755
+ source: CompositionSourceRefSchema,
11756
+ cap: string().min(1),
11757
+ fieldPath: string().min(1)
11758
+ });
11759
+ var HelperSpecSchema = discriminatedUnion("kind", [
11760
+ object({
11761
+ kind: literal("group"),
11762
+ templateId: GroupTemplateIdSchema,
11763
+ aggregate: AggregateReducerSchema,
11764
+ members: array(HelperMemberSchema).min(1).max(64),
11765
+ /** Actuator groups only. Readings leave this unset. */
11766
+ active: ActiveCriterionSchema.optional()
11767
+ }),
11768
+ object({
11769
+ kind: literal("appliance"),
11770
+ templateId: literal(APPLIANCE_TEMPLATE_ID),
11771
+ appliance: _enum(APPLIANCE_KINDS),
11772
+ thresholdWatts: number().positive(),
11773
+ startDwellMs: number().int().nonnegative(),
11774
+ stopDwellMs: number().int().nonnegative(),
11775
+ member: HelperMemberSchema
11776
+ }),
11777
+ object({
11778
+ kind: literal("statistic"),
11779
+ stat: _enum(STATISTIC_STATS),
11780
+ window: StatisticWindowSchema,
11781
+ source: HelperMemberSchema
11782
+ }),
11783
+ object({
11784
+ kind: literal("integral"),
11785
+ reset: _enum(RESET_PERIODS),
11786
+ output: _enum(["energy", "meter"]),
11787
+ source: HelperMemberSchema
11788
+ }),
11789
+ object({
11790
+ kind: literal("threshold"),
11791
+ source: HelperMemberSchema,
11792
+ high: number(),
11793
+ low: number(),
11794
+ onForMs: number().int().nonnegative(),
11795
+ offForMs: number().int().nonnegative()
11796
+ }),
11797
+ object({
11798
+ kind: literal("arithmetic"),
11799
+ op: _enum([
11800
+ "sum",
11801
+ "difference",
11802
+ "ratio"
11803
+ ]),
11804
+ inputs: array(HelperMemberSchema).min(2).max(64)
11805
+ }),
11806
+ object({
11807
+ kind: literal("expression"),
11808
+ expr: string().min(1),
11809
+ inputs: array(object({
11810
+ name: string().min(1),
11811
+ member: HelperMemberSchema
11812
+ })).min(1).max(64),
11813
+ output: _enum(["number", "boolean"])
11814
+ }),
11815
+ object({
11816
+ kind: literal("derivative"),
11817
+ window: RollingWindowSchema,
11818
+ per: _enum([
11819
+ "second",
11820
+ "minute",
11821
+ "hour"
11822
+ ]),
11823
+ source: HelperMemberSchema
11824
+ })
11825
+ ]);
11826
+ /** A composed device's stableId is this prefix plus the block id. */
11827
+ var COMPOSED_DEVICE_STABLE_ID_PREFIX = "composed-";
11828
+ /** Longest snippet a `code` source may carry (slice 4). */
11829
+ var MAX_COMPOSITION_CODE_LENGTH = 2e4;
11519
11830
  /** One field of one capability of one source device. */
11520
11831
  var CompositionFieldReadSchema = object({
11521
11832
  source: CompositionSourceRefSchema,
@@ -11559,7 +11870,59 @@ var CompositionCodeSourceSchema = object({
11559
11870
  var CompositionFieldSourceSchema = discriminatedUnion("kind", [
11560
11871
  CompositionFromSourceSchema,
11561
11872
  CompositionExpressionSourceSchema,
11562
- CompositionCodeSourceSchema
11873
+ CompositionCodeSourceSchema,
11874
+ object({
11875
+ kind: literal("aggregate"),
11876
+ reducer: _enum([
11877
+ "mean",
11878
+ "median",
11879
+ "min",
11880
+ "max",
11881
+ "sum",
11882
+ "any",
11883
+ "all"
11884
+ ]),
11885
+ reads: array(CompositionFieldReadSchema).min(1).max(64),
11886
+ /**
11887
+ * Set when the reads are an enum state, not a yes/no: the listed states
11888
+ * count as active (a cover is `open`). A state outside the list is inactive;
11889
+ * a read that is not a state at all is left out. Only `any` / `all` use it.
11890
+ */
11891
+ activeWhen: array(string().min(1)).min(1).optional(),
11892
+ /** `value` is the reading; the others are the member counts. */
11893
+ publish: _enum([
11894
+ "value",
11895
+ "included",
11896
+ "excluded",
11897
+ "total"
11898
+ ]),
11899
+ /** What a `value` publish does when nobody is included. Counts ignore this. */
11900
+ empty: _enum([
11901
+ "null",
11902
+ "omit",
11903
+ "offline"
11904
+ ])
11905
+ }),
11906
+ object({
11907
+ kind: literal("series"),
11908
+ read: CompositionFieldReadSchema,
11909
+ /** `value` is the statistic or the integral. The others are the gap counts. */
11910
+ publish: _enum([
11911
+ "value",
11912
+ "included",
11913
+ "excluded",
11914
+ "total"
11915
+ ]),
11916
+ /**
11917
+ * What an unanswered `value` does. Counts ignore this. `offline` leaves the
11918
+ * device unseeded until history answers, so a restart cannot publish 0.
11919
+ */
11920
+ empty: _enum([
11921
+ "null",
11922
+ "omit",
11923
+ "offline"
11924
+ ])
11925
+ })
11563
11926
  ]);
11564
11927
  var CompositionCommandTargetSchema = discriminatedUnion("kind", [object({
11565
11928
  kind: literal("forward"),
@@ -11605,7 +11968,13 @@ var CompositionSchema = object({
11605
11968
  kind: literal("existing"),
11606
11969
  device: CompositionSourceRefSchema
11607
11970
  })]),
11608
- features: array(CompositionFeatureSchema).min(1).max(16)
11971
+ features: array(CompositionFeatureSchema).min(1).max(16),
11972
+ /**
11973
+ * Present when the block is a helper template. Absent on a free
11974
+ * composition (the room example, device 4603). The editor reads this,
11975
+ * never the compiled features.
11976
+ */
11977
+ helper: HelperSpecSchema.optional()
11609
11978
  }).superRefine((composition, ctx) => {
11610
11979
  const seen = /* @__PURE__ */ new Set();
11611
11980
  composition.features.forEach((feature, index) => {
@@ -16712,7 +17081,22 @@ var BrokerProviderInfoSchema = object({
16712
17081
  */
16713
17082
  interactiveConnectPath: string().min(1).optional(),
16714
17083
  /** Relative hub path to disconnect the linked account (same popup pattern). */
16715
- interactiveDisconnectPath: string().min(1).optional()
17084
+ interactiveDisconnectPath: string().min(1).optional(),
17085
+ /**
17086
+ * The kind signs in through a server-held interactive session instead of
17087
+ * (or before) typed credentials. `basePath` is a hub-relative route set
17088
+ * served by the owning addon (`/addon/<id>/...`) speaking the sign-in
17089
+ * contract: `POST {basePath}/start` (body: the form's settings) answers
17090
+ * `{ sessionId, loginUrl }`; `GET {basePath}/status?sessionId=` answers
17091
+ * `{ phase: 'starting' | 'awaiting-login' | 'captured' | 'error' |
17092
+ * 'cancelled', loginUrl, error }`; `POST {basePath}/commit`
17093
+ * (`{ sessionId, name, brokerId? }`) stores the credentials on a new or
17094
+ * existing broker and answers `{ brokerId }`; `POST {basePath}/cancel`
17095
+ * (`{ sessionId }`) drops the session. The dialog that edits a broker
17096
+ * offers it as the default path; the fields the session fills are
17097
+ * marked `filledBySignIn` in the kind's settings schema.
17098
+ */
17099
+ signIn: object({ basePath: string().min(1) }).optional()
16716
17100
  }))
16717
17101
  });
16718
17102
  var ListInputSchema = object({
@@ -17814,7 +18198,11 @@ var CompositionProblemSchema = object({
17814
18198
  "target-missing",
17815
18199
  "target-unreadable",
17816
18200
  "not-replaceable",
17817
- "native-capability-replace"
18201
+ "native-capability-replace",
18202
+ "mixed-quantity",
18203
+ "helper-mismatch",
18204
+ "member-constraint",
18205
+ "retention"
17818
18206
  ]),
17819
18207
  path: string(),
17820
18208
  message: string()
@@ -17835,7 +18223,8 @@ var CompositionUnavailableModeSchema = _enum([
17835
18223
  "null",
17836
18224
  "offline",
17837
18225
  "unknown",
17838
- "release"
18226
+ "release",
18227
+ "omit"
17839
18228
  ]);
17840
18229
  /**
17841
18230
  * `derived` reads a source · `clock` reads only `now`, recomputed when a sibling
@@ -18047,8 +18436,392 @@ Object.freeze({
18047
18436
  latchedAt: {
18048
18437
  kind: "fixed",
18049
18438
  result: ["number", "null"]
18439
+ },
18440
+ schmitt: {
18441
+ kind: "fixed",
18442
+ result: ["boolean", "null"]
18050
18443
  }
18051
18444
  });
18445
+ /**
18446
+ * One catalog row per base reading a group helper can build (D944 §3).
18447
+ * Data, not a form default written into the block.
18448
+ */
18449
+ var NOW$2 = {
18450
+ fieldPath: "lastFetchedAt",
18451
+ expr: "now"
18452
+ };
18453
+ var CHANGED = {
18454
+ fieldPath: "lastChangedAt",
18455
+ expr: "now"
18456
+ };
18457
+ function numeric(input) {
18458
+ return {
18459
+ ...input,
18460
+ family: "numeric",
18461
+ deviceType: DeviceType.Sensor,
18462
+ memberDeviceType: DeviceType.Sensor,
18463
+ memberDeviceTypes: [DeviceType.Sensor],
18464
+ activeWhen: void 0,
18465
+ commandCaps: [],
18466
+ baseUnit: baseUnitOf(input.quantity),
18467
+ aggregates: NUMERIC_AGGREGATES,
18468
+ accept: [{
18469
+ cap: input.outputCap,
18470
+ fieldPath: input.outputField
18471
+ }]
18472
+ };
18473
+ }
18474
+ function binary(input) {
18475
+ return {
18476
+ ...input,
18477
+ family: "binary",
18478
+ deviceType: DeviceType.Sensor,
18479
+ memberDeviceType: DeviceType.Sensor,
18480
+ memberDeviceTypes: [DeviceType.Sensor],
18481
+ activeWhen: void 0,
18482
+ commandCaps: [],
18483
+ quantity: "none",
18484
+ baseUnit: void 0,
18485
+ aggregates: BINARY_AGGREGATES,
18486
+ empty: "offline"
18487
+ };
18488
+ }
18489
+ var GROUP_TEMPLATES = [
18490
+ numeric({
18491
+ id: "temperature",
18492
+ summary: "Mean, median, min, max or sum of temperatures. Offline and unknown members are left out, never read as 0 °C.",
18493
+ role: DeviceRole.TemperatureSensor,
18494
+ outputCap: "temperature-sensor",
18495
+ outputField: "celsius",
18496
+ quantity: "temperature",
18497
+ defaultAggregate: "mean",
18498
+ empty: "null",
18499
+ companions: [NOW$2]
18500
+ }),
18501
+ numeric({
18502
+ id: "humidity",
18503
+ summary: "Humidity in percent. Offline and unknown members are left out, never read as 0 %.",
18504
+ role: DeviceRole.HumiditySensor,
18505
+ outputCap: "humidity-sensor",
18506
+ outputField: "percent",
18507
+ quantity: "humidity",
18508
+ defaultAggregate: "mean",
18509
+ empty: "null",
18510
+ companions: [NOW$2]
18511
+ }),
18512
+ numeric({
18513
+ id: "pressure",
18514
+ summary: "Pressure in hectopascals. Offline and unknown members are left out, never read as 0 hPa.",
18515
+ role: DeviceRole.PressureSensor,
18516
+ outputCap: "pressure-sensor",
18517
+ outputField: "hpa",
18518
+ quantity: "pressure",
18519
+ defaultAggregate: "mean",
18520
+ empty: "null",
18521
+ companions: [NOW$2]
18522
+ }),
18523
+ numeric({
18524
+ id: "illuminance",
18525
+ summary: "Illuminance in lux. Offline and unknown members are left out, never read as 0 lx.",
18526
+ role: DeviceRole.AmbientLightSensor,
18527
+ outputCap: "ambient-light-sensor",
18528
+ outputField: "lux",
18529
+ quantity: "illuminance",
18530
+ defaultAggregate: "mean",
18531
+ empty: "null",
18532
+ companions: [NOW$2]
18533
+ }),
18534
+ numeric({
18535
+ id: "power",
18536
+ summary: "Power in watts, summed by default. Nobody reporting omits the key rather than writing 0 W.",
18537
+ role: DeviceRole.PowerSensor,
18538
+ outputCap: "power-meter",
18539
+ outputField: "watts",
18540
+ quantity: "power",
18541
+ defaultAggregate: "sum",
18542
+ empty: "omit",
18543
+ companions: [NOW$2]
18544
+ }),
18545
+ numeric({
18546
+ id: "energy",
18547
+ summary: "Energy in kilowatt-hours, summed by default. Nobody reporting omits the key rather than writing 0 kWh.",
18548
+ role: DeviceRole.EnergySensor,
18549
+ outputCap: "power-meter",
18550
+ outputField: "kwhTotal",
18551
+ quantity: "energy",
18552
+ defaultAggregate: "sum",
18553
+ empty: "omit",
18554
+ companions: [NOW$2]
18555
+ }),
18556
+ numeric({
18557
+ id: "battery",
18558
+ summary: "Battery charge in percent. Offline and unknown members are left out, never read as 0 %.",
18559
+ role: DeviceRole.BatterySensor,
18560
+ outputCap: "battery",
18561
+ outputField: "percentage",
18562
+ quantity: "percentage",
18563
+ defaultAggregate: "mean",
18564
+ empty: "null",
18565
+ companions: [
18566
+ {
18567
+ fieldPath: "charging",
18568
+ expr: "\"unknown\""
18569
+ },
18570
+ {
18571
+ fieldPath: "sleeping",
18572
+ expr: "false"
18573
+ },
18574
+ {
18575
+ fieldPath: "lastUpdated",
18576
+ expr: "now"
18577
+ }
18578
+ ]
18579
+ }),
18580
+ numeric({
18581
+ id: "numeric",
18582
+ summary: "A numeric reading in the members’ shared quantity. Mixed quantities are refused. Nobody reporting publishes null, not 0.",
18583
+ role: DeviceRole.NumericSensor,
18584
+ outputCap: "numeric-sensor",
18585
+ outputField: "value",
18586
+ quantity: "device",
18587
+ defaultAggregate: "mean",
18588
+ empty: "null",
18589
+ companions: [NOW$2]
18590
+ }),
18591
+ binary({
18592
+ id: "motion",
18593
+ summary: "Any or all motion. Offline and unknown members are left out, never read as off. Nobody reporting takes the device offline.",
18594
+ role: DeviceRole.MotionSensor,
18595
+ outputCap: "motion",
18596
+ outputField: "detected",
18597
+ defaultAggregate: "any",
18598
+ accept: [{
18599
+ cap: "motion",
18600
+ fieldPath: "detected"
18601
+ }],
18602
+ companions: [{
18603
+ fieldPath: "lastDetectedAt",
18604
+ expr: "null"
18605
+ }, {
18606
+ fieldPath: "autoClearAfterMs",
18607
+ expr: "null"
18608
+ }]
18609
+ }),
18610
+ binary({
18611
+ id: "contact",
18612
+ summary: "Any or all open contacts. Offline and unknown members are left out, never read as closed.",
18613
+ role: DeviceRole.ContactSensor,
18614
+ outputCap: "contact",
18615
+ outputField: "entryOpen",
18616
+ defaultAggregate: "any",
18617
+ accept: [{
18618
+ cap: "contact",
18619
+ fieldPath: "entryOpen"
18620
+ }],
18621
+ companions: [CHANGED]
18622
+ }),
18623
+ binary({
18624
+ id: "leak",
18625
+ summary: "Any or all leak detections. Offline and unknown members are left out, never read as dry.",
18626
+ role: DeviceRole.LeakSensor,
18627
+ outputCap: "flood",
18628
+ outputField: "flooded",
18629
+ defaultAggregate: "any",
18630
+ accept: [{
18631
+ cap: "flood",
18632
+ fieldPath: "flooded"
18633
+ }],
18634
+ companions: [CHANGED]
18635
+ }),
18636
+ binary({
18637
+ id: "smoke",
18638
+ summary: "Any or all smoke detections. Offline and unknown members are left out, never read as clear.",
18639
+ role: DeviceRole.SmokeSensor,
18640
+ outputCap: "smoke",
18641
+ outputField: "detected",
18642
+ defaultAggregate: "any",
18643
+ accept: [{
18644
+ cap: "smoke",
18645
+ fieldPath: "detected"
18646
+ }],
18647
+ companions: [CHANGED]
18648
+ }),
18649
+ binary({
18650
+ id: "occupancy",
18651
+ summary: "Any or all of motion or binary sensors, published as a binary. Presence zones are not aggregated. Nobody reporting is offline, not off.",
18652
+ role: DeviceRole.BinarySensor,
18653
+ outputCap: "binary",
18654
+ outputField: "on",
18655
+ defaultAggregate: "any",
18656
+ accept: [{
18657
+ cap: "motion",
18658
+ fieldPath: "detected"
18659
+ }, {
18660
+ cap: "binary",
18661
+ fieldPath: "on"
18662
+ }],
18663
+ companions: [CHANGED]
18664
+ }),
18665
+ binary({
18666
+ id: "binary",
18667
+ summary: "Any or all generic binary sensors. Offline and unknown members are left out, never read as off.",
18668
+ role: DeviceRole.BinarySensor,
18669
+ outputCap: "binary",
18670
+ outputField: "on",
18671
+ defaultAggregate: "any",
18672
+ accept: [{
18673
+ cap: "binary",
18674
+ fieldPath: "on"
18675
+ }],
18676
+ companions: [CHANGED]
18677
+ }),
18678
+ actuator({
18679
+ id: "switch",
18680
+ summary: "On when at least one switch is on, or when all of them are. Offline and unknown members are left out of that decision, never read as off, and still receive the command.",
18681
+ deviceType: DeviceType.Switch,
18682
+ outputCap: "switch",
18683
+ outputField: "on",
18684
+ member: {
18685
+ cap: "switch",
18686
+ fieldPath: "on"
18687
+ },
18688
+ commandCaps: ["switch"]
18689
+ }),
18690
+ actuator({
18691
+ id: "light",
18692
+ summary: "On when at least one light is on, or when all of them are. Brightness and colour are offered only when every member has them. A command is not sent to a member that lacks it.",
18693
+ deviceType: DeviceType.Light,
18694
+ outputCap: "switch",
18695
+ outputField: "on",
18696
+ member: {
18697
+ cap: "switch",
18698
+ fieldPath: "on"
18699
+ },
18700
+ commandCaps: [
18701
+ "switch",
18702
+ "brightness",
18703
+ "color"
18704
+ ]
18705
+ }),
18706
+ actuator({
18707
+ id: "fan",
18708
+ summary: "On when at least one fan is on, or when all of them are. Speed, preset, direction and oscillation are offered only when every fan has them. A command is not sent to a fan that lacks it.",
18709
+ deviceType: DeviceType.Fan,
18710
+ outputCap: "switch",
18711
+ outputField: "on",
18712
+ member: {
18713
+ cap: "switch",
18714
+ fieldPath: "on"
18715
+ },
18716
+ commandCaps: ["switch", "fan-control"]
18717
+ }),
18718
+ actuator({
18719
+ id: "cover",
18720
+ summary: "Open when at least one cover is open or part-open, or only when all of them are. Position and tilt are offered only when every cover has them. A cover that reports nothing is left out, never read as closed.",
18721
+ deviceType: DeviceType.Cover,
18722
+ outputCap: "group-active",
18723
+ outputField: "active",
18724
+ member: {
18725
+ cap: "cover",
18726
+ fieldPath: "state"
18727
+ },
18728
+ activeWhen: [
18729
+ "open",
18730
+ "opening",
18731
+ "stopped"
18732
+ ],
18733
+ commandCaps: ["cover"]
18734
+ }),
18735
+ actuator({
18736
+ id: "valve",
18737
+ summary: "Open when at least one valve is open or part-open, or only when all of them are. Position is offered only when every valve has it. A valve that reports nothing is left out, never read as closed.",
18738
+ deviceType: DeviceType.Valve,
18739
+ outputCap: "group-active",
18740
+ outputField: "active",
18741
+ member: {
18742
+ cap: "valve",
18743
+ fieldPath: "state"
18744
+ },
18745
+ activeWhen: [
18746
+ "open",
18747
+ "opening",
18748
+ "stopped"
18749
+ ],
18750
+ commandCaps: ["valve"]
18751
+ }),
18752
+ actuator({
18753
+ id: "lock",
18754
+ summary: "Locked when at least one lock is locked, or only when all of them are. A jammed or moving lock is not locked. Locking is one tap; unlocking the group needs a confirmation every time, and nothing is sent without it.",
18755
+ deviceType: DeviceType.Lock,
18756
+ outputCap: "group-active",
18757
+ outputField: "active",
18758
+ member: {
18759
+ cap: "lock-control",
18760
+ fieldPath: "state"
18761
+ },
18762
+ activeWhen: ["locked"],
18763
+ commandCaps: ["lock-control"]
18764
+ }),
18765
+ actuator({
18766
+ id: "media-player",
18767
+ summary: "Playing when at least one player is playing, or only when all of them are. Volume is offered only when every player has it. A player that reports nothing is left out, never read as stopped.",
18768
+ deviceType: DeviceType.MediaPlayer,
18769
+ outputCap: "group-active",
18770
+ outputField: "active",
18771
+ member: {
18772
+ cap: "media-player",
18773
+ fieldPath: "state"
18774
+ },
18775
+ activeWhen: ["playing", "buffering"],
18776
+ commandCaps: ["media-player"]
18777
+ }),
18778
+ actuator({
18779
+ id: "climate",
18780
+ summary: "Running when at least one thermostat or air conditioner is not off, or only when all of them are. Target temperature and fan are offered only when every device has them. A device that reports nothing is left out, never read as off.",
18781
+ deviceType: DeviceType.Thermostat,
18782
+ memberDeviceTypes: [DeviceType.Thermostat, DeviceType.Climate],
18783
+ outputCap: "group-active",
18784
+ outputField: "active",
18785
+ member: {
18786
+ cap: "climate-control",
18787
+ fieldPath: "mode"
18788
+ },
18789
+ activeWhen: [
18790
+ "heat",
18791
+ "cool",
18792
+ "auto",
18793
+ "heat_cool",
18794
+ "fan_only",
18795
+ "dry"
18796
+ ],
18797
+ commandCaps: ["climate-control"]
18798
+ })
18799
+ ];
18800
+ function actuator(input) {
18801
+ return {
18802
+ id: input.id,
18803
+ summary: input.summary,
18804
+ deviceType: input.deviceType,
18805
+ outputCap: input.outputCap,
18806
+ outputField: input.outputField,
18807
+ commandCaps: input.commandCaps,
18808
+ family: "actuator",
18809
+ role: void 0,
18810
+ memberDeviceType: input.deviceType,
18811
+ memberDeviceTypes: input.memberDeviceTypes ?? [input.deviceType],
18812
+ activeWhen: input.activeWhen,
18813
+ quantity: "none",
18814
+ baseUnit: void 0,
18815
+ aggregates: BINARY_AGGREGATES,
18816
+ defaultAggregate: "any",
18817
+ empty: "offline",
18818
+ accept: [input.member],
18819
+ companions: [CHANGED]
18820
+ };
18821
+ }
18822
+ new Map(GROUP_TEMPLATES.map((template) => [template.id, template]));
18823
+ DeviceFeature.LightColorRgb, DeviceFeature.LightColorHsv, DeviceFeature.LightColorMired;
18824
+ DeviceType.Camera;
18052
18825
  `${COMPOSED_DEVICE_STABLE_ID_PREFIX}`;
18053
18826
  /**
18054
18827
  * What a composition may BUILD on a device type (G2, D676): the caps a new
@@ -43368,7 +44141,7 @@ var NetworkAccessStatusSchema = object({
43368
44141
  });
43369
44142
  /**
43370
44143
  * Optional, richer endpoint shape returned by providers that expose
43371
- * MORE than one ingress concurrently (Tailscale Ingress with mixed
44144
+ * MORE than one ingress concurrently (Tailscale Funnel with mixed
43372
44145
  * serve+funnel rules, future ngrok multi-tunnel, …). Each entry carries
43373
44146
  * the originating provider config (mode + sourcePort) so the
43374
44147
  * orchestrator UI can label rows distinctly. Providers that expose only
@@ -44964,6 +45737,8 @@ var NcSystemEventKindSchema = _enum([
44964
45737
  "detection-blind",
44965
45738
  "motion-noisy",
44966
45739
  "motion-calm",
45740
+ "package-llm-silent",
45741
+ "package-llm-answered",
44967
45742
  "recording-stalled",
44968
45743
  "recording-healthy",
44969
45744
  "recording-degraded",
@@ -46053,7 +46828,20 @@ var NcRuleInputSchema = object({
46053
46828
  * save by the hub's grouping guard). `.optional()`, never `.default()`: the addon cap
46054
46829
  * path does not run Zod defaults.
46055
46830
  */
46056
- groupingSec: number().int().min(5).max(60).optional()
46831
+ groupingSec: number().int().min(5).max(60).optional(),
46832
+ /**
46833
+ * ASK ME TO CONFIRM DETECTIONS (#243): a DETECTION notification of this rule
46834
+ * carries "Correct" / "Wrong" buttons (and, where the channel has room, a
46835
+ * "Wrong, it is a <class>" choice). A tap marks the track for retraining, the
46836
+ * same mark the Library writes, and records whose notification it was and
46837
+ * when. A channel with no buttons gets the same two choices as links.
46838
+ *
46839
+ * `.optional()`, never `.default()` (a Zod default does not run on the addon
46840
+ * cap path): absent and `false` both mean off, which is what every rule
46841
+ * authored before this field meant. An editor turns it off by writing
46842
+ * `false`, so it needs no `clear` key.
46843
+ */
46844
+ askVerdict: boolean().optional()
46057
46845
  });
46058
46846
  /**
46059
46847
  * Partial patch for `updateRule` — any subset of the input fields, plus the
@@ -56055,6 +56843,28 @@ var PackageVersionInfoSchema = object({
56055
56843
  deprecated: string().optional(),
56056
56844
  distTags: array(string()).readonly()
56057
56845
  });
56846
+ /**
56847
+ * One published document. `ok` is markdown from the registry. `missing` means
56848
+ * the registry answered and the file was not there. `error` is a registry or
56849
+ * tarball failure — never an empty string standing in for either.
56850
+ */
56851
+ var PackageDocBodySchema = discriminatedUnion("status", [
56852
+ object({
56853
+ status: literal("ok"),
56854
+ markdown: string()
56855
+ }),
56856
+ object({ status: literal("missing") }),
56857
+ object({
56858
+ status: literal("error"),
56859
+ message: string()
56860
+ })
56861
+ ]);
56862
+ var PackageDocsSchema = object({
56863
+ name: string(),
56864
+ version: string(),
56865
+ readme: PackageDocBodySchema,
56866
+ changelog: PackageDocBodySchema
56867
+ });
56058
56868
  var SearchResultSchema = object({
56059
56869
  name: string(),
56060
56870
  version: string(),
@@ -56273,7 +57083,10 @@ method(object({ nodeId: string().optional() }).optional(), array(AddonListItemSc
56273
57083
  }), object({ success: literal(true) }), {
56274
57084
  kind: "mutation",
56275
57085
  auth: "admin"
56276
- }), method(object({ name: string() }), array(PackageVersionInfoSchema).readonly()), method(object({ addonId: string() }), RestartAddonResultSchema, {
57086
+ }), method(object({ name: string() }), array(PackageVersionInfoSchema).readonly()), method(object({
57087
+ name: string().min(1),
57088
+ version: string().min(1).optional()
57089
+ }), PackageDocsSchema, { auth: "admin" }), method(object({ addonId: string() }), RestartAddonResultSchema, {
56277
57090
  kind: "mutation",
56278
57091
  auth: "admin"
56279
57092
  }), method(object({ packageName: string() }), object({ success: literal(true) }), {
@@ -56748,7 +57561,8 @@ var BATTERY_DEVICE_TYPES = [
56748
57561
  DeviceType.Switch,
56749
57562
  DeviceType.PetFeeder,
56750
57563
  DeviceType.Container,
56751
- DeviceType.Thermostat
57564
+ DeviceType.Thermostat,
57565
+ DeviceType.EventEmitter
56752
57566
  ];
56753
57567
  /** Generic Customize target for the percentage reading (D936). */
56754
57568
  var batteryCustomize = {
@@ -59609,6 +60423,148 @@ var gasCapability = {
59609
60423
  * whether persisting is worth a SQLite commit. */
59610
60424
  volatileStateFields: ["lastChangedAt"]
59611
60425
  };
60426
+ var GroupCommandsSchema = object({
60427
+ /** One row per member that has been commanded. A later command replaces that member's row. */
60428
+ results: array(object({
60429
+ deviceId: number().int().nonnegative(),
60430
+ cap: string().min(1),
60431
+ method: string().min(1),
60432
+ ok: boolean(),
60433
+ error: string().optional(),
60434
+ /** Ms epoch of the attempt. */
60435
+ at: number()
60436
+ })) });
60437
+ var groupCommandsCapability = {
60438
+ name: "group-commands",
60439
+ scope: "device",
60440
+ deviceNative: true,
60441
+ mode: "singleton",
60442
+ deviceTypes: [
60443
+ DeviceType.Switch,
60444
+ DeviceType.Light,
60445
+ DeviceType.Fan,
60446
+ DeviceType.Cover,
60447
+ DeviceType.Valve,
60448
+ DeviceType.Lock,
60449
+ DeviceType.MediaPlayer,
60450
+ DeviceType.Thermostat,
60451
+ DeviceType.Climate
60452
+ ],
60453
+ methods: {},
60454
+ status: {
60455
+ schema: GroupCommandsSchema,
60456
+ kind: "push"
60457
+ },
60458
+ runtimeState: GroupCommandsSchema,
60459
+ /**
60460
+ * Runtime-state durability: **session** — the last attempt. A restored
60461
+ * failure would outlive the command that caused it.
60462
+ *
60463
+ * See `RuntimeStateDurability`. Enforced by
60464
+ * `scripts/check-runtime-state-durability.ts`.
60465
+ */
60466
+ durability: "session",
60467
+ history: "none"
60468
+ };
60469
+ /**
60470
+ * Whether a helper actuator group counts as active (D944): at least one
60471
+ * included member is, or every included member is. What "active" means is the
60472
+ * type's: a cover is open, a lock is locked, a media player is playing, a
60473
+ * climate device is not off. A group of lights, switches and fans reports
60474
+ * `switch.on` instead; this cap is for the types whose own state is not a
60475
+ * yes/no. Unknown members are left out (`group-status` counts them) and an
60476
+ * empty included set takes the device offline, never `active: false`.
60477
+ */
60478
+ var GroupActiveSchema = object({
60479
+ active: boolean().meta({ label: "Active" }),
60480
+ /** Ms epoch when the slice was last updated. */
60481
+ lastChangedAt: number()
60482
+ });
60483
+ var groupActiveCapability = {
60484
+ name: "group-active",
60485
+ scope: "device",
60486
+ deviceNative: true,
60487
+ mode: "singleton",
60488
+ deviceTypes: [
60489
+ DeviceType.Cover,
60490
+ DeviceType.Valve,
60491
+ DeviceType.Lock,
60492
+ DeviceType.MediaPlayer,
60493
+ DeviceType.Climate,
60494
+ DeviceType.Thermostat
60495
+ ],
60496
+ methods: {},
60497
+ status: {
60498
+ schema: GroupActiveSchema,
60499
+ kind: "push"
60500
+ },
60501
+ runtimeState: GroupActiveSchema,
60502
+ /**
60503
+ * Runtime-state durability: **session** — recomputed from the members on the
60504
+ * next source event; a restored value would outlive the members it named.
60505
+ *
60506
+ * See `RuntimeStateDurability`. Enforced by
60507
+ * `scripts/check-runtime-state-durability.ts`.
60508
+ */
60509
+ durability: "session",
60510
+ history: "none"
60511
+ };
60512
+ /**
60513
+ * How many members of a helper group answered (D944). Counts are integers,
60514
+ * not measurements: zero included is a real count, never a stand-in reading.
60515
+ * The reading itself stays on the output capability. History is none — the
60516
+ * series that later statistics read is the output cap's own history block.
60517
+ */
60518
+ var GroupStatusSchema = object({
60519
+ /** Members whose current value entered the aggregate. */
60520
+ included: number().int().nonnegative().meta(readingMeta("count", {
60521
+ precision: 0,
60522
+ label: "Reporting"
60523
+ })),
60524
+ /** Members left out: offline, unknown, or not a finite reading (D393). */
60525
+ excluded: number().int().nonnegative().meta(readingMeta("count", {
60526
+ precision: 0,
60527
+ label: "Excluded"
60528
+ })),
60529
+ /** `included` + `excluded`. */
60530
+ total: number().int().nonnegative().meta(readingMeta("count", {
60531
+ precision: 0,
60532
+ label: "Members"
60533
+ }))
60534
+ });
60535
+ var groupStatusCapability = {
60536
+ name: "group-status",
60537
+ scope: "device",
60538
+ deviceNative: true,
60539
+ mode: "singleton",
60540
+ deviceTypes: [
60541
+ DeviceType.Sensor,
60542
+ DeviceType.Switch,
60543
+ DeviceType.Light,
60544
+ DeviceType.Fan,
60545
+ DeviceType.Cover,
60546
+ DeviceType.Valve,
60547
+ DeviceType.Lock,
60548
+ DeviceType.MediaPlayer,
60549
+ DeviceType.Thermostat,
60550
+ DeviceType.Climate
60551
+ ],
60552
+ methods: {},
60553
+ status: {
60554
+ schema: GroupStatusSchema,
60555
+ kind: "push"
60556
+ },
60557
+ runtimeState: GroupStatusSchema,
60558
+ /**
60559
+ * Runtime-state durability: **session** — recomputed from members on the
60560
+ * next source event; a restored count would outlive the readings it named.
60561
+ *
60562
+ * See `RuntimeStateDurability`. Enforced by
60563
+ * `scripts/check-runtime-state-durability.ts`.
60564
+ */
60565
+ durability: "session",
60566
+ history: "none"
60567
+ };
59612
60568
  var HeatingValveStatusSchema = object({
59613
60569
  /** Radiator valve opening 0 (closed) .. 100 (open). Null = not yet known. */
59614
60570
  position: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
@@ -60864,7 +61820,14 @@ var lockControlCapability = {
60864
61820
  }),
60865
61821
  unlock: method(object({
60866
61822
  deviceId: number().int().nonnegative(),
60867
- code: string().min(1).optional()
61823
+ code: string().min(1).optional(),
61824
+ /**
61825
+ * Honoured by a helper lock GROUP only (D944): unlocking several doors
61826
+ * with one call is refused unless the caller says it was confirmed. A
61827
+ * single lock ignores it. The refusal lives in the callee, so no
61828
+ * automation or API caller reaches the doors by skipping a dialog.
61829
+ */
61830
+ confirm: boolean().optional()
60868
61831
  }), _void(), {
60869
61832
  kind: "mutation",
60870
61833
  auth: "protected"
@@ -60901,6 +61864,44 @@ var lockControlCapability = {
60901
61864
  volatileStateFields: ["lastChangedAt"]
60902
61865
  };
60903
61866
  /**
61867
+ * A monotonic total between resets (D944). Energy uses `power-meter.kwhTotal`
61868
+ * so dashboards keep one series; every other instantaneous reading lands here.
61869
+ * `value` is the time integral in the source quantity's accumulated base
61870
+ * (base-unit seconds, or kWh on the power meter). `null` is a gap, never zero.
61871
+ */
61872
+ var MeterStatusSchema = object({
61873
+ value: number().nullable().meta(readingMeta("device", { label: "Total" })),
61874
+ lastFetchedAt: number()
61875
+ });
61876
+ var meterCapability = {
61877
+ name: "meter",
61878
+ scope: "device",
61879
+ deviceNative: true,
61880
+ mode: "singleton",
61881
+ deviceTypes: [DeviceType.Sensor],
61882
+ methods: {},
61883
+ status: {
61884
+ schema: MeterStatusSchema,
61885
+ kind: "push"
61886
+ },
61887
+ runtimeState: MeterStatusSchema,
61888
+ /**
61889
+ * Runtime-state durability: **restored** — the total is a cache of the
61890
+ * history integral. A restart shows it only until the history pass
61891
+ * recomputes the open period; it is not an in-memory buffer.
61892
+ *
61893
+ * See `RuntimeStateDurability`. Enforced by
61894
+ * `scripts/check-runtime-state-durability.ts`.
61895
+ */
61896
+ durability: "restored",
61897
+ history: { fields: { value: {
61898
+ kind: "counter",
61899
+ deadband: .001,
61900
+ minIntervalMs: 6e4
61901
+ } } },
61902
+ volatileStateFields: ["lastFetchedAt"]
61903
+ };
61904
+ /**
60904
61905
  * Media-player cap. Models HA `media_player.*` (Sonos, Chromecast,
60905
61906
  * Apple TV, Spotify, Roku, generic OTT receivers, …) on
60906
61907
  * `DeviceType.MediaPlayer`. Disjoint from the camera streaming
@@ -61378,12 +62379,18 @@ var motionCapability = {
61378
62379
  methods: {
61379
62380
  /**
61380
62381
  * Pull the current motion state synchronously. Convenience shortcut
61381
- * for consumers that don't need the full status object; equivalent
61382
- * to `getStatus()?.detected ?? false`. Will likely be folded into
61383
- * `getStatus` once the auto-injected status surface lands in every
61384
- * consumer.
62382
+ * for consumers that don't need the full status object. A composed
62383
+ * group answers from its slice (D944): unknown throws, it is not off.
61385
62384
  */
61386
62385
  isDetected: method(object({ deviceId: number() }), boolean()) },
62386
+ /**
62387
+ * A composed motion group serves `isDetected` from `detected` (D944).
62388
+ * Without this the cap stays uncomposable (`has-commands`).
62389
+ */
62390
+ composedMethods: { isDetected: {
62391
+ kind: "slice",
62392
+ field: "detected"
62393
+ } },
61387
62394
  events: {
61388
62395
  /**
61389
62396
  * Fires every time the runner transitions a camera between
@@ -63406,9 +64413,9 @@ var PowerMeterStatusSchema = object({
63406
64413
  /** Cumulative energy in kilowatt-hours since the meter was reset. */
63407
64414
  kwhTotal: number().optional().meta(readingMeta("energy", { label: "Energy" })),
63408
64415
  /** Voltage in volts. */
63409
- volts: number().optional().meta(readingMeta("voltage")),
64416
+ volts: number().optional().meta(readingMeta("voltage", { label: "Voltage" })),
63410
64417
  /** Current in amperes. */
63411
- amps: number().optional().meta(readingMeta("current")),
64418
+ amps: number().optional().meta(readingMeta("current", { label: "Current" })),
63412
64419
  /** Apparent power in volt-amperes. */
63413
64420
  va: number().optional().meta(readingMeta("apparent-power")),
63414
64421
  /** Power factor (0..1) if reported. */
@@ -63416,12 +64423,74 @@ var PowerMeterStatusSchema = object({
63416
64423
  /** Ms epoch when the slice was last updated. */
63417
64424
  lastFetchedAt: number()
63418
64425
  });
64426
+ /**
64427
+ * Loads that draw metered mains power (D951). The reading is a feature of the
64428
+ * device itself — a plug, a lamp, a fan, an air conditioner, a boiler, a
64429
+ * vacuum dock — not a separate sensor beside it. A `Sensor` stays: a clamp
64430
+ * meter or a standalone energy monitor IS the device. Cover, lock, valve,
64431
+ * camera and the like are left out: their draw is not what anyone meters.
64432
+ */
64433
+ var POWER_METER_DEVICE_TYPES = [
64434
+ DeviceType.Sensor,
64435
+ DeviceType.Switch,
64436
+ DeviceType.Light,
64437
+ DeviceType.Fan,
64438
+ DeviceType.Climate,
64439
+ DeviceType.Thermostat,
64440
+ DeviceType.Humidifier,
64441
+ DeviceType.WaterHeater,
64442
+ DeviceType.MediaPlayer,
64443
+ DeviceType.Washer,
64444
+ DeviceType.Dryer,
64445
+ DeviceType.Dishwasher,
64446
+ DeviceType.Vacuum,
64447
+ DeviceType.LawnMower,
64448
+ DeviceType.PetFeeder
64449
+ ];
64450
+ /** Everything but a bare `Sensor`: a sensor that takes its reading from another sensor adds nothing. */
64451
+ var POWER_METER_CUSTOMIZE_DEVICE_TYPES = POWER_METER_DEVICE_TYPES.filter((type) => type !== DeviceType.Sensor);
64452
+ /** One scalar target per reading; each is sourced from a device of its own (D951). */
64453
+ function powerTarget(id, unit) {
64454
+ return {
64455
+ id,
64456
+ cardinality: "scalar",
64457
+ vocabulary: {
64458
+ cap: "power-meter",
64459
+ stateField: id
64460
+ },
64461
+ deviceTypes: POWER_METER_CUSTOMIZE_DEVICE_TYPES,
64462
+ apply: "add",
64463
+ path: id,
64464
+ sources: [{
64465
+ kind: "numeric",
64466
+ requiredUnit: unit,
64467
+ transforms: [{ kind: "identity" }]
64468
+ }],
64469
+ companions: [{
64470
+ kind: "clock",
64471
+ path: "lastFetchedAt",
64472
+ when: "always"
64473
+ }],
64474
+ sourceReport: { status: "assignment-status" },
64475
+ advancedExpression: true
64476
+ };
64477
+ }
64478
+ /** "Power and energy" extension: watts, energy, voltage and current from other devices (D951). */
64479
+ var powerMeterCustomize = {
64480
+ version: 1,
64481
+ targets: [
64482
+ powerTarget("watts", "W"),
64483
+ powerTarget("kwhTotal", "kWh"),
64484
+ powerTarget("volts", "V"),
64485
+ powerTarget("amps", "A")
64486
+ ]
64487
+ };
63419
64488
  var powerMeterCapability = {
63420
64489
  name: "power-meter",
63421
64490
  scope: "device",
63422
64491
  deviceNative: true,
63423
64492
  mode: "singleton",
63424
- deviceTypes: [DeviceType.Sensor],
64493
+ deviceTypes: POWER_METER_DEVICE_TYPES,
63425
64494
  methods: {},
63426
64495
  status: {
63427
64496
  schema: PowerMeterStatusSchema,
@@ -63478,7 +64547,8 @@ var powerMeterCapability = {
63478
64547
  } },
63479
64548
  /** Clock fields: written, but excluded from the compare that decides
63480
64549
  * whether persisting is worth a SQLite commit. */
63481
- volatileStateFields: ["lastFetchedAt"]
64550
+ volatileStateFields: ["lastFetchedAt"],
64551
+ customize: powerMeterCustomize
63482
64552
  };
63483
64553
  /**
63484
64554
  * Presence cap. Models HA `person.*` and `device_tracker.*` entities
@@ -64159,6 +65229,8 @@ var runningCustomize = {
64159
65229
  stateField: "running"
64160
65230
  },
64161
65231
  deviceTypes: [
65232
+ DeviceType.Washer,
65233
+ DeviceType.Dryer,
64162
65234
  DeviceType.Dishwasher,
64163
65235
  DeviceType.Vacuum,
64164
65236
  DeviceType.LawnMower,
@@ -66648,7 +67720,8 @@ var switchCapability = {
66648
67720
  deviceTypes: [
66649
67721
  DeviceType.Switch,
66650
67722
  DeviceType.Siren,
66651
- DeviceType.Light
67723
+ DeviceType.Light,
67724
+ DeviceType.Fan
66652
67725
  ],
66653
67726
  methods: { setState: method(object({
66654
67727
  deviceId: number(),
@@ -68861,8 +69934,9 @@ method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" })
68861
69934
  kind: "mutation",
68862
69935
  auth: "admin"
68863
69936
  });
69937
+ DeviceFeature.FanSpeed, DeviceFeature.FanPreset, DeviceFeature.FanDirection, DeviceFeature.FanOscillating, DeviceFeature.CoverPositionable, DeviceFeature.CoverTilt, DeviceFeature.ValvePositionable, DeviceFeature.MediaPlayerVolume, DeviceFeature.ClimateFanMode;
68864
69938
  SOURCE_CAPS.filter((cap) => cap !== "switch" && cap !== "motion");
68865
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Camera, DeviceType.Camera, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
69939
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
68866
69940
  String.raw`rose\(active(\d+), changed(\d+), (\d+(?:\.\d+)?)\)`;
68867
69941
  DeviceRole.BinarySensor, DeviceRole.MotionSensor;
68868
69942
  new Set(CAP_NAMES);
@@ -69191,6 +70265,9 @@ var DEVICE_LOCAL_STATE_CAPS = {
69191
70265
  featureProbe: featureProbeCapability,
69192
70266
  flood: floodCapability,
69193
70267
  gas: gasCapability,
70268
+ groupActive: groupActiveCapability,
70269
+ groupCommands: groupCommandsCapability,
70270
+ groupStatus: groupStatusCapability,
69194
70271
  heatingValve: heatingValveCapability,
69195
70272
  humidifier: humidifierCapability,
69196
70273
  humiditySensor: humiditySensorCapability,
@@ -69200,6 +70277,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
69200
70277
  lawnMowerControl: lawnMowerControlCapability,
69201
70278
  lockControl: lockControlCapability,
69202
70279
  mediaPlayer: mediaPlayerCapability,
70280
+ meter: meterCapability,
69203
70281
  motion: motionCapability,
69204
70282
  motionTrigger: motionTriggerCapability,
69205
70283
  motionZones: motionZonesCapability,
@@ -70459,7 +71537,7 @@ var BaseDeviceProvider = class extends BaseAddon {
70459
71537
  return toDeviceSummary(device, this.addonId);
70460
71538
  }
70461
71539
  };
70462
- DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher;
71540
+ DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
70463
71541
  new Set(Object.values(DeviceType));
70464
71542
  Object.freeze({
70465
71543
  "accessories.getStatus": {
@@ -70567,6 +71645,13 @@ Object.freeze({
70567
71645
  access: "view",
70568
71646
  role: "admin"
70569
71647
  },
71648
+ "addons.getPackageDocs": {
71649
+ capName: "addons",
71650
+ capScope: "system",
71651
+ addonId: null,
71652
+ access: "view",
71653
+ role: "admin"
71654
+ },
70570
71655
  "addons.getVersions": {
70571
71656
  capName: "addons",
70572
71657
  capScope: "system",
@@ -73675,6 +74760,27 @@ Object.freeze({
73675
74760
  access: "view",
73676
74761
  role: "viewer"
73677
74762
  },
74763
+ "groupActive.getStatus": {
74764
+ capName: "group-active",
74765
+ capScope: "device",
74766
+ addonId: null,
74767
+ access: "view",
74768
+ role: "viewer"
74769
+ },
74770
+ "groupCommands.getStatus": {
74771
+ capName: "group-commands",
74772
+ capScope: "device",
74773
+ addonId: null,
74774
+ access: "view",
74775
+ role: "viewer"
74776
+ },
74777
+ "groupStatus.getStatus": {
74778
+ capName: "group-status",
74779
+ capScope: "device",
74780
+ addonId: null,
74781
+ access: "view",
74782
+ role: "viewer"
74783
+ },
73678
74784
  "heatingValve.getStatus": {
73679
74785
  capName: "heating-valve",
73680
74786
  capScope: "device",
@@ -74627,6 +75733,13 @@ Object.freeze({
74627
75733
  access: "create",
74628
75734
  role: "admin"
74629
75735
  },
75736
+ "meter.getStatus": {
75737
+ capName: "meter",
75738
+ capScope: "device",
75739
+ addonId: null,
75740
+ access: "view",
75741
+ role: "viewer"
75742
+ },
74630
75743
  "metricsProvider.collectSnapshot": {
74631
75744
  capName: "metrics-provider",
74632
75745
  capScope: "system",
@@ -82725,7 +83838,39 @@ var APPLIANCE_CAP_VOCABULARY = {
82725
83838
  phrase: t("When {device} finishes", "Quando {device} finisce"),
82726
83839
  icon: "square"
82727
83840
  }
82728
- }
83841
+ },
83842
+ overrides: { byType: {
83843
+ [DeviceType.Washer]: {
83844
+ state: { running: {
83845
+ whenTrue: t("When the washing machine starts", "Quando la lavatrice inizia"),
83846
+ whenFalse: t("When the washing machine has finished", "Quando la lavatrice ha finito")
83847
+ } },
83848
+ events: {
83849
+ onStarted: { phrase: t("When the washing machine starts", "Quando la lavatrice inizia") },
83850
+ onFinished: { phrase: t("When the washing machine has finished", "Quando la lavatrice ha finito") }
83851
+ }
83852
+ },
83853
+ [DeviceType.Dryer]: {
83854
+ state: { running: {
83855
+ whenTrue: t("When the dryer starts", "Quando l'asciugatrice inizia"),
83856
+ whenFalse: t("When the dryer has finished", "Quando l'asciugatrice ha finito")
83857
+ } },
83858
+ events: {
83859
+ onStarted: { phrase: t("When the dryer starts", "Quando l'asciugatrice inizia") },
83860
+ onFinished: { phrase: t("When the dryer has finished", "Quando l'asciugatrice ha finito") }
83861
+ }
83862
+ },
83863
+ [DeviceType.Dishwasher]: {
83864
+ state: { running: {
83865
+ whenTrue: t("When the dishwasher starts", "Quando la lavastoviglie inizia"),
83866
+ whenFalse: t("When the dishwasher has finished", "Quando la lavastoviglie ha finito")
83867
+ } },
83868
+ events: {
83869
+ onStarted: { phrase: t("When the dishwasher starts", "Quando la lavastoviglie inizia") },
83870
+ onFinished: { phrase: t("When the dishwasher has finished", "Quando la lavastoviglie ha finito") }
83871
+ }
83872
+ }
83873
+ } }
82729
83874
  },
82730
83875
  update: {
82731
83876
  scope: "device",
@@ -83497,6 +84642,41 @@ var SENSOR_CAP_VOCABULARY = {
83497
84642
  icon: "flame"
83498
84643
  }]
83499
84644
  },
84645
+ "group-active": {
84646
+ scope: "device",
84647
+ noun: t("Group state", "Stato del gruppo")
84648
+ },
84649
+ "group-commands": {
84650
+ scope: "device",
84651
+ noun: t("Group command", "Comando di gruppo")
84652
+ },
84653
+ "group-status": {
84654
+ scope: "device",
84655
+ noun: t("Group", "Gruppo"),
84656
+ state: [
84657
+ {
84658
+ kind: "numeric",
84659
+ field: "included",
84660
+ quantity: t("the members reporting", "i membri che rispondono"),
84661
+ label: t("Reporting", "Rispondono"),
84662
+ icon: "users"
84663
+ },
84664
+ {
84665
+ kind: "numeric",
84666
+ field: "excluded",
84667
+ quantity: t("the members left out", "i membri esclusi"),
84668
+ label: t("Excluded", "Esclusi"),
84669
+ icon: "users"
84670
+ },
84671
+ {
84672
+ kind: "numeric",
84673
+ field: "total",
84674
+ quantity: t("the member count", "il numero di membri"),
84675
+ label: t("Members", "Membri"),
84676
+ icon: "sigma"
84677
+ }
84678
+ ]
84679
+ },
83500
84680
  "humidity-sensor": {
83501
84681
  scope: "device",
83502
84682
  noun: t("Humidity", "Umidità"),
@@ -83522,6 +84702,17 @@ var SENSOR_CAP_VOCABULARY = {
83522
84702
  }],
83523
84703
  events: { onMotionChanged: { notOperatorFacing: "the `detected` state trigger phrases both edges, from the mirror that survives a dropped event (D49)" } }
83524
84704
  },
84705
+ meter: {
84706
+ scope: "device",
84707
+ noun: t("Meter", "Contatore"),
84708
+ state: [{
84709
+ kind: "numeric",
84710
+ field: "value",
84711
+ quantity: t("the total", "il totale"),
84712
+ label: t("Total", "Totale"),
84713
+ icon: "gauge"
84714
+ }]
84715
+ },
83525
84716
  "numeric-sensor": {
83526
84717
  scope: "device",
83527
84718
  noun: t("Sensor", "Sensore"),
@@ -83994,8 +85185,47 @@ function projectAction(cap, action) {
83994
85185
  };
83995
85186
  }
83996
85187
  Object.entries(CAP_VOCABULARY_BY_NAME).flatMap(([cap, entry]) => entry.scope === "device" ? (entry.actions ?? []).map((a) => projectAction(cap, a)) : []);
83997
- DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher;
85188
+ DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
83998
85189
  DeviceFeature.BatteryOperated;
85190
+ DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
85191
+ var HA_AS = "a power sensor (device_class power). Home Assistant has no laundry domain. running-state stays unexported until a null reading can be published as unavailable.";
85192
+ var HOMEKIT_REASON = "HomeKit has no laundry-appliance service. The export tab would pair an accessory with nothing on it: running-state is withheld until a null reading can be unavailable, and power is not a HomeKit service this export honours.";
85193
+ var ALEXA_REASON = "Alexa has no laundry category in this export, and neither power nor running has an Alexa interface.";
85194
+ var GOOGLE_REASON = "Google WASHER, DRYER and DISHWASHER require RunCycle. A power threshold is not that trait, and this export does not publish RunCycle.";
85195
+ var MATTER_REASON = "No Matter export is built. The closest device types are Laundry Washer (0x0073) and Laundry Dryer (0x0074); a power threshold is not the Laundry Washer Mode cluster.";
85196
+ function withheld(reason) {
85197
+ return {
85198
+ [DeviceType.Washer]: {
85199
+ exported: false,
85200
+ reason
85201
+ },
85202
+ [DeviceType.Dryer]: {
85203
+ exported: false,
85204
+ reason
85205
+ },
85206
+ [DeviceType.Dishwasher]: {
85207
+ exported: false,
85208
+ reason
85209
+ }
85210
+ };
85211
+ }
85212
+ function offered(received) {
85213
+ return {
85214
+ [DeviceType.Washer]: {
85215
+ exported: true,
85216
+ as: received
85217
+ },
85218
+ [DeviceType.Dryer]: {
85219
+ exported: true,
85220
+ as: received
85221
+ },
85222
+ [DeviceType.Dishwasher]: {
85223
+ exported: true,
85224
+ as: received
85225
+ }
85226
+ };
85227
+ }
85228
+ offered(HA_AS), withheld(HOMEKIT_REASON), withheld(ALEXA_REASON), withheld(GOOGLE_REASON), withheld(MATTER_REASON);
83999
85229
  Object.freeze({
84000
85230
  "accessories.getStatus": [{
84001
85231
  name: "deviceId",
@@ -84962,6 +86192,21 @@ Object.freeze({
84962
86192
  form: "single",
84963
86193
  optional: false
84964
86194
  }],
86195
+ "groupActive.getStatus": [{
86196
+ name: "deviceId",
86197
+ form: "single",
86198
+ optional: false
86199
+ }],
86200
+ "groupCommands.getStatus": [{
86201
+ name: "deviceId",
86202
+ form: "single",
86203
+ optional: false
86204
+ }],
86205
+ "groupStatus.getStatus": [{
86206
+ name: "deviceId",
86207
+ form: "single",
86208
+ optional: false
86209
+ }],
84965
86210
  "heatingValve.getStatus": [{
84966
86211
  name: "deviceId",
84967
86212
  form: "single",
@@ -85162,6 +86407,11 @@ Object.freeze({
85162
86407
  form: "single",
85163
86408
  optional: false
85164
86409
  }],
86410
+ "meter.getStatus": [{
86411
+ name: "deviceId",
86412
+ form: "single",
86413
+ optional: false
86414
+ }],
85165
86415
  "motion.getStatus": [{
85166
86416
  name: "deviceId",
85167
86417
  form: "single",
@@ -86769,7 +88019,6 @@ Object.freeze({
86769
88019
  "network-access": "ingress",
86770
88020
  "smtp-provider": "email"
86771
88021
  });
86772
- DeviceType.Camera;
86773
88022
  /**
86774
88023
  * A saved Customize assignment (D936). The schema is the type: callers use
86775
88024
  * `z.infer`, they do not restate the shape.
@@ -86946,6 +88195,8 @@ new Map(Object.entries({
86946
88195
  "detection-blind": "device-events",
86947
88196
  "motion-noisy": "device-events",
86948
88197
  "motion-calm": "device-events",
88198
+ "package-llm-silent": "device-events",
88199
+ "package-llm-answered": "device-events",
86949
88200
  "recording-stalled": "device-events",
86950
88201
  "recording-healthy": "device-events",
86951
88202
  "recording-degraded": "device-events",
@@ -87029,6 +88280,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
87029
88280
  label: "Motion without a subject",
87030
88281
  kinds: ["motion-noisy", "motion-calm"]
87031
88282
  },
88283
+ {
88284
+ id: "package-llm",
88285
+ family: "device-events",
88286
+ label: "Package confirm",
88287
+ kinds: ["package-llm-silent", "package-llm-answered"]
88288
+ },
87032
88289
  {
87033
88290
  id: "recording",
87034
88291
  family: "device-events",
@@ -87210,6 +88467,8 @@ var DEVICE_EVENTS = [
87210
88467
  "detection-blind",
87211
88468
  "motion-noisy",
87212
88469
  "motion-calm",
88470
+ "package-llm-silent",
88471
+ "package-llm-answered",
87213
88472
  "recording-stalled",
87214
88473
  "recording-healthy",
87215
88474
  "recording-degraded",
@@ -87478,6 +88737,15 @@ new Map([
87478
88737
  snapshotLabel: "Cameras with constant motion now",
87479
88738
  snapshotSection: null
87480
88739
  },
88740
+ {
88741
+ id: "package-llm-confirm",
88742
+ family: "device-events",
88743
+ label: "Package confirm (not answering / answering again)",
88744
+ bad: ["package-llm-silent"],
88745
+ recovery: ["package-llm-answered"],
88746
+ snapshotLabel: "Cameras whose package confirm is not answering",
88747
+ snapshotSection: null
88748
+ },
87481
88749
  {
87482
88750
  id: "recording-health",
87483
88751
  family: "device-events",