@camstack/addon-provider-homeassistant 1.2.66 → 1.2.67
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/addon.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_dist = require("./dist-
|
|
2
|
+
const require_dist = require("./dist-B-VA4Gku.js");
|
|
3
3
|
let node_crypto = require("node:crypto");
|
|
4
4
|
let node_zlib = require("node:zlib");
|
|
5
5
|
//#region src/ha-device-source.ts
|
package/dist/addon.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as presenceCapability, A as controlCapability, At as EventCategory, B as humiditySensorCapability, C as buildAddonRouteProvider, Ct as number, D as colorCapability, Dt as union, E as climateControlCapability, Et as string, F as eventEmitterCapability, G as motionCapability, H as lawnMowerControlCapability, I as fanControlCapability, J as notifierCapability, K as normalizeUnit, L as floodCapability, M as deviceAdoptionCapability, O as connectivityCapability, Ot as unknown, P as enumSensorCapability, Q as prepareNotification, R as gasCapability, S as brokerCapability, St as literal, T as carbonMonoxideCapability, Tt as record, U as lockControlCapability, V as imageCapability, W as mediaPlayerCapability, Y as numericSensorCapability, Z as powerMeterCapability, _ as automationControlCapability, _t as createEvent, at as temperatureSensorCapability, b as binaryCapability, bt as array, ct as valveCapability, d as TargetSchema, dt as weatherCapability, et as pressureSensorCapability, f as accessoriesCapability, ft as errMsg, g as ambientLightSensorCapability, gt as DeviceType, h as alarmPanelCapability, ht as DeviceRole, it as tamperCapability, j as coverCapability, k as contactCapability, kt as url, lt as vibrationCapability, m as airQualitySensorCapability, mt as DeviceFeature, n as BaseDevice, nt as smokeCapability, ot as updateCapability, p as addonRoutesCapability, q as notificationOutputCapability, r as BaseDeviceProvider, rt as switchCapability, s as EnumSensorDateTimeFormatSchema, st as vacuumControlCapability, tt as scriptRunnerCapability, ut as waterHeaterCapability, v as batteryCapability, w as buttonCapability, wt as object, x as brightnessCapability, xt as discriminatedUnion, y as bestLocationMatch, yt as _enum, z as humidifierCapability } from "./dist-
|
|
1
|
+
import { $ as presenceCapability, A as controlCapability, At as EventCategory, B as humiditySensorCapability, C as buildAddonRouteProvider, Ct as number, D as colorCapability, Dt as union, E as climateControlCapability, Et as string, F as eventEmitterCapability, G as motionCapability, H as lawnMowerControlCapability, I as fanControlCapability, J as notifierCapability, K as normalizeUnit, L as floodCapability, M as deviceAdoptionCapability, O as connectivityCapability, Ot as unknown, P as enumSensorCapability, Q as prepareNotification, R as gasCapability, S as brokerCapability, St as literal, T as carbonMonoxideCapability, Tt as record, U as lockControlCapability, V as imageCapability, W as mediaPlayerCapability, Y as numericSensorCapability, Z as powerMeterCapability, _ as automationControlCapability, _t as createEvent, at as temperatureSensorCapability, b as binaryCapability, bt as array, ct as valveCapability, d as TargetSchema, dt as weatherCapability, et as pressureSensorCapability, f as accessoriesCapability, ft as errMsg, g as ambientLightSensorCapability, gt as DeviceType, h as alarmPanelCapability, ht as DeviceRole, it as tamperCapability, j as coverCapability, k as contactCapability, kt as url, lt as vibrationCapability, m as airQualitySensorCapability, mt as DeviceFeature, n as BaseDevice, nt as smokeCapability, ot as updateCapability, p as addonRoutesCapability, q as notificationOutputCapability, r as BaseDeviceProvider, rt as switchCapability, s as EnumSensorDateTimeFormatSchema, st as vacuumControlCapability, tt as scriptRunnerCapability, ut as waterHeaterCapability, v as batteryCapability, w as buttonCapability, wt as object, x as brightnessCapability, xt as discriminatedUnion, y as bestLocationMatch, yt as _enum, z as humidifierCapability } from "./dist-u4VAeV0m.mjs";
|
|
2
2
|
import { randomUUID } from "node:crypto";
|
|
3
3
|
import { brotliCompressSync, deflateSync, gzipSync } from "node:zlib";
|
|
4
4
|
//#region src/ha-device-source.ts
|
|
@@ -7921,7 +7921,8 @@ var OpsLogReasonSchema = _enum([
|
|
|
7921
7921
|
"quota",
|
|
7922
7922
|
"manual",
|
|
7923
7923
|
"operator",
|
|
7924
|
-
"maintenance"
|
|
7924
|
+
"maintenance",
|
|
7925
|
+
"orphaned-device"
|
|
7925
7926
|
]);
|
|
7926
7927
|
/** One audit row, shared verbatim by both domains. */
|
|
7927
7928
|
var OpsLogEntrySchema = object({
|
|
@@ -13371,10 +13372,39 @@ var DevicePersistConfigPayloadSchema = object({
|
|
|
13371
13372
|
deviceId: number(),
|
|
13372
13373
|
data: record(string(), unknown())
|
|
13373
13374
|
});
|
|
13375
|
+
/** What a migration actually did, per switch. `unreachable` is a first-class
|
|
13376
|
+
* answer: a camera that could not be asked is not a camera that was silenced. */
|
|
13377
|
+
var MigrateSwitchOutcomeSchema = _enum([
|
|
13378
|
+
"off",
|
|
13379
|
+
"on",
|
|
13380
|
+
"not-offered",
|
|
13381
|
+
"unreachable"
|
|
13382
|
+
]);
|
|
13383
|
+
var MigrateSwitchReportSchema = object({
|
|
13384
|
+
deviceId: number(),
|
|
13385
|
+
switchId: CameraSwitchIdSchema,
|
|
13386
|
+
outcome: MigrateSwitchOutcomeSchema,
|
|
13387
|
+
detail: string().optional()
|
|
13388
|
+
});
|
|
13389
|
+
var MigrateDeviceResultSchema = object({
|
|
13390
|
+
sourceId: number(),
|
|
13391
|
+
targetId: number(),
|
|
13392
|
+
switches: array(MigrateSwitchReportSchema).readonly(),
|
|
13393
|
+
/** Switches that could NOT be turned off on the source. Empty is the only
|
|
13394
|
+
* value meaning the replaced hardware is quiet. */
|
|
13395
|
+
sourceStillLive: array(CameraSwitchIdSchema).readonly(),
|
|
13396
|
+
swapped: boolean()
|
|
13397
|
+
});
|
|
13374
13398
|
method(object({
|
|
13375
13399
|
addonId: string(),
|
|
13376
13400
|
stableId: string()
|
|
13377
|
-
}), object({ id: number() }), { kind: "mutation" }), method(
|
|
13401
|
+
}), object({ id: number() }), { kind: "mutation" }), method(object({
|
|
13402
|
+
sourceId: number(),
|
|
13403
|
+
targetId: number()
|
|
13404
|
+
}), MigrateDeviceResultSchema, {
|
|
13405
|
+
kind: "mutation",
|
|
13406
|
+
auth: "admin"
|
|
13407
|
+
}), method(DeviceRegisterPayloadSchema, _void(), { kind: "mutation" }), method(DeviceRemovePayloadSchema, _void(), { kind: "mutation" }), method(DevicePersistConfigPayloadSchema, _void(), { kind: "mutation" }), method(object({ deviceId: number() }), record(string(), unknown())), method(object({ deviceId: number() }), record(string(), unknown())), method(object({ deviceId: number() }), DeviceMetaSchema.nullable()), method(object({
|
|
13378
13408
|
deviceId: number(),
|
|
13379
13409
|
name: string()
|
|
13380
13410
|
}), _void(), {
|
|
@@ -34488,6 +34518,12 @@ Object.freeze({
|
|
|
34488
34518
|
addonId: null,
|
|
34489
34519
|
access: "view"
|
|
34490
34520
|
},
|
|
34521
|
+
"deviceManager.migrateDevice": {
|
|
34522
|
+
capName: "device-manager",
|
|
34523
|
+
capScope: "system",
|
|
34524
|
+
addonId: null,
|
|
34525
|
+
access: "create"
|
|
34526
|
+
},
|
|
34491
34527
|
"deviceManager.persistConfig": {
|
|
34492
34528
|
capName: "device-manager",
|
|
34493
34529
|
capScope: "system",
|
|
@@ -7921,7 +7921,8 @@ var OpsLogReasonSchema = _enum([
|
|
|
7921
7921
|
"quota",
|
|
7922
7922
|
"manual",
|
|
7923
7923
|
"operator",
|
|
7924
|
-
"maintenance"
|
|
7924
|
+
"maintenance",
|
|
7925
|
+
"orphaned-device"
|
|
7925
7926
|
]);
|
|
7926
7927
|
/** One audit row, shared verbatim by both domains. */
|
|
7927
7928
|
var OpsLogEntrySchema = object({
|
|
@@ -13371,10 +13372,39 @@ var DevicePersistConfigPayloadSchema = object({
|
|
|
13371
13372
|
deviceId: number(),
|
|
13372
13373
|
data: record(string(), unknown())
|
|
13373
13374
|
});
|
|
13375
|
+
/** What a migration actually did, per switch. `unreachable` is a first-class
|
|
13376
|
+
* answer: a camera that could not be asked is not a camera that was silenced. */
|
|
13377
|
+
var MigrateSwitchOutcomeSchema = _enum([
|
|
13378
|
+
"off",
|
|
13379
|
+
"on",
|
|
13380
|
+
"not-offered",
|
|
13381
|
+
"unreachable"
|
|
13382
|
+
]);
|
|
13383
|
+
var MigrateSwitchReportSchema = object({
|
|
13384
|
+
deviceId: number(),
|
|
13385
|
+
switchId: CameraSwitchIdSchema,
|
|
13386
|
+
outcome: MigrateSwitchOutcomeSchema,
|
|
13387
|
+
detail: string().optional()
|
|
13388
|
+
});
|
|
13389
|
+
var MigrateDeviceResultSchema = object({
|
|
13390
|
+
sourceId: number(),
|
|
13391
|
+
targetId: number(),
|
|
13392
|
+
switches: array(MigrateSwitchReportSchema).readonly(),
|
|
13393
|
+
/** Switches that could NOT be turned off on the source. Empty is the only
|
|
13394
|
+
* value meaning the replaced hardware is quiet. */
|
|
13395
|
+
sourceStillLive: array(CameraSwitchIdSchema).readonly(),
|
|
13396
|
+
swapped: boolean()
|
|
13397
|
+
});
|
|
13374
13398
|
method(object({
|
|
13375
13399
|
addonId: string(),
|
|
13376
13400
|
stableId: string()
|
|
13377
|
-
}), object({ id: number() }), { kind: "mutation" }), method(
|
|
13401
|
+
}), object({ id: number() }), { kind: "mutation" }), method(object({
|
|
13402
|
+
sourceId: number(),
|
|
13403
|
+
targetId: number()
|
|
13404
|
+
}), MigrateDeviceResultSchema, {
|
|
13405
|
+
kind: "mutation",
|
|
13406
|
+
auth: "admin"
|
|
13407
|
+
}), method(DeviceRegisterPayloadSchema, _void(), { kind: "mutation" }), method(DeviceRemovePayloadSchema, _void(), { kind: "mutation" }), method(DevicePersistConfigPayloadSchema, _void(), { kind: "mutation" }), method(object({ deviceId: number() }), record(string(), unknown())), method(object({ deviceId: number() }), record(string(), unknown())), method(object({ deviceId: number() }), DeviceMetaSchema.nullable()), method(object({
|
|
13378
13408
|
deviceId: number(),
|
|
13379
13409
|
name: string()
|
|
13380
13410
|
}), _void(), {
|
|
@@ -34488,6 +34518,12 @@ Object.freeze({
|
|
|
34488
34518
|
addonId: null,
|
|
34489
34519
|
access: "view"
|
|
34490
34520
|
},
|
|
34521
|
+
"deviceManager.migrateDevice": {
|
|
34522
|
+
capName: "device-manager",
|
|
34523
|
+
capScope: "system",
|
|
34524
|
+
addonId: null,
|
|
34525
|
+
access: "create"
|
|
34526
|
+
},
|
|
34491
34527
|
"deviceManager.persistConfig": {
|
|
34492
34528
|
capName: "device-manager",
|
|
34493
34529
|
capScope: "system",
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
//#endregion
|
|
6
|
-
const require_dist = require("../dist-
|
|
6
|
+
const require_dist = require("../dist-B-VA4Gku.js");
|
|
7
7
|
let node_crypto = require("node:crypto");
|
|
8
8
|
//#region src/ha-export/topics.ts
|
|
9
9
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { At as EventCategory, C as buildAddonRouteProvider, Et as string, N as deviceExportCapability, X as oauthIntegrationCapability, a as COCO_TO_MACRO, c as FanDirectionSchema, i as CAMERA_SWITCH_ORDER, l as HvacModeSchema, o as CameraSwitchIdSchema, p as addonRoutesCapability, pt as BaseAddon, t as AlarmArmModeSchema, u as MediaPlayerRepeatSchema, vt as nodePin } from "../dist-
|
|
1
|
+
import { At as EventCategory, C as buildAddonRouteProvider, Et as string, N as deviceExportCapability, X as oauthIntegrationCapability, a as COCO_TO_MACRO, c as FanDirectionSchema, i as CAMERA_SWITCH_ORDER, l as HvacModeSchema, o as CameraSwitchIdSchema, p as addonRoutesCapability, pt as BaseAddon, t as AlarmArmModeSchema, u as MediaPlayerRepeatSchema, vt as nodePin } from "../dist-u4VAeV0m.mjs";
|
|
2
2
|
import { createHmac, timingSafeEqual } from "node:crypto";
|
|
3
3
|
//#region src/ha-export/topics.ts
|
|
4
4
|
/**
|