@camstack/addon-provider-homeassistant 1.2.601 → 1.2.603

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.
@@ -5538,7 +5538,7 @@ var ZodIssueCode = {
5538
5538
  var ZodFirstPartyTypeKind;
5539
5539
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5540
5540
  //#endregion
5541
- //#region ../types/dist/sleep-bZIhUvjd.mjs
5541
+ //#region ../types/dist/sleep-BegKjwUu.mjs
5542
5542
  /**
5543
5543
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5544
5544
  * window to float samples (D455).
@@ -8816,7 +8816,7 @@ object({
8816
8816
  params: record(string(), union([string(), number()])).optional()
8817
8817
  });
8818
8818
  //#endregion
8819
- //#region ../types/dist/err-msg--2RrYiLO.mjs
8819
+ //#region ../types/dist/err-msg-BXKzRBwg.mjs
8820
8820
  var DeviceType = /* @__PURE__ */ function(DeviceType) {
8821
8821
  DeviceType["Camera"] = "camera";
8822
8822
  DeviceType["Hub"] = "hub";
@@ -8908,6 +8908,10 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
8908
8908
  * native PetKit (`nodepetkit` `FeederDevice`), reusable by other feeder
8909
8909
  * integrations sharing the same food/desiccant/hopper surface. */
8910
8910
  DeviceType["PetFeeder"] = "pet-feeder";
8911
+ /** Built-in dishwasher — program lifecycle, door / remote-start gates,
8912
+ * salt and rinse-aid levels. Installed with the `dishwasher` cap.
8913
+ * Sources: native Bosch Home Connect, reusable by similar integrations. */
8914
+ DeviceType["Dishwasher"] = "dishwasher";
8911
8915
  return DeviceType;
8912
8916
  }({});
8913
8917
  var DeviceFeature = /* @__PURE__ */ function(DeviceFeature) {
@@ -9165,7 +9169,7 @@ function errMsg(err) {
9165
9169
  return String(err);
9166
9170
  }
9167
9171
  //#endregion
9168
- //#region ../types/dist/composition-DOwQB_Ua.mjs
9172
+ //#region ../types/dist/composition-CB6PMT9p.mjs
9169
9173
  /**
9170
9174
  * The ffmpeg build every CamStack node downloads, per platform and arch.
9171
9175
  *
@@ -13714,8 +13718,13 @@ var AlertSeveritySchema = _enum([
13714
13718
  "info",
13715
13719
  "success",
13716
13720
  "warning",
13717
- "error"
13721
+ "error",
13722
+ "critical"
13718
13723
  ]);
13724
+ var AlertActionSchema = object({
13725
+ label: string(),
13726
+ href: string().optional()
13727
+ });
13719
13728
  var AlertStatusSchema = _enum([
13720
13729
  "active",
13721
13730
  "in-progress",
@@ -13733,6 +13742,7 @@ var AlertSchema = object({
13733
13742
  severity: AlertSeveritySchema,
13734
13743
  title: string(),
13735
13744
  message: string(),
13745
+ action: AlertActionSchema.optional(),
13736
13746
  status: AlertStatusSchema,
13737
13747
  progress: number().optional(),
13738
13748
  read: boolean(),
@@ -18335,7 +18345,11 @@ var deviceDiscoveryCapability = {
18335
18345
  };
18336
18346
  /**
18337
18347
  * `device-adoption` — generic discovery + adoption surface,
18338
- * system-scoped singleton. The de-HA-ified successor to `ha-discovery`:
18348
+ * system-scoped collection (one provider per integration addon), routed
18349
+ * by explicit `{ addonId }` on direct `deviceAdoption.*` calls — the same
18350
+ * pin model as `connection-test`. The admin UI keeps using
18351
+ * `deviceManager.adoption*` (which already threads `addonId`). The de-HA-ified
18352
+ * successor to `ha-discovery`:
18339
18353
  * keyed by `integrationId` (the addon resolves integrationId → broker
18340
18354
  * internally) rather than a connection-specific `brokerId`, and it
18341
18355
  * REUSES the shared `DiscoveredChildDevice` candidate type from
@@ -18500,7 +18514,7 @@ var ResyncResultSchema = object({
18500
18514
  var deviceAdoptionCapability = {
18501
18515
  name: "device-adoption",
18502
18516
  scope: "system",
18503
- mode: "singleton",
18517
+ mode: "collection",
18504
18518
  status: {
18505
18519
  schema: AdoptionStatusSchema,
18506
18520
  kind: "poll"
@@ -54667,7 +54681,8 @@ var batteryCapability = {
54667
54681
  DeviceType.Button,
54668
54682
  DeviceType.Switch,
54669
54683
  DeviceType.PetFeeder,
54670
- DeviceType.Container
54684
+ DeviceType.Container,
54685
+ DeviceType.Thermostat
54671
54686
  ],
54672
54687
  methods: {
54673
54688
  /**
@@ -56167,6 +56182,161 @@ onStatusChanged: { data: object({
56167
56182
  * whether persisting is worth a SQLite commit. */
56168
56183
  volatileStateFields: ["lastChangedAt"]
56169
56184
  };
56185
+ /**
56186
+ * Smart-dishwasher cap — program lifecycle, door / remote-start gates,
56187
+ * consumable levels (salt, rinse aid) and common program options.
56188
+ *
56189
+ * Sources: native Bosch Home Connect (`dishwasher` device type). Reusable
56190
+ * by any integration that exposes the same program / option surface.
56191
+ *
56192
+ * `kind: 'poll'` — cloud REST APIs typically have no push channel; the
56193
+ * provider refreshes the slice on an interval and eagerly after commands.
56194
+ */
56195
+ var DishwasherStateSchema = _enum([
56196
+ "idle",
56197
+ "running",
56198
+ "paused",
56199
+ "finished",
56200
+ "error",
56201
+ "unavailable"
56202
+ ]);
56203
+ var DishwasherConsumableLevelSchema = _enum([
56204
+ "ok",
56205
+ "low",
56206
+ "empty"
56207
+ ]);
56208
+ var DishwasherStatusSchema = object({
56209
+ state: DishwasherStateSchema,
56210
+ /** Active program id/name, or null when none selected / unknown. */
56211
+ program: string().nullable(),
56212
+ /** Program tokens the hardware accepts — drives the UI selector. */
56213
+ availablePrograms: array(string()),
56214
+ /** Minutes remaining on the active cycle, or null when not running. */
56215
+ remainingMinutes: number().int().nonnegative().nullable(),
56216
+ /** Cycle completion 0..100, or null when not applicable. */
56217
+ progressPercent: number().min(0).max(100).nullable(),
56218
+ /** True when the door is reported open. */
56219
+ doorOpen: boolean(),
56220
+ /** True when remote start is allowed (door closed, power on, etc.). */
56221
+ remoteStartAllowed: boolean(),
56222
+ /** Main power / switched-on state. */
56223
+ powerOn: boolean(),
56224
+ saltLevel: DishwasherConsumableLevelSchema.nullable(),
56225
+ rinseAidLevel: DishwasherConsumableLevelSchema.nullable(),
56226
+ halfLoad: boolean(),
56227
+ hygienePlus: boolean(),
56228
+ /** Extra dry option when the appliance exposes it. */
56229
+ extraDry: boolean(),
56230
+ /** Intensive zone (lower basket) when the appliance exposes it. */
56231
+ intensiveZone: boolean(),
56232
+ /** VarioSpeed / VarioSpeed+ when the appliance exposes it. */
56233
+ varioSpeedPlus: boolean(),
56234
+ /** Child lock (controls disabled on the appliance). */
56235
+ childLock: boolean(),
56236
+ errorCode: number().nullable(),
56237
+ errorLabel: string().nullable(),
56238
+ lastFetchedAt: number()
56239
+ });
56240
+ var dishwasherCapability = {
56241
+ name: "dishwasher",
56242
+ scope: "device",
56243
+ deviceNative: true,
56244
+ mode: "singleton",
56245
+ deviceTypes: [DeviceType.Dishwasher],
56246
+ methods: {
56247
+ start: method(object({ deviceId: number().int().nonnegative() }), _void(), {
56248
+ kind: "mutation",
56249
+ auth: "protected"
56250
+ }),
56251
+ pause: method(object({ deviceId: number().int().nonnegative() }), _void(), {
56252
+ kind: "mutation",
56253
+ auth: "protected"
56254
+ }),
56255
+ stop: method(object({ deviceId: number().int().nonnegative() }), _void(), {
56256
+ kind: "mutation",
56257
+ auth: "protected"
56258
+ }),
56259
+ setProgram: method(object({
56260
+ deviceId: number().int().nonnegative(),
56261
+ program: string().min(1)
56262
+ }), _void(), {
56263
+ kind: "mutation",
56264
+ auth: "protected"
56265
+ }),
56266
+ setPower: method(object({
56267
+ deviceId: number().int().nonnegative(),
56268
+ on: boolean()
56269
+ }), _void(), {
56270
+ kind: "mutation",
56271
+ auth: "protected"
56272
+ }),
56273
+ setHalfLoad: method(object({
56274
+ deviceId: number().int().nonnegative(),
56275
+ on: boolean()
56276
+ }), _void(), {
56277
+ kind: "mutation",
56278
+ auth: "protected"
56279
+ }),
56280
+ setHygienePlus: method(object({
56281
+ deviceId: number().int().nonnegative(),
56282
+ on: boolean()
56283
+ }), _void(), {
56284
+ kind: "mutation",
56285
+ auth: "protected"
56286
+ }),
56287
+ setExtraDry: method(object({
56288
+ deviceId: number().int().nonnegative(),
56289
+ on: boolean()
56290
+ }), _void(), {
56291
+ kind: "mutation",
56292
+ auth: "protected"
56293
+ }),
56294
+ setIntensiveZone: method(object({
56295
+ deviceId: number().int().nonnegative(),
56296
+ on: boolean()
56297
+ }), _void(), {
56298
+ kind: "mutation",
56299
+ auth: "protected"
56300
+ }),
56301
+ setVarioSpeedPlus: method(object({
56302
+ deviceId: number().int().nonnegative(),
56303
+ on: boolean()
56304
+ }), _void(), {
56305
+ kind: "mutation",
56306
+ auth: "protected"
56307
+ }),
56308
+ setChildLock: method(object({
56309
+ deviceId: number().int().nonnegative(),
56310
+ on: boolean()
56311
+ }), _void(), {
56312
+ kind: "mutation",
56313
+ auth: "protected"
56314
+ }),
56315
+ setOption: method(object({
56316
+ deviceId: number().int().nonnegative(),
56317
+ key: string().min(1),
56318
+ value: union([
56319
+ boolean(),
56320
+ string(),
56321
+ number()
56322
+ ])
56323
+ }), _void(), {
56324
+ kind: "mutation",
56325
+ auth: "protected"
56326
+ })
56327
+ },
56328
+ status: {
56329
+ schema: DishwasherStatusSchema,
56330
+ kind: "poll"
56331
+ },
56332
+ runtimeState: DishwasherStatusSchema,
56333
+ durability: "session",
56334
+ history: { fields: { progressPercent: {
56335
+ kind: "gauge",
56336
+ unit: "%",
56337
+ deadband: 2
56338
+ } } }
56339
+ };
56170
56340
  var DoorbellStatusSchema = object({
56171
56341
  /** Ms epoch of the last press. null = never observed since this provider started. */
56172
56342
  lastPressedAt: number().nullable(),
@@ -56969,6 +57139,32 @@ var gasCapability = {
56969
57139
  * whether persisting is worth a SQLite commit. */
56970
57140
  volatileStateFields: ["lastChangedAt"]
56971
57141
  };
57142
+ var HeatingValveStatusSchema = object({
57143
+ /** Radiator valve opening 0 (closed) .. 100 (open). Null = not yet known. */
57144
+ position: number().min(0).max(100).nullable(),
57145
+ /** Ms epoch when the slice was last updated (push or poll). */
57146
+ lastFetchedAt: number()
57147
+ });
57148
+ var heatingValveCapability = {
57149
+ name: "heating-valve",
57150
+ scope: "device",
57151
+ deviceNative: true,
57152
+ mode: "singleton",
57153
+ deviceTypes: [DeviceType.Thermostat],
57154
+ methods: {},
57155
+ status: {
57156
+ schema: HeatingValveStatusSchema,
57157
+ kind: "push"
57158
+ },
57159
+ runtimeState: HeatingValveStatusSchema,
57160
+ durability: "session",
57161
+ history: { fields: { position: {
57162
+ kind: "gauge",
57163
+ unit: "%",
57164
+ deadband: 1
57165
+ } } },
57166
+ volatileStateFields: ["lastFetchedAt"]
57167
+ };
56972
57168
  /**
56973
57169
  * Humidifier / dehumidifier cap. Models HA `humidifier.*` entities —
56974
57170
  * an on/off actuator with an optional target-humidity setpoint and an
@@ -66389,6 +66585,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
66389
66585
  dayNight: dayNightCapability,
66390
66586
  deviceDiscovery: deviceDiscoveryCapability,
66391
66587
  deviceStatus: deviceStatusCapability,
66588
+ dishwasher: dishwasherCapability,
66392
66589
  doorbell: doorbellCapability,
66393
66590
  enumSensor: enumSensorCapability,
66394
66591
  eventEmitter: eventEmitterCapability,
@@ -66396,6 +66593,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
66396
66593
  featureProbe: featureProbeCapability,
66397
66594
  flood: floodCapability,
66398
66595
  gas: gasCapability,
66596
+ heatingValve: heatingValveCapability,
66399
66597
  humidifier: humidifierCapability,
66400
66598
  humiditySensor: humiditySensorCapability,
66401
66599
  image: imageCapability,
@@ -67121,6 +67319,12 @@ var BaseDeviceProvider = class extends BaseAddon {
67121
67319
  provider: this
67122
67320
  }];
67123
67321
  }
67322
+ /** Flatten `super.onInitialize()` whether it returned an array or an envelope. */
67323
+ providerRegistrationsFromSuper(result) {
67324
+ if (Array.isArray(result)) return result;
67325
+ if (result !== void 0 && result.providers !== void 0) return [...result.providers];
67326
+ return [];
67327
+ }
67124
67328
  async onShutdown() {
67125
67329
  this._restoreShuttingDown = true;
67126
67330
  this.cancelRestoreRetries();
@@ -67647,7 +67851,7 @@ var BaseDeviceProvider = class extends BaseAddon {
67647
67851
  return toDeviceSummary(device, this.addonId);
67648
67852
  }
67649
67853
  };
67650
- 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;
67854
+ 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;
67651
67855
  new Set(Object.values(DeviceType));
67652
67856
  Object.freeze({
67653
67857
  "accessories.getStatus": {
@@ -70068,6 +70272,84 @@ Object.freeze({
70068
70272
  addonId: null,
70069
70273
  access: "view"
70070
70274
  },
70275
+ "dishwasher.getStatus": {
70276
+ capName: "dishwasher",
70277
+ capScope: "device",
70278
+ addonId: null,
70279
+ access: "view"
70280
+ },
70281
+ "dishwasher.pause": {
70282
+ capName: "dishwasher",
70283
+ capScope: "device",
70284
+ addonId: null,
70285
+ access: "create"
70286
+ },
70287
+ "dishwasher.setChildLock": {
70288
+ capName: "dishwasher",
70289
+ capScope: "device",
70290
+ addonId: null,
70291
+ access: "create"
70292
+ },
70293
+ "dishwasher.setExtraDry": {
70294
+ capName: "dishwasher",
70295
+ capScope: "device",
70296
+ addonId: null,
70297
+ access: "create"
70298
+ },
70299
+ "dishwasher.setHalfLoad": {
70300
+ capName: "dishwasher",
70301
+ capScope: "device",
70302
+ addonId: null,
70303
+ access: "create"
70304
+ },
70305
+ "dishwasher.setHygienePlus": {
70306
+ capName: "dishwasher",
70307
+ capScope: "device",
70308
+ addonId: null,
70309
+ access: "create"
70310
+ },
70311
+ "dishwasher.setIntensiveZone": {
70312
+ capName: "dishwasher",
70313
+ capScope: "device",
70314
+ addonId: null,
70315
+ access: "create"
70316
+ },
70317
+ "dishwasher.setOption": {
70318
+ capName: "dishwasher",
70319
+ capScope: "device",
70320
+ addonId: null,
70321
+ access: "create"
70322
+ },
70323
+ "dishwasher.setPower": {
70324
+ capName: "dishwasher",
70325
+ capScope: "device",
70326
+ addonId: null,
70327
+ access: "create"
70328
+ },
70329
+ "dishwasher.setProgram": {
70330
+ capName: "dishwasher",
70331
+ capScope: "device",
70332
+ addonId: null,
70333
+ access: "create"
70334
+ },
70335
+ "dishwasher.setVarioSpeedPlus": {
70336
+ capName: "dishwasher",
70337
+ capScope: "device",
70338
+ addonId: null,
70339
+ access: "create"
70340
+ },
70341
+ "dishwasher.start": {
70342
+ capName: "dishwasher",
70343
+ capScope: "device",
70344
+ addonId: null,
70345
+ access: "create"
70346
+ },
70347
+ "dishwasher.stop": {
70348
+ capName: "dishwasher",
70349
+ capScope: "device",
70350
+ addonId: null,
70351
+ access: "create"
70352
+ },
70071
70353
  "doorbell.getStatus": {
70072
70354
  capName: "doorbell",
70073
70355
  capScope: "device",
@@ -70278,6 +70560,12 @@ Object.freeze({
70278
70560
  addonId: null,
70279
70561
  access: "view"
70280
70562
  },
70563
+ "heatingValve.getStatus": {
70564
+ capName: "heating-valve",
70565
+ capScope: "device",
70566
+ addonId: null,
70567
+ access: "view"
70568
+ },
70281
70569
  "humidifier.getStatus": {
70282
70570
  capName: "humidifier",
70283
70571
  capScope: "device",
@@ -75865,7 +76153,7 @@ Object.freeze({
75865
76153
  access: "create"
75866
76154
  }
75867
76155
  });
75868
- 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;
76156
+ 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;
75869
76157
  DeviceFeature.BatteryOperated;
75870
76158
  Object.freeze({
75871
76159
  "accessories.getStatus": [{
@@ -76689,6 +76977,71 @@ Object.freeze({
76689
76977
  form: "single",
76690
76978
  optional: false
76691
76979
  }],
76980
+ "dishwasher.getStatus": [{
76981
+ name: "deviceId",
76982
+ form: "single",
76983
+ optional: false
76984
+ }],
76985
+ "dishwasher.pause": [{
76986
+ name: "deviceId",
76987
+ form: "single",
76988
+ optional: false
76989
+ }],
76990
+ "dishwasher.setChildLock": [{
76991
+ name: "deviceId",
76992
+ form: "single",
76993
+ optional: false
76994
+ }],
76995
+ "dishwasher.setExtraDry": [{
76996
+ name: "deviceId",
76997
+ form: "single",
76998
+ optional: false
76999
+ }],
77000
+ "dishwasher.setHalfLoad": [{
77001
+ name: "deviceId",
77002
+ form: "single",
77003
+ optional: false
77004
+ }],
77005
+ "dishwasher.setHygienePlus": [{
77006
+ name: "deviceId",
77007
+ form: "single",
77008
+ optional: false
77009
+ }],
77010
+ "dishwasher.setIntensiveZone": [{
77011
+ name: "deviceId",
77012
+ form: "single",
77013
+ optional: false
77014
+ }],
77015
+ "dishwasher.setOption": [{
77016
+ name: "deviceId",
77017
+ form: "single",
77018
+ optional: false
77019
+ }],
77020
+ "dishwasher.setPower": [{
77021
+ name: "deviceId",
77022
+ form: "single",
77023
+ optional: false
77024
+ }],
77025
+ "dishwasher.setProgram": [{
77026
+ name: "deviceId",
77027
+ form: "single",
77028
+ optional: false
77029
+ }],
77030
+ "dishwasher.setVarioSpeedPlus": [{
77031
+ name: "deviceId",
77032
+ form: "single",
77033
+ optional: false
77034
+ }],
77035
+ "dishwasher.start": [{
77036
+ name: "deviceId",
77037
+ form: "single",
77038
+ optional: false
77039
+ }],
77040
+ "dishwasher.stop": [{
77041
+ name: "deviceId",
77042
+ form: "single",
77043
+ optional: false
77044
+ }],
76692
77045
  "doorbell.getStatus": [{
76693
77046
  name: "deviceId",
76694
77047
  form: "single",
@@ -76758,6 +77111,11 @@ Object.freeze({
76758
77111
  form: "single",
76759
77112
  optional: false
76760
77113
  }],
77114
+ "heatingValve.getStatus": [{
77115
+ name: "deviceId",
77116
+ form: "single",
77117
+ optional: false
77118
+ }],
76761
77119
  "humidifier.getStatus": [{
76762
77120
  name: "deviceId",
76763
77121
  form: "single",