@camstack/addon-export-hap 1.2.182 → 1.2.184

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.
@@ -5492,7 +5492,7 @@ var ZodIssueCode = {
5492
5492
  var ZodFirstPartyTypeKind;
5493
5493
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5494
5494
  //#endregion
5495
- //#region ../types/dist/sleep-bykKrTgu.mjs
5495
+ //#region ../types/dist/sleep--jXS9hWo.mjs
5496
5496
  /**
5497
5497
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5498
5498
  * window to float samples (D455).
@@ -8673,6 +8673,7 @@ var CAP_NAMES = Object.freeze([
8673
8673
  "filesystem-browse",
8674
8674
  "flood",
8675
8675
  "gas",
8676
+ "group-active",
8676
8677
  "group-commands",
8677
8678
  "group-status",
8678
8679
  "heating-valve",
@@ -8695,6 +8696,7 @@ var CAP_NAMES = Object.freeze([
8695
8696
  "login-method",
8696
8697
  "media-player",
8697
8698
  "mesh-network",
8699
+ "meter",
8698
8700
  "metrics-provider",
8699
8701
  "model-convert",
8700
8702
  "model-distributor",
@@ -9493,6 +9495,10 @@ Object.freeze({
9493
9495
  "path": "detected",
9494
9496
  "valueType": "boolean"
9495
9497
  }],
9498
+ "group-active": [{
9499
+ "path": "active",
9500
+ "valueType": "boolean"
9501
+ }],
9496
9502
  "group-status": [
9497
9503
  {
9498
9504
  "path": "included",
@@ -9752,6 +9758,10 @@ Object.freeze({
9752
9758
  ]
9753
9759
  }
9754
9760
  ],
9761
+ "meter": [{
9762
+ "path": "value",
9763
+ "valueType": "number"
9764
+ }],
9755
9765
  "motion": [
9756
9766
  {
9757
9767
  "path": "detected",
@@ -10495,7 +10505,7 @@ object({
10495
10505
  params: record(string(), union([string(), number()])).optional()
10496
10506
  });
10497
10507
  //#endregion
10498
- //#region ../types/dist/err-msg-BXKzRBwg.mjs
10508
+ //#region ../types/dist/err-msg-DIorGYeC.mjs
10499
10509
  var DeviceType = /* @__PURE__ */ function(DeviceType) {
10500
10510
  DeviceType["Camera"] = "camera";
10501
10511
  DeviceType["Hub"] = "hub";
@@ -10589,8 +10599,14 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
10589
10599
  DeviceType["PetFeeder"] = "pet-feeder";
10590
10600
  /** Built-in dishwasher — program lifecycle, door / remote-start gates,
10591
10601
  * salt and rinse-aid levels. Installed with the `dishwasher` cap.
10592
- * Sources: native Bosch Home Connect, reusable by similar integrations. */
10602
+ * Sources: native Bosch Home Connect, reusable by similar integrations.
10603
+ * A plug-built dishwasher carries running-state and power instead. */
10593
10604
  DeviceType["Dishwasher"] = "dishwasher";
10605
+ /** Washing machine. A plug-built one is running while its power stays
10606
+ * above a threshold. No program cap — that surface is the dishwasher's. */
10607
+ DeviceType["Washer"] = "washer";
10608
+ /** Tumble dryer. Same plug-built running surface as {@link Washer}. */
10609
+ DeviceType["Dryer"] = "dryer";
10594
10610
  return DeviceType;
10595
10611
  }({});
10596
10612
  var DeviceFeature = /* @__PURE__ */ function(DeviceFeature) {
@@ -10848,7 +10864,7 @@ function errMsg$16(err) {
10848
10864
  return String(err);
10849
10865
  }
10850
10866
  //#endregion
10851
- //#region ../types/dist/composition-OhpuespA.mjs
10867
+ //#region ../types/dist/composition-Bb8iwHEJ.mjs
10852
10868
  var AUDIO_ENCODER_BY_CODEC = {
10853
10869
  opus: "libopus",
10854
10870
  aac: "aac",
@@ -11758,6 +11774,13 @@ var table = {
11758
11774
  apply: () => {
11759
11775
  throw new ExpressionEvalError("latchedAt: stateful evaluation context is required");
11760
11776
  }
11777
+ },
11778
+ schmitt: {
11779
+ minArgs: 3,
11780
+ maxArgs: 5,
11781
+ apply: () => {
11782
+ throw new ExpressionEvalError("schmitt: stateful evaluation context is required");
11783
+ }
11761
11784
  }
11762
11785
  };
11763
11786
  Object.freeze(Object.assign(Object.create(null), table));
@@ -12199,6 +12222,99 @@ function validateExpressionSource(src) {
12199
12222
  return null;
12200
12223
  }
12201
12224
  /**
12225
+ * One power reading becomes a washer, dryer or dishwasher (D944 helper).
12226
+ *
12227
+ * Standby of the control board is under 5 W; a motor or a heater is far
12228
+ * above that, so 5 W is the line. A door lock or a short pump spike is not
12229
+ * a cycle, so running starts only after 30 s above the line.
12230
+ *
12231
+ * A wash, dry or dishwasher pause (soak, heat-wait, heater off between
12232
+ * bursts) lasts several minutes. Ending the cycle on the first dip would
12233
+ * report "finished" in the middle of the program, so the stop dwell is
12234
+ * 10 minutes on every type. The number is stored per type so one machine
12235
+ * can move later without moving the others.
12236
+ */
12237
+ var APPLIANCE_TEMPLATE_ID = "appliance";
12238
+ var APPLIANCE_KINDS = [
12239
+ "washer",
12240
+ "dryer",
12241
+ "dishwasher"
12242
+ ];
12243
+ DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
12244
+ /**
12245
+ * Statistics and integrals over a history read (D944).
12246
+ *
12247
+ * Pure: the same points always give the same answer, so a restart recomputes
12248
+ * rather than trusting a buffer. A gauge mean is time-weighted (value × ms),
12249
+ * never the mean of the samples. A hole with no held value is not integrated
12250
+ * as zero. A truncated read is not published.
12251
+ */
12252
+ var STATISTIC_STATS = [
12253
+ "min",
12254
+ "max",
12255
+ "mean",
12256
+ "sum",
12257
+ "count",
12258
+ "change"
12259
+ ];
12260
+ /**
12261
+ * The range a statistics or integral helper asks history for (D944).
12262
+ *
12263
+ * Calendar edges are the hub's timezone, never UTC midnight: a day is 23, 24
12264
+ * or 25 hours across a DST change. A tier is eligible only when its retention
12265
+ * is strictly longer than the longest that range can be. Forever qualifies.
12266
+ * Equal to a tier's retention is a refusal, not a short answer.
12267
+ */
12268
+ var MINUTE_MS = 6e4;
12269
+ var HOUR_MS = 60 * MINUTE_MS;
12270
+ var DAY_MS = 24 * HOUR_MS;
12271
+ var ROLLING_SPANS = [
12272
+ "1h",
12273
+ "24h",
12274
+ "2d",
12275
+ "7d",
12276
+ "30d",
12277
+ "custom"
12278
+ ];
12279
+ var CALENDAR_PERIODS = [
12280
+ "today",
12281
+ "yesterday",
12282
+ "this-week",
12283
+ "this-month"
12284
+ ];
12285
+ var RESET_PERIODS = [
12286
+ "never",
12287
+ "daily",
12288
+ "weekly",
12289
+ "monthly"
12290
+ ];
12291
+ 5 * MINUTE_MS;
12292
+ 24 * HOUR_MS, 2 * DAY_MS, 7 * DAY_MS, 30 * DAY_MS;
12293
+ 7 * DAY_MS, 30 * DAY_MS, 365 * DAY_MS;
12294
+ var rollingWindowObject = object({
12295
+ kind: literal("rolling"),
12296
+ span: _enum(ROLLING_SPANS),
12297
+ customMinutes: number().int().min(5).optional()
12298
+ }).check((payload) => {
12299
+ if (payload.value.span === "custom" && payload.value.customMinutes === void 0) payload.issues.push({
12300
+ code: "custom",
12301
+ message: "a custom range needs a duration in minutes",
12302
+ path: ["customMinutes"],
12303
+ input: payload.value
12304
+ });
12305
+ if (payload.value.span !== "custom" && payload.value.customMinutes !== void 0) payload.issues.push({
12306
+ code: "custom",
12307
+ message: "only a custom range carries a duration",
12308
+ path: ["customMinutes"],
12309
+ input: payload.value
12310
+ });
12311
+ });
12312
+ var RollingWindowSchema = rollingWindowObject;
12313
+ var StatisticWindowSchema = discriminatedUnion("kind", [rollingWindowObject, object({
12314
+ kind: literal("calendar"),
12315
+ period: _enum(CALENDAR_PERIODS)
12316
+ })]);
12317
+ /**
12202
12318
  * A composition source identity: `(addonId, stableId)`, never a numeric device
12203
12319
  * id. Split out so helper schemas can name it without a cycle through
12204
12320
  * `composition.ts` (D659).
@@ -12224,7 +12340,13 @@ var GROUP_TEMPLATE_IDS = [
12224
12340
  "occupancy",
12225
12341
  "binary",
12226
12342
  "switch",
12227
- "light"
12343
+ "light",
12344
+ "fan",
12345
+ "cover",
12346
+ "valve",
12347
+ "lock",
12348
+ "media-player",
12349
+ "climate"
12228
12350
  ];
12229
12351
  var NUMERIC_AGGREGATES = [
12230
12352
  "mean",
@@ -12254,14 +12376,73 @@ var HelperMemberSchema = object({
12254
12376
  cap: string().min(1),
12255
12377
  fieldPath: string().min(1)
12256
12378
  });
12257
- var HelperSpecSchema = discriminatedUnion("kind", [object({
12258
- kind: literal("group"),
12259
- templateId: GroupTemplateIdSchema,
12260
- aggregate: AggregateReducerSchema,
12261
- members: array(HelperMemberSchema).min(1).max(64),
12262
- /** Actuator groups only. Readings leave this unset. */
12263
- active: ActiveCriterionSchema.optional()
12264
- })]);
12379
+ var HelperSpecSchema = discriminatedUnion("kind", [
12380
+ object({
12381
+ kind: literal("group"),
12382
+ templateId: GroupTemplateIdSchema,
12383
+ aggregate: AggregateReducerSchema,
12384
+ members: array(HelperMemberSchema).min(1).max(64),
12385
+ /** Actuator groups only. Readings leave this unset. */
12386
+ active: ActiveCriterionSchema.optional()
12387
+ }),
12388
+ object({
12389
+ kind: literal("appliance"),
12390
+ templateId: literal(APPLIANCE_TEMPLATE_ID),
12391
+ appliance: _enum(APPLIANCE_KINDS),
12392
+ thresholdWatts: number().positive(),
12393
+ startDwellMs: number().int().nonnegative(),
12394
+ stopDwellMs: number().int().nonnegative(),
12395
+ member: HelperMemberSchema
12396
+ }),
12397
+ object({
12398
+ kind: literal("statistic"),
12399
+ stat: _enum(STATISTIC_STATS),
12400
+ window: StatisticWindowSchema,
12401
+ source: HelperMemberSchema
12402
+ }),
12403
+ object({
12404
+ kind: literal("integral"),
12405
+ reset: _enum(RESET_PERIODS),
12406
+ output: _enum(["energy", "meter"]),
12407
+ source: HelperMemberSchema
12408
+ }),
12409
+ object({
12410
+ kind: literal("threshold"),
12411
+ source: HelperMemberSchema,
12412
+ high: number(),
12413
+ low: number(),
12414
+ onForMs: number().int().nonnegative(),
12415
+ offForMs: number().int().nonnegative()
12416
+ }),
12417
+ object({
12418
+ kind: literal("arithmetic"),
12419
+ op: _enum([
12420
+ "sum",
12421
+ "difference",
12422
+ "ratio"
12423
+ ]),
12424
+ inputs: array(HelperMemberSchema).min(2).max(64)
12425
+ }),
12426
+ object({
12427
+ kind: literal("expression"),
12428
+ expr: string().min(1),
12429
+ inputs: array(object({
12430
+ name: string().min(1),
12431
+ member: HelperMemberSchema
12432
+ })).min(1).max(64),
12433
+ output: _enum(["number", "boolean"])
12434
+ }),
12435
+ object({
12436
+ kind: literal("derivative"),
12437
+ window: RollingWindowSchema,
12438
+ per: _enum([
12439
+ "second",
12440
+ "minute",
12441
+ "hour"
12442
+ ]),
12443
+ source: HelperMemberSchema
12444
+ })
12445
+ ]);
12265
12446
  /** A composed device's stableId is this prefix plus the block id. */
12266
12447
  var COMPOSED_DEVICE_STABLE_ID_PREFIX = "composed-";
12267
12448
  /** Longest snippet a `code` source may carry (slice 4). */
@@ -12322,6 +12503,12 @@ var CompositionFieldSourceSchema = discriminatedUnion("kind", [
12322
12503
  "all"
12323
12504
  ]),
12324
12505
  reads: array(CompositionFieldReadSchema).min(1).max(64),
12506
+ /**
12507
+ * Set when the reads are an enum state, not a yes/no: the listed states
12508
+ * count as active (a cover is `open`). A state outside the list is inactive;
12509
+ * a read that is not a state at all is left out. Only `any` / `all` use it.
12510
+ */
12511
+ activeWhen: array(string().min(1)).min(1).optional(),
12325
12512
  /** `value` is the reading; the others are the member counts. */
12326
12513
  publish: _enum([
12327
12514
  "value",
@@ -12335,6 +12522,26 @@ var CompositionFieldSourceSchema = discriminatedUnion("kind", [
12335
12522
  "omit",
12336
12523
  "offline"
12337
12524
  ])
12525
+ }),
12526
+ object({
12527
+ kind: literal("series"),
12528
+ read: CompositionFieldReadSchema,
12529
+ /** `value` is the statistic or the integral. The others are the gap counts. */
12530
+ publish: _enum([
12531
+ "value",
12532
+ "included",
12533
+ "excluded",
12534
+ "total"
12535
+ ]),
12536
+ /**
12537
+ * What an unanswered `value` does. Counts ignore this. `offline` leaves the
12538
+ * device unseeded until history answers, so a restart cannot publish 0.
12539
+ */
12540
+ empty: _enum([
12541
+ "null",
12542
+ "omit",
12543
+ "offline"
12544
+ ])
12338
12545
  })
12339
12546
  ]);
12340
12547
  var CompositionCommandTargetSchema = discriminatedUnion("kind", [object({
@@ -17718,7 +17925,22 @@ var BrokerProviderInfoSchema = object({
17718
17925
  */
17719
17926
  interactiveConnectPath: string().min(1).optional(),
17720
17927
  /** Relative hub path to disconnect the linked account (same popup pattern). */
17721
- interactiveDisconnectPath: string().min(1).optional()
17928
+ interactiveDisconnectPath: string().min(1).optional(),
17929
+ /**
17930
+ * The kind signs in through a server-held interactive session instead of
17931
+ * (or before) typed credentials. `basePath` is a hub-relative route set
17932
+ * served by the owning addon (`/addon/<id>/...`) speaking the sign-in
17933
+ * contract: `POST {basePath}/start` (body: the form's settings) answers
17934
+ * `{ sessionId, loginUrl }`; `GET {basePath}/status?sessionId=` answers
17935
+ * `{ phase: 'starting' | 'awaiting-login' | 'captured' | 'error' |
17936
+ * 'cancelled', loginUrl, error }`; `POST {basePath}/commit`
17937
+ * (`{ sessionId, name, brokerId? }`) stores the credentials on a new or
17938
+ * existing broker and answers `{ brokerId }`; `POST {basePath}/cancel`
17939
+ * (`{ sessionId }`) drops the session. The dialog that edits a broker
17940
+ * offers it as the default path; the fields the session fills are
17941
+ * marked `filledBySignIn` in the kind's settings schema.
17942
+ */
17943
+ signIn: object({ basePath: string().min(1) }).optional()
17722
17944
  }))
17723
17945
  });
17724
17946
  var ListInputSchema = object({
@@ -18717,7 +18939,8 @@ var CompositionProblemSchema = object({
18717
18939
  "native-capability-replace",
18718
18940
  "mixed-quantity",
18719
18941
  "helper-mismatch",
18720
- "member-constraint"
18942
+ "member-constraint",
18943
+ "retention"
18721
18944
  ]),
18722
18945
  path: string(),
18723
18946
  message: string()
@@ -18951,13 +19174,17 @@ Object.freeze({
18951
19174
  latchedAt: {
18952
19175
  kind: "fixed",
18953
19176
  result: ["number", "null"]
19177
+ },
19178
+ schmitt: {
19179
+ kind: "fixed",
19180
+ result: ["boolean", "null"]
18954
19181
  }
18955
19182
  });
18956
19183
  /**
18957
19184
  * One catalog row per base reading a group helper can build (D944 §3).
18958
19185
  * Data, not a form default written into the block.
18959
19186
  */
18960
- var NOW = {
19187
+ var NOW$2 = {
18961
19188
  fieldPath: "lastFetchedAt",
18962
19189
  expr: "now"
18963
19190
  };
@@ -18971,6 +19198,8 @@ function numeric(input) {
18971
19198
  family: "numeric",
18972
19199
  deviceType: DeviceType.Sensor,
18973
19200
  memberDeviceType: DeviceType.Sensor,
19201
+ memberDeviceTypes: [DeviceType.Sensor],
19202
+ activeWhen: void 0,
18974
19203
  commandCaps: [],
18975
19204
  baseUnit: baseUnitOf(input.quantity),
18976
19205
  aggregates: NUMERIC_AGGREGATES,
@@ -18986,6 +19215,8 @@ function binary(input) {
18986
19215
  family: "binary",
18987
19216
  deviceType: DeviceType.Sensor,
18988
19217
  memberDeviceType: DeviceType.Sensor,
19218
+ memberDeviceTypes: [DeviceType.Sensor],
19219
+ activeWhen: void 0,
18989
19220
  commandCaps: [],
18990
19221
  quantity: "none",
18991
19222
  baseUnit: void 0,
@@ -19003,7 +19234,7 @@ var GROUP_TEMPLATES = [
19003
19234
  quantity: "temperature",
19004
19235
  defaultAggregate: "mean",
19005
19236
  empty: "null",
19006
- companions: [NOW]
19237
+ companions: [NOW$2]
19007
19238
  }),
19008
19239
  numeric({
19009
19240
  id: "humidity",
@@ -19014,7 +19245,7 @@ var GROUP_TEMPLATES = [
19014
19245
  quantity: "humidity",
19015
19246
  defaultAggregate: "mean",
19016
19247
  empty: "null",
19017
- companions: [NOW]
19248
+ companions: [NOW$2]
19018
19249
  }),
19019
19250
  numeric({
19020
19251
  id: "pressure",
@@ -19025,7 +19256,7 @@ var GROUP_TEMPLATES = [
19025
19256
  quantity: "pressure",
19026
19257
  defaultAggregate: "mean",
19027
19258
  empty: "null",
19028
- companions: [NOW]
19259
+ companions: [NOW$2]
19029
19260
  }),
19030
19261
  numeric({
19031
19262
  id: "illuminance",
@@ -19036,7 +19267,7 @@ var GROUP_TEMPLATES = [
19036
19267
  quantity: "illuminance",
19037
19268
  defaultAggregate: "mean",
19038
19269
  empty: "null",
19039
- companions: [NOW]
19270
+ companions: [NOW$2]
19040
19271
  }),
19041
19272
  numeric({
19042
19273
  id: "power",
@@ -19047,7 +19278,7 @@ var GROUP_TEMPLATES = [
19047
19278
  quantity: "power",
19048
19279
  defaultAggregate: "sum",
19049
19280
  empty: "omit",
19050
- companions: [NOW]
19281
+ companions: [NOW$2]
19051
19282
  }),
19052
19283
  numeric({
19053
19284
  id: "energy",
@@ -19058,7 +19289,7 @@ var GROUP_TEMPLATES = [
19058
19289
  quantity: "energy",
19059
19290
  defaultAggregate: "sum",
19060
19291
  empty: "omit",
19061
- companions: [NOW]
19292
+ companions: [NOW$2]
19062
19293
  }),
19063
19294
  numeric({
19064
19295
  id: "battery",
@@ -19093,7 +19324,7 @@ var GROUP_TEMPLATES = [
19093
19324
  quantity: "device",
19094
19325
  defaultAggregate: "mean",
19095
19326
  empty: "null",
19096
- companions: [NOW]
19327
+ companions: [NOW$2]
19097
19328
  }),
19098
19329
  binary({
19099
19330
  id: "motion",
@@ -19187,6 +19418,11 @@ var GROUP_TEMPLATES = [
19187
19418
  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.",
19188
19419
  deviceType: DeviceType.Switch,
19189
19420
  outputCap: "switch",
19421
+ outputField: "on",
19422
+ member: {
19423
+ cap: "switch",
19424
+ fieldPath: "on"
19425
+ },
19190
19426
  commandCaps: ["switch"]
19191
19427
  }),
19192
19428
  actuator({
@@ -19194,34 +19430,136 @@ var GROUP_TEMPLATES = [
19194
19430
  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.",
19195
19431
  deviceType: DeviceType.Light,
19196
19432
  outputCap: "switch",
19433
+ outputField: "on",
19434
+ member: {
19435
+ cap: "switch",
19436
+ fieldPath: "on"
19437
+ },
19197
19438
  commandCaps: [
19198
19439
  "switch",
19199
19440
  "brightness",
19200
19441
  "color"
19201
19442
  ]
19443
+ }),
19444
+ actuator({
19445
+ id: "fan",
19446
+ 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.",
19447
+ deviceType: DeviceType.Fan,
19448
+ outputCap: "switch",
19449
+ outputField: "on",
19450
+ member: {
19451
+ cap: "switch",
19452
+ fieldPath: "on"
19453
+ },
19454
+ commandCaps: ["switch", "fan-control"]
19455
+ }),
19456
+ actuator({
19457
+ id: "cover",
19458
+ 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.",
19459
+ deviceType: DeviceType.Cover,
19460
+ outputCap: "group-active",
19461
+ outputField: "active",
19462
+ member: {
19463
+ cap: "cover",
19464
+ fieldPath: "state"
19465
+ },
19466
+ activeWhen: [
19467
+ "open",
19468
+ "opening",
19469
+ "stopped"
19470
+ ],
19471
+ commandCaps: ["cover"]
19472
+ }),
19473
+ actuator({
19474
+ id: "valve",
19475
+ 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.",
19476
+ deviceType: DeviceType.Valve,
19477
+ outputCap: "group-active",
19478
+ outputField: "active",
19479
+ member: {
19480
+ cap: "valve",
19481
+ fieldPath: "state"
19482
+ },
19483
+ activeWhen: [
19484
+ "open",
19485
+ "opening",
19486
+ "stopped"
19487
+ ],
19488
+ commandCaps: ["valve"]
19489
+ }),
19490
+ actuator({
19491
+ id: "lock",
19492
+ 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.",
19493
+ deviceType: DeviceType.Lock,
19494
+ outputCap: "group-active",
19495
+ outputField: "active",
19496
+ member: {
19497
+ cap: "lock-control",
19498
+ fieldPath: "state"
19499
+ },
19500
+ activeWhen: ["locked"],
19501
+ commandCaps: ["lock-control"]
19502
+ }),
19503
+ actuator({
19504
+ id: "media-player",
19505
+ 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.",
19506
+ deviceType: DeviceType.MediaPlayer,
19507
+ outputCap: "group-active",
19508
+ outputField: "active",
19509
+ member: {
19510
+ cap: "media-player",
19511
+ fieldPath: "state"
19512
+ },
19513
+ activeWhen: ["playing", "buffering"],
19514
+ commandCaps: ["media-player"]
19515
+ }),
19516
+ actuator({
19517
+ id: "climate",
19518
+ 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.",
19519
+ deviceType: DeviceType.Thermostat,
19520
+ memberDeviceTypes: [DeviceType.Thermostat, DeviceType.Climate],
19521
+ outputCap: "group-active",
19522
+ outputField: "active",
19523
+ member: {
19524
+ cap: "climate-control",
19525
+ fieldPath: "mode"
19526
+ },
19527
+ activeWhen: [
19528
+ "heat",
19529
+ "cool",
19530
+ "auto",
19531
+ "heat_cool",
19532
+ "fan_only",
19533
+ "dry"
19534
+ ],
19535
+ commandCaps: ["climate-control"]
19202
19536
  })
19203
19537
  ];
19204
19538
  function actuator(input) {
19205
19539
  return {
19206
- ...input,
19540
+ id: input.id,
19541
+ summary: input.summary,
19542
+ deviceType: input.deviceType,
19543
+ outputCap: input.outputCap,
19544
+ outputField: input.outputField,
19545
+ commandCaps: input.commandCaps,
19207
19546
  family: "actuator",
19208
19547
  role: void 0,
19209
19548
  memberDeviceType: input.deviceType,
19210
- outputField: "on",
19549
+ memberDeviceTypes: input.memberDeviceTypes ?? [input.deviceType],
19550
+ activeWhen: input.activeWhen,
19211
19551
  quantity: "none",
19212
19552
  baseUnit: void 0,
19213
19553
  aggregates: BINARY_AGGREGATES,
19214
19554
  defaultAggregate: "any",
19215
19555
  empty: "offline",
19216
- accept: [{
19217
- cap: "switch",
19218
- fieldPath: "on"
19219
- }],
19556
+ accept: [input.member],
19220
19557
  companions: [CHANGED]
19221
19558
  };
19222
19559
  }
19223
19560
  new Map(GROUP_TEMPLATES.map((template) => [template.id, template]));
19224
19561
  DeviceFeature.LightColorRgb, DeviceFeature.LightColorHsv, DeviceFeature.LightColorMired;
19562
+ DeviceType.Camera;
19225
19563
  `${COMPOSED_DEVICE_STABLE_ID_PREFIX}`;
19226
19564
  /**
19227
19565
  * What a composition may BUILD on a device type (G2, D676): the caps a new
@@ -44317,7 +44655,7 @@ var NetworkAccessStatusSchema = object({
44317
44655
  });
44318
44656
  /**
44319
44657
  * Optional, richer endpoint shape returned by providers that expose
44320
- * MORE than one ingress concurrently (Tailscale Ingress with mixed
44658
+ * MORE than one ingress concurrently (Tailscale Funnel with mixed
44321
44659
  * serve+funnel rules, future ngrok multi-tunnel, …). Each entry carries
44322
44660
  * the originating provider config (mode + sourcePort) so the
44323
44661
  * orchestrator UI can label rows distinctly. Providers that expose only
@@ -46960,7 +47298,20 @@ var NcRuleInputSchema = object({
46960
47298
  * save by the hub's grouping guard). `.optional()`, never `.default()`: the addon cap
46961
47299
  * path does not run Zod defaults.
46962
47300
  */
46963
- groupingSec: number().int().min(5).max(60).optional()
47301
+ groupingSec: number().int().min(5).max(60).optional(),
47302
+ /**
47303
+ * ASK ME TO CONFIRM DETECTIONS (#243): a DETECTION notification of this rule
47304
+ * carries "Correct" / "Wrong" buttons (and, where the channel has room, a
47305
+ * "Wrong, it is a <class>" choice). A tap marks the track for retraining, the
47306
+ * same mark the Library writes, and records whose notification it was and
47307
+ * when. A channel with no buttons gets the same two choices as links.
47308
+ *
47309
+ * `.optional()`, never `.default()` (a Zod default does not run on the addon
47310
+ * cap path): absent and `false` both mean off, which is what every rule
47311
+ * authored before this field meant. An editor turns it off by writing
47312
+ * `false`, so it needs no `clear` key.
47313
+ */
47314
+ askVerdict: boolean().optional()
46964
47315
  });
46965
47316
  /**
46966
47317
  * Partial patch for `updateRule` — any subset of the input fields, plus the
@@ -57614,7 +57965,7 @@ var BatteryStatusSchema = object({
57614
57965
  */
57615
57966
  binary: boolean().optional().meta({ label: "Binary indicator" })
57616
57967
  });
57617
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat;
57968
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.EventEmitter;
57618
57969
  method(object({
57619
57970
  deviceId: number(),
57620
57971
  /** Bound on the wait. Sensible range 3000–10000ms. */
@@ -59382,7 +59733,13 @@ results: array(object({
59382
59733
  /** Ms epoch of the attempt. */
59383
59734
  at: number()
59384
59735
  })) });
59385
- DeviceType.Switch, DeviceType.Light;
59736
+ DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Cover, DeviceType.Valve, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.Thermostat, DeviceType.Climate;
59737
+ object({
59738
+ active: boolean().meta({ label: "Active" }),
59739
+ /** Ms epoch when the slice was last updated. */
59740
+ lastChangedAt: number()
59741
+ });
59742
+ DeviceType.Cover, DeviceType.Valve, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.Climate, DeviceType.Thermostat;
59386
59743
  object({
59387
59744
  /** Members whose current value entered the aggregate. */
59388
59745
  included: number().int().nonnegative().meta(readingMeta("count", {
@@ -59400,7 +59757,7 @@ object({
59400
59757
  label: "Members"
59401
59758
  }))
59402
59759
  });
59403
- DeviceType.Sensor, DeviceType.Switch, DeviceType.Light;
59760
+ DeviceType.Sensor, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Cover, DeviceType.Valve, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.Thermostat, DeviceType.Climate;
59404
59761
  object({
59405
59762
  /** Radiator valve opening 0 (closed) .. 100 (open). Null = not yet known. */
59406
59763
  position: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
@@ -60315,7 +60672,14 @@ DeviceType.Lock, method(object({
60315
60672
  auth: "protected"
60316
60673
  }), method(object({
60317
60674
  deviceId: number().int().nonnegative(),
60318
- code: string().min(1).optional()
60675
+ code: string().min(1).optional(),
60676
+ /**
60677
+ * Honoured by a helper lock GROUP only (D944): unlocking several doors
60678
+ * with one call is refused unless the caller says it was confirmed. A
60679
+ * single lock ignores it. The refusal lives in the callee, so no
60680
+ * automation or API caller reaches the doors by skipping a dialog.
60681
+ */
60682
+ confirm: boolean().optional()
60319
60683
  }), _void(), {
60320
60684
  kind: "mutation",
60321
60685
  auth: "protected"
@@ -60323,6 +60687,11 @@ DeviceType.Lock, method(object({
60323
60687
  kind: "mutation",
60324
60688
  auth: "protected"
60325
60689
  });
60690
+ object({
60691
+ value: number().nullable().meta(readingMeta("device", { label: "Total" })),
60692
+ lastFetchedAt: number()
60693
+ });
60694
+ DeviceType.Sensor;
60326
60695
  /**
60327
60696
  * Media-player cap. Models HA `media_player.*` (Sonos, Chromecast,
60328
60697
  * Apple TV, Spotify, Roku, generic OTT receivers, …) on
@@ -62230,9 +62599,9 @@ object({
62230
62599
  /** Cumulative energy in kilowatt-hours since the meter was reset. */
62231
62600
  kwhTotal: number().optional().meta(readingMeta("energy", { label: "Energy" })),
62232
62601
  /** Voltage in volts. */
62233
- volts: number().optional().meta(readingMeta("voltage")),
62602
+ volts: number().optional().meta(readingMeta("voltage", { label: "Voltage" })),
62234
62603
  /** Current in amperes. */
62235
- amps: number().optional().meta(readingMeta("current")),
62604
+ amps: number().optional().meta(readingMeta("current", { label: "Current" })),
62236
62605
  /** Apparent power in volt-amperes. */
62237
62606
  va: number().optional().meta(readingMeta("apparent-power")),
62238
62607
  /** Power factor (0..1) if reported. */
@@ -62240,7 +62609,23 @@ object({
62240
62609
  /** Ms epoch when the slice was last updated. */
62241
62610
  lastFetchedAt: number()
62242
62611
  });
62243
- DeviceType.Sensor;
62612
+ [
62613
+ DeviceType.Sensor,
62614
+ DeviceType.Switch,
62615
+ DeviceType.Light,
62616
+ DeviceType.Fan,
62617
+ DeviceType.Climate,
62618
+ DeviceType.Thermostat,
62619
+ DeviceType.Humidifier,
62620
+ DeviceType.WaterHeater,
62621
+ DeviceType.MediaPlayer,
62622
+ DeviceType.Washer,
62623
+ DeviceType.Dryer,
62624
+ DeviceType.Dishwasher,
62625
+ DeviceType.Vacuum,
62626
+ DeviceType.LawnMower,
62627
+ DeviceType.PetFeeder
62628
+ ].filter((type) => type !== DeviceType.Sensor);
62244
62629
  /**
62245
62630
  * Presence cap. Models HA `person.*` and `device_tracker.*` entities
62246
62631
  * on `DeviceType.Presence`. Read-only — no setters: presence is
@@ -62687,7 +63072,7 @@ object({
62687
63072
  phase: string().nullable()
62688
63073
  });
62689
63074
  Object.values(DeviceType);
62690
- DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
63075
+ DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
62691
63076
  DeviceType.Camera, DeviceType.Sensor, DeviceType.Switch, method(object({ deviceId: number().int().nonnegative() }), object({ success: literal(true) }), {
62692
63077
  kind: "mutation",
62693
63078
  auth: "admin"
@@ -64735,7 +65120,7 @@ object({
64735
65120
  /** Ms epoch of the last state change. Useful for UI "X minutes ago". */
64736
65121
  lastChangedAt: number()
64737
65122
  });
64738
- DeviceType.Switch, DeviceType.Siren, DeviceType.Light, method(object({
65123
+ DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, method(object({
64739
65124
  deviceId: number(),
64740
65125
  on: boolean()
64741
65126
  }), _void(), {
@@ -66439,8 +66824,9 @@ method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" })
66439
66824
  kind: "mutation",
66440
66825
  auth: "admin"
66441
66826
  });
66827
+ DeviceFeature.FanSpeed, DeviceFeature.FanPreset, DeviceFeature.FanDirection, DeviceFeature.FanOscillating, DeviceFeature.CoverPositionable, DeviceFeature.CoverTilt, DeviceFeature.ValvePositionable, DeviceFeature.MediaPlayerVolume, DeviceFeature.ClimateFanMode;
66442
66828
  SOURCE_CAPS.filter((cap) => cap !== "switch" && cap !== "motion");
66443
- 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;
66829
+ 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;
66444
66830
  String.raw`rose\(active(\d+), changed(\d+), (\d+(?:\.\d+)?)\)`;
66445
66831
  DeviceRole.BinarySensor, DeviceRole.MotionSensor;
66446
66832
  new Set(CAP_NAMES);
@@ -66493,7 +66879,7 @@ var AccessoryKind = {
66493
66879
  PrivacyMask: DeviceRole.PrivacyMask
66494
66880
  };
66495
66881
  AccessoryKind.Siren, AccessoryKind.Floodlight, AccessoryKind.Spotlight, AccessoryKind.PirSensor, AccessoryKind.Chime, AccessoryKind.Autotrack, AccessoryKind.Nightvision, AccessoryKind.PrivacyMask;
66496
- 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;
66882
+ 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;
66497
66883
  new Set(Object.values(DeviceType));
66498
66884
  Object.freeze({
66499
66885
  "accessories.getStatus": {
@@ -69716,6 +70102,13 @@ Object.freeze({
69716
70102
  access: "view",
69717
70103
  role: "viewer"
69718
70104
  },
70105
+ "groupActive.getStatus": {
70106
+ capName: "group-active",
70107
+ capScope: "device",
70108
+ addonId: null,
70109
+ access: "view",
70110
+ role: "viewer"
70111
+ },
69719
70112
  "groupCommands.getStatus": {
69720
70113
  capName: "group-commands",
69721
70114
  capScope: "device",
@@ -70682,6 +71075,13 @@ Object.freeze({
70682
71075
  access: "create",
70683
71076
  role: "admin"
70684
71077
  },
71078
+ "meter.getStatus": {
71079
+ capName: "meter",
71080
+ capScope: "device",
71081
+ addonId: null,
71082
+ access: "view",
71083
+ role: "viewer"
71084
+ },
70685
71085
  "metricsProvider.collectSnapshot": {
70686
71086
  capName: "metrics-provider",
70687
71087
  capScope: "system",
@@ -78780,7 +79180,39 @@ var APPLIANCE_CAP_VOCABULARY = {
78780
79180
  phrase: t("When {device} finishes", "Quando {device} finisce"),
78781
79181
  icon: "square"
78782
79182
  }
78783
- }
79183
+ },
79184
+ overrides: { byType: {
79185
+ [DeviceType.Washer]: {
79186
+ state: { running: {
79187
+ whenTrue: t("When the washing machine starts", "Quando la lavatrice inizia"),
79188
+ whenFalse: t("When the washing machine has finished", "Quando la lavatrice ha finito")
79189
+ } },
79190
+ events: {
79191
+ onStarted: { phrase: t("When the washing machine starts", "Quando la lavatrice inizia") },
79192
+ onFinished: { phrase: t("When the washing machine has finished", "Quando la lavatrice ha finito") }
79193
+ }
79194
+ },
79195
+ [DeviceType.Dryer]: {
79196
+ state: { running: {
79197
+ whenTrue: t("When the dryer starts", "Quando l'asciugatrice inizia"),
79198
+ whenFalse: t("When the dryer has finished", "Quando l'asciugatrice ha finito")
79199
+ } },
79200
+ events: {
79201
+ onStarted: { phrase: t("When the dryer starts", "Quando l'asciugatrice inizia") },
79202
+ onFinished: { phrase: t("When the dryer has finished", "Quando l'asciugatrice ha finito") }
79203
+ }
79204
+ },
79205
+ [DeviceType.Dishwasher]: {
79206
+ state: { running: {
79207
+ whenTrue: t("When the dishwasher starts", "Quando la lavastoviglie inizia"),
79208
+ whenFalse: t("When the dishwasher has finished", "Quando la lavastoviglie ha finito")
79209
+ } },
79210
+ events: {
79211
+ onStarted: { phrase: t("When the dishwasher starts", "Quando la lavastoviglie inizia") },
79212
+ onFinished: { phrase: t("When the dishwasher has finished", "Quando la lavastoviglie ha finito") }
79213
+ }
79214
+ }
79215
+ } }
78784
79216
  },
78785
79217
  update: {
78786
79218
  scope: "device",
@@ -79552,6 +79984,10 @@ var SENSOR_CAP_VOCABULARY = {
79552
79984
  icon: "flame"
79553
79985
  }]
79554
79986
  },
79987
+ "group-active": {
79988
+ scope: "device",
79989
+ noun: t("Group state", "Stato del gruppo")
79990
+ },
79555
79991
  "group-commands": {
79556
79992
  scope: "device",
79557
79993
  noun: t("Group command", "Comando di gruppo")
@@ -79608,6 +80044,17 @@ var SENSOR_CAP_VOCABULARY = {
79608
80044
  }],
79609
80045
  events: { onMotionChanged: { notOperatorFacing: "the `detected` state trigger phrases both edges, from the mirror that survives a dropped event (D49)" } }
79610
80046
  },
80047
+ meter: {
80048
+ scope: "device",
80049
+ noun: t("Meter", "Contatore"),
80050
+ state: [{
80051
+ kind: "numeric",
80052
+ field: "value",
80053
+ quantity: t("the total", "il totale"),
80054
+ label: t("Total", "Totale"),
80055
+ icon: "gauge"
80056
+ }]
80057
+ },
79611
80058
  "numeric-sensor": {
79612
80059
  scope: "device",
79613
80060
  noun: t("Sensor", "Sensore"),
@@ -80080,8 +80527,72 @@ function projectAction(cap, action) {
80080
80527
  };
80081
80528
  }
80082
80529
  Object.entries(CAP_VOCABULARY_BY_NAME).flatMap(([cap, entry]) => entry.scope === "device" ? (entry.actions ?? []).map((a) => projectAction(cap, a)) : []);
80083
- 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;
80530
+ 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;
80084
80531
  DeviceFeature.BatteryOperated;
80532
+ /**
80533
+ * How a washer, dryer or dishwasher leaves CamStack.
80534
+ *
80535
+ * Home Assistant has no laundry domain: the device is offered, and what
80536
+ * travels is its power reading. The others have a laundry type that this
80537
+ * export cannot honour yet, so they are named and withheld.
80538
+ */
80539
+ var PLUG_APPLIANCE_TYPES = [
80540
+ DeviceType.Washer,
80541
+ DeviceType.Dryer,
80542
+ DeviceType.Dishwasher
80543
+ ];
80544
+ 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.";
80545
+ 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.";
80546
+ var ALEXA_REASON = "Alexa has no laundry category in this export, and neither power nor running has an Alexa interface.";
80547
+ var GOOGLE_REASON = "Google WASHER, DRYER and DISHWASHER require RunCycle. A power threshold is not that trait, and this export does not publish RunCycle.";
80548
+ 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.";
80549
+ function withheld(reason) {
80550
+ return {
80551
+ [DeviceType.Washer]: {
80552
+ exported: false,
80553
+ reason
80554
+ },
80555
+ [DeviceType.Dryer]: {
80556
+ exported: false,
80557
+ reason
80558
+ },
80559
+ [DeviceType.Dishwasher]: {
80560
+ exported: false,
80561
+ reason
80562
+ }
80563
+ };
80564
+ }
80565
+ function offered(received) {
80566
+ return {
80567
+ [DeviceType.Washer]: {
80568
+ exported: true,
80569
+ as: received
80570
+ },
80571
+ [DeviceType.Dryer]: {
80572
+ exported: true,
80573
+ as: received
80574
+ },
80575
+ [DeviceType.Dishwasher]: {
80576
+ exported: true,
80577
+ as: received
80578
+ }
80579
+ };
80580
+ }
80581
+ var APPLIANCE_EXPORT = {
80582
+ ha: offered(HA_AS),
80583
+ homekit: withheld(HOMEKIT_REASON),
80584
+ alexa: withheld(ALEXA_REASON),
80585
+ google: withheld(GOOGLE_REASON),
80586
+ matter: withheld(MATTER_REASON)
80587
+ };
80588
+ function isPlugApplianceType(deviceType) {
80589
+ return PLUG_APPLIANCE_TYPES.some((type) => type === deviceType);
80590
+ }
80591
+ /** The decision for this ecosystem, or null when the type is not an appliance. */
80592
+ function applianceExport(ecosystem, deviceType) {
80593
+ if (!isPlugApplianceType(deviceType)) return null;
80594
+ return APPLIANCE_EXPORT[ecosystem][deviceType];
80595
+ }
80085
80596
  Object.freeze({
80086
80597
  "accessories.getStatus": [{
80087
80598
  name: "deviceId",
@@ -81048,6 +81559,11 @@ Object.freeze({
81048
81559
  form: "single",
81049
81560
  optional: false
81050
81561
  }],
81562
+ "groupActive.getStatus": [{
81563
+ name: "deviceId",
81564
+ form: "single",
81565
+ optional: false
81566
+ }],
81051
81567
  "groupCommands.getStatus": [{
81052
81568
  name: "deviceId",
81053
81569
  form: "single",
@@ -81258,6 +81774,11 @@ Object.freeze({
81258
81774
  form: "single",
81259
81775
  optional: false
81260
81776
  }],
81777
+ "meter.getStatus": [{
81778
+ name: "deviceId",
81779
+ form: "single",
81780
+ optional: false
81781
+ }],
81261
81782
  "motion.getStatus": [{
81262
81783
  name: "deviceId",
81263
81784
  form: "single",
@@ -82865,7 +83386,6 @@ Object.freeze({
82865
83386
  "network-access": "ingress",
82866
83387
  "smtp-provider": "email"
82867
83388
  });
82868
- DeviceType.Camera;
82869
83389
  /**
82870
83390
  * A saved Customize assignment (D936). The schema is the type: callers use
82871
83391
  * `z.infer`, they do not restate the shape.
@@ -149367,6 +149887,8 @@ var HAP_EXPORTABLE_DEVICE_TYPES = [
149367
149887
  function pickMapperKind(deviceType) {
149368
149888
  if (deviceType === null || deviceType === void 0 || deviceType.length === 0) return "camera";
149369
149889
  if (deviceType === DeviceType.Camera) return "camera";
149890
+ const withheld = applianceExport("homekit", deviceType);
149891
+ if (withheld !== null && !withheld.exported) return null;
149370
149892
  return HAP_EXPORTABLE_DEVICE_TYPES.find((type) => type === deviceType) === void 0 ? null : "generic";
149371
149893
  }
149372
149894
  /**