@camstack/addon-provider-ecowitt 0.2.139 → 0.2.141
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/addon.js +125 -2
- package/dist/addon.mjs +125 -2
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -2,7 +2,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
2
2
|
let http = require("http");
|
|
3
3
|
let events = require("events");
|
|
4
4
|
let dgram = require("dgram");
|
|
5
|
-
//#region ../types/dist/event-category-
|
|
5
|
+
//#region ../types/dist/event-category-7pZEBmVg.mjs
|
|
6
6
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
7
7
|
EventCategory["SystemBoot"] = "system.boot";
|
|
8
8
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -690,6 +690,14 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
690
690
|
EventCategory["BackupRestored"] = "backup.restored";
|
|
691
691
|
EventCategory["NotificationDispatched"] = "notification.dispatched";
|
|
692
692
|
EventCategory["NotificationFailed"] = "notification.failed";
|
|
693
|
+
/**
|
|
694
|
+
* A notification rule that cannot work (D905): its stored row does not load,
|
|
695
|
+
* or it still names a device / delivery target the prune CONFIRMED deleted.
|
|
696
|
+
* One edge per rule per distinct set of reasons; never on an unanswered read.
|
|
697
|
+
*/
|
|
698
|
+
EventCategory["NotificationRuleBroken"] = "notification.rule-broken";
|
|
699
|
+
/** The clear of {@link NotificationRuleBroken}: the rule loads and names nothing deleted. */
|
|
700
|
+
EventCategory["NotificationRuleRepaired"] = "notification.rule-repaired";
|
|
693
701
|
EventCategory["DeviceUpdated"] = "device.updated";
|
|
694
702
|
/**
|
|
695
703
|
* Transport-level connectivity. Emitted by the device driver when
|
|
@@ -5417,7 +5425,7 @@ var ZodIssueCode$1 = {
|
|
|
5417
5425
|
var ZodFirstPartyTypeKind$1;
|
|
5418
5426
|
ZodFirstPartyTypeKind$1 || (ZodFirstPartyTypeKind$1 = {});
|
|
5419
5427
|
//#endregion
|
|
5420
|
-
//#region ../types/dist/sleep-
|
|
5428
|
+
//#region ../types/dist/sleep-CueztlR1.mjs
|
|
5421
5429
|
/**
|
|
5422
5430
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5423
5431
|
* window to float samples (D455).
|
|
@@ -42505,6 +42513,8 @@ var NcSystemEventKindSchema = _enum([
|
|
|
42505
42513
|
"alert-critical",
|
|
42506
42514
|
"alert-error",
|
|
42507
42515
|
"alert-critical-resolved",
|
|
42516
|
+
"rule-broken",
|
|
42517
|
+
"rule-repaired",
|
|
42508
42518
|
"camera-online",
|
|
42509
42519
|
"camera-offline",
|
|
42510
42520
|
"camera-disabled",
|
|
@@ -78781,6 +78791,8 @@ new Map(Object.entries({
|
|
|
78781
78791
|
"alert-critical": "system",
|
|
78782
78792
|
"alert-error": "system",
|
|
78783
78793
|
"alert-critical-resolved": "system",
|
|
78794
|
+
"rule-broken": "system",
|
|
78795
|
+
"rule-repaired": "system",
|
|
78784
78796
|
"storage-location-low": "system",
|
|
78785
78797
|
"storage-location-critical": "system",
|
|
78786
78798
|
"storage-location-ok": "system",
|
|
@@ -78915,6 +78927,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
|
|
|
78915
78927
|
"alert-critical-resolved"
|
|
78916
78928
|
]
|
|
78917
78929
|
},
|
|
78930
|
+
{
|
|
78931
|
+
id: "rule-health",
|
|
78932
|
+
family: "system",
|
|
78933
|
+
label: "Notification rules",
|
|
78934
|
+
kinds: ["rule-broken", "rule-repaired"]
|
|
78935
|
+
},
|
|
78918
78936
|
{
|
|
78919
78937
|
id: "alarm",
|
|
78920
78938
|
family: "alarm",
|
|
@@ -79192,6 +79210,10 @@ var STATE_SUMMARY_VARS = [
|
|
|
79192
79210
|
[...RULE_TEXT],
|
|
79193
79211
|
[...RULE_TEXT],
|
|
79194
79212
|
[...RULE_TEXT],
|
|
79213
|
+
[...RULE_TEXT],
|
|
79214
|
+
[...RULE_TEXT],
|
|
79215
|
+
[...RULE_TEXT],
|
|
79216
|
+
[...RULE_TEXT],
|
|
79195
79217
|
([...RULE_TEXT], [...UPDATES]),
|
|
79196
79218
|
([...RULE_TEXT], [...PACKAGE_UPDATES]),
|
|
79197
79219
|
([...RULE_TEXT], [...PACKAGE_UPDATES]),
|
|
@@ -79230,6 +79252,107 @@ var STATE_SUMMARY_VARS = [
|
|
|
79230
79252
|
[...RULE_TEXT],
|
|
79231
79253
|
...STATE_SUMMARY_VARS
|
|
79232
79254
|
];
|
|
79255
|
+
new Map([
|
|
79256
|
+
{
|
|
79257
|
+
id: "device-connectivity",
|
|
79258
|
+
family: "device-events",
|
|
79259
|
+
label: "Device connectivity (offline / back online)",
|
|
79260
|
+
bad: ["device-offline"],
|
|
79261
|
+
recovery: ["device-online"],
|
|
79262
|
+
snapshotLabel: "Devices offline now",
|
|
79263
|
+
snapshotSection: "device-state"
|
|
79264
|
+
},
|
|
79265
|
+
{
|
|
79266
|
+
id: "device-switch",
|
|
79267
|
+
family: "device-events",
|
|
79268
|
+
label: "Device switched off / back on",
|
|
79269
|
+
bad: ["device-disabled"],
|
|
79270
|
+
recovery: ["device-enabled"],
|
|
79271
|
+
snapshotLabel: "Devices switched off now",
|
|
79272
|
+
snapshotSection: "device-state"
|
|
79273
|
+
},
|
|
79274
|
+
{
|
|
79275
|
+
id: "stream-connectivity",
|
|
79276
|
+
family: "device-events",
|
|
79277
|
+
label: "Stream connectivity (offline / back online)",
|
|
79278
|
+
bad: ["stream-offline"],
|
|
79279
|
+
recovery: ["stream-online"],
|
|
79280
|
+
snapshotLabel: "Streams offline now",
|
|
79281
|
+
snapshotSection: "streams"
|
|
79282
|
+
},
|
|
79283
|
+
{
|
|
79284
|
+
id: "battery",
|
|
79285
|
+
family: "device-events",
|
|
79286
|
+
label: "Battery (low / back to normal)",
|
|
79287
|
+
bad: ["device-battery-low"],
|
|
79288
|
+
recovery: ["device-battery-normal"],
|
|
79289
|
+
snapshotLabel: "Batteries low now",
|
|
79290
|
+
snapshotSection: "battery"
|
|
79291
|
+
},
|
|
79292
|
+
{
|
|
79293
|
+
id: "consumables",
|
|
79294
|
+
family: "device-events",
|
|
79295
|
+
label: "Consumables (low / replaced)",
|
|
79296
|
+
bad: ["device-consumable-low"],
|
|
79297
|
+
recovery: ["device-consumable-normal"],
|
|
79298
|
+
snapshotLabel: "Consumables low now",
|
|
79299
|
+
snapshotSection: "consumables"
|
|
79300
|
+
},
|
|
79301
|
+
{
|
|
79302
|
+
id: "tanks",
|
|
79303
|
+
family: "device-events",
|
|
79304
|
+
label: "Tanks (low or full / back to normal)",
|
|
79305
|
+
bad: ["device-tank-low", "device-tank-full"],
|
|
79306
|
+
recovery: ["device-tank-normal"],
|
|
79307
|
+
snapshotLabel: "Tanks low or full now",
|
|
79308
|
+
snapshotSection: "tanks"
|
|
79309
|
+
},
|
|
79310
|
+
{
|
|
79311
|
+
id: "recording-health",
|
|
79312
|
+
family: "device-events",
|
|
79313
|
+
label: "Recording health (stalled or degraded / recording again)",
|
|
79314
|
+
bad: ["recording-stalled", "recording-degraded"],
|
|
79315
|
+
recovery: ["recording-healthy"],
|
|
79316
|
+
snapshotLabel: "Recordings stalled now",
|
|
79317
|
+
snapshotSection: null
|
|
79318
|
+
},
|
|
79319
|
+
{
|
|
79320
|
+
id: "node-connectivity",
|
|
79321
|
+
family: "system",
|
|
79322
|
+
label: "Node connectivity (offline / back online)",
|
|
79323
|
+
bad: ["node-offline"],
|
|
79324
|
+
recovery: ["node-online"],
|
|
79325
|
+
snapshotLabel: "Nodes offline now",
|
|
79326
|
+
snapshotSection: "nodes"
|
|
79327
|
+
},
|
|
79328
|
+
{
|
|
79329
|
+
id: "storage-space",
|
|
79330
|
+
family: "system",
|
|
79331
|
+
label: "Storage space (low or critical / ok again)",
|
|
79332
|
+
bad: ["storage-location-low", "storage-location-critical"],
|
|
79333
|
+
recovery: ["storage-location-ok"],
|
|
79334
|
+
snapshotLabel: "Storage locations low now",
|
|
79335
|
+
snapshotSection: null
|
|
79336
|
+
},
|
|
79337
|
+
{
|
|
79338
|
+
id: "critical-alerts",
|
|
79339
|
+
family: "system",
|
|
79340
|
+
label: "Critical alerts (raised / resolved)",
|
|
79341
|
+
bad: ["alert-critical"],
|
|
79342
|
+
recovery: ["alert-critical-resolved"],
|
|
79343
|
+
snapshotLabel: "Critical alerts open now",
|
|
79344
|
+
snapshotSection: null
|
|
79345
|
+
},
|
|
79346
|
+
{
|
|
79347
|
+
id: "rule-health",
|
|
79348
|
+
family: "system",
|
|
79349
|
+
label: "Rule health (broken / repaired)",
|
|
79350
|
+
bad: ["rule-broken"],
|
|
79351
|
+
recovery: ["rule-repaired"],
|
|
79352
|
+
snapshotLabel: "Notification rules broken now",
|
|
79353
|
+
snapshotSection: null
|
|
79354
|
+
}
|
|
79355
|
+
].flatMap((spec) => [...spec.bad, ...spec.recovery].map((kind) => [kind, spec])));
|
|
79233
79356
|
new Set([
|
|
79234
79357
|
"disarmed",
|
|
79235
79358
|
"armed_home",
|
package/dist/addon.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createServer } from "http";
|
|
2
2
|
import { EventEmitter } from "events";
|
|
3
3
|
import { createSocket } from "dgram";
|
|
4
|
-
//#region ../types/dist/event-category-
|
|
4
|
+
//#region ../types/dist/event-category-7pZEBmVg.mjs
|
|
5
5
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
6
6
|
EventCategory["SystemBoot"] = "system.boot";
|
|
7
7
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -689,6 +689,14 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
689
689
|
EventCategory["BackupRestored"] = "backup.restored";
|
|
690
690
|
EventCategory["NotificationDispatched"] = "notification.dispatched";
|
|
691
691
|
EventCategory["NotificationFailed"] = "notification.failed";
|
|
692
|
+
/**
|
|
693
|
+
* A notification rule that cannot work (D905): its stored row does not load,
|
|
694
|
+
* or it still names a device / delivery target the prune CONFIRMED deleted.
|
|
695
|
+
* One edge per rule per distinct set of reasons; never on an unanswered read.
|
|
696
|
+
*/
|
|
697
|
+
EventCategory["NotificationRuleBroken"] = "notification.rule-broken";
|
|
698
|
+
/** The clear of {@link NotificationRuleBroken}: the rule loads and names nothing deleted. */
|
|
699
|
+
EventCategory["NotificationRuleRepaired"] = "notification.rule-repaired";
|
|
692
700
|
EventCategory["DeviceUpdated"] = "device.updated";
|
|
693
701
|
/**
|
|
694
702
|
* Transport-level connectivity. Emitted by the device driver when
|
|
@@ -5416,7 +5424,7 @@ var ZodIssueCode$1 = {
|
|
|
5416
5424
|
var ZodFirstPartyTypeKind$1;
|
|
5417
5425
|
ZodFirstPartyTypeKind$1 || (ZodFirstPartyTypeKind$1 = {});
|
|
5418
5426
|
//#endregion
|
|
5419
|
-
//#region ../types/dist/sleep-
|
|
5427
|
+
//#region ../types/dist/sleep-CueztlR1.mjs
|
|
5420
5428
|
/**
|
|
5421
5429
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5422
5430
|
* window to float samples (D455).
|
|
@@ -42504,6 +42512,8 @@ var NcSystemEventKindSchema = _enum([
|
|
|
42504
42512
|
"alert-critical",
|
|
42505
42513
|
"alert-error",
|
|
42506
42514
|
"alert-critical-resolved",
|
|
42515
|
+
"rule-broken",
|
|
42516
|
+
"rule-repaired",
|
|
42507
42517
|
"camera-online",
|
|
42508
42518
|
"camera-offline",
|
|
42509
42519
|
"camera-disabled",
|
|
@@ -78780,6 +78790,8 @@ new Map(Object.entries({
|
|
|
78780
78790
|
"alert-critical": "system",
|
|
78781
78791
|
"alert-error": "system",
|
|
78782
78792
|
"alert-critical-resolved": "system",
|
|
78793
|
+
"rule-broken": "system",
|
|
78794
|
+
"rule-repaired": "system",
|
|
78783
78795
|
"storage-location-low": "system",
|
|
78784
78796
|
"storage-location-critical": "system",
|
|
78785
78797
|
"storage-location-ok": "system",
|
|
@@ -78914,6 +78926,12 @@ var NC_SYSTEM_EVENT_KIND_GROUP_SPECS = [
|
|
|
78914
78926
|
"alert-critical-resolved"
|
|
78915
78927
|
]
|
|
78916
78928
|
},
|
|
78929
|
+
{
|
|
78930
|
+
id: "rule-health",
|
|
78931
|
+
family: "system",
|
|
78932
|
+
label: "Notification rules",
|
|
78933
|
+
kinds: ["rule-broken", "rule-repaired"]
|
|
78934
|
+
},
|
|
78917
78935
|
{
|
|
78918
78936
|
id: "alarm",
|
|
78919
78937
|
family: "alarm",
|
|
@@ -79191,6 +79209,10 @@ var STATE_SUMMARY_VARS = [
|
|
|
79191
79209
|
[...RULE_TEXT],
|
|
79192
79210
|
[...RULE_TEXT],
|
|
79193
79211
|
[...RULE_TEXT],
|
|
79212
|
+
[...RULE_TEXT],
|
|
79213
|
+
[...RULE_TEXT],
|
|
79214
|
+
[...RULE_TEXT],
|
|
79215
|
+
[...RULE_TEXT],
|
|
79194
79216
|
([...RULE_TEXT], [...UPDATES]),
|
|
79195
79217
|
([...RULE_TEXT], [...PACKAGE_UPDATES]),
|
|
79196
79218
|
([...RULE_TEXT], [...PACKAGE_UPDATES]),
|
|
@@ -79229,6 +79251,107 @@ var STATE_SUMMARY_VARS = [
|
|
|
79229
79251
|
[...RULE_TEXT],
|
|
79230
79252
|
...STATE_SUMMARY_VARS
|
|
79231
79253
|
];
|
|
79254
|
+
new Map([
|
|
79255
|
+
{
|
|
79256
|
+
id: "device-connectivity",
|
|
79257
|
+
family: "device-events",
|
|
79258
|
+
label: "Device connectivity (offline / back online)",
|
|
79259
|
+
bad: ["device-offline"],
|
|
79260
|
+
recovery: ["device-online"],
|
|
79261
|
+
snapshotLabel: "Devices offline now",
|
|
79262
|
+
snapshotSection: "device-state"
|
|
79263
|
+
},
|
|
79264
|
+
{
|
|
79265
|
+
id: "device-switch",
|
|
79266
|
+
family: "device-events",
|
|
79267
|
+
label: "Device switched off / back on",
|
|
79268
|
+
bad: ["device-disabled"],
|
|
79269
|
+
recovery: ["device-enabled"],
|
|
79270
|
+
snapshotLabel: "Devices switched off now",
|
|
79271
|
+
snapshotSection: "device-state"
|
|
79272
|
+
},
|
|
79273
|
+
{
|
|
79274
|
+
id: "stream-connectivity",
|
|
79275
|
+
family: "device-events",
|
|
79276
|
+
label: "Stream connectivity (offline / back online)",
|
|
79277
|
+
bad: ["stream-offline"],
|
|
79278
|
+
recovery: ["stream-online"],
|
|
79279
|
+
snapshotLabel: "Streams offline now",
|
|
79280
|
+
snapshotSection: "streams"
|
|
79281
|
+
},
|
|
79282
|
+
{
|
|
79283
|
+
id: "battery",
|
|
79284
|
+
family: "device-events",
|
|
79285
|
+
label: "Battery (low / back to normal)",
|
|
79286
|
+
bad: ["device-battery-low"],
|
|
79287
|
+
recovery: ["device-battery-normal"],
|
|
79288
|
+
snapshotLabel: "Batteries low now",
|
|
79289
|
+
snapshotSection: "battery"
|
|
79290
|
+
},
|
|
79291
|
+
{
|
|
79292
|
+
id: "consumables",
|
|
79293
|
+
family: "device-events",
|
|
79294
|
+
label: "Consumables (low / replaced)",
|
|
79295
|
+
bad: ["device-consumable-low"],
|
|
79296
|
+
recovery: ["device-consumable-normal"],
|
|
79297
|
+
snapshotLabel: "Consumables low now",
|
|
79298
|
+
snapshotSection: "consumables"
|
|
79299
|
+
},
|
|
79300
|
+
{
|
|
79301
|
+
id: "tanks",
|
|
79302
|
+
family: "device-events",
|
|
79303
|
+
label: "Tanks (low or full / back to normal)",
|
|
79304
|
+
bad: ["device-tank-low", "device-tank-full"],
|
|
79305
|
+
recovery: ["device-tank-normal"],
|
|
79306
|
+
snapshotLabel: "Tanks low or full now",
|
|
79307
|
+
snapshotSection: "tanks"
|
|
79308
|
+
},
|
|
79309
|
+
{
|
|
79310
|
+
id: "recording-health",
|
|
79311
|
+
family: "device-events",
|
|
79312
|
+
label: "Recording health (stalled or degraded / recording again)",
|
|
79313
|
+
bad: ["recording-stalled", "recording-degraded"],
|
|
79314
|
+
recovery: ["recording-healthy"],
|
|
79315
|
+
snapshotLabel: "Recordings stalled now",
|
|
79316
|
+
snapshotSection: null
|
|
79317
|
+
},
|
|
79318
|
+
{
|
|
79319
|
+
id: "node-connectivity",
|
|
79320
|
+
family: "system",
|
|
79321
|
+
label: "Node connectivity (offline / back online)",
|
|
79322
|
+
bad: ["node-offline"],
|
|
79323
|
+
recovery: ["node-online"],
|
|
79324
|
+
snapshotLabel: "Nodes offline now",
|
|
79325
|
+
snapshotSection: "nodes"
|
|
79326
|
+
},
|
|
79327
|
+
{
|
|
79328
|
+
id: "storage-space",
|
|
79329
|
+
family: "system",
|
|
79330
|
+
label: "Storage space (low or critical / ok again)",
|
|
79331
|
+
bad: ["storage-location-low", "storage-location-critical"],
|
|
79332
|
+
recovery: ["storage-location-ok"],
|
|
79333
|
+
snapshotLabel: "Storage locations low now",
|
|
79334
|
+
snapshotSection: null
|
|
79335
|
+
},
|
|
79336
|
+
{
|
|
79337
|
+
id: "critical-alerts",
|
|
79338
|
+
family: "system",
|
|
79339
|
+
label: "Critical alerts (raised / resolved)",
|
|
79340
|
+
bad: ["alert-critical"],
|
|
79341
|
+
recovery: ["alert-critical-resolved"],
|
|
79342
|
+
snapshotLabel: "Critical alerts open now",
|
|
79343
|
+
snapshotSection: null
|
|
79344
|
+
},
|
|
79345
|
+
{
|
|
79346
|
+
id: "rule-health",
|
|
79347
|
+
family: "system",
|
|
79348
|
+
label: "Rule health (broken / repaired)",
|
|
79349
|
+
bad: ["rule-broken"],
|
|
79350
|
+
recovery: ["rule-repaired"],
|
|
79351
|
+
snapshotLabel: "Notification rules broken now",
|
|
79352
|
+
snapshotSection: null
|
|
79353
|
+
}
|
|
79354
|
+
].flatMap((spec) => [...spec.bad, ...spec.recovery].map((kind) => [kind, spec])));
|
|
79232
79355
|
new Set([
|
|
79233
79356
|
"disarmed",
|
|
79234
79357
|
"armed_home",
|
package/package.json
CHANGED