@camstack/addon-provider-hikvision 1.2.174 → 1.2.176
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/CHANGELOG.md +12 -0
- package/dist/addon.js +966 -509
- package/dist/addon.mjs +966 -509
- package/package.json +10 -3
package/dist/addon.mjs
CHANGED
|
@@ -13,7 +13,7 @@ import { Agent as Agent$1, request as request$1 } from "node:https";
|
|
|
13
13
|
var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
|
|
14
14
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
15
15
|
//#endregion
|
|
16
|
-
//#region ../types/dist/event-category-
|
|
16
|
+
//#region ../types/dist/event-category-CT-hz5Rb.mjs
|
|
17
17
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
18
18
|
EventCategory["SystemBoot"] = "system.boot";
|
|
19
19
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -339,6 +339,14 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
339
339
|
/** The recovery edge of {@link PipelineMotionNoisy}: the motion fell back, or a detection arrived. */
|
|
340
340
|
EventCategory["PipelineMotionCalm"] = "pipeline.motion-calm";
|
|
341
341
|
/**
|
|
342
|
+
* A camera's package LLM confirm has failed closed three times in a row
|
|
343
|
+
* (D931, 2026-10-26). One edge per camera until
|
|
344
|
+
* {@link PipelinePackageLlmAnswered}.
|
|
345
|
+
*/
|
|
346
|
+
EventCategory["PipelinePackageLlmSilent"] = "pipeline.package-llm-silent";
|
|
347
|
+
/** The recovery edge of {@link PipelinePackageLlmSilent}: a confirm returned yes or no. */
|
|
348
|
+
EventCategory["PipelinePackageLlmAnswered"] = "pipeline.package-llm-answered";
|
|
349
|
+
/**
|
|
342
350
|
* Per-camera pipeline config was mutated by the orchestrator
|
|
343
351
|
* (a settings change via `setAgentInferenceDevices` /
|
|
344
352
|
* `setCameraStepToggle` / `setCameraStepSettings`). Orchestrator
|
|
@@ -5448,7 +5456,7 @@ var ZodIssueCode = {
|
|
|
5448
5456
|
var ZodFirstPartyTypeKind;
|
|
5449
5457
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5450
5458
|
//#endregion
|
|
5451
|
-
//#region ../types/dist/sleep-
|
|
5459
|
+
//#region ../types/dist/sleep-bykKrTgu.mjs
|
|
5452
5460
|
/**
|
|
5453
5461
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5454
5462
|
* window to float samples (D455).
|
|
@@ -8002,6 +8010,99 @@ var RecordKindDeclarationSchema = object({
|
|
|
8002
8010
|
}).strict();
|
|
8003
8011
|
/** The kind names: lower-case, dash separated, short enough for an index name. */
|
|
8004
8012
|
var RecordKindNameSchema = string().regex(/^[a-z][a-z0-9-]{0,47}$/);
|
|
8013
|
+
var READING_QUANTITIES = [
|
|
8014
|
+
"temperature",
|
|
8015
|
+
"pressure",
|
|
8016
|
+
"speed",
|
|
8017
|
+
"precipitation",
|
|
8018
|
+
"precipitation-rate",
|
|
8019
|
+
"length",
|
|
8020
|
+
"area",
|
|
8021
|
+
"illuminance",
|
|
8022
|
+
"irradiance",
|
|
8023
|
+
"power",
|
|
8024
|
+
"energy",
|
|
8025
|
+
"voltage",
|
|
8026
|
+
"current",
|
|
8027
|
+
"apparent-power",
|
|
8028
|
+
"humidity",
|
|
8029
|
+
"percentage",
|
|
8030
|
+
"concentration-volume",
|
|
8031
|
+
"concentration-mass",
|
|
8032
|
+
"concentration-ppb",
|
|
8033
|
+
"volume",
|
|
8034
|
+
"duration",
|
|
8035
|
+
"duration-ms",
|
|
8036
|
+
"information",
|
|
8037
|
+
"sound-level",
|
|
8038
|
+
"signal-level",
|
|
8039
|
+
"colour-temperature",
|
|
8040
|
+
"angle",
|
|
8041
|
+
"bitrate",
|
|
8042
|
+
"rate",
|
|
8043
|
+
"mass",
|
|
8044
|
+
"index",
|
|
8045
|
+
"ratio",
|
|
8046
|
+
"count",
|
|
8047
|
+
"none",
|
|
8048
|
+
"device"
|
|
8049
|
+
];
|
|
8050
|
+
var ReadingQuantitySchema = _enum(READING_QUANTITIES);
|
|
8051
|
+
new Set(READING_QUANTITIES);
|
|
8052
|
+
/**
|
|
8053
|
+
* Stored unit symbol for a quantity. `none` means the number is dimensionless
|
|
8054
|
+
* (or an index / ratio / count). `device` means the cap has no single unit.
|
|
8055
|
+
*/
|
|
8056
|
+
var QUANTITY_BASE = {
|
|
8057
|
+
temperature: "°C",
|
|
8058
|
+
pressure: "hPa",
|
|
8059
|
+
speed: "m/s",
|
|
8060
|
+
precipitation: "mm",
|
|
8061
|
+
"precipitation-rate": "mm/h",
|
|
8062
|
+
length: "m",
|
|
8063
|
+
area: "m²",
|
|
8064
|
+
illuminance: "lx",
|
|
8065
|
+
irradiance: "W/m²",
|
|
8066
|
+
power: "W",
|
|
8067
|
+
energy: "kWh",
|
|
8068
|
+
voltage: "V",
|
|
8069
|
+
current: "A",
|
|
8070
|
+
"apparent-power": "VA",
|
|
8071
|
+
humidity: "%",
|
|
8072
|
+
percentage: "%",
|
|
8073
|
+
"concentration-volume": "ppm",
|
|
8074
|
+
"concentration-mass": "µg/m³",
|
|
8075
|
+
"concentration-ppb": "ppb",
|
|
8076
|
+
volume: "L",
|
|
8077
|
+
duration: "s",
|
|
8078
|
+
"duration-ms": "ms",
|
|
8079
|
+
information: "B",
|
|
8080
|
+
"sound-level": "dBFS",
|
|
8081
|
+
"signal-level": "dBm",
|
|
8082
|
+
"colour-temperature": "mired",
|
|
8083
|
+
angle: "°",
|
|
8084
|
+
bitrate: "kbps",
|
|
8085
|
+
rate: "fps",
|
|
8086
|
+
mass: "kg",
|
|
8087
|
+
index: "none",
|
|
8088
|
+
ratio: "none",
|
|
8089
|
+
count: "none",
|
|
8090
|
+
none: "none",
|
|
8091
|
+
device: "device"
|
|
8092
|
+
};
|
|
8093
|
+
/** The stored unit, or `undefined` when the quantity has no unit symbol. */
|
|
8094
|
+
function baseUnitOf(quantity) {
|
|
8095
|
+
const symbol = QUANTITY_BASE[quantity];
|
|
8096
|
+
if (symbol === "none" || symbol === "device") return void 0;
|
|
8097
|
+
return symbol;
|
|
8098
|
+
}
|
|
8099
|
+
function readingMeta(quantity, extras) {
|
|
8100
|
+
return {
|
|
8101
|
+
quantity,
|
|
8102
|
+
...extras?.precision !== void 0 ? { precision: extras.precision } : {},
|
|
8103
|
+
...extras?.label !== void 0 ? { label: extras.label } : {}
|
|
8104
|
+
};
|
|
8105
|
+
}
|
|
8005
8106
|
/** Shared Zod schemas used across streaming capabilities. */
|
|
8006
8107
|
var CamProfileSchema = _enum([
|
|
8007
8108
|
"high",
|
|
@@ -8029,8 +8130,8 @@ var CamStreamKindSchema = _enum([
|
|
|
8029
8130
|
"derived"
|
|
8030
8131
|
]);
|
|
8031
8132
|
var CamStreamResolutionSchema = object({
|
|
8032
|
-
width: number().int().positive(),
|
|
8033
|
-
height: number().int().positive()
|
|
8133
|
+
width: number().int().positive().meta(readingMeta("none")),
|
|
8134
|
+
height: number().int().positive().meta(readingMeta("none"))
|
|
8034
8135
|
});
|
|
8035
8136
|
var CameraStreamSchema = object({
|
|
8036
8137
|
/** Stable, provider-assigned id unique within the (deviceId) scope. */
|
|
@@ -8560,6 +8661,8 @@ var CAP_NAMES = Object.freeze([
|
|
|
8560
8661
|
"filesystem-browse",
|
|
8561
8662
|
"flood",
|
|
8562
8663
|
"gas",
|
|
8664
|
+
"group-commands",
|
|
8665
|
+
"group-status",
|
|
8563
8666
|
"heating-valve",
|
|
8564
8667
|
"humidifier",
|
|
8565
8668
|
"humidity-sensor",
|
|
@@ -8689,14 +8792,6 @@ Object.freeze({
|
|
|
8689
8792
|
{
|
|
8690
8793
|
"path": "aqi",
|
|
8691
8794
|
"valueType": "number"
|
|
8692
|
-
},
|
|
8693
|
-
{
|
|
8694
|
-
"path": "unit",
|
|
8695
|
-
"valueType": "string"
|
|
8696
|
-
},
|
|
8697
|
-
{
|
|
8698
|
-
"path": "precision",
|
|
8699
|
-
"valueType": "number"
|
|
8700
8795
|
}
|
|
8701
8796
|
],
|
|
8702
8797
|
"alarm-panel": [
|
|
@@ -8732,20 +8827,10 @@ Object.freeze({
|
|
|
8732
8827
|
"valueType": "boolean"
|
|
8733
8828
|
}
|
|
8734
8829
|
],
|
|
8735
|
-
"ambient-light-sensor": [
|
|
8736
|
-
|
|
8737
|
-
|
|
8738
|
-
|
|
8739
|
-
},
|
|
8740
|
-
{
|
|
8741
|
-
"path": "unit",
|
|
8742
|
-
"valueType": "string"
|
|
8743
|
-
},
|
|
8744
|
-
{
|
|
8745
|
-
"path": "precision",
|
|
8746
|
-
"valueType": "number"
|
|
8747
|
-
}
|
|
8748
|
-
],
|
|
8830
|
+
"ambient-light-sensor": [{
|
|
8831
|
+
"path": "lux",
|
|
8832
|
+
"valueType": "number"
|
|
8833
|
+
}],
|
|
8749
8834
|
"audio-metrics": [
|
|
8750
8835
|
{
|
|
8751
8836
|
"path": "ts",
|
|
@@ -8825,6 +8910,10 @@ Object.freeze({
|
|
|
8825
8910
|
"path": "lastUpdated",
|
|
8826
8911
|
"valueType": "number"
|
|
8827
8912
|
},
|
|
8913
|
+
{
|
|
8914
|
+
"path": "volts",
|
|
8915
|
+
"valueType": "number"
|
|
8916
|
+
},
|
|
8828
8917
|
{
|
|
8829
8918
|
"path": "lastContactAt",
|
|
8830
8919
|
"valueType": "number"
|
|
@@ -9067,10 +9156,6 @@ Object.freeze({
|
|
|
9067
9156
|
"datetime"
|
|
9068
9157
|
]
|
|
9069
9158
|
},
|
|
9070
|
-
{
|
|
9071
|
-
"path": "unit",
|
|
9072
|
-
"valueType": "string"
|
|
9073
|
-
},
|
|
9074
9159
|
{
|
|
9075
9160
|
"path": "min",
|
|
9076
9161
|
"valueType": "number"
|
|
@@ -9082,19 +9167,6 @@ Object.freeze({
|
|
|
9082
9167
|
{
|
|
9083
9168
|
"path": "step",
|
|
9084
9169
|
"valueType": "number"
|
|
9085
|
-
},
|
|
9086
|
-
{
|
|
9087
|
-
"path": "precision",
|
|
9088
|
-
"valueType": "number"
|
|
9089
|
-
},
|
|
9090
|
-
{
|
|
9091
|
-
"path": "format",
|
|
9092
|
-
"valueType": "enum",
|
|
9093
|
-
"enumValues": [
|
|
9094
|
-
"date",
|
|
9095
|
-
"time",
|
|
9096
|
-
"datetime"
|
|
9097
|
-
]
|
|
9098
9170
|
}
|
|
9099
9171
|
],
|
|
9100
9172
|
"cover": [
|
|
@@ -9335,13 +9407,8 @@ Object.freeze({
|
|
|
9335
9407
|
"path": "value",
|
|
9336
9408
|
"valueType": "string"
|
|
9337
9409
|
}, {
|
|
9338
|
-
"path": "
|
|
9339
|
-
"valueType": "
|
|
9340
|
-
"enumValues": [
|
|
9341
|
-
"date",
|
|
9342
|
-
"time",
|
|
9343
|
-
"datetime"
|
|
9344
|
-
]
|
|
9410
|
+
"path": "timestamp",
|
|
9411
|
+
"valueType": "boolean"
|
|
9345
9412
|
}],
|
|
9346
9413
|
"event-emitter": [
|
|
9347
9414
|
{
|
|
@@ -9414,6 +9481,20 @@ Object.freeze({
|
|
|
9414
9481
|
"path": "detected",
|
|
9415
9482
|
"valueType": "boolean"
|
|
9416
9483
|
}],
|
|
9484
|
+
"group-status": [
|
|
9485
|
+
{
|
|
9486
|
+
"path": "included",
|
|
9487
|
+
"valueType": "number"
|
|
9488
|
+
},
|
|
9489
|
+
{
|
|
9490
|
+
"path": "excluded",
|
|
9491
|
+
"valueType": "number"
|
|
9492
|
+
},
|
|
9493
|
+
{
|
|
9494
|
+
"path": "total",
|
|
9495
|
+
"valueType": "number"
|
|
9496
|
+
}
|
|
9497
|
+
],
|
|
9417
9498
|
"heating-valve": [{
|
|
9418
9499
|
"path": "position",
|
|
9419
9500
|
"valueType": "number"
|
|
@@ -9448,20 +9529,10 @@ Object.freeze({
|
|
|
9448
9529
|
"valueType": "number"
|
|
9449
9530
|
}
|
|
9450
9531
|
],
|
|
9451
|
-
"humidity-sensor": [
|
|
9452
|
-
|
|
9453
|
-
|
|
9454
|
-
|
|
9455
|
-
},
|
|
9456
|
-
{
|
|
9457
|
-
"path": "unit",
|
|
9458
|
-
"valueType": "string"
|
|
9459
|
-
},
|
|
9460
|
-
{
|
|
9461
|
-
"path": "precision",
|
|
9462
|
-
"valueType": "number"
|
|
9463
|
-
}
|
|
9464
|
-
],
|
|
9532
|
+
"humidity-sensor": [{
|
|
9533
|
+
"path": "percent",
|
|
9534
|
+
"valueType": "number"
|
|
9535
|
+
}],
|
|
9465
9536
|
"image": [{
|
|
9466
9537
|
"path": "url",
|
|
9467
9538
|
"valueType": "string"
|
|
@@ -9800,20 +9871,10 @@ Object.freeze({
|
|
|
9800
9871
|
"valueType": "boolean"
|
|
9801
9872
|
}
|
|
9802
9873
|
],
|
|
9803
|
-
"numeric-sensor": [
|
|
9804
|
-
|
|
9805
|
-
|
|
9806
|
-
|
|
9807
|
-
},
|
|
9808
|
-
{
|
|
9809
|
-
"path": "unit",
|
|
9810
|
-
"valueType": "string"
|
|
9811
|
-
},
|
|
9812
|
-
{
|
|
9813
|
-
"path": "precision",
|
|
9814
|
-
"valueType": "number"
|
|
9815
|
-
}
|
|
9816
|
-
],
|
|
9874
|
+
"numeric-sensor": [{
|
|
9875
|
+
"path": "value",
|
|
9876
|
+
"valueType": "number"
|
|
9877
|
+
}],
|
|
9817
9878
|
"pet-feeder": [
|
|
9818
9879
|
{
|
|
9819
9880
|
"path": "foodLevel",
|
|
@@ -9905,14 +9966,6 @@ Object.freeze({
|
|
|
9905
9966
|
{
|
|
9906
9967
|
"path": "powerFactor",
|
|
9907
9968
|
"valueType": "number"
|
|
9908
|
-
},
|
|
9909
|
-
{
|
|
9910
|
-
"path": "unit",
|
|
9911
|
-
"valueType": "string"
|
|
9912
|
-
},
|
|
9913
|
-
{
|
|
9914
|
-
"path": "precision",
|
|
9915
|
-
"valueType": "number"
|
|
9916
9969
|
}
|
|
9917
9970
|
],
|
|
9918
9971
|
"presence": [
|
|
@@ -9941,20 +9994,10 @@ Object.freeze({
|
|
|
9941
9994
|
"valueType": "number"
|
|
9942
9995
|
}
|
|
9943
9996
|
],
|
|
9944
|
-
"pressure-sensor": [
|
|
9945
|
-
|
|
9946
|
-
|
|
9947
|
-
|
|
9948
|
-
},
|
|
9949
|
-
{
|
|
9950
|
-
"path": "unit",
|
|
9951
|
-
"valueType": "string"
|
|
9952
|
-
},
|
|
9953
|
-
{
|
|
9954
|
-
"path": "precision",
|
|
9955
|
-
"valueType": "number"
|
|
9956
|
-
}
|
|
9957
|
-
],
|
|
9997
|
+
"pressure-sensor": [{
|
|
9998
|
+
"path": "hpa",
|
|
9999
|
+
"valueType": "number"
|
|
10000
|
+
}],
|
|
9958
10001
|
"privacy-mask": [{
|
|
9959
10002
|
"path": "enabled",
|
|
9960
10003
|
"valueType": "boolean"
|
|
@@ -10265,20 +10308,10 @@ Object.freeze({
|
|
|
10265
10308
|
"path": "tampered",
|
|
10266
10309
|
"valueType": "boolean"
|
|
10267
10310
|
}],
|
|
10268
|
-
"temperature-sensor": [
|
|
10269
|
-
|
|
10270
|
-
|
|
10271
|
-
|
|
10272
|
-
},
|
|
10273
|
-
{
|
|
10274
|
-
"path": "unit",
|
|
10275
|
-
"valueType": "string"
|
|
10276
|
-
},
|
|
10277
|
-
{
|
|
10278
|
-
"path": "precision",
|
|
10279
|
-
"valueType": "number"
|
|
10280
|
-
}
|
|
10281
|
-
],
|
|
10311
|
+
"temperature-sensor": [{
|
|
10312
|
+
"path": "celsius",
|
|
10313
|
+
"valueType": "number"
|
|
10314
|
+
}],
|
|
10282
10315
|
"update": [
|
|
10283
10316
|
{
|
|
10284
10317
|
"path": "currentVersion",
|
|
@@ -10389,10 +10422,6 @@ Object.freeze({
|
|
|
10389
10422
|
"path": "temperature",
|
|
10390
10423
|
"valueType": "number"
|
|
10391
10424
|
},
|
|
10392
|
-
{
|
|
10393
|
-
"path": "temperatureUnit",
|
|
10394
|
-
"valueType": "string"
|
|
10395
|
-
},
|
|
10396
10425
|
{
|
|
10397
10426
|
"path": "humidity",
|
|
10398
10427
|
"valueType": "number"
|
|
@@ -10401,18 +10430,10 @@ Object.freeze({
|
|
|
10401
10430
|
"path": "pressure",
|
|
10402
10431
|
"valueType": "number"
|
|
10403
10432
|
},
|
|
10404
|
-
{
|
|
10405
|
-
"path": "pressureUnit",
|
|
10406
|
-
"valueType": "string"
|
|
10407
|
-
},
|
|
10408
10433
|
{
|
|
10409
10434
|
"path": "windSpeed",
|
|
10410
10435
|
"valueType": "number"
|
|
10411
10436
|
},
|
|
10412
|
-
{
|
|
10413
|
-
"path": "windSpeedUnit",
|
|
10414
|
-
"valueType": "string"
|
|
10415
|
-
},
|
|
10416
10437
|
{
|
|
10417
10438
|
"path": "windBearing",
|
|
10418
10439
|
"valueType": "number"
|
|
@@ -10819,7 +10840,7 @@ var DeviceRole = /* @__PURE__ */ function(DeviceRole) {
|
|
|
10819
10840
|
return DeviceRole;
|
|
10820
10841
|
}({});
|
|
10821
10842
|
//#endregion
|
|
10822
|
-
//#region ../types/dist/composition-
|
|
10843
|
+
//#region ../types/dist/composition-OhpuespA.mjs
|
|
10823
10844
|
/**
|
|
10824
10845
|
* The ffmpeg build every CamStack node downloads, per platform and arch.
|
|
10825
10846
|
*
|
|
@@ -11574,15 +11595,74 @@ function validateExpressionSource(src) {
|
|
|
11574
11595
|
}
|
|
11575
11596
|
return null;
|
|
11576
11597
|
}
|
|
11577
|
-
/**
|
|
11578
|
-
|
|
11579
|
-
|
|
11580
|
-
|
|
11598
|
+
/**
|
|
11599
|
+
* A composition source identity: `(addonId, stableId)`, never a numeric device
|
|
11600
|
+
* id. Split out so helper schemas can name it without a cycle through
|
|
11601
|
+
* `composition.ts` (D659).
|
|
11602
|
+
*/
|
|
11581
11603
|
var CompositionSourceRefSchema = object({
|
|
11582
11604
|
/** The owning addon; `stableId` is unique only within it. */
|
|
11583
11605
|
addonId: string().min(1),
|
|
11584
11606
|
stableId: string().min(1)
|
|
11585
11607
|
});
|
|
11608
|
+
var GROUP_TEMPLATE_IDS = [
|
|
11609
|
+
"temperature",
|
|
11610
|
+
"humidity",
|
|
11611
|
+
"pressure",
|
|
11612
|
+
"illuminance",
|
|
11613
|
+
"power",
|
|
11614
|
+
"energy",
|
|
11615
|
+
"battery",
|
|
11616
|
+
"numeric",
|
|
11617
|
+
"motion",
|
|
11618
|
+
"contact",
|
|
11619
|
+
"leak",
|
|
11620
|
+
"smoke",
|
|
11621
|
+
"occupancy",
|
|
11622
|
+
"binary",
|
|
11623
|
+
"switch",
|
|
11624
|
+
"light"
|
|
11625
|
+
];
|
|
11626
|
+
var NUMERIC_AGGREGATES = [
|
|
11627
|
+
"mean",
|
|
11628
|
+
"median",
|
|
11629
|
+
"min",
|
|
11630
|
+
"max",
|
|
11631
|
+
"sum"
|
|
11632
|
+
];
|
|
11633
|
+
var BINARY_AGGREGATES = ["any", "all"];
|
|
11634
|
+
/** How an actuator group decides it is on. Unknown members never count as off. */
|
|
11635
|
+
var ACTIVE_CRITERIA = ["at-least-one", "all"];
|
|
11636
|
+
var AGGREGATE_REDUCERS = [
|
|
11637
|
+
"mean",
|
|
11638
|
+
"median",
|
|
11639
|
+
"min",
|
|
11640
|
+
"max",
|
|
11641
|
+
"sum",
|
|
11642
|
+
"any",
|
|
11643
|
+
"all"
|
|
11644
|
+
];
|
|
11645
|
+
var GroupTemplateIdSchema = _enum(GROUP_TEMPLATE_IDS);
|
|
11646
|
+
var AggregateReducerSchema = _enum(AGGREGATE_REDUCERS);
|
|
11647
|
+
var ActiveCriterionSchema = _enum(ACTIVE_CRITERIA);
|
|
11648
|
+
/** One member. The field is stored so occupancy can name motion or binary. */
|
|
11649
|
+
var HelperMemberSchema = object({
|
|
11650
|
+
source: CompositionSourceRefSchema,
|
|
11651
|
+
cap: string().min(1),
|
|
11652
|
+
fieldPath: string().min(1)
|
|
11653
|
+
});
|
|
11654
|
+
var HelperSpecSchema = discriminatedUnion("kind", [object({
|
|
11655
|
+
kind: literal("group"),
|
|
11656
|
+
templateId: GroupTemplateIdSchema,
|
|
11657
|
+
aggregate: AggregateReducerSchema,
|
|
11658
|
+
members: array(HelperMemberSchema).min(1).max(64),
|
|
11659
|
+
/** Actuator groups only. Readings leave this unset. */
|
|
11660
|
+
active: ActiveCriterionSchema.optional()
|
|
11661
|
+
})]);
|
|
11662
|
+
/** A composed device's stableId is this prefix plus the block id. */
|
|
11663
|
+
var COMPOSED_DEVICE_STABLE_ID_PREFIX = "composed-";
|
|
11664
|
+
/** Longest snippet a `code` source may carry (slice 4). */
|
|
11665
|
+
var MAX_COMPOSITION_CODE_LENGTH = 2e4;
|
|
11586
11666
|
/** One field of one capability of one source device. */
|
|
11587
11667
|
var CompositionFieldReadSchema = object({
|
|
11588
11668
|
source: CompositionSourceRefSchema,
|
|
@@ -11626,7 +11706,33 @@ var CompositionCodeSourceSchema = object({
|
|
|
11626
11706
|
var CompositionFieldSourceSchema = discriminatedUnion("kind", [
|
|
11627
11707
|
CompositionFromSourceSchema,
|
|
11628
11708
|
CompositionExpressionSourceSchema,
|
|
11629
|
-
CompositionCodeSourceSchema
|
|
11709
|
+
CompositionCodeSourceSchema,
|
|
11710
|
+
object({
|
|
11711
|
+
kind: literal("aggregate"),
|
|
11712
|
+
reducer: _enum([
|
|
11713
|
+
"mean",
|
|
11714
|
+
"median",
|
|
11715
|
+
"min",
|
|
11716
|
+
"max",
|
|
11717
|
+
"sum",
|
|
11718
|
+
"any",
|
|
11719
|
+
"all"
|
|
11720
|
+
]),
|
|
11721
|
+
reads: array(CompositionFieldReadSchema).min(1).max(64),
|
|
11722
|
+
/** `value` is the reading; the others are the member counts. */
|
|
11723
|
+
publish: _enum([
|
|
11724
|
+
"value",
|
|
11725
|
+
"included",
|
|
11726
|
+
"excluded",
|
|
11727
|
+
"total"
|
|
11728
|
+
]),
|
|
11729
|
+
/** What a `value` publish does when nobody is included. Counts ignore this. */
|
|
11730
|
+
empty: _enum([
|
|
11731
|
+
"null",
|
|
11732
|
+
"omit",
|
|
11733
|
+
"offline"
|
|
11734
|
+
])
|
|
11735
|
+
})
|
|
11630
11736
|
]);
|
|
11631
11737
|
var CompositionCommandTargetSchema = discriminatedUnion("kind", [object({
|
|
11632
11738
|
kind: literal("forward"),
|
|
@@ -11672,7 +11778,13 @@ var CompositionSchema = object({
|
|
|
11672
11778
|
kind: literal("existing"),
|
|
11673
11779
|
device: CompositionSourceRefSchema
|
|
11674
11780
|
})]),
|
|
11675
|
-
features: array(CompositionFeatureSchema).min(1).max(16)
|
|
11781
|
+
features: array(CompositionFeatureSchema).min(1).max(16),
|
|
11782
|
+
/**
|
|
11783
|
+
* Present when the block is a helper template. Absent on a free
|
|
11784
|
+
* composition (the room example, device 4603). The editor reads this,
|
|
11785
|
+
* never the compiled features.
|
|
11786
|
+
*/
|
|
11787
|
+
helper: HelperSpecSchema.optional()
|
|
11676
11788
|
}).superRefine((composition, ctx) => {
|
|
11677
11789
|
const seen = /* @__PURE__ */ new Set();
|
|
11678
11790
|
composition.features.forEach((feature, index) => {
|
|
@@ -18199,7 +18311,11 @@ var CompositionProblemSchema = object({
|
|
|
18199
18311
|
"item-field-reserved",
|
|
18200
18312
|
"target-missing",
|
|
18201
18313
|
"target-unreadable",
|
|
18202
|
-
"not-replaceable"
|
|
18314
|
+
"not-replaceable",
|
|
18315
|
+
"native-capability-replace",
|
|
18316
|
+
"mixed-quantity",
|
|
18317
|
+
"helper-mismatch",
|
|
18318
|
+
"member-constraint"
|
|
18203
18319
|
]),
|
|
18204
18320
|
path: string(),
|
|
18205
18321
|
message: string()
|
|
@@ -18220,7 +18336,8 @@ var CompositionUnavailableModeSchema = _enum([
|
|
|
18220
18336
|
"null",
|
|
18221
18337
|
"offline",
|
|
18222
18338
|
"unknown",
|
|
18223
|
-
"release"
|
|
18339
|
+
"release",
|
|
18340
|
+
"omit"
|
|
18224
18341
|
]);
|
|
18225
18342
|
/**
|
|
18226
18343
|
* `derived` reads a source · `clock` reads only `now`, recomputed when a sibling
|
|
@@ -18257,9 +18374,11 @@ var CompositionFieldPlanSchema = object({
|
|
|
18257
18374
|
reads: array(CompositionFieldReadSchema)
|
|
18258
18375
|
});
|
|
18259
18376
|
/**
|
|
18260
|
-
* What a feature does to its target (D663): `new` builds a capability on a
|
|
18261
|
-
* device; on an existing device it `add`s a capability the device lacks
|
|
18262
|
-
*
|
|
18377
|
+
* What a feature does to its target (D663, D944): `new` builds a capability on a
|
|
18378
|
+
* new device; on an existing device it `add`s a capability the device lacks.
|
|
18379
|
+
* Replacing a capability the device already serves is refused
|
|
18380
|
+
* (`native-capability-replace`), not planned. `replace` remains on the claim
|
|
18381
|
+
* wire for a claim the hub already holds.
|
|
18263
18382
|
*/
|
|
18264
18383
|
var CompositionFeatureModeSchema = _enum([
|
|
18265
18384
|
"new",
|
|
@@ -18432,6 +18551,275 @@ Object.freeze({
|
|
|
18432
18551
|
result: ["number", "null"]
|
|
18433
18552
|
}
|
|
18434
18553
|
});
|
|
18554
|
+
/**
|
|
18555
|
+
* One catalog row per base reading a group helper can build (D944 §3).
|
|
18556
|
+
* Data, not a form default written into the block.
|
|
18557
|
+
*/
|
|
18558
|
+
var NOW = {
|
|
18559
|
+
fieldPath: "lastFetchedAt",
|
|
18560
|
+
expr: "now"
|
|
18561
|
+
};
|
|
18562
|
+
var CHANGED = {
|
|
18563
|
+
fieldPath: "lastChangedAt",
|
|
18564
|
+
expr: "now"
|
|
18565
|
+
};
|
|
18566
|
+
function numeric(input) {
|
|
18567
|
+
return {
|
|
18568
|
+
...input,
|
|
18569
|
+
family: "numeric",
|
|
18570
|
+
deviceType: DeviceType.Sensor,
|
|
18571
|
+
memberDeviceType: DeviceType.Sensor,
|
|
18572
|
+
commandCaps: [],
|
|
18573
|
+
baseUnit: baseUnitOf(input.quantity),
|
|
18574
|
+
aggregates: NUMERIC_AGGREGATES,
|
|
18575
|
+
accept: [{
|
|
18576
|
+
cap: input.outputCap,
|
|
18577
|
+
fieldPath: input.outputField
|
|
18578
|
+
}]
|
|
18579
|
+
};
|
|
18580
|
+
}
|
|
18581
|
+
function binary(input) {
|
|
18582
|
+
return {
|
|
18583
|
+
...input,
|
|
18584
|
+
family: "binary",
|
|
18585
|
+
deviceType: DeviceType.Sensor,
|
|
18586
|
+
memberDeviceType: DeviceType.Sensor,
|
|
18587
|
+
commandCaps: [],
|
|
18588
|
+
quantity: "none",
|
|
18589
|
+
baseUnit: void 0,
|
|
18590
|
+
aggregates: BINARY_AGGREGATES,
|
|
18591
|
+
empty: "offline"
|
|
18592
|
+
};
|
|
18593
|
+
}
|
|
18594
|
+
var GROUP_TEMPLATES = [
|
|
18595
|
+
numeric({
|
|
18596
|
+
id: "temperature",
|
|
18597
|
+
summary: "Mean, median, min, max or sum of temperatures. Offline and unknown members are left out, never read as 0 °C.",
|
|
18598
|
+
role: DeviceRole.TemperatureSensor,
|
|
18599
|
+
outputCap: "temperature-sensor",
|
|
18600
|
+
outputField: "celsius",
|
|
18601
|
+
quantity: "temperature",
|
|
18602
|
+
defaultAggregate: "mean",
|
|
18603
|
+
empty: "null",
|
|
18604
|
+
companions: [NOW]
|
|
18605
|
+
}),
|
|
18606
|
+
numeric({
|
|
18607
|
+
id: "humidity",
|
|
18608
|
+
summary: "Humidity in percent. Offline and unknown members are left out, never read as 0 %.",
|
|
18609
|
+
role: DeviceRole.HumiditySensor,
|
|
18610
|
+
outputCap: "humidity-sensor",
|
|
18611
|
+
outputField: "percent",
|
|
18612
|
+
quantity: "humidity",
|
|
18613
|
+
defaultAggregate: "mean",
|
|
18614
|
+
empty: "null",
|
|
18615
|
+
companions: [NOW]
|
|
18616
|
+
}),
|
|
18617
|
+
numeric({
|
|
18618
|
+
id: "pressure",
|
|
18619
|
+
summary: "Pressure in hectopascals. Offline and unknown members are left out, never read as 0 hPa.",
|
|
18620
|
+
role: DeviceRole.PressureSensor,
|
|
18621
|
+
outputCap: "pressure-sensor",
|
|
18622
|
+
outputField: "hpa",
|
|
18623
|
+
quantity: "pressure",
|
|
18624
|
+
defaultAggregate: "mean",
|
|
18625
|
+
empty: "null",
|
|
18626
|
+
companions: [NOW]
|
|
18627
|
+
}),
|
|
18628
|
+
numeric({
|
|
18629
|
+
id: "illuminance",
|
|
18630
|
+
summary: "Illuminance in lux. Offline and unknown members are left out, never read as 0 lx.",
|
|
18631
|
+
role: DeviceRole.AmbientLightSensor,
|
|
18632
|
+
outputCap: "ambient-light-sensor",
|
|
18633
|
+
outputField: "lux",
|
|
18634
|
+
quantity: "illuminance",
|
|
18635
|
+
defaultAggregate: "mean",
|
|
18636
|
+
empty: "null",
|
|
18637
|
+
companions: [NOW]
|
|
18638
|
+
}),
|
|
18639
|
+
numeric({
|
|
18640
|
+
id: "power",
|
|
18641
|
+
summary: "Power in watts, summed by default. Nobody reporting omits the key rather than writing 0 W.",
|
|
18642
|
+
role: DeviceRole.PowerSensor,
|
|
18643
|
+
outputCap: "power-meter",
|
|
18644
|
+
outputField: "watts",
|
|
18645
|
+
quantity: "power",
|
|
18646
|
+
defaultAggregate: "sum",
|
|
18647
|
+
empty: "omit",
|
|
18648
|
+
companions: [NOW]
|
|
18649
|
+
}),
|
|
18650
|
+
numeric({
|
|
18651
|
+
id: "energy",
|
|
18652
|
+
summary: "Energy in kilowatt-hours, summed by default. Nobody reporting omits the key rather than writing 0 kWh.",
|
|
18653
|
+
role: DeviceRole.EnergySensor,
|
|
18654
|
+
outputCap: "power-meter",
|
|
18655
|
+
outputField: "kwhTotal",
|
|
18656
|
+
quantity: "energy",
|
|
18657
|
+
defaultAggregate: "sum",
|
|
18658
|
+
empty: "omit",
|
|
18659
|
+
companions: [NOW]
|
|
18660
|
+
}),
|
|
18661
|
+
numeric({
|
|
18662
|
+
id: "battery",
|
|
18663
|
+
summary: "Battery charge in percent. Offline and unknown members are left out, never read as 0 %.",
|
|
18664
|
+
role: DeviceRole.BatterySensor,
|
|
18665
|
+
outputCap: "battery",
|
|
18666
|
+
outputField: "percentage",
|
|
18667
|
+
quantity: "percentage",
|
|
18668
|
+
defaultAggregate: "mean",
|
|
18669
|
+
empty: "null",
|
|
18670
|
+
companions: [
|
|
18671
|
+
{
|
|
18672
|
+
fieldPath: "charging",
|
|
18673
|
+
expr: "\"unknown\""
|
|
18674
|
+
},
|
|
18675
|
+
{
|
|
18676
|
+
fieldPath: "sleeping",
|
|
18677
|
+
expr: "false"
|
|
18678
|
+
},
|
|
18679
|
+
{
|
|
18680
|
+
fieldPath: "lastUpdated",
|
|
18681
|
+
expr: "now"
|
|
18682
|
+
}
|
|
18683
|
+
]
|
|
18684
|
+
}),
|
|
18685
|
+
numeric({
|
|
18686
|
+
id: "numeric",
|
|
18687
|
+
summary: "A numeric reading in the members’ shared quantity. Mixed quantities are refused. Nobody reporting publishes null, not 0.",
|
|
18688
|
+
role: DeviceRole.NumericSensor,
|
|
18689
|
+
outputCap: "numeric-sensor",
|
|
18690
|
+
outputField: "value",
|
|
18691
|
+
quantity: "device",
|
|
18692
|
+
defaultAggregate: "mean",
|
|
18693
|
+
empty: "null",
|
|
18694
|
+
companions: [NOW]
|
|
18695
|
+
}),
|
|
18696
|
+
binary({
|
|
18697
|
+
id: "motion",
|
|
18698
|
+
summary: "Any or all motion. Offline and unknown members are left out, never read as off. Nobody reporting takes the device offline.",
|
|
18699
|
+
role: DeviceRole.MotionSensor,
|
|
18700
|
+
outputCap: "motion",
|
|
18701
|
+
outputField: "detected",
|
|
18702
|
+
defaultAggregate: "any",
|
|
18703
|
+
accept: [{
|
|
18704
|
+
cap: "motion",
|
|
18705
|
+
fieldPath: "detected"
|
|
18706
|
+
}],
|
|
18707
|
+
companions: [{
|
|
18708
|
+
fieldPath: "lastDetectedAt",
|
|
18709
|
+
expr: "null"
|
|
18710
|
+
}, {
|
|
18711
|
+
fieldPath: "autoClearAfterMs",
|
|
18712
|
+
expr: "null"
|
|
18713
|
+
}]
|
|
18714
|
+
}),
|
|
18715
|
+
binary({
|
|
18716
|
+
id: "contact",
|
|
18717
|
+
summary: "Any or all open contacts. Offline and unknown members are left out, never read as closed.",
|
|
18718
|
+
role: DeviceRole.ContactSensor,
|
|
18719
|
+
outputCap: "contact",
|
|
18720
|
+
outputField: "entryOpen",
|
|
18721
|
+
defaultAggregate: "any",
|
|
18722
|
+
accept: [{
|
|
18723
|
+
cap: "contact",
|
|
18724
|
+
fieldPath: "entryOpen"
|
|
18725
|
+
}],
|
|
18726
|
+
companions: [CHANGED]
|
|
18727
|
+
}),
|
|
18728
|
+
binary({
|
|
18729
|
+
id: "leak",
|
|
18730
|
+
summary: "Any or all leak detections. Offline and unknown members are left out, never read as dry.",
|
|
18731
|
+
role: DeviceRole.LeakSensor,
|
|
18732
|
+
outputCap: "flood",
|
|
18733
|
+
outputField: "flooded",
|
|
18734
|
+
defaultAggregate: "any",
|
|
18735
|
+
accept: [{
|
|
18736
|
+
cap: "flood",
|
|
18737
|
+
fieldPath: "flooded"
|
|
18738
|
+
}],
|
|
18739
|
+
companions: [CHANGED]
|
|
18740
|
+
}),
|
|
18741
|
+
binary({
|
|
18742
|
+
id: "smoke",
|
|
18743
|
+
summary: "Any or all smoke detections. Offline and unknown members are left out, never read as clear.",
|
|
18744
|
+
role: DeviceRole.SmokeSensor,
|
|
18745
|
+
outputCap: "smoke",
|
|
18746
|
+
outputField: "detected",
|
|
18747
|
+
defaultAggregate: "any",
|
|
18748
|
+
accept: [{
|
|
18749
|
+
cap: "smoke",
|
|
18750
|
+
fieldPath: "detected"
|
|
18751
|
+
}],
|
|
18752
|
+
companions: [CHANGED]
|
|
18753
|
+
}),
|
|
18754
|
+
binary({
|
|
18755
|
+
id: "occupancy",
|
|
18756
|
+
summary: "Any or all of motion or binary sensors, published as a binary. Presence zones are not aggregated. Nobody reporting is offline, not off.",
|
|
18757
|
+
role: DeviceRole.BinarySensor,
|
|
18758
|
+
outputCap: "binary",
|
|
18759
|
+
outputField: "on",
|
|
18760
|
+
defaultAggregate: "any",
|
|
18761
|
+
accept: [{
|
|
18762
|
+
cap: "motion",
|
|
18763
|
+
fieldPath: "detected"
|
|
18764
|
+
}, {
|
|
18765
|
+
cap: "binary",
|
|
18766
|
+
fieldPath: "on"
|
|
18767
|
+
}],
|
|
18768
|
+
companions: [CHANGED]
|
|
18769
|
+
}),
|
|
18770
|
+
binary({
|
|
18771
|
+
id: "binary",
|
|
18772
|
+
summary: "Any or all generic binary sensors. Offline and unknown members are left out, never read as off.",
|
|
18773
|
+
role: DeviceRole.BinarySensor,
|
|
18774
|
+
outputCap: "binary",
|
|
18775
|
+
outputField: "on",
|
|
18776
|
+
defaultAggregate: "any",
|
|
18777
|
+
accept: [{
|
|
18778
|
+
cap: "binary",
|
|
18779
|
+
fieldPath: "on"
|
|
18780
|
+
}],
|
|
18781
|
+
companions: [CHANGED]
|
|
18782
|
+
}),
|
|
18783
|
+
actuator({
|
|
18784
|
+
id: "switch",
|
|
18785
|
+
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.",
|
|
18786
|
+
deviceType: DeviceType.Switch,
|
|
18787
|
+
outputCap: "switch",
|
|
18788
|
+
commandCaps: ["switch"]
|
|
18789
|
+
}),
|
|
18790
|
+
actuator({
|
|
18791
|
+
id: "light",
|
|
18792
|
+
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.",
|
|
18793
|
+
deviceType: DeviceType.Light,
|
|
18794
|
+
outputCap: "switch",
|
|
18795
|
+
commandCaps: [
|
|
18796
|
+
"switch",
|
|
18797
|
+
"brightness",
|
|
18798
|
+
"color"
|
|
18799
|
+
]
|
|
18800
|
+
})
|
|
18801
|
+
];
|
|
18802
|
+
function actuator(input) {
|
|
18803
|
+
return {
|
|
18804
|
+
...input,
|
|
18805
|
+
family: "actuator",
|
|
18806
|
+
role: void 0,
|
|
18807
|
+
memberDeviceType: input.deviceType,
|
|
18808
|
+
outputField: "on",
|
|
18809
|
+
quantity: "none",
|
|
18810
|
+
baseUnit: void 0,
|
|
18811
|
+
aggregates: BINARY_AGGREGATES,
|
|
18812
|
+
defaultAggregate: "any",
|
|
18813
|
+
empty: "offline",
|
|
18814
|
+
accept: [{
|
|
18815
|
+
cap: "switch",
|
|
18816
|
+
fieldPath: "on"
|
|
18817
|
+
}],
|
|
18818
|
+
companions: [CHANGED]
|
|
18819
|
+
};
|
|
18820
|
+
}
|
|
18821
|
+
new Map(GROUP_TEMPLATES.map((template) => [template.id, template]));
|
|
18822
|
+
DeviceFeature.LightColorRgb, DeviceFeature.LightColorHsv, DeviceFeature.LightColorMired;
|
|
18435
18823
|
`${COMPOSED_DEVICE_STABLE_ID_PREFIX}`;
|
|
18436
18824
|
/**
|
|
18437
18825
|
* What a composition may BUILD on a device type (G2, D676): the caps a new
|
|
@@ -20258,12 +20646,12 @@ function buildDeviceAdminUrl(parts) {
|
|
|
20258
20646
|
* providers detect renames by matching `uniqueId` and patch `id`
|
|
20259
20647
|
* in-place so dispatch keeps working.
|
|
20260
20648
|
*
|
|
20261
|
-
* **
|
|
20262
|
-
*
|
|
20263
|
-
*
|
|
20264
|
-
*
|
|
20265
|
-
* (`ha-domain-mapping`)
|
|
20266
|
-
* stored after that point.
|
|
20649
|
+
* **Display unit and precision are NOT stored here.** They are a read-time
|
|
20650
|
+
* preference (D944). A polymorphic reading stores its `quantity` here once,
|
|
20651
|
+
* at adopt, and a date/time value stores `dateTimeShape` the same way —
|
|
20652
|
+
* neither is repeated on each sample. The `device_class` tag is an
|
|
20653
|
+
* HA-specific input consumed at the discovery boundary (`ha-domain-mapping`)
|
|
20654
|
+
* to derive the CamStack `DeviceRole`; it is never stored after that point.
|
|
20267
20655
|
*
|
|
20268
20656
|
* The `raw` escape hatch carries provider-specific attributes that don't
|
|
20269
20657
|
* fit the structured slots (HA `attributes` whitelist, Reolink `deviceCache`
|
|
@@ -20277,6 +20665,14 @@ var SourceInfoSchema = object({
|
|
|
20277
20665
|
/** Immutable upstream identifier when available (HA `unique_id`, … ).
|
|
20278
20666
|
* Used to detect rename when `id` changes. */
|
|
20279
20667
|
uniqueId: string().optional(),
|
|
20668
|
+
/** Quantity of a polymorphic reading, written once at adopt (D944). */
|
|
20669
|
+
quantity: ReadingQuantitySchema.optional(),
|
|
20670
|
+
/** Date / time / datetime shape of a string reading, written once at adopt. */
|
|
20671
|
+
dateTimeShape: _enum([
|
|
20672
|
+
"date",
|
|
20673
|
+
"time",
|
|
20674
|
+
"datetime"
|
|
20675
|
+
]).optional(),
|
|
20280
20676
|
/** Provider-specific extras that don't fit the structured slots.
|
|
20281
20677
|
* Whitelist what goes here per provider — do NOT dump entire HA
|
|
20282
20678
|
* attribute blobs (would explode the meta JSON column). */
|
|
@@ -41381,7 +41777,8 @@ method(object({
|
|
|
41381
41777
|
"enum"
|
|
41382
41778
|
]),
|
|
41383
41779
|
enumValues: array(string()).optional(),
|
|
41384
|
-
item: boolean().optional()
|
|
41780
|
+
item: boolean().optional(),
|
|
41781
|
+
quantity: ReadingQuantitySchema.optional()
|
|
41385
41782
|
})).readonly(),
|
|
41386
41783
|
itemArray: object({
|
|
41387
41784
|
path: string(),
|
|
@@ -45244,8 +45641,8 @@ var MaskPolygonShapeSchema = object({
|
|
|
45244
45641
|
/** Boolean cell grid — row-major, length === gridWidth*gridHeight. */
|
|
45245
45642
|
var MaskGridShapeSchema = object({
|
|
45246
45643
|
kind: literal("grid"),
|
|
45247
|
-
gridWidth: number(),
|
|
45248
|
-
gridHeight: number(),
|
|
45644
|
+
gridWidth: number().meta(readingMeta("none")),
|
|
45645
|
+
gridHeight: number().meta(readingMeta("none")),
|
|
45249
45646
|
cells: array(boolean())
|
|
45250
45647
|
});
|
|
45251
45648
|
discriminatedUnion("kind", [
|
|
@@ -45357,6 +45754,8 @@ var NcSystemEventKindSchema = _enum([
|
|
|
45357
45754
|
"detection-blind",
|
|
45358
45755
|
"motion-noisy",
|
|
45359
45756
|
"motion-calm",
|
|
45757
|
+
"package-llm-silent",
|
|
45758
|
+
"package-llm-answered",
|
|
45360
45759
|
"recording-stalled",
|
|
45361
45760
|
"recording-healthy",
|
|
45362
45761
|
"recording-degraded",
|
|
@@ -56970,6 +57369,28 @@ var PackageVersionInfoSchema = object({
|
|
|
56970
57369
|
deprecated: string().optional(),
|
|
56971
57370
|
distTags: array(string()).readonly()
|
|
56972
57371
|
});
|
|
57372
|
+
/**
|
|
57373
|
+
* One published document. `ok` is markdown from the registry. `missing` means
|
|
57374
|
+
* the registry answered and the file was not there. `error` is a registry or
|
|
57375
|
+
* tarball failure — never an empty string standing in for either.
|
|
57376
|
+
*/
|
|
57377
|
+
var PackageDocBodySchema = discriminatedUnion("status", [
|
|
57378
|
+
object({
|
|
57379
|
+
status: literal("ok"),
|
|
57380
|
+
markdown: string()
|
|
57381
|
+
}),
|
|
57382
|
+
object({ status: literal("missing") }),
|
|
57383
|
+
object({
|
|
57384
|
+
status: literal("error"),
|
|
57385
|
+
message: string()
|
|
57386
|
+
})
|
|
57387
|
+
]);
|
|
57388
|
+
var PackageDocsSchema = object({
|
|
57389
|
+
name: string(),
|
|
57390
|
+
version: string(),
|
|
57391
|
+
readme: PackageDocBodySchema,
|
|
57392
|
+
changelog: PackageDocBodySchema
|
|
57393
|
+
});
|
|
56973
57394
|
var SearchResultSchema = object({
|
|
56974
57395
|
name: string(),
|
|
56975
57396
|
version: string(),
|
|
@@ -57188,7 +57609,10 @@ method(object({ nodeId: string().optional() }).optional(), array(AddonListItemSc
|
|
|
57188
57609
|
}), object({ success: literal(true) }), {
|
|
57189
57610
|
kind: "mutation",
|
|
57190
57611
|
auth: "admin"
|
|
57191
|
-
}), method(object({ name: string() }), array(PackageVersionInfoSchema).readonly()), method(object({
|
|
57612
|
+
}), method(object({ name: string() }), array(PackageVersionInfoSchema).readonly()), method(object({
|
|
57613
|
+
name: string().min(1),
|
|
57614
|
+
version: string().min(1).optional()
|
|
57615
|
+
}), PackageDocsSchema, { auth: "admin" }), method(object({ addonId: string() }), RestartAddonResultSchema, {
|
|
57192
57616
|
kind: "mutation",
|
|
57193
57617
|
auth: "admin"
|
|
57194
57618
|
}), method(object({ packageName: string() }), object({ success: literal(true) }), {
|
|
@@ -57247,27 +57671,17 @@ method(object({ nodeId: string().optional() }).optional(), array(AddonListItemSc
|
|
|
57247
57671
|
*/
|
|
57248
57672
|
var AirQualitySensorStatusSchema = object({
|
|
57249
57673
|
/** Carbon dioxide concentration in ppm. */
|
|
57250
|
-
co2Ppm: number().min(0).optional(),
|
|
57674
|
+
co2Ppm: number().min(0).optional().meta(readingMeta("concentration-volume")),
|
|
57251
57675
|
/** Total volatile organic compounds in ppb. */
|
|
57252
|
-
vocPpb: number().min(0).optional(),
|
|
57676
|
+
vocPpb: number().min(0).optional().meta(readingMeta("concentration-ppb")),
|
|
57253
57677
|
/** Particulate matter ≤ 2.5 μm in µg/m³. */
|
|
57254
|
-
pm25: number().min(0).optional(),
|
|
57678
|
+
pm25: number().min(0).optional().meta(readingMeta("concentration-mass")),
|
|
57255
57679
|
/** Particulate matter ≤ 10 μm in µg/m³. */
|
|
57256
|
-
pm10: number().min(0).optional(),
|
|
57680
|
+
pm10: number().min(0).optional().meta(readingMeta("concentration-mass")),
|
|
57257
57681
|
/** Composite AQI value (typically 0..500). */
|
|
57258
|
-
aqi: number().optional(),
|
|
57682
|
+
aqi: number().optional().meta(readingMeta("index")),
|
|
57259
57683
|
/** Ms epoch when the slice was last updated. */
|
|
57260
|
-
lastFetchedAt: number()
|
|
57261
|
-
/** Live display unit of the single metric this slice carries (e.g. HA
|
|
57262
|
-
* `attributes.unit_of_measurement` → 'ppm' / 'ppb' / 'µg/m³'). Each
|
|
57263
|
-
* upstream `sensor.*` entity surfaces ONE device_class, so one unit
|
|
57264
|
-
* per slice is unambiguous. */
|
|
57265
|
-
unit: string().optional(),
|
|
57266
|
-
/** Suggested decimal places for numeric display.
|
|
57267
|
-
* Populated live from the upstream source when provided (e.g. HA
|
|
57268
|
-
* `attributes.suggested_display_precision`). Falls back to
|
|
57269
|
-
* auto-formatting when absent. */
|
|
57270
|
-
precision: number().int().min(0).max(10).optional()
|
|
57684
|
+
lastFetchedAt: number()
|
|
57271
57685
|
});
|
|
57272
57686
|
var airQualitySensorCapability = {
|
|
57273
57687
|
name: "air-quality-sensor",
|
|
@@ -57304,12 +57718,12 @@ var airQualitySensorCapability = {
|
|
|
57304
57718
|
},
|
|
57305
57719
|
pm25: {
|
|
57306
57720
|
kind: "gauge",
|
|
57307
|
-
unit: "
|
|
57721
|
+
unit: "µg/m³",
|
|
57308
57722
|
deadband: 1
|
|
57309
57723
|
},
|
|
57310
57724
|
pm10: {
|
|
57311
57725
|
kind: "gauge",
|
|
57312
|
-
unit: "
|
|
57726
|
+
unit: "µg/m³",
|
|
57313
57727
|
deadband: 1
|
|
57314
57728
|
},
|
|
57315
57729
|
aqi: {
|
|
@@ -57327,22 +57741,13 @@ var airQualitySensorCapability = {
|
|
|
57327
57741
|
* entries with `device_class: illuminance`.
|
|
57328
57742
|
*/
|
|
57329
57743
|
var AmbientLightSensorStatusSchema = object({
|
|
57330
|
-
/** Current illuminance in lux (lx). */
|
|
57331
|
-
lux: number().min(0).meta({
|
|
57332
|
-
|
|
57744
|
+
/** Current illuminance in lux (lx). `null` when the sample was refused (D393). */
|
|
57745
|
+
lux: number().min(0).nullable().meta(readingMeta("illuminance", {
|
|
57746
|
+
precision: 0,
|
|
57333
57747
|
label: "Illuminance"
|
|
57334
|
-
}),
|
|
57748
|
+
})),
|
|
57335
57749
|
/** Ms epoch when the slice was last updated. */
|
|
57336
|
-
lastFetchedAt: number()
|
|
57337
|
-
/** Live display unit from the upstream source (e.g. HA
|
|
57338
|
-
* `attributes.unit_of_measurement`). The UI prefers this over the
|
|
57339
|
-
* role's canonical unit. Absent → fall back to the canonical unit. */
|
|
57340
|
-
unit: string().optional(),
|
|
57341
|
-
/** Suggested decimal places for numeric display.
|
|
57342
|
-
* Populated live from the upstream source when provided (e.g. HA
|
|
57343
|
-
* `attributes.suggested_display_precision`). Falls back to
|
|
57344
|
-
* auto-formatting when absent. */
|
|
57345
|
-
precision: number().int().min(0).max(10).optional()
|
|
57750
|
+
lastFetchedAt: number()
|
|
57346
57751
|
});
|
|
57347
57752
|
var ambientLightSensorCapability = {
|
|
57348
57753
|
name: "ambient-light-sensor",
|
|
@@ -57374,12 +57779,7 @@ var ambientLightSensorCapability = {
|
|
|
57374
57779
|
} } },
|
|
57375
57780
|
/** Clock fields: written, but excluded from the compare that decides
|
|
57376
57781
|
* whether persisting is worth a SQLite commit. */
|
|
57377
|
-
volatileStateFields: ["lastFetchedAt"]
|
|
57378
|
-
customize: {
|
|
57379
|
-
version: 1,
|
|
57380
|
-
advanced: "derive",
|
|
57381
|
-
targets: []
|
|
57382
|
-
}
|
|
57782
|
+
volatileStateFields: ["lastFetchedAt"]
|
|
57383
57783
|
};
|
|
57384
57784
|
/**
|
|
57385
57785
|
* Per-class audio metrics aggregated over a sliding window.
|
|
@@ -57606,10 +58006,7 @@ var BatteryStatusSchema = object({
|
|
|
57606
58006
|
* Consumers must SKIP a null rather than coerce it — `battery-band` already
|
|
57607
58007
|
* declines to band a non-finite reading, which is the correct shape.
|
|
57608
58008
|
*/
|
|
57609
|
-
percentage: number().min(0).max(100).nullable().meta({
|
|
57610
|
-
unit: "%",
|
|
57611
|
-
label: "Charge"
|
|
57612
|
-
}),
|
|
58009
|
+
percentage: number().min(0).max(100).nullable().meta(readingMeta("percentage", { label: "Charge" })),
|
|
57613
58010
|
/**
|
|
57614
58011
|
* Charging source. `'dc'` covers wall/USB adapters; `'solar'` is
|
|
57615
58012
|
* Reolink-specific for the Solar Panel 2 accessory (will become
|
|
@@ -57636,7 +58033,14 @@ var BatteryStatusSchema = object({
|
|
|
57636
58033
|
*/
|
|
57637
58034
|
sleeping: boolean().meta({ label: "Sleeping" }),
|
|
57638
58035
|
/** Ms epoch of the last observation. Lets consumers reason about freshness. */
|
|
57639
|
-
lastUpdated: number(),
|
|
58036
|
+
lastUpdated: number().meta(readingMeta("none")),
|
|
58037
|
+
/**
|
|
58038
|
+
* Battery voltage in volts, for a cell the firmware reports as voltage
|
|
58039
|
+
* rather than a percentage (Ecowitt capacitor packs). Absent on cameras
|
|
58040
|
+
* that only report charge. A second reading on this cap, not a second
|
|
58041
|
+
* `numeric-sensor` on the same device.
|
|
58042
|
+
*/
|
|
58043
|
+
volts: number().nullable().optional().meta(readingMeta("voltage", { label: "Voltage" })),
|
|
57640
58044
|
/**
|
|
57641
58045
|
* Ms epoch of the last time the device PROVED it was reachable — a
|
|
57642
58046
|
* completed firmware round-trip, an observed wake, or an inbound push
|
|
@@ -57688,7 +58092,6 @@ var BATTERY_DEVICE_TYPES = [
|
|
|
57688
58092
|
/** Generic Customize target for the percentage reading (D936). */
|
|
57689
58093
|
var batteryCustomize = {
|
|
57690
58094
|
version: 1,
|
|
57691
|
-
advanced: "derive",
|
|
57692
58095
|
targets: [{
|
|
57693
58096
|
id: "percentage",
|
|
57694
58097
|
cardinality: "scalar",
|
|
@@ -57697,7 +58100,7 @@ var batteryCustomize = {
|
|
|
57697
58100
|
stateField: "percentage"
|
|
57698
58101
|
},
|
|
57699
58102
|
deviceTypes: BATTERY_DEVICE_TYPES,
|
|
57700
|
-
apply: "add
|
|
58103
|
+
apply: "add",
|
|
57701
58104
|
path: "percentage",
|
|
57702
58105
|
sources: [{
|
|
57703
58106
|
kind: "field",
|
|
@@ -57818,10 +58221,16 @@ onStatusChanged: { data: object({
|
|
|
57818
58221
|
/**
|
|
57819
58222
|
* History (D850): recorded series. The generic capture replaces the `battery` series of `pipeline-analytics:stats-5m`.
|
|
57820
58223
|
*/
|
|
57821
|
-
history: { fields: {
|
|
57822
|
-
|
|
57823
|
-
|
|
57824
|
-
|
|
58224
|
+
history: { fields: {
|
|
58225
|
+
percentage: {
|
|
58226
|
+
kind: "gauge",
|
|
58227
|
+
unit: "%"
|
|
58228
|
+
},
|
|
58229
|
+
volts: {
|
|
58230
|
+
kind: "gauge",
|
|
58231
|
+
unit: "V"
|
|
58232
|
+
}
|
|
58233
|
+
} },
|
|
57825
58234
|
customize: batteryCustomize,
|
|
57826
58235
|
/** Clock fields: written, but excluded from the compare that decides
|
|
57827
58236
|
* whether persisting is worth a SQLite commit. */
|
|
@@ -57868,12 +58277,7 @@ var binaryCapability = {
|
|
|
57868
58277
|
history: { fields: { on: { kind: "boolean" } } },
|
|
57869
58278
|
/** Clock fields: written, but excluded from the compare that decides
|
|
57870
58279
|
* whether persisting is worth a SQLite commit. */
|
|
57871
|
-
volatileStateFields: ["lastChangedAt"]
|
|
57872
|
-
customize: {
|
|
57873
|
-
version: 1,
|
|
57874
|
-
advanced: "derive",
|
|
57875
|
-
targets: []
|
|
57876
|
-
}
|
|
58280
|
+
volatileStateFields: ["lastChangedAt"]
|
|
57877
58281
|
};
|
|
57878
58282
|
/**
|
|
57879
58283
|
* Dimmable-light brightness control. Co-exists with `switch` on the
|
|
@@ -57889,7 +58293,7 @@ var binaryCapability = {
|
|
|
57889
58293
|
*/
|
|
57890
58294
|
var BrightnessStatusSchema = object({
|
|
57891
58295
|
/** Current level as 0..100 inclusive. Firmware-reported. */
|
|
57892
|
-
percentage: number().min(0).max(100),
|
|
58296
|
+
percentage: number().min(0).max(100).meta(readingMeta("percentage")),
|
|
57893
58297
|
/** Ms epoch of the last operator-driven change. Useful for UI freshness. */
|
|
57894
58298
|
lastChangedAt: number()
|
|
57895
58299
|
});
|
|
@@ -58343,21 +58747,21 @@ var ClimateControlStatusSchema = object({
|
|
|
58343
58747
|
/** Single setpoint in Celsius. Used by single-target modes
|
|
58344
58748
|
* (heat / cool / dry). Null when the device is in a range mode
|
|
58345
58749
|
* (`heat_cool`) or has no setpoint at all (`fan_only`/`off`). */
|
|
58346
|
-
target: number().nullable(),
|
|
58750
|
+
target: number().nullable().meta(readingMeta("temperature")),
|
|
58347
58751
|
/** Upper bound of the dual setpoint in Celsius. Populated only
|
|
58348
58752
|
* in `heat_cool` mode. */
|
|
58349
|
-
targetHigh: number().nullable(),
|
|
58753
|
+
targetHigh: number().nullable().meta(readingMeta("temperature")),
|
|
58350
58754
|
/** Lower bound of the dual setpoint in Celsius. Populated only
|
|
58351
58755
|
* in `heat_cool` mode. */
|
|
58352
|
-
targetLow: number().nullable(),
|
|
58756
|
+
targetLow: number().nullable().meta(readingMeta("temperature")),
|
|
58353
58757
|
/** Target relative humidity (0..100). Null when the device has no
|
|
58354
58758
|
* humidity control. */
|
|
58355
|
-
targetHumidity: number().min(0).max(100).nullable(),
|
|
58759
|
+
targetHumidity: number().min(0).max(100).nullable().meta(readingMeta("humidity")),
|
|
58356
58760
|
/** Current measured temperature in Celsius. Read-only — pushed by
|
|
58357
58761
|
* the device's internal sensor. */
|
|
58358
|
-
currentTemp: number().nullable(),
|
|
58762
|
+
currentTemp: number().nullable().meta(readingMeta("temperature")),
|
|
58359
58763
|
/** Current measured relative humidity (0..100). Read-only. */
|
|
58360
|
-
currentHumidity: number().min(0).max(100).nullable(),
|
|
58764
|
+
currentHumidity: number().min(0).max(100).nullable().meta(readingMeta("humidity")),
|
|
58361
58765
|
/** Vertical louver swing on/off. Null when the device has no vertical
|
|
58362
58766
|
* swing surface (gate with `DeviceFeature.ClimateSwingVertical`). */
|
|
58363
58767
|
swingVertical: boolean().nullable(),
|
|
@@ -58365,11 +58769,11 @@ var ClimateControlStatusSchema = object({
|
|
|
58365
58769
|
* horizontal swing surface (gate with `DeviceFeature.ClimateSwingHorizontal`). */
|
|
58366
58770
|
swingHorizontal: boolean().nullable(),
|
|
58367
58771
|
/** Lowest setpoint the device accepts, Celsius. Absent / null = not reported. */
|
|
58368
|
-
minTemp: number().nullable().optional(),
|
|
58772
|
+
minTemp: number().nullable().optional().meta(readingMeta("temperature")),
|
|
58369
58773
|
/** Highest setpoint the device accepts, Celsius. Absent / null = not reported. */
|
|
58370
|
-
maxTemp: number().nullable().optional(),
|
|
58774
|
+
maxTemp: number().nullable().optional().meta(readingMeta("temperature")),
|
|
58371
58775
|
/** Setpoint granularity, Celsius (0.5, 1). Absent / null = not reported. */
|
|
58372
|
-
tempStep: number().positive().nullable().optional(),
|
|
58776
|
+
tempStep: number().positive().nullable().optional().meta(readingMeta("temperature")),
|
|
58373
58777
|
/** Ms epoch when the slice was last updated (push or command). */
|
|
58374
58778
|
lastFetchedAt: number()
|
|
58375
58779
|
});
|
|
@@ -58511,17 +58915,17 @@ var climateControlCapability = {
|
|
|
58511
58915
|
* modes to expose in the picker without a slice fetch.
|
|
58512
58916
|
*/
|
|
58513
58917
|
var RgbTripletSchema = object({
|
|
58514
|
-
r: number().int().min(0).max(255),
|
|
58515
|
-
g: number().int().min(0).max(255),
|
|
58516
|
-
b: number().int().min(0).max(255)
|
|
58918
|
+
r: number().int().min(0).max(255).meta(readingMeta("none")),
|
|
58919
|
+
g: number().int().min(0).max(255).meta(readingMeta("none")),
|
|
58920
|
+
b: number().int().min(0).max(255).meta(readingMeta("none"))
|
|
58517
58921
|
});
|
|
58518
58922
|
var HsvTripletSchema = object({
|
|
58519
58923
|
/** Hue in degrees, 0..360. */
|
|
58520
|
-
h: number().min(0).max(360),
|
|
58924
|
+
h: number().min(0).max(360).meta(readingMeta("none")),
|
|
58521
58925
|
/** Saturation as 0..100 inclusive. */
|
|
58522
|
-
s: number().min(0).max(100),
|
|
58926
|
+
s: number().min(0).max(100).meta(readingMeta("none")),
|
|
58523
58927
|
/** Value/brightness as 0..100 inclusive. */
|
|
58524
|
-
v: number().min(0).max(100)
|
|
58928
|
+
v: number().min(0).max(100).meta(readingMeta("none"))
|
|
58525
58929
|
});
|
|
58526
58930
|
var ColorInputSchema = discriminatedUnion("mode", [
|
|
58527
58931
|
object({
|
|
@@ -58550,7 +58954,7 @@ var ColorStatusSchema = object({
|
|
|
58550
58954
|
/** Populated when `mode === 'hsv'`. */
|
|
58551
58955
|
hsv: HsvTripletSchema.optional(),
|
|
58552
58956
|
/** Populated when `mode === 'mired'`. */
|
|
58553
|
-
mireds: number().int().optional(),
|
|
58957
|
+
mireds: number().int().optional().meta(readingMeta("colour-temperature")),
|
|
58554
58958
|
/** Ms epoch of the last operator-driven change. */
|
|
58555
58959
|
lastChangedAt: number()
|
|
58556
58960
|
});
|
|
@@ -58745,18 +59149,12 @@ _enum([
|
|
|
58745
59149
|
"empty",
|
|
58746
59150
|
"full"
|
|
58747
59151
|
]);
|
|
58748
|
-
/**
|
|
58749
|
-
|
|
58750
|
-
|
|
58751
|
-
"days",
|
|
58752
|
-
"hours",
|
|
58753
|
-
"cycles"
|
|
58754
|
-
]);
|
|
58755
|
-
/** Remaining life as a COUNT, not a percentage (the PetKit desiccant reports
|
|
58756
|
-
* days). `value` null = unknown (D393). */
|
|
59152
|
+
/** Whether `remaining.value` is a duration in seconds or a dimensionless count. */
|
|
59153
|
+
var ConsumableRemainingKindSchema = _enum(["duration", "count"]);
|
|
59154
|
+
/** Remaining life. `value` null = unknown (D393). Duration is seconds. */
|
|
58757
59155
|
var ConsumableRemainingSchema = object({
|
|
58758
|
-
value: number().min(0).nullable(),
|
|
58759
|
-
|
|
59156
|
+
value: number().min(0).nullable().meta(readingMeta("device")),
|
|
59157
|
+
kind: ConsumableRemainingKindSchema
|
|
58760
59158
|
});
|
|
58761
59159
|
/** A single consumable item. Either a continuous `level` (remaining
|
|
58762
59160
|
* life %, or fill % for a `supply` / `waste` item) or a discrete `status`
|
|
@@ -58769,7 +59167,7 @@ var ConsumableItemSchema = object({
|
|
|
58769
59167
|
/** Display name. */
|
|
58770
59168
|
label: string().min(1),
|
|
58771
59169
|
/** Remaining life % (`wear`) or fill % (`supply`, `waste`) when known (0..100). */
|
|
58772
|
-
level: number().min(0).max(100).nullable(),
|
|
59170
|
+
level: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
58773
59171
|
/** The provider's discrete verdict when known (binary mode). */
|
|
58774
59172
|
status: ConsumableStatusSchema.nullable(),
|
|
58775
59173
|
/** What the item is — decides whether low or full is bad. Absent = `wear`. */
|
|
@@ -58851,8 +59249,8 @@ var consumablesCustomize = {
|
|
|
58851
59249
|
transforms: [{ kind: "identity" }]
|
|
58852
59250
|
}],
|
|
58853
59251
|
literals: [{
|
|
58854
|
-
path: "remaining.
|
|
58855
|
-
values: [...
|
|
59252
|
+
path: "remaining.kind",
|
|
59253
|
+
values: [...ConsumableRemainingKindSchema.options]
|
|
58856
59254
|
}]
|
|
58857
59255
|
},
|
|
58858
59256
|
{
|
|
@@ -58981,7 +59379,6 @@ reset: method(object({
|
|
|
58981
59379
|
},
|
|
58982
59380
|
"remaining.value": {
|
|
58983
59381
|
kind: "gauge",
|
|
58984
|
-
unitFrom: "remaining.unit",
|
|
58985
59382
|
deadband: 1,
|
|
58986
59383
|
displayName: "Remaining"
|
|
58987
59384
|
}
|
|
@@ -59051,10 +59448,9 @@ var contactCapability = {
|
|
|
59051
59448
|
* (empty array for the other kinds). It lives in the slice because
|
|
59052
59449
|
* HA `select.*` entities may update their options at runtime.
|
|
59053
59450
|
*
|
|
59054
|
-
*
|
|
59055
|
-
*
|
|
59056
|
-
*
|
|
59057
|
-
* push — consistent with `options` and the sensor-unit approach.
|
|
59451
|
+
* Numeric `min` / `max` / `step` live in the slice and share the device
|
|
59452
|
+
* quantity (`SourceInfo.quantity`, D944). Display precision is a read-time
|
|
59453
|
+
* preference. A datetime control's shape is `SourceInfo.dateTimeShape`.
|
|
59058
59454
|
*/
|
|
59059
59455
|
var ControlStatusSchema = object({
|
|
59060
59456
|
kind: _enum([
|
|
@@ -59066,39 +59462,17 @@ var ControlStatusSchema = object({
|
|
|
59066
59462
|
/** Current value. Numeric kind → number; select/text/datetime → string.
|
|
59067
59463
|
* Datetime values are ISO 8601 strings (full timestamp, date-only,
|
|
59068
59464
|
* or time-only — HA accepts all three forms). */
|
|
59069
|
-
value: union([number(), string()]),
|
|
59465
|
+
value: union([number().meta(readingMeta("device")), string()]),
|
|
59070
59466
|
/** Acceptable values when `kind === 'select'`. Empty for other kinds. */
|
|
59071
59467
|
options: array(string()),
|
|
59072
59468
|
/** Ms epoch when the slice was last updated. */
|
|
59073
59469
|
lastChangedAt: number(),
|
|
59074
|
-
/**
|
|
59075
|
-
|
|
59076
|
-
|
|
59077
|
-
|
|
59078
|
-
/**
|
|
59079
|
-
|
|
59080
|
-
min: number().optional(),
|
|
59081
|
-
/** Maximum allowed value. Populated live from HA `attributes.max`.
|
|
59082
|
-
* Meaningful for `kind === 'numeric'`; absent for other kinds. */
|
|
59083
|
-
max: number().optional(),
|
|
59084
|
-
/** Step increment. Populated live from HA `attributes.step`.
|
|
59085
|
-
* Meaningful for `kind === 'numeric'`; absent for other kinds. */
|
|
59086
|
-
step: number().optional(),
|
|
59087
|
-
/** Suggested decimal places for numeric display. Populated live from HA
|
|
59088
|
-
* `attributes.suggested_display_precision`, or derived from `step` when the
|
|
59089
|
-
* HA attribute is absent. Meaningful for `kind === 'numeric'`; absent for
|
|
59090
|
-
* other kinds. Falls back to auto-formatting when absent. */
|
|
59091
|
-
precision: number().int().min(0).max(10).optional(),
|
|
59092
|
-
/** Date-picker granularity for `kind === 'datetime'`. 'date' → date-only,
|
|
59093
|
-
* 'time' → time-only, 'datetime' → full timestamp. Absent for other kinds
|
|
59094
|
-
* (UI defaults to 'datetime'). Derived live from the device's HA domain
|
|
59095
|
-
* (date.* / time.* / datetime.*) or, for input_datetime, from the entity's
|
|
59096
|
-
* `has_date`/`has_time` attributes on each push. */
|
|
59097
|
-
format: _enum([
|
|
59098
|
-
"date",
|
|
59099
|
-
"time",
|
|
59100
|
-
"datetime"
|
|
59101
|
-
]).optional()
|
|
59470
|
+
/** Minimum allowed value, in the device quantity's base unit. */
|
|
59471
|
+
min: number().optional().meta(readingMeta("device")),
|
|
59472
|
+
/** Maximum allowed value, in the device quantity's base unit. */
|
|
59473
|
+
max: number().optional().meta(readingMeta("device")),
|
|
59474
|
+
/** Step increment, in the device quantity's base unit. */
|
|
59475
|
+
step: number().optional().meta(readingMeta("device"))
|
|
59102
59476
|
});
|
|
59103
59477
|
var ControlSetValueInputSchema = discriminatedUnion("kind", [
|
|
59104
59478
|
object({
|
|
@@ -59164,9 +59538,9 @@ var CoverStatusSchema = object({
|
|
|
59164
59538
|
]),
|
|
59165
59539
|
/** 0 = fully closed, 100 = fully open. Null when the device has
|
|
59166
59540
|
* no intermediate position surface. */
|
|
59167
|
-
position: number().min(0).max(100).nullable(),
|
|
59541
|
+
position: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
59168
59542
|
/** 0 = closed slats, 100 = open slats. Null when no tilt support. */
|
|
59169
|
-
tiltPosition: number().min(0).max(100).nullable(),
|
|
59543
|
+
tiltPosition: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
59170
59544
|
/** Ms epoch when the slice was last updated. */
|
|
59171
59545
|
lastChangedAt: number()
|
|
59172
59546
|
});
|
|
@@ -59269,9 +59643,9 @@ var NormalizedRangeSchema$1 = object({
|
|
|
59269
59643
|
var DayNightStatusSchema = object({
|
|
59270
59644
|
mode: DayNightModeSchema,
|
|
59271
59645
|
/** IR-cut trigger sensitivity, NORMALIZED 0–100 (higher = switches to night sooner). */
|
|
59272
|
-
sensitivity: number().optional(),
|
|
59646
|
+
sensitivity: number().optional().meta(readingMeta("none")),
|
|
59273
59647
|
/** Delay before the IR-cut filter flips, in seconds. */
|
|
59274
|
-
switchDelaySec: number().optional(),
|
|
59648
|
+
switchDelaySec: number().optional().meta(readingMeta("duration")),
|
|
59275
59649
|
lastFetchedAt: number()
|
|
59276
59650
|
});
|
|
59277
59651
|
/**
|
|
@@ -59489,11 +59863,11 @@ var DishwasherStatusSchema = object({
|
|
|
59489
59863
|
/** Feature keys of the programs the appliance currently offers — drives the UI selector. */
|
|
59490
59864
|
availablePrograms: array(string()),
|
|
59491
59865
|
/** Seconds remaining on the active cycle, or null when not running / not known. */
|
|
59492
|
-
remainingSeconds: number().int().nonnegative().nullable(),
|
|
59866
|
+
remainingSeconds: number().int().nonnegative().nullable().meta(readingMeta("duration")),
|
|
59493
59867
|
/** Seconds the delayed start is set to (time until the cycle starts), or null. */
|
|
59494
|
-
delayedStartSeconds: number().int().nonnegative().nullable(),
|
|
59868
|
+
delayedStartSeconds: number().int().nonnegative().nullable().meta(readingMeta("duration")),
|
|
59495
59869
|
/** Cycle completion 0..100, or null when not applicable. */
|
|
59496
|
-
progressPercent: number().min(0).max(100).nullable(),
|
|
59870
|
+
progressPercent: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
59497
59871
|
/** True when the door is reported open; null when the door state is not known. */
|
|
59498
59872
|
doorOpen: boolean().nullable(),
|
|
59499
59873
|
/** True when the door is latched (locked) during a cycle; null when not reported. */
|
|
@@ -59517,7 +59891,7 @@ var DishwasherStatusSchema = object({
|
|
|
59517
59891
|
/** True while the machine-care (descaling / cleaning-program) reminder is raised; false when clear; null when not reported. */
|
|
59518
59892
|
machineCareDue: boolean().nullable(),
|
|
59519
59893
|
/** Program runs left before the machine-care reminder is due; null when the appliance does not say. */
|
|
59520
|
-
machineCareRemainingRuns: number().int().nonnegative().nullable(),
|
|
59894
|
+
machineCareRemainingRuns: number().int().nonnegative().nullable().meta(readingMeta("count")),
|
|
59521
59895
|
/** Option states: null when the appliance does not expose the option or has not said. */
|
|
59522
59896
|
halfLoad: boolean().nullable(),
|
|
59523
59897
|
hygienePlus: boolean().nullable(),
|
|
@@ -59532,7 +59906,7 @@ var DishwasherStatusSchema = object({
|
|
|
59532
59906
|
/** Feature keys of the events currently raised (salt low, rinse aid low, program finished, …). */
|
|
59533
59907
|
activeEvents: array(string()),
|
|
59534
59908
|
/** Numeric error code when the appliance reports one; null otherwise. */
|
|
59535
|
-
errorCode: number().nullable(),
|
|
59909
|
+
errorCode: number().nullable().meta(readingMeta("none")),
|
|
59536
59910
|
/** Name of the raised alert-level event while the appliance is in error; null otherwise. */
|
|
59537
59911
|
errorLabel: string().nullable(),
|
|
59538
59912
|
/** Ms epoch of the last value received from the appliance; 0 = never. */
|
|
@@ -59744,6 +60118,7 @@ var doorbellCustomize = {
|
|
|
59744
60118
|
applyAuthority: { kind: "composition-claim" },
|
|
59745
60119
|
eventName: "onPressed",
|
|
59746
60120
|
edges: ["rising"],
|
|
60121
|
+
defaultEdge: "rising",
|
|
59747
60122
|
timestampPath: "lastPressedAt",
|
|
59748
60123
|
counterPath: "pressCountSinceStart",
|
|
59749
60124
|
highWater: "composer-advance",
|
|
@@ -59762,7 +60137,7 @@ var DoorbellStatusSchema = object({
|
|
|
59762
60137
|
/** Ms epoch of the last press. null = never observed since this provider started. */
|
|
59763
60138
|
lastPressedAt: number().nullable(),
|
|
59764
60139
|
/** Counter since provider start. Resets on reboot. Useful for metrics/debug. */
|
|
59765
|
-
pressCountSinceStart: number()
|
|
60140
|
+
pressCountSinceStart: number().meta(readingMeta("count"))
|
|
59766
60141
|
});
|
|
59767
60142
|
var DoorbellPressEventSchema = object({
|
|
59768
60143
|
deviceId: number(),
|
|
@@ -59827,17 +60202,7 @@ onPressed: {
|
|
|
59827
60202
|
history: "none",
|
|
59828
60203
|
customize: doorbellCustomize
|
|
59829
60204
|
};
|
|
59830
|
-
|
|
59831
|
-
* Enum-state sensor — a string value picked from a finite option set.
|
|
59832
|
-
* Drives HA `sensor` entries with `state_class: enum` (HVAC action
|
|
59833
|
-
* states, weather conditions, contact-source channels, mode strings).
|
|
59834
|
-
* The option set is stable across observations; it is persisted in the
|
|
59835
|
-
* device config blob (via the control slice at adoption) and is NOT
|
|
59836
|
-
* stored in `sourceInfo`.
|
|
59837
|
-
*/
|
|
59838
|
-
/** Locale-render shape for an ISO `value` carried by a `DateTimeSensor`-role
|
|
59839
|
-
* enum sensor: `date` (date-only), `time` (time-only), `datetime` (both). */
|
|
59840
|
-
var EnumSensorDateTimeFormatSchema = _enum([
|
|
60205
|
+
_enum([
|
|
59841
60206
|
"date",
|
|
59842
60207
|
"time",
|
|
59843
60208
|
"datetime"
|
|
@@ -59845,12 +60210,11 @@ var EnumSensorDateTimeFormatSchema = _enum([
|
|
|
59845
60210
|
var EnumSensorStatusSchema = object({
|
|
59846
60211
|
value: string(),
|
|
59847
60212
|
/**
|
|
59848
|
-
* Set
|
|
59849
|
-
* as
|
|
59850
|
-
*
|
|
59851
|
-
* a time-only sensor → `'time'`.
|
|
60213
|
+
* Set when `value` is a timestamp rather than an enum state, so history
|
|
60214
|
+
* does not learn ISO strings as states. The display shape (date / time /
|
|
60215
|
+
* datetime) lives on `SourceInfo.dateTimeShape`, written once at adopt.
|
|
59852
60216
|
*/
|
|
59853
|
-
|
|
60217
|
+
timestamp: boolean().optional(),
|
|
59854
60218
|
/** Ms epoch when the slice was last updated. */
|
|
59855
60219
|
lastFetchedAt: number()
|
|
59856
60220
|
});
|
|
@@ -59877,11 +60241,11 @@ var enumSensorCapability = {
|
|
|
59877
60241
|
* History (D850): the value as an `enum` series (an appliance's program or
|
|
59878
60242
|
* operation state, an HVAC action). The option set is per device, so the
|
|
59879
60243
|
* value list is LEARNED as values are first seen (bounded). A sensor with a
|
|
59880
|
-
* `
|
|
60244
|
+
* `timestamp` carries a clock, not a state, and is not recorded.
|
|
59881
60245
|
*/
|
|
59882
60246
|
history: { fields: { value: {
|
|
59883
60247
|
kind: "enum",
|
|
59884
|
-
skipWhenSet: "
|
|
60248
|
+
skipWhenSet: "timestamp"
|
|
59885
60249
|
} } },
|
|
59886
60250
|
/** Clock fields: written, but excluded from the compare that decides
|
|
59887
60251
|
* whether persisting is worth a SQLite commit. */
|
|
@@ -59901,13 +60265,13 @@ var EventFireSchema = object({
|
|
|
59901
60265
|
deviceId: number(),
|
|
59902
60266
|
eventType: string(),
|
|
59903
60267
|
data: record(string(), unknown()).nullable(),
|
|
59904
|
-
timestamp: number(),
|
|
59905
|
-
seq: number()
|
|
60268
|
+
timestamp: number().meta(readingMeta("none")),
|
|
60269
|
+
seq: number().meta(readingMeta("count"))
|
|
59906
60270
|
});
|
|
59907
60271
|
var EventEmitterStatusSchema = object({
|
|
59908
60272
|
eventTypes: array(string()),
|
|
59909
60273
|
lastEvent: EventFireSchema.nullable(),
|
|
59910
|
-
eventCountSinceStart: number()
|
|
60274
|
+
eventCountSinceStart: number().meta(readingMeta("count"))
|
|
59911
60275
|
});
|
|
59912
60276
|
var eventEmitterCapability = {
|
|
59913
60277
|
name: "event-emitter",
|
|
@@ -60320,10 +60684,10 @@ var FanDirectionSchema = _enum(["forward", "reverse"]);
|
|
|
60320
60684
|
var FanControlStatusSchema = object({
|
|
60321
60685
|
/** Active speed as 0..100 inclusive. Null when the device has no
|
|
60322
60686
|
* speed surface (single-speed fan). */
|
|
60323
|
-
percentage: number().min(0).max(100).nullable(),
|
|
60687
|
+
percentage: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
60324
60688
|
/** Speed granularity the device accepts (HA `percentage_step`, e.g. 25 for
|
|
60325
60689
|
* a 4-speed fan). Absent when unknown — the UI then falls back to step 1. */
|
|
60326
|
-
percentageStep: number().positive().optional(),
|
|
60690
|
+
percentageStep: number().positive().optional().meta(readingMeta("percentage")),
|
|
60327
60691
|
/** Active preset mode (`auto` / `quiet` / `turbo` / vendor-specific)
|
|
60328
60692
|
* — empty string when no preset is active or supported. */
|
|
60329
60693
|
preset: string(),
|
|
@@ -60444,7 +60808,7 @@ var FeatureProbeStatusSchema = object({
|
|
|
60444
60808
|
/** Camera/firmware model string. `null` when the firmware doesn't expose it. */
|
|
60445
60809
|
model: string().nullable(),
|
|
60446
60810
|
/** Channel count for NVR/Hub devices; `1` for standalone cameras; `null` pre-probe. */
|
|
60447
|
-
channelCount: number().nullable(),
|
|
60811
|
+
channelCount: number().nullable().meta(readingMeta("count")),
|
|
60448
60812
|
/**
|
|
60449
60813
|
* Ms epoch of the last SUCCESSFUL probe. `0` before the first probe
|
|
60450
60814
|
* completes — drivers' `getAccessoryChildren()` should treat zero as
|
|
@@ -60567,9 +60931,91 @@ var gasCapability = {
|
|
|
60567
60931
|
* whether persisting is worth a SQLite commit. */
|
|
60568
60932
|
volatileStateFields: ["lastChangedAt"]
|
|
60569
60933
|
};
|
|
60934
|
+
var GroupCommandsSchema = object({
|
|
60935
|
+
/** One row per member that has been commanded. A later command replaces that member's row. */
|
|
60936
|
+
results: array(object({
|
|
60937
|
+
deviceId: number().int().nonnegative(),
|
|
60938
|
+
cap: string().min(1),
|
|
60939
|
+
method: string().min(1),
|
|
60940
|
+
ok: boolean(),
|
|
60941
|
+
error: string().optional(),
|
|
60942
|
+
/** Ms epoch of the attempt. */
|
|
60943
|
+
at: number()
|
|
60944
|
+
})) });
|
|
60945
|
+
var groupCommandsCapability = {
|
|
60946
|
+
name: "group-commands",
|
|
60947
|
+
scope: "device",
|
|
60948
|
+
deviceNative: true,
|
|
60949
|
+
mode: "singleton",
|
|
60950
|
+
deviceTypes: [DeviceType.Switch, DeviceType.Light],
|
|
60951
|
+
methods: {},
|
|
60952
|
+
status: {
|
|
60953
|
+
schema: GroupCommandsSchema,
|
|
60954
|
+
kind: "push"
|
|
60955
|
+
},
|
|
60956
|
+
runtimeState: GroupCommandsSchema,
|
|
60957
|
+
/**
|
|
60958
|
+
* Runtime-state durability: **session** — the last attempt. A restored
|
|
60959
|
+
* failure would outlive the command that caused it.
|
|
60960
|
+
*
|
|
60961
|
+
* See `RuntimeStateDurability`. Enforced by
|
|
60962
|
+
* `scripts/check-runtime-state-durability.ts`.
|
|
60963
|
+
*/
|
|
60964
|
+
durability: "session",
|
|
60965
|
+
history: "none"
|
|
60966
|
+
};
|
|
60967
|
+
/**
|
|
60968
|
+
* How many members of a helper group answered (D944). Counts are integers,
|
|
60969
|
+
* not measurements: zero included is a real count, never a stand-in reading.
|
|
60970
|
+
* The reading itself stays on the output capability. History is none — the
|
|
60971
|
+
* series that later statistics read is the output cap's own history block.
|
|
60972
|
+
*/
|
|
60973
|
+
var GroupStatusSchema = object({
|
|
60974
|
+
/** Members whose current value entered the aggregate. */
|
|
60975
|
+
included: number().int().nonnegative().meta(readingMeta("count", {
|
|
60976
|
+
precision: 0,
|
|
60977
|
+
label: "Reporting"
|
|
60978
|
+
})),
|
|
60979
|
+
/** Members left out: offline, unknown, or not a finite reading (D393). */
|
|
60980
|
+
excluded: number().int().nonnegative().meta(readingMeta("count", {
|
|
60981
|
+
precision: 0,
|
|
60982
|
+
label: "Excluded"
|
|
60983
|
+
})),
|
|
60984
|
+
/** `included` + `excluded`. */
|
|
60985
|
+
total: number().int().nonnegative().meta(readingMeta("count", {
|
|
60986
|
+
precision: 0,
|
|
60987
|
+
label: "Members"
|
|
60988
|
+
}))
|
|
60989
|
+
});
|
|
60990
|
+
var groupStatusCapability = {
|
|
60991
|
+
name: "group-status",
|
|
60992
|
+
scope: "device",
|
|
60993
|
+
deviceNative: true,
|
|
60994
|
+
mode: "singleton",
|
|
60995
|
+
deviceTypes: [
|
|
60996
|
+
DeviceType.Sensor,
|
|
60997
|
+
DeviceType.Switch,
|
|
60998
|
+
DeviceType.Light
|
|
60999
|
+
],
|
|
61000
|
+
methods: {},
|
|
61001
|
+
status: {
|
|
61002
|
+
schema: GroupStatusSchema,
|
|
61003
|
+
kind: "push"
|
|
61004
|
+
},
|
|
61005
|
+
runtimeState: GroupStatusSchema,
|
|
61006
|
+
/**
|
|
61007
|
+
* Runtime-state durability: **session** — recomputed from members on the
|
|
61008
|
+
* next source event; a restored count would outlive the readings it named.
|
|
61009
|
+
*
|
|
61010
|
+
* See `RuntimeStateDurability`. Enforced by
|
|
61011
|
+
* `scripts/check-runtime-state-durability.ts`.
|
|
61012
|
+
*/
|
|
61013
|
+
durability: "session",
|
|
61014
|
+
history: "none"
|
|
61015
|
+
};
|
|
60570
61016
|
var HeatingValveStatusSchema = object({
|
|
60571
61017
|
/** Radiator valve opening 0 (closed) .. 100 (open). Null = not yet known. */
|
|
60572
|
-
position: number().min(0).max(100).nullable(),
|
|
61018
|
+
position: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
60573
61019
|
/** Ms epoch when the slice was last updated (push or poll). */
|
|
60574
61020
|
lastFetchedAt: number()
|
|
60575
61021
|
});
|
|
@@ -60612,9 +61058,9 @@ var HumidifierStatusSchema = object({
|
|
|
60612
61058
|
/** Whether the humidifier is currently on. */
|
|
60613
61059
|
on: boolean(),
|
|
60614
61060
|
/** Current measured relative humidity (0..100). Null when not reported. */
|
|
60615
|
-
currentHumidity: number().min(0).max(100).nullable(),
|
|
61061
|
+
currentHumidity: number().min(0).max(100).nullable().meta(readingMeta("humidity")),
|
|
60616
61062
|
/** Target relative humidity (0..100). Null when no setpoint surface. */
|
|
60617
|
-
targetHumidity: number().min(0).max(100).nullable(),
|
|
61063
|
+
targetHumidity: number().min(0).max(100).nullable().meta(readingMeta("humidity")),
|
|
60618
61064
|
/** Active mode (`auto` / `normal` / `baby` / vendor). Null when the
|
|
60619
61065
|
* device has no mode surface. */
|
|
60620
61066
|
mode: string().nullable(),
|
|
@@ -60624,9 +61070,9 @@ var HumidifierStatusSchema = object({
|
|
|
60624
61070
|
* `idle` / `off`). Null when the device doesn't report it. */
|
|
60625
61071
|
action: string().nullable(),
|
|
60626
61072
|
/** HA `min_humidity` attribute. Null → UI uses 0. */
|
|
60627
|
-
minHumidity: number().nullable(),
|
|
61073
|
+
minHumidity: number().nullable().meta(readingMeta("humidity")),
|
|
60628
61074
|
/** HA `max_humidity` attribute. Null → UI uses 100. */
|
|
60629
|
-
maxHumidity: number().nullable(),
|
|
61075
|
+
maxHumidity: number().nullable().meta(readingMeta("humidity")),
|
|
60630
61076
|
/** Ms epoch when the slice was last updated. */
|
|
60631
61077
|
lastChangedAt: number()
|
|
60632
61078
|
});
|
|
@@ -60696,22 +61142,13 @@ var humidifierCapability = {
|
|
|
60696
61142
|
* `sourceInfo`.
|
|
60697
61143
|
*/
|
|
60698
61144
|
var HumiditySensorStatusSchema = object({
|
|
60699
|
-
/** Current relative humidity, 0..100. */
|
|
60700
|
-
percent: number().min(0).max(100).meta({
|
|
60701
|
-
|
|
61145
|
+
/** Current relative humidity, 0..100. `null` when the sample was refused (D393). */
|
|
61146
|
+
percent: number().min(0).max(100).nullable().meta(readingMeta("humidity", {
|
|
61147
|
+
precision: 0,
|
|
60702
61148
|
label: "Humidity"
|
|
60703
|
-
}),
|
|
61149
|
+
})),
|
|
60704
61150
|
/** Ms epoch when the slice was last updated. */
|
|
60705
|
-
lastFetchedAt: number()
|
|
60706
|
-
/** Live display unit from the upstream source (e.g. HA
|
|
60707
|
-
* `attributes.unit_of_measurement`). The UI prefers this over the
|
|
60708
|
-
* role's canonical unit. Absent → fall back to the canonical unit. */
|
|
60709
|
-
unit: string().optional(),
|
|
60710
|
-
/** Suggested decimal places for numeric display.
|
|
60711
|
-
* Populated live from the upstream source when provided (e.g. HA
|
|
60712
|
-
* `attributes.suggested_display_precision`). Falls back to
|
|
60713
|
-
* auto-formatting when absent. */
|
|
60714
|
-
precision: number().int().min(0).max(10).optional()
|
|
61151
|
+
lastFetchedAt: number()
|
|
60715
61152
|
});
|
|
60716
61153
|
var humiditySensorCapability = {
|
|
60717
61154
|
name: "humidity-sensor",
|
|
@@ -60742,12 +61179,7 @@ var humiditySensorCapability = {
|
|
|
60742
61179
|
} } },
|
|
60743
61180
|
/** Clock fields: written, but excluded from the compare that decides
|
|
60744
61181
|
* whether persisting is worth a SQLite commit. */
|
|
60745
|
-
volatileStateFields: ["lastFetchedAt"]
|
|
60746
|
-
customize: {
|
|
60747
|
-
version: 1,
|
|
60748
|
-
advanced: "derive",
|
|
60749
|
-
targets: []
|
|
60750
|
-
}
|
|
61182
|
+
volatileStateFields: ["lastFetchedAt"]
|
|
60751
61183
|
};
|
|
60752
61184
|
/**
|
|
60753
61185
|
* Image display cap. Models a single still image exposed by an integration —
|
|
@@ -60768,7 +61200,7 @@ var ImageStatusSchema = object({
|
|
|
60768
61200
|
* entity exposes no `entity_picture` (yet). */
|
|
60769
61201
|
url: string().nullable(),
|
|
60770
61202
|
/** Ms epoch of the upstream last-updated timestamp. Null at cold-start. */
|
|
60771
|
-
lastUpdated: number().nullable()
|
|
61203
|
+
lastUpdated: number().nullable().meta(readingMeta("none"))
|
|
60772
61204
|
});
|
|
60773
61205
|
var imageCapability = {
|
|
60774
61206
|
name: "image",
|
|
@@ -60856,19 +61288,19 @@ var NormalizedRangeSchema = object({
|
|
|
60856
61288
|
*/
|
|
60857
61289
|
var ImageSettingsStatusSchema = object({
|
|
60858
61290
|
/** Normalized 0–100. */
|
|
60859
|
-
brightness: number().optional(),
|
|
61291
|
+
brightness: number().optional().meta(readingMeta("none")),
|
|
60860
61292
|
/** Normalized 0–100. */
|
|
60861
|
-
contrast: number().optional(),
|
|
61293
|
+
contrast: number().optional().meta(readingMeta("none")),
|
|
60862
61294
|
/** Normalized 0–100. */
|
|
60863
|
-
saturation: number().optional(),
|
|
61295
|
+
saturation: number().optional().meta(readingMeta("none")),
|
|
60864
61296
|
/** Normalized 0–100. */
|
|
60865
|
-
sharpness: number().optional(),
|
|
61297
|
+
sharpness: number().optional().meta(readingMeta("none")),
|
|
60866
61298
|
mirror: boolean().optional(),
|
|
60867
61299
|
flip: boolean().optional(),
|
|
60868
61300
|
rotate: ImageRotateSchema.optional(),
|
|
60869
61301
|
whiteBalance: WhiteBalanceModeSchema.optional(),
|
|
60870
61302
|
/** Manual white-balance warmth, NORMALIZED 0–100. Meaningful only when `whiteBalance === 'manual'`. */
|
|
60871
|
-
warmth: number().optional(),
|
|
61303
|
+
warmth: number().optional().meta(readingMeta("none")),
|
|
60872
61304
|
exposureMode: ExposureModeSchema.optional(),
|
|
60873
61305
|
backlightMode: BacklightModeSchema.optional(),
|
|
60874
61306
|
lastFetchedAt: number()
|
|
@@ -61147,10 +61579,10 @@ var IntercomAbilitySchema = object({
|
|
|
61147
61579
|
/** Codecs accepted by firmware, in preference order. Driver-authored strings. */
|
|
61148
61580
|
codecs: array(string()),
|
|
61149
61581
|
/** Sample rate (Hz) the firmware expects. Reolink typical: 16000. */
|
|
61150
|
-
sampleRate: number(),
|
|
61582
|
+
sampleRate: number().meta(readingMeta("none")),
|
|
61151
61583
|
duplex: _enum(["half", "full"]),
|
|
61152
61584
|
/** Max in-flight audio backlog before drop (ms). Server uses this to bound latency. */
|
|
61153
|
-
maxBacklogMs: number()
|
|
61585
|
+
maxBacklogMs: number().meta(readingMeta("duration-ms"))
|
|
61154
61586
|
});
|
|
61155
61587
|
var IntercomStatusSchema = object({
|
|
61156
61588
|
/** True while a talk session is open. */
|
|
@@ -61377,13 +61809,13 @@ var LawnMowerControlStatusSchema = object({
|
|
|
61377
61809
|
activity: LawnMowerActivitySchema,
|
|
61378
61810
|
/** 0..100 battery percentage. Null when the device has no battery
|
|
61379
61811
|
* reading. */
|
|
61380
|
-
batteryLevel: number().min(0).max(100).nullable(),
|
|
61812
|
+
batteryLevel: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
61381
61813
|
/** 0..100 mowing-completion percentage of the current task, or null when no
|
|
61382
61814
|
* task is active / progress is unavailable. */
|
|
61383
|
-
progressPercent: number().min(0).max(100).nullable(),
|
|
61815
|
+
progressPercent: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
61384
61816
|
/** Current device/event code (dynamic — mostly status, sometimes an error),
|
|
61385
61817
|
* or null when unknown. */
|
|
61386
|
-
currentCode: number().nullable(),
|
|
61818
|
+
currentCode: number().nullable().meta(readingMeta("none")),
|
|
61387
61819
|
/** Human label for {@link currentCode}, or null when undecodable. */
|
|
61388
61820
|
currentCodeLabel: string().nullable(),
|
|
61389
61821
|
/** Severity of {@link currentCode}. `error` (and often `warning`) warrants UI
|
|
@@ -61916,7 +62348,7 @@ var MediaPlayerStatusSchema = object({
|
|
|
61916
62348
|
state: MediaPlayerStateSchema,
|
|
61917
62349
|
/** Volume as 0..100 inclusive. Null when the device has no volume
|
|
61918
62350
|
* surface. Pair with `DeviceFeature.MediaPlayerVolume`. */
|
|
61919
|
-
volumeLevel: number().min(0).max(100).nullable(),
|
|
62351
|
+
volumeLevel: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
61920
62352
|
/** Mute toggle distinct from volume=0. Null when no mute surface.
|
|
61921
62353
|
* Pair with `DeviceFeature.MediaPlayerMute`. */
|
|
61922
62354
|
isMuted: boolean().nullable(),
|
|
@@ -61929,10 +62361,10 @@ var MediaPlayerStatusSchema = object({
|
|
|
61929
62361
|
currentMedia: MediaInfoSchema.nullable(),
|
|
61930
62362
|
/** Current playback position in ms. Null when not seekable or
|
|
61931
62363
|
* nothing is playing. Pair with `DeviceFeature.MediaPlayerSeek`. */
|
|
61932
|
-
positionMs: number().int().nonnegative().nullable(),
|
|
62364
|
+
positionMs: number().int().nonnegative().nullable().meta(readingMeta("duration-ms")),
|
|
61933
62365
|
/** Total duration of the current media in ms. Null when unknown
|
|
61934
62366
|
* (live stream) or nothing is playing. */
|
|
61935
|
-
durationMs: number().int().nonnegative().nullable(),
|
|
62367
|
+
durationMs: number().int().nonnegative().nullable().meta(readingMeta("duration-ms")),
|
|
61936
62368
|
/** Shuffle toggle. Null when no shuffle surface.
|
|
61937
62369
|
* Pair with `DeviceFeature.MediaPlayerShuffle`. */
|
|
61938
62370
|
shuffle: boolean().nullable(),
|
|
@@ -62241,7 +62673,7 @@ var motionCustomize = {
|
|
|
62241
62673
|
eventName: "onMotionChanged"
|
|
62242
62674
|
},
|
|
62243
62675
|
deviceTypes: [DeviceType.Camera],
|
|
62244
|
-
apply: "
|
|
62676
|
+
apply: "add",
|
|
62245
62677
|
applyAuthority: {
|
|
62246
62678
|
kind: "camera-sensors",
|
|
62247
62679
|
timeoutField: "motionCooldownMs"
|
|
@@ -62313,7 +62745,7 @@ var MotionStatusSchema = object({
|
|
|
62313
62745
|
* it, every provider seeded it at boot, and every session left it
|
|
62314
62746
|
* `detected: true` after its detach.
|
|
62315
62747
|
*/
|
|
62316
|
-
autoClearAfterMs: number().nullable()
|
|
62748
|
+
autoClearAfterMs: number().nullable().meta(readingMeta("duration-ms"))
|
|
62317
62749
|
});
|
|
62318
62750
|
/**
|
|
62319
62751
|
* Payload of `motion.onMotionChanged` event + the corresponding bus
|
|
@@ -62350,12 +62782,18 @@ var motionCapability = {
|
|
|
62350
62782
|
methods: {
|
|
62351
62783
|
/**
|
|
62352
62784
|
* Pull the current motion state synchronously. Convenience shortcut
|
|
62353
|
-
* for consumers that don't need the full status object
|
|
62354
|
-
*
|
|
62355
|
-
* `getStatus` once the auto-injected status surface lands in every
|
|
62356
|
-
* consumer.
|
|
62785
|
+
* for consumers that don't need the full status object. A composed
|
|
62786
|
+
* group answers from its slice (D944): unknown throws, it is not off.
|
|
62357
62787
|
*/
|
|
62358
62788
|
isDetected: method(object({ deviceId: number() }), boolean()) },
|
|
62789
|
+
/**
|
|
62790
|
+
* A composed motion group serves `isDetected` from `detected` (D944).
|
|
62791
|
+
* Without this the cap stays uncomposable (`has-commands`).
|
|
62792
|
+
*/
|
|
62793
|
+
composedMethods: { isDetected: {
|
|
62794
|
+
kind: "slice",
|
|
62795
|
+
field: "detected"
|
|
62796
|
+
} },
|
|
62359
62797
|
events: {
|
|
62360
62798
|
/**
|
|
62361
62799
|
* Fires every time the runner transitions a camera between
|
|
@@ -62495,7 +62933,7 @@ var MotionZoneRegionSchema = object({
|
|
|
62495
62933
|
* the grid region(s). */
|
|
62496
62934
|
var MotionZoneStatusSchema = object({
|
|
62497
62935
|
enabled: boolean(),
|
|
62498
|
-
sensitivity: number(),
|
|
62936
|
+
sensitivity: number().meta(readingMeta("none")),
|
|
62499
62937
|
/** Grid region(s). Today exactly one `grid` shape. */
|
|
62500
62938
|
regions: array(MotionZoneRegionSchema),
|
|
62501
62939
|
lastFetchedAt: number()
|
|
@@ -62865,7 +63303,7 @@ var NavigationStatusSchema = object({
|
|
|
62865
63303
|
following: boolean(),
|
|
62866
63304
|
flash: boolean(),
|
|
62867
63305
|
lightMode: NavigationLightModeSchema,
|
|
62868
|
-
lightLevel: number().min(40).max(100),
|
|
63306
|
+
lightLevel: number().min(40).max(100).meta(readingMeta("none")),
|
|
62869
63307
|
/** Ms epoch when the slice was last updated. */
|
|
62870
63308
|
lastChangedAt: number()
|
|
62871
63309
|
});
|
|
@@ -62999,13 +63437,13 @@ var NetworkLinkStatusSchema = object({
|
|
|
62999
63437
|
* one whose reading has not landed must not be drawn at 0 %. Consumers
|
|
63000
63438
|
* SKIP a null rather than coerce it.
|
|
63001
63439
|
*/
|
|
63002
|
-
signalPercent: number().min(0).max(100).nullable(),
|
|
63440
|
+
signalPercent: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
63003
63441
|
/** Raw received signal strength in dBm, when the firmware reports one. */
|
|
63004
|
-
rssiDbm: number().optional(),
|
|
63442
|
+
rssiDbm: number().optional().meta(readingMeta("signal-level")),
|
|
63005
63443
|
/** Network name of a wireless link, when the firmware reports it. */
|
|
63006
63444
|
ssid: string().optional(),
|
|
63007
63445
|
/** Ms epoch of the last observation. Lets consumers reason about freshness. */
|
|
63008
|
-
lastUpdated: number()
|
|
63446
|
+
lastUpdated: number().meta(readingMeta("none"))
|
|
63009
63447
|
});
|
|
63010
63448
|
var networkLinkCapability = {
|
|
63011
63449
|
name: "network-link",
|
|
@@ -63390,7 +63828,7 @@ var NotifierStatusSchema = object({
|
|
|
63390
63828
|
lastError: string().nullable(),
|
|
63391
63829
|
/** Number of deliveries currently buffered server-side (rate-limited
|
|
63392
63830
|
* notifiers may queue). 0 when the provider sends synchronously. */
|
|
63393
|
-
queueDepth: number().int().nonnegative(),
|
|
63831
|
+
queueDepth: number().int().nonnegative().meta(readingMeta("count")),
|
|
63394
63832
|
/** Per-feature capability matrix — authoritative source for the
|
|
63395
63833
|
* compose-form field gating. */
|
|
63396
63834
|
supports: NotifierSupportsSchema
|
|
@@ -63482,11 +63920,9 @@ onSent: { data: object({
|
|
|
63482
63920
|
* cap fits (HA `sensor` whose `device_class` we don't have a typed cap
|
|
63483
63921
|
* for: water flow, distance, weight, frequency, signal strength, …).
|
|
63484
63922
|
*
|
|
63485
|
-
* The
|
|
63486
|
-
*
|
|
63487
|
-
*
|
|
63488
|
-
* The UI reads them directly from the slice — they are the single source
|
|
63489
|
-
* of truth for generic numeric rendering and do NOT live on `sourceInfo`.
|
|
63923
|
+
* The quantity is not on this slice. It is chosen when the device is
|
|
63924
|
+
* adopted and stored once on `SourceInfo.quantity` (D944). `value` is in
|
|
63925
|
+
* that quantity's base unit. `null` is a refused sample (D393).
|
|
63490
63926
|
*
|
|
63491
63927
|
* Prefer the typed alternatives (`temperature-sensor`, `humidity-sensor`,
|
|
63492
63928
|
* `ambient-light-sensor`, `pressure-sensor`, `power-meter`,
|
|
@@ -63495,15 +63931,8 @@ onSent: { data: object({
|
|
|
63495
63931
|
* numeric values land here.
|
|
63496
63932
|
*/
|
|
63497
63933
|
var NumericSensorStatusSchema = object({
|
|
63498
|
-
|
|
63499
|
-
|
|
63500
|
-
* Populated live from the upstream source on each state push.
|
|
63501
|
-
* Absent for unitless sensors. */
|
|
63502
|
-
unit: string().optional(),
|
|
63503
|
-
/** Suggested decimal places for numeric display.
|
|
63504
|
-
* Populated live from the upstream source when provided.
|
|
63505
|
-
* Falls back to auto-formatting when absent. */
|
|
63506
|
-
precision: number().int().min(0).max(10).optional(),
|
|
63934
|
+
/** Reading in the device quantity's base unit. `null` when refused (D393). */
|
|
63935
|
+
value: number().nullable().meta(readingMeta("device")),
|
|
63507
63936
|
/** Ms epoch when the slice was last updated. */
|
|
63508
63937
|
lastFetchedAt: number()
|
|
63509
63938
|
});
|
|
@@ -63527,11 +63956,11 @@ var numericSensorCapability = {
|
|
|
63527
63956
|
*/
|
|
63528
63957
|
durability: "restored",
|
|
63529
63958
|
/**
|
|
63530
|
-
* History (D850): recorded series. The unit is
|
|
63959
|
+
* History (D850): recorded series. The unit is the device quantity's base,
|
|
63960
|
+
* resolved when the series is read — the cap has no single unit.
|
|
63531
63961
|
*/
|
|
63532
63962
|
history: { fields: { value: {
|
|
63533
63963
|
kind: "gauge",
|
|
63534
|
-
unitFrom: "unit",
|
|
63535
63964
|
minIntervalMs: 3e4
|
|
63536
63965
|
} } },
|
|
63537
63966
|
/** Clock fields: written, but excluded from the compare that decides
|
|
@@ -63869,23 +64298,26 @@ var PetFeederStatusSchema = object({
|
|
|
63869
64298
|
/** Food currently in the bowl (grams). Null when the device has not
|
|
63870
64299
|
* reported a reading yet. On dual-hopper models this is the combined
|
|
63871
64300
|
* bowl reading; per-hopper levels live in `food1`/`food2`. */
|
|
63872
|
-
foodLevel: number().nullable(),
|
|
64301
|
+
foodLevel: number().nullable().meta(readingMeta("none")),
|
|
63873
64302
|
/** Hopper-1 food level (grams) on dual-hopper feeders; null on
|
|
63874
64303
|
* single-hopper models. */
|
|
63875
|
-
food1: number().nullable(),
|
|
64304
|
+
food1: number().nullable().meta(readingMeta("none")),
|
|
63876
64305
|
/** Hopper-2 food level (grams) on dual-hopper feeders; null on
|
|
63877
64306
|
* single-hopper models. */
|
|
63878
|
-
food2: number().nullable(),
|
|
64307
|
+
food2: number().nullable().meta(readingMeta("none")),
|
|
63879
64308
|
/** Derived low-food flag — mirrors the HA `food_level` binary_sensor
|
|
63880
64309
|
* (`device_class: problem`, on = low). True when the bowl is empty /
|
|
63881
64310
|
* below the feeder's low threshold. */
|
|
63882
64311
|
lowFood: boolean(),
|
|
63883
64312
|
/** Battery charge 0..100 (%). Null on mains-powered models or when the
|
|
63884
64313
|
* device has no battery reading. */
|
|
63885
|
-
batteryPower: number().min(0).max(100).nullable(),
|
|
63886
|
-
/**
|
|
63887
|
-
*
|
|
63888
|
-
|
|
64314
|
+
batteryPower: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
64315
|
+
/**
|
|
64316
|
+
* Desiccant life remaining, stored in seconds (duration base, D944).
|
|
64317
|
+
* Providers convert from the days the feeder reports. Null when the
|
|
64318
|
+
* model has no desiccant sensor.
|
|
64319
|
+
*/
|
|
64320
|
+
desiccantLeftDays: number().nullable().meta(readingMeta("duration")),
|
|
63889
64321
|
/** True while a feed is in progress. */
|
|
63890
64322
|
feeding: boolean(),
|
|
63891
64323
|
/** Decoded connectivity / power status (HA petkit device-status enum).
|
|
@@ -63896,7 +64328,7 @@ var PetFeederStatusSchema = object({
|
|
|
63896
64328
|
* with `errorCode` for consumers that want the raw integer. */
|
|
63897
64329
|
error: string().nullable(),
|
|
63898
64330
|
/** Raw device error code (0 / null = no error). */
|
|
63899
|
-
errorCode: number().nullable(),
|
|
64331
|
+
errorCode: number().nullable().meta(readingMeta("none")),
|
|
63900
64332
|
/** True for D4S/D4SH dual-hopper hardware — gates the per-hopper UI. */
|
|
63901
64333
|
isDualHopper: boolean(),
|
|
63902
64334
|
/** Child-lock (manual-lock) setting — buttons on the unit are disabled. */
|
|
@@ -63906,7 +64338,7 @@ var PetFeederStatusSchema = object({
|
|
|
63906
64338
|
/** Play a chime when dispensing. */
|
|
63907
64339
|
feedSound: boolean(),
|
|
63908
64340
|
/** Speaker / prompt volume level (device-scaled integer). */
|
|
63909
|
-
volume: number(),
|
|
64341
|
+
volume: number().meta(readingMeta("none")),
|
|
63910
64342
|
/** Ms epoch when the slice was last refreshed from the cloud. */
|
|
63911
64343
|
lastFetchedAt: number()
|
|
63912
64344
|
});
|
|
@@ -64025,7 +64457,7 @@ var petFeederCapability = {
|
|
|
64025
64457
|
},
|
|
64026
64458
|
desiccantLeftDays: {
|
|
64027
64459
|
kind: "gauge",
|
|
64028
|
-
unit: "
|
|
64460
|
+
unit: "s"
|
|
64029
64461
|
}
|
|
64030
64462
|
} }
|
|
64031
64463
|
};
|
|
@@ -64426,36 +64858,19 @@ method(_void(), PlatformCapabilitiesSchema), method(_void(), HardwareInfoSchema)
|
|
|
64426
64858
|
*/
|
|
64427
64859
|
var PowerMeterStatusSchema = object({
|
|
64428
64860
|
/** Instantaneous power draw in watts. */
|
|
64429
|
-
watts: number().optional().meta({
|
|
64430
|
-
unit: "W",
|
|
64431
|
-
label: "Power"
|
|
64432
|
-
}),
|
|
64861
|
+
watts: number().optional().meta(readingMeta("power", { label: "Power" })),
|
|
64433
64862
|
/** Cumulative energy in kilowatt-hours since the meter was reset. */
|
|
64434
|
-
kwhTotal: number().optional().meta({
|
|
64435
|
-
unit: "kWh",
|
|
64436
|
-
label: "Energy"
|
|
64437
|
-
}),
|
|
64863
|
+
kwhTotal: number().optional().meta(readingMeta("energy", { label: "Energy" })),
|
|
64438
64864
|
/** Voltage in volts. */
|
|
64439
|
-
volts: number().optional(),
|
|
64865
|
+
volts: number().optional().meta(readingMeta("voltage")),
|
|
64440
64866
|
/** Current in amperes. */
|
|
64441
|
-
amps: number().optional(),
|
|
64442
|
-
/** Apparent power in volt-amperes
|
|
64443
|
-
va: number().optional(),
|
|
64867
|
+
amps: number().optional().meta(readingMeta("current")),
|
|
64868
|
+
/** Apparent power in volt-amperes. */
|
|
64869
|
+
va: number().optional().meta(readingMeta("apparent-power")),
|
|
64444
64870
|
/** Power factor (0..1) if reported. */
|
|
64445
|
-
powerFactor: number().min(0).max(1).optional(),
|
|
64871
|
+
powerFactor: number().min(0).max(1).optional().meta(readingMeta("ratio")),
|
|
64446
64872
|
/** Ms epoch when the slice was last updated. */
|
|
64447
|
-
lastFetchedAt: number()
|
|
64448
|
-
/** Live display unit of the single metric this slice carries (e.g. HA
|
|
64449
|
-
* `attributes.unit_of_measurement` → 'V' / 'A' / 'W' / 'kW' / 'kWh').
|
|
64450
|
-
* Each upstream `sensor.*` entity surfaces ONE device_class, so one
|
|
64451
|
-
* unit per slice is unambiguous. The UI prefers this over the role's
|
|
64452
|
-
* canonical unit so a 'kW' / 'Wh' feed renders verbatim. */
|
|
64453
|
-
unit: string().optional(),
|
|
64454
|
-
/** Suggested decimal places for numeric display.
|
|
64455
|
-
* Populated live from the upstream source when provided (e.g. HA
|
|
64456
|
-
* `attributes.suggested_display_precision`). Falls back to
|
|
64457
|
-
* auto-formatting when absent. */
|
|
64458
|
-
precision: number().int().min(0).max(10).optional()
|
|
64873
|
+
lastFetchedAt: number()
|
|
64459
64874
|
});
|
|
64460
64875
|
var powerMeterCapability = {
|
|
64461
64876
|
name: "power-meter",
|
|
@@ -64519,12 +64934,7 @@ var powerMeterCapability = {
|
|
|
64519
64934
|
} },
|
|
64520
64935
|
/** Clock fields: written, but excluded from the compare that decides
|
|
64521
64936
|
* whether persisting is worth a SQLite commit. */
|
|
64522
|
-
volatileStateFields: ["lastFetchedAt"]
|
|
64523
|
-
customize: {
|
|
64524
|
-
version: 1,
|
|
64525
|
-
advanced: "derive",
|
|
64526
|
-
targets: []
|
|
64527
|
-
}
|
|
64937
|
+
volatileStateFields: ["lastFetchedAt"]
|
|
64528
64938
|
};
|
|
64529
64939
|
/**
|
|
64530
64940
|
* Presence cap. Models HA `person.*` and `device_tracker.*` entities
|
|
@@ -64544,11 +64954,11 @@ var powerMeterCapability = {
|
|
|
64544
64954
|
*/
|
|
64545
64955
|
var GpsLocationSchema = object({
|
|
64546
64956
|
/** Latitude in decimal degrees, -90..90. */
|
|
64547
|
-
latitude: number().min(-90).max(90),
|
|
64957
|
+
latitude: number().min(-90).max(90).meta(readingMeta("angle")),
|
|
64548
64958
|
/** Longitude in decimal degrees, -180..180. */
|
|
64549
|
-
longitude: number().min(-180).max(180),
|
|
64959
|
+
longitude: number().min(-180).max(180).meta(readingMeta("angle")),
|
|
64550
64960
|
/** Reported accuracy in meters (lower = better). */
|
|
64551
|
-
accuracyMeters: number().nonnegative()
|
|
64961
|
+
accuracyMeters: number().nonnegative().meta(readingMeta("length"))
|
|
64552
64962
|
});
|
|
64553
64963
|
var PresenceStatusSchema = object({
|
|
64554
64964
|
/** `home` / `not_home` / any user-defined zone name. */
|
|
@@ -64560,7 +64970,7 @@ var PresenceStatusSchema = object({
|
|
|
64560
64970
|
gps: GpsLocationSchema.nullable(),
|
|
64561
64971
|
/** Optional battery level of the tracking device (0..100). Null
|
|
64562
64972
|
* when not reported. */
|
|
64563
|
-
batteryPercent: number().min(0).max(100).nullable(),
|
|
64973
|
+
batteryPercent: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
64564
64974
|
/** Ms epoch when the slice was last updated. */
|
|
64565
64975
|
lastChangedAt: number()
|
|
64566
64976
|
});
|
|
@@ -64610,19 +65020,10 @@ var presenceCapability = {
|
|
|
64610
65020
|
* `sourceInfo`.
|
|
64611
65021
|
*/
|
|
64612
65022
|
var PressureSensorStatusSchema = object({
|
|
64613
|
-
/** Current pressure in hPa. */
|
|
64614
|
-
hpa: number(),
|
|
65023
|
+
/** Current pressure in hPa. `null` when the sample was refused (D393). */
|
|
65024
|
+
hpa: number().nullable().meta(readingMeta("pressure", { precision: 0 })),
|
|
64615
65025
|
/** Ms epoch when the slice was last updated. */
|
|
64616
|
-
lastFetchedAt: number()
|
|
64617
|
-
/** Live display unit from the upstream source (e.g. HA
|
|
64618
|
-
* `attributes.unit_of_measurement`). The UI prefers this over the
|
|
64619
|
-
* role's canonical unit. Absent → fall back to the canonical unit. */
|
|
64620
|
-
unit: string().optional(),
|
|
64621
|
-
/** Suggested decimal places for numeric display.
|
|
64622
|
-
* Populated live from the upstream source when provided (e.g. HA
|
|
64623
|
-
* `attributes.suggested_display_precision`). Falls back to
|
|
64624
|
-
* auto-formatting when absent. */
|
|
64625
|
-
precision: number().int().min(0).max(10).optional()
|
|
65026
|
+
lastFetchedAt: number()
|
|
64626
65027
|
});
|
|
64627
65028
|
var pressureSensorCapability = {
|
|
64628
65029
|
name: "pressure-sensor",
|
|
@@ -65148,8 +65549,8 @@ var ptzCapability = {
|
|
|
65148
65549
|
};
|
|
65149
65550
|
var PtzAutotrackSettingsSchema = object({
|
|
65150
65551
|
targetType: string().describe("Vendor target string (people/vehicle/pet); empty = camera default"),
|
|
65151
|
-
stopDelaySeconds: number().int().min(0).max(300),
|
|
65152
|
-
disappearDelaySeconds: number().int().min(0).max(300)
|
|
65552
|
+
stopDelaySeconds: number().int().min(0).max(300).meta(readingMeta("duration")),
|
|
65553
|
+
disappearDelaySeconds: number().int().min(0).max(300).meta(readingMeta("duration"))
|
|
65153
65554
|
});
|
|
65154
65555
|
/**
|
|
65155
65556
|
* One option the camera advertises as a valid `targetType`. Drivers
|
|
@@ -65303,7 +65704,7 @@ var RunningStateStatusSchema = object({
|
|
|
65303
65704
|
/** null = unknown — never coerced to false (D393). */
|
|
65304
65705
|
running: boolean().nullable(),
|
|
65305
65706
|
/** Epoch ms the current boolean began; null while `running` is null. */
|
|
65306
|
-
since: number().nullable(),
|
|
65707
|
+
since: number().nullable().meta(readingMeta("none")),
|
|
65307
65708
|
source: RunningStateSourceSchema.meta({ label: "Source" }),
|
|
65308
65709
|
phase: string().nullable(),
|
|
65309
65710
|
/** null until a reading has been published (D393). */
|
|
@@ -65318,7 +65719,6 @@ var RUNNING_DEVICE_TYPES = Object.values(DeviceType);
|
|
|
65318
65719
|
/** Generic Customize target for the running boolean (D936). */
|
|
65319
65720
|
var runningCustomize = {
|
|
65320
65721
|
version: 1,
|
|
65321
|
-
advanced: "derive",
|
|
65322
65722
|
targets: [{
|
|
65323
65723
|
id: "running",
|
|
65324
65724
|
cardinality: "scalar",
|
|
@@ -65338,7 +65738,7 @@ var runningCustomize = {
|
|
|
65338
65738
|
DeviceType.Thermostat,
|
|
65339
65739
|
DeviceType.PetFeeder
|
|
65340
65740
|
],
|
|
65341
|
-
apply: "add
|
|
65741
|
+
apply: "add",
|
|
65342
65742
|
path: "running",
|
|
65343
65743
|
sources: [
|
|
65344
65744
|
{
|
|
@@ -65354,6 +65754,7 @@ var runningCustomize = {
|
|
|
65354
65754
|
requiredUnit: "W",
|
|
65355
65755
|
transforms: [{
|
|
65356
65756
|
kind: "threshold",
|
|
65757
|
+
comparisons: ["gte", "lte"],
|
|
65357
65758
|
comparison: "gte",
|
|
65358
65759
|
defaultThreshold: 5,
|
|
65359
65760
|
defaultStartDwellMs: RUNNING_POWER_START_DELAY_MS,
|
|
@@ -66630,9 +67031,9 @@ var RecordTriggerSchema = _enum([
|
|
|
66630
67031
|
*/
|
|
66631
67032
|
var RecordWindowSchema = object({
|
|
66632
67033
|
trigger: RecordTriggerSchema,
|
|
66633
|
-
day: number().int().min(0).max(6),
|
|
66634
|
-
startMinute: number().int().min(0).max(1439),
|
|
66635
|
-
endMinute: number().int().min(1).max(1440)
|
|
67034
|
+
day: number().int().min(0).max(6).meta(readingMeta("none")),
|
|
67035
|
+
startMinute: number().int().min(0).max(1439).meta(readingMeta("none")),
|
|
67036
|
+
endMinute: number().int().min(1).max(1440).meta(readingMeta("none"))
|
|
66636
67037
|
});
|
|
66637
67038
|
/** Status of one physical volume, as the camera itself describes it. */
|
|
66638
67039
|
var OnboardStorageVolumeSchema = object({
|
|
@@ -66708,10 +67109,10 @@ var RecordingOnboardStatusSchema = object({
|
|
|
66708
67109
|
/** Master "record to the card at all" switch. */
|
|
66709
67110
|
enabled: boolean().nullable(),
|
|
66710
67111
|
overwriteWhenFull: boolean().nullable(),
|
|
66711
|
-
preRecordSec: number().nullable(),
|
|
66712
|
-
postRecordSec: number().nullable(),
|
|
67112
|
+
preRecordSec: number().nullable().meta(readingMeta("duration")),
|
|
67113
|
+
postRecordSec: number().nullable().meta(readingMeta("duration")),
|
|
66713
67114
|
/** Length of one recorded file, in minutes. */
|
|
66714
|
-
segmentMinutes: number().nullable(),
|
|
67115
|
+
segmentMinutes: number().nullable().meta(readingMeta("none")),
|
|
66715
67116
|
/** The primary track's weekly windows, flattened. */
|
|
66716
67117
|
windows: array(RecordWindowSchema),
|
|
66717
67118
|
/**
|
|
@@ -66727,7 +67128,7 @@ var RecordingOnboardStatusSchema = object({
|
|
|
66727
67128
|
* provider reporting a non-zero count also reports the schedule as not
|
|
66728
67129
|
* writable.
|
|
66729
67130
|
*/
|
|
66730
|
-
unreadableWindows: number(),
|
|
67131
|
+
unreadableWindows: number().meta(readingMeta("count")),
|
|
66731
67132
|
/**
|
|
66732
67133
|
* The camera is scheduled to record and has NO usable storage.
|
|
66733
67134
|
*
|
|
@@ -67748,7 +68149,7 @@ var CamStreamDescriptorSchema = object({
|
|
|
67748
68149
|
url: string().optional(),
|
|
67749
68150
|
codec: string().optional(),
|
|
67750
68151
|
resolution: CamStreamResolutionSchema.optional(),
|
|
67751
|
-
fps: number().positive().optional(),
|
|
68152
|
+
fps: number().positive().optional().meta(readingMeta("rate")),
|
|
67752
68153
|
label: string().optional(),
|
|
67753
68154
|
/** Device-level features (e.g. `battery-operated`) — drives broker policy. */
|
|
67754
68155
|
deviceFeatures: array(string()).optional(),
|
|
@@ -67835,18 +68236,18 @@ var StreamProfileSchema = _enum([
|
|
|
67835
68236
|
]);
|
|
67836
68237
|
/** The current encoding config of one stream profile. */
|
|
67837
68238
|
var StreamProfileConfigSchema = object({
|
|
67838
|
-
width: number(),
|
|
67839
|
-
height: number(),
|
|
68239
|
+
width: number().meta(readingMeta("none")),
|
|
68240
|
+
height: number().meta(readingMeta("none")),
|
|
67840
68241
|
codec: _enum(["h264", "h265"]),
|
|
67841
|
-
framerate: number(),
|
|
67842
|
-
bitrate: number(),
|
|
68242
|
+
framerate: number().meta(readingMeta("rate")),
|
|
68243
|
+
bitrate: number().meta(readingMeta("bitrate")),
|
|
67843
68244
|
bitrateMode: _enum(["vbr", "cbr"]).optional(),
|
|
67844
68245
|
encoderProfile: _enum([
|
|
67845
68246
|
"high",
|
|
67846
68247
|
"main",
|
|
67847
68248
|
"baseline"
|
|
67848
68249
|
]).optional(),
|
|
67849
|
-
gop: number().optional(),
|
|
68250
|
+
gop: number().optional().meta(readingMeta("none")),
|
|
67850
68251
|
/**
|
|
67851
68252
|
* Whether THIS profile currently carries an audio track. READ-ONLY here.
|
|
67852
68253
|
*
|
|
@@ -68265,12 +68666,7 @@ var switchCapability = {
|
|
|
68265
68666
|
label: "On",
|
|
68266
68667
|
kind: "boolean"
|
|
68267
68668
|
}
|
|
68268
|
-
}] }
|
|
68269
|
-
customize: {
|
|
68270
|
-
version: 1,
|
|
68271
|
-
advanced: "derive",
|
|
68272
|
-
targets: []
|
|
68273
|
-
}
|
|
68669
|
+
}] }
|
|
68274
68670
|
};
|
|
68275
68671
|
/** C0 controls, DEL and the C1 range: none of them belongs in a name. */
|
|
68276
68672
|
function hasControlCharacter(value) {
|
|
@@ -68853,35 +69249,21 @@ var tamperCapability = {
|
|
|
68853
69249
|
* entries with `device_class: temperature` and any future native
|
|
68854
69250
|
* thermometer.
|
|
68855
69251
|
*
|
|
68856
|
-
*
|
|
68857
|
-
*
|
|
68858
|
-
* (climate-control's `currentTemp`, energy analytics) can compose
|
|
68859
|
-
* without per-source unit fixups. The canonical display unit (`°C`) is
|
|
68860
|
-
* a descriptor constant in the UI (ROLE_DESCRIPTOR), not stored in
|
|
68861
|
-
* `sourceInfo`.
|
|
69252
|
+
* The number is Celsius (D944). Providers convert on ingest. A failed
|
|
69253
|
+
* conversion is `null`, never a guess. Display unit is a read-time preference.
|
|
68862
69254
|
*
|
|
68863
69255
|
* Status `lastFetchedAt` lets staleness-aware consumers detect a
|
|
68864
69256
|
* frozen feed (provider hung) distinct from a "temperature hasn't
|
|
68865
69257
|
* changed" steady state.
|
|
68866
69258
|
*/
|
|
68867
69259
|
var TemperatureSensorStatusSchema = object({
|
|
68868
|
-
/** Current temperature in Celsius. */
|
|
68869
|
-
celsius: number().meta({
|
|
68870
|
-
|
|
69260
|
+
/** Current temperature in Celsius. `null` when the sample was refused (D393). */
|
|
69261
|
+
celsius: number().nullable().meta(readingMeta("temperature", {
|
|
69262
|
+
precision: 1,
|
|
68871
69263
|
label: "Temperature"
|
|
68872
|
-
}),
|
|
69264
|
+
})),
|
|
68873
69265
|
/** Ms epoch when the slice was last updated (push or poll). */
|
|
68874
|
-
lastFetchedAt: number()
|
|
68875
|
-
/** Live display unit from the upstream source (e.g. HA
|
|
68876
|
-
* `attributes.unit_of_measurement`). The UI prefers this over the
|
|
68877
|
-
* role's canonical unit, so a Fahrenheit feed renders '°F' not '°C'.
|
|
68878
|
-
* Absent → the UI falls back to the role's canonical unit. */
|
|
68879
|
-
unit: string().optional(),
|
|
68880
|
-
/** Suggested decimal places for numeric display.
|
|
68881
|
-
* Populated live from the upstream source when provided (e.g. HA
|
|
68882
|
-
* `attributes.suggested_display_precision`). Falls back to
|
|
68883
|
-
* auto-formatting when absent. */
|
|
68884
|
-
precision: number().int().min(0).max(10).optional()
|
|
69266
|
+
lastFetchedAt: number()
|
|
68885
69267
|
});
|
|
68886
69268
|
var temperatureSensorCapability = {
|
|
68887
69269
|
name: "temperature-sensor",
|
|
@@ -68912,12 +69294,7 @@ var temperatureSensorCapability = {
|
|
|
68912
69294
|
} } },
|
|
68913
69295
|
/** Clock fields: written, but excluded from the compare that decides
|
|
68914
69296
|
* whether persisting is worth a SQLite commit. */
|
|
68915
|
-
volatileStateFields: ["lastFetchedAt"]
|
|
68916
|
-
customize: {
|
|
68917
|
-
version: 1,
|
|
68918
|
-
advanced: "derive",
|
|
68919
|
-
targets: []
|
|
68920
|
-
}
|
|
69297
|
+
volatileStateFields: ["lastFetchedAt"]
|
|
68921
69298
|
};
|
|
68922
69299
|
/**
|
|
68923
69300
|
* toast — system-scoped singleton capability that streams toast
|
|
@@ -69200,16 +69577,16 @@ var VacuumControlStatusSchema = object({
|
|
|
69200
69577
|
]),
|
|
69201
69578
|
/** 0..100 battery percentage. Null when the device has no battery
|
|
69202
69579
|
* reading. */
|
|
69203
|
-
batteryLevel: number().min(0).max(100).nullable(),
|
|
69580
|
+
batteryLevel: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
69204
69581
|
/** Current fan-speed token (provider-verbatim). Null when unknown or
|
|
69205
69582
|
* the vacuum has no speed control. */
|
|
69206
69583
|
fanSpeed: string().nullable(),
|
|
69207
69584
|
/** Speed tokens the hardware accepts — drives the UI selector. */
|
|
69208
69585
|
availableFanSpeeds: array(string()),
|
|
69209
69586
|
/** 0..100 cleaning-completion percentage of the current task, or null. */
|
|
69210
|
-
progressPercent: number().min(0).max(100).nullable(),
|
|
69587
|
+
progressPercent: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
69211
69588
|
/** Current error code (0 / null = no error). */
|
|
69212
|
-
errorCode: number().nullable(),
|
|
69589
|
+
errorCode: number().nullable().meta(readingMeta("none")),
|
|
69213
69590
|
/** Human label for {@link errorCode}, or null when none / undecodable. */
|
|
69214
69591
|
errorLabel: string().nullable(),
|
|
69215
69592
|
/** Ms epoch when the slice was last updated. */
|
|
@@ -69287,7 +69664,7 @@ var ValveStatusSchema = object({
|
|
|
69287
69664
|
]),
|
|
69288
69665
|
/** 0 = fully closed, 100 = fully open. Null when the device has no
|
|
69289
69666
|
* intermediate position surface. */
|
|
69290
|
-
position: number().min(0).max(100).nullable(),
|
|
69667
|
+
position: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
69291
69668
|
/** Ms epoch when the slice was last updated. */
|
|
69292
69669
|
lastChangedAt: number()
|
|
69293
69670
|
});
|
|
@@ -69395,9 +69772,9 @@ var vibrationCapability = {
|
|
|
69395
69772
|
*/
|
|
69396
69773
|
var WaterHeaterStatusSchema = object({
|
|
69397
69774
|
/** Current measured temperature. Null when not reported. */
|
|
69398
|
-
currentTemp: number().nullable(),
|
|
69775
|
+
currentTemp: number().nullable().meta(readingMeta("temperature")),
|
|
69399
69776
|
/** Target temperature setpoint. Null when no setpoint surface. */
|
|
69400
|
-
targetTemp: number().nullable(),
|
|
69777
|
+
targetTemp: number().nullable().meta(readingMeta("temperature")),
|
|
69401
69778
|
/** Active operation mode = HA `state` (`eco` / `electric` / `gas` /
|
|
69402
69779
|
* `heat_pump` / `high_demand` / `performance` / `off`). Null when the
|
|
69403
69780
|
* device reports an unknown state. */
|
|
@@ -69408,9 +69785,9 @@ var WaterHeaterStatusSchema = object({
|
|
|
69408
69785
|
* has no away surface. */
|
|
69409
69786
|
away: boolean().nullable(),
|
|
69410
69787
|
/** HA `min_temp` attribute. Null when not reported. */
|
|
69411
|
-
minTemp: number().nullable(),
|
|
69788
|
+
minTemp: number().nullable().meta(readingMeta("temperature")),
|
|
69412
69789
|
/** HA `max_temp` attribute. Null when not reported. */
|
|
69413
|
-
maxTemp: number().nullable(),
|
|
69790
|
+
maxTemp: number().nullable().meta(readingMeta("temperature")),
|
|
69414
69791
|
/** Ms epoch when the slice was last updated. */
|
|
69415
69792
|
lastChangedAt: number()
|
|
69416
69793
|
});
|
|
@@ -69495,25 +69872,18 @@ var waterHeaterCapability = {
|
|
|
69495
69872
|
* Forecast deferred — current conditions only for v1.
|
|
69496
69873
|
*/
|
|
69497
69874
|
var WeatherStatusSchema = object({
|
|
69498
|
-
/** Verbatim
|
|
69499
|
-
* when no condition has been reported yet. */
|
|
69875
|
+
/** Verbatim condition state (`sunny`, `cloudy`, `rainy`, …). Null when none yet. */
|
|
69500
69876
|
condition: string().nullable(),
|
|
69501
|
-
/** Current temperature in
|
|
69502
|
-
temperature: number().nullable(),
|
|
69503
|
-
/** Temperature unit string (e.g. `°C` / `°F`). Null when not provided. */
|
|
69504
|
-
temperatureUnit: string().nullable(),
|
|
69877
|
+
/** Current temperature in Celsius. Null when not provided or refused. */
|
|
69878
|
+
temperature: number().nullable().meta(readingMeta("temperature", { precision: 1 })),
|
|
69505
69879
|
/** Relative humidity (0..100). Null when not provided. */
|
|
69506
|
-
humidity: number().min(0).max(100).nullable(),
|
|
69507
|
-
/** Barometric pressure in
|
|
69508
|
-
pressure: number().nullable(),
|
|
69509
|
-
/**
|
|
69510
|
-
|
|
69511
|
-
/** Wind speed in the reported unit. Null when not provided. */
|
|
69512
|
-
windSpeed: number().nullable(),
|
|
69513
|
-
/** Wind-speed unit string (e.g. `km/h` / `mph`). Null when not provided. */
|
|
69514
|
-
windSpeedUnit: string().nullable(),
|
|
69880
|
+
humidity: number().min(0).max(100).nullable().meta(readingMeta("humidity")),
|
|
69881
|
+
/** Barometric pressure in hPa. Null when not provided or refused. */
|
|
69882
|
+
pressure: number().nullable().meta(readingMeta("pressure")),
|
|
69883
|
+
/** Wind speed in metres per second. Null when not provided or refused. */
|
|
69884
|
+
windSpeed: number().nullable().meta(readingMeta("speed")),
|
|
69515
69885
|
/** Wind bearing in degrees (0..360, meteorological). Null when not provided. */
|
|
69516
|
-
windBearing: number().nullable(),
|
|
69886
|
+
windBearing: number().nullable().meta(readingMeta("angle")),
|
|
69517
69887
|
/** Ms epoch when the slice was last updated. */
|
|
69518
69888
|
lastFetchedAt: number()
|
|
69519
69889
|
});
|
|
@@ -69541,12 +69911,12 @@ var weatherCapability = {
|
|
|
69541
69911
|
*/
|
|
69542
69912
|
durability: "session",
|
|
69543
69913
|
/**
|
|
69544
|
-
* History (D850): recorded series.
|
|
69914
|
+
* History (D850): recorded series. Numbers are the quantity base (D944).
|
|
69545
69915
|
*/
|
|
69546
69916
|
history: { fields: {
|
|
69547
69917
|
temperature: {
|
|
69548
69918
|
kind: "gauge",
|
|
69549
|
-
|
|
69919
|
+
unit: "°C",
|
|
69550
69920
|
deadband: .2
|
|
69551
69921
|
},
|
|
69552
69922
|
humidity: {
|
|
@@ -69556,12 +69926,12 @@ var weatherCapability = {
|
|
|
69556
69926
|
},
|
|
69557
69927
|
pressure: {
|
|
69558
69928
|
kind: "gauge",
|
|
69559
|
-
|
|
69929
|
+
unit: "hPa",
|
|
69560
69930
|
deadband: .5
|
|
69561
69931
|
},
|
|
69562
69932
|
windSpeed: {
|
|
69563
69933
|
kind: "gauge",
|
|
69564
|
-
|
|
69934
|
+
unit: "m/s",
|
|
69565
69935
|
deadband: .5
|
|
69566
69936
|
}
|
|
69567
69937
|
} }
|
|
@@ -70940,6 +71310,8 @@ var DEVICE_LOCAL_STATE_CAPS = {
|
|
|
70940
71310
|
featureProbe: featureProbeCapability,
|
|
70941
71311
|
flood: floodCapability,
|
|
70942
71312
|
gas: gasCapability,
|
|
71313
|
+
groupCommands: groupCommandsCapability,
|
|
71314
|
+
groupStatus: groupStatusCapability,
|
|
70943
71315
|
heatingValve: heatingValveCapability,
|
|
70944
71316
|
humidifier: humidifierCapability,
|
|
70945
71317
|
humiditySensor: humiditySensorCapability,
|
|
@@ -72320,6 +72692,13 @@ Object.freeze({
|
|
|
72320
72692
|
access: "view",
|
|
72321
72693
|
role: "admin"
|
|
72322
72694
|
},
|
|
72695
|
+
"addons.getPackageDocs": {
|
|
72696
|
+
capName: "addons",
|
|
72697
|
+
capScope: "system",
|
|
72698
|
+
addonId: null,
|
|
72699
|
+
access: "view",
|
|
72700
|
+
role: "admin"
|
|
72701
|
+
},
|
|
72323
72702
|
"addons.getVersions": {
|
|
72324
72703
|
capName: "addons",
|
|
72325
72704
|
capScope: "system",
|
|
@@ -75428,6 +75807,20 @@ Object.freeze({
|
|
|
75428
75807
|
access: "view",
|
|
75429
75808
|
role: "viewer"
|
|
75430
75809
|
},
|
|
75810
|
+
"groupCommands.getStatus": {
|
|
75811
|
+
capName: "group-commands",
|
|
75812
|
+
capScope: "device",
|
|
75813
|
+
addonId: null,
|
|
75814
|
+
access: "view",
|
|
75815
|
+
role: "viewer"
|
|
75816
|
+
},
|
|
75817
|
+
"groupStatus.getStatus": {
|
|
75818
|
+
capName: "group-status",
|
|
75819
|
+
capScope: "device",
|
|
75820
|
+
addonId: null,
|
|
75821
|
+
access: "view",
|
|
75822
|
+
role: "viewer"
|
|
75823
|
+
},
|
|
75431
75824
|
"heatingValve.getStatus": {
|
|
75432
75825
|
capName: "heating-valve",
|
|
75433
75826
|
capScope: "device",
|
|
@@ -85250,6 +85643,37 @@ var SENSOR_CAP_VOCABULARY = {
|
|
|
85250
85643
|
icon: "flame"
|
|
85251
85644
|
}]
|
|
85252
85645
|
},
|
|
85646
|
+
"group-commands": {
|
|
85647
|
+
scope: "device",
|
|
85648
|
+
noun: t("Group command", "Comando di gruppo")
|
|
85649
|
+
},
|
|
85650
|
+
"group-status": {
|
|
85651
|
+
scope: "device",
|
|
85652
|
+
noun: t("Group", "Gruppo"),
|
|
85653
|
+
state: [
|
|
85654
|
+
{
|
|
85655
|
+
kind: "numeric",
|
|
85656
|
+
field: "included",
|
|
85657
|
+
quantity: t("the members reporting", "i membri che rispondono"),
|
|
85658
|
+
label: t("Reporting", "Rispondono"),
|
|
85659
|
+
icon: "users"
|
|
85660
|
+
},
|
|
85661
|
+
{
|
|
85662
|
+
kind: "numeric",
|
|
85663
|
+
field: "excluded",
|
|
85664
|
+
quantity: t("the members left out", "i membri esclusi"),
|
|
85665
|
+
label: t("Excluded", "Esclusi"),
|
|
85666
|
+
icon: "users"
|
|
85667
|
+
},
|
|
85668
|
+
{
|
|
85669
|
+
kind: "numeric",
|
|
85670
|
+
field: "total",
|
|
85671
|
+
quantity: t("the member count", "il numero di membri"),
|
|
85672
|
+
label: t("Members", "Membri"),
|
|
85673
|
+
icon: "sigma"
|
|
85674
|
+
}
|
|
85675
|
+
]
|
|
85676
|
+
},
|
|
85253
85677
|
"humidity-sensor": {
|
|
85254
85678
|
scope: "device",
|
|
85255
85679
|
noun: t("Humidity", "Umidità"),
|
|
@@ -85283,7 +85707,6 @@ var SENSOR_CAP_VOCABULARY = {
|
|
|
85283
85707
|
field: "value",
|
|
85284
85708
|
quantity: t("the reading", "il valore"),
|
|
85285
85709
|
label: t("Reading", "Valore"),
|
|
85286
|
-
unitField: "unit",
|
|
85287
85710
|
icon: "gauge"
|
|
85288
85711
|
}]
|
|
85289
85712
|
},
|
|
@@ -85419,7 +85842,7 @@ var SENSOR_CAP_VOCABULARY = {
|
|
|
85419
85842
|
field: "temperature",
|
|
85420
85843
|
quantity: t("the outdoor temperature", "la temperatura esterna"),
|
|
85421
85844
|
label: t("Temperature", "Temperatura"),
|
|
85422
|
-
|
|
85845
|
+
unit: "°C",
|
|
85423
85846
|
icon: "thermometer"
|
|
85424
85847
|
},
|
|
85425
85848
|
{
|
|
@@ -85435,7 +85858,7 @@ var SENSOR_CAP_VOCABULARY = {
|
|
|
85435
85858
|
field: "windSpeed",
|
|
85436
85859
|
quantity: t("the wind speed", "la velocità del vento"),
|
|
85437
85860
|
label: t("Wind", "Vento"),
|
|
85438
|
-
|
|
85861
|
+
unit: "m/s",
|
|
85439
85862
|
icon: "wind"
|
|
85440
85863
|
},
|
|
85441
85864
|
{
|
|
@@ -85443,7 +85866,7 @@ var SENSOR_CAP_VOCABULARY = {
|
|
|
85443
85866
|
field: "pressure",
|
|
85444
85867
|
quantity: t("the air pressure", "la pressione atmosferica"),
|
|
85445
85868
|
label: t("Pressure", "Pressione"),
|
|
85446
|
-
|
|
85869
|
+
unit: "hPa",
|
|
85447
85870
|
icon: "gauge"
|
|
85448
85871
|
}
|
|
85449
85872
|
]
|
|
@@ -86934,6 +87357,16 @@ Object.freeze({
|
|
|
86934
87357
|
form: "single",
|
|
86935
87358
|
optional: false
|
|
86936
87359
|
}],
|
|
87360
|
+
"groupCommands.getStatus": [{
|
|
87361
|
+
name: "deviceId",
|
|
87362
|
+
form: "single",
|
|
87363
|
+
optional: false
|
|
87364
|
+
}],
|
|
87365
|
+
"groupStatus.getStatus": [{
|
|
87366
|
+
name: "deviceId",
|
|
87367
|
+
form: "single",
|
|
87368
|
+
optional: false
|
|
87369
|
+
}],
|
|
86937
87370
|
"heatingValve.getStatus": [{
|
|
86938
87371
|
name: "deviceId",
|
|
86939
87372
|
form: "single",
|
|
@@ -88798,6 +89231,11 @@ var PulseOverrideDraftSchema = object({
|
|
|
88798
89231
|
targetId: string().min(1),
|
|
88799
89232
|
enabled: boolean(),
|
|
88800
89233
|
debounceMs: number().nonnegative(),
|
|
89234
|
+
edges: array(_enum([
|
|
89235
|
+
"rising",
|
|
89236
|
+
"button",
|
|
89237
|
+
"native-event"
|
|
89238
|
+
])).min(1).optional(),
|
|
88801
89239
|
sources: array(OverrideSourceSchema).min(1)
|
|
88802
89240
|
});
|
|
88803
89241
|
var SpanSourceDraftSchema = OverrideSourceSchema.extend({ mode: _enum([
|
|
@@ -88913,6 +89351,8 @@ new Map(Object.entries({
|
|
|
88913
89351
|
"detection-blind": "device-events",
|
|
88914
89352
|
"motion-noisy": "device-events",
|
|
88915
89353
|
"motion-calm": "device-events",
|
|
89354
|
+
"package-llm-silent": "device-events",
|
|
89355
|
+
"package-llm-answered": "device-events",
|
|
88916
89356
|
"recording-stalled": "device-events",
|
|
88917
89357
|
"recording-healthy": "device-events",
|
|
88918
89358
|
"recording-degraded": "device-events",
|
|
@@ -88996,6 +89436,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
|
|
|
88996
89436
|
label: "Motion without a subject",
|
|
88997
89437
|
kinds: ["motion-noisy", "motion-calm"]
|
|
88998
89438
|
},
|
|
89439
|
+
{
|
|
89440
|
+
id: "package-llm",
|
|
89441
|
+
family: "device-events",
|
|
89442
|
+
label: "Package confirm",
|
|
89443
|
+
kinds: ["package-llm-silent", "package-llm-answered"]
|
|
89444
|
+
},
|
|
88999
89445
|
{
|
|
89000
89446
|
id: "recording",
|
|
89001
89447
|
family: "device-events",
|
|
@@ -89177,6 +89623,8 @@ var DEVICE_EVENTS = [
|
|
|
89177
89623
|
"detection-blind",
|
|
89178
89624
|
"motion-noisy",
|
|
89179
89625
|
"motion-calm",
|
|
89626
|
+
"package-llm-silent",
|
|
89627
|
+
"package-llm-answered",
|
|
89180
89628
|
"recording-stalled",
|
|
89181
89629
|
"recording-healthy",
|
|
89182
89630
|
"recording-degraded",
|
|
@@ -89445,6 +89893,15 @@ new Map([
|
|
|
89445
89893
|
snapshotLabel: "Cameras with constant motion now",
|
|
89446
89894
|
snapshotSection: null
|
|
89447
89895
|
},
|
|
89896
|
+
{
|
|
89897
|
+
id: "package-llm-confirm",
|
|
89898
|
+
family: "device-events",
|
|
89899
|
+
label: "Package confirm (not answering / answering again)",
|
|
89900
|
+
bad: ["package-llm-silent"],
|
|
89901
|
+
recovery: ["package-llm-answered"],
|
|
89902
|
+
snapshotLabel: "Cameras whose package confirm is not answering",
|
|
89903
|
+
snapshotSection: null
|
|
89904
|
+
},
|
|
89448
89905
|
{
|
|
89449
89906
|
id: "recording-health",
|
|
89450
89907
|
family: "device-events",
|