@camstack/addon-export-hap 1.2.86 → 1.2.87
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/hap-export.addon.js +47 -34
- package/dist/hap-export.addon.mjs +47 -34
- package/package.json +1 -1
package/dist/hap-export.addon.js
CHANGED
|
@@ -8515,17 +8515,29 @@ var HHMM = /^([01]\d|2[0-3]):[0-5]\d$/;
|
|
|
8515
8515
|
/**
|
|
8516
8516
|
* DERIVED per-camera storage summary — the single field cheap consumers read
|
|
8517
8517
|
* (the viewer's status dot, the camera list) instead of walking `bands`:
|
|
8518
|
-
* - `off`
|
|
8519
|
-
* - `events`
|
|
8520
|
-
* - `continuous`
|
|
8521
|
-
*
|
|
8522
|
-
*
|
|
8523
|
-
*
|
|
8518
|
+
* - `off` — no band covers the camera (or it is disabled).
|
|
8519
|
+
* - `events` — every band records around triggers only.
|
|
8520
|
+
* - `continuous` — at least one band records continuously.
|
|
8521
|
+
* - `on-device-decision`— the DEVICE decides: recording runs for as long as the
|
|
8522
|
+
* camera raises its own `recording-signal` level (a robot that cleans). There
|
|
8523
|
+
* is no schedule to author, because there is no hour to program — see
|
|
8524
|
+
* {@link RecordingConfigSchema}`.deviceDecision`.
|
|
8525
|
+
*
|
|
8526
|
+
* NEVER authored: the recorder stamps it from the authoritative intent
|
|
8527
|
+
* (`bands` + `deviceDecision`) on every save (`activeModeForConfig`). Writing it
|
|
8528
|
+
* has no effect.
|
|
8529
|
+
*
|
|
8530
|
+
* `on-device-decision` is named for WHO decides, not for how the recording is
|
|
8531
|
+
* requested. `on-demand` was rejected: in this repo's vocabulary a "demand" is
|
|
8532
|
+
* something the operator makes (the live gate is the recorder's own "demand
|
|
8533
|
+
* window"), and a knob whose name suggests the operator starts it while the
|
|
8534
|
+
* device actually does is the D62 shape — a control nobody can predict.
|
|
8524
8535
|
*/
|
|
8525
8536
|
var RecordingStorageModeSchema = _enum([
|
|
8526
8537
|
"off",
|
|
8527
8538
|
"events",
|
|
8528
|
-
"continuous"
|
|
8539
|
+
"continuous",
|
|
8540
|
+
"on-device-decision"
|
|
8529
8541
|
]);
|
|
8530
8542
|
/**
|
|
8531
8543
|
* Le macro classi che possono aprire una finestra di registrazione — le stesse
|
|
@@ -8575,22 +8587,7 @@ var RecordingTriggersSchema = object({
|
|
|
8575
8587
|
* il livello: un contatto trovato già aperto al riavvio del runner non fa
|
|
8576
8588
|
* registrare.
|
|
8577
8589
|
*/
|
|
8578
|
-
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
8579
|
-
/**
|
|
8580
|
-
* La camera registra per tutta la durata del SEGNALE che lei stessa
|
|
8581
|
-
* pubblica — la cap `recording-signal` (`active: true` mentre il device è in
|
|
8582
|
-
* funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
|
|
8583
|
-
* resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
|
|
8584
|
-
* caduta, così una pulizia di quaranta minuti è UNA clip.
|
|
8585
|
-
*
|
|
8586
|
-
* Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
|
|
8587
|
-
* suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
|
|
8588
|
-
* riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
|
|
8589
|
-
* segnale mai abbassato (un evento perso) non può tenere aperta una
|
|
8590
|
-
* registrazione (D11). Vedi `recorder/addon/band-decision.ts`
|
|
8591
|
-
* (`holdTrigger` / `releaseTrigger`).
|
|
8592
|
-
*/
|
|
8593
|
-
deviceSignal: boolean().optional()
|
|
8590
|
+
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
8594
8591
|
});
|
|
8595
8592
|
/**
|
|
8596
8593
|
* Mode of a single recording band — the recorder per-band vocabulary.
|
|
@@ -8674,8 +8671,29 @@ var RecordingConfigSchema = object({
|
|
|
8674
8671
|
* "off" is the absence of a covering band, never a band value.
|
|
8675
8672
|
*/
|
|
8676
8673
|
bands: array(RecordingBandSchema).default([]),
|
|
8674
|
+
/**
|
|
8675
|
+
* THE device-decided intent: record for as long as the camera itself raises
|
|
8676
|
+
* `recording-signal` (`active: true` while the device is in function — a
|
|
8677
|
+
* robot that cleans). AUTHORED, unlike `mode`, and the only authored
|
|
8678
|
+
* recording intent that is not a band.
|
|
8679
|
+
*
|
|
8680
|
+
* It carries NO schedule on purpose. A band is an HOUR, and this feature has
|
|
8681
|
+
* no hour to program: the device decides. What it costs the operator is one
|
|
8682
|
+
* flag — "this camera can record on its own" — and what it buys is the same
|
|
8683
|
+
* hold/release the recorder already implements (D371, `holdTrigger` /
|
|
8684
|
+
* `releaseTrigger`): the window opens on the rise, stays open for the whole
|
|
8685
|
+
* job however long it is, and closes one pad after the fall.
|
|
8686
|
+
*
|
|
8687
|
+
* EXCLUSIVE with `bands` (below): two authorities deciding when the same
|
|
8688
|
+
* camera records is the D62 failure. `off` remains `enabled: false`, so an
|
|
8689
|
+
* operator switching this camera off is REPORTED off, never as broken.
|
|
8690
|
+
*/
|
|
8691
|
+
deviceDecision: boolean().optional(),
|
|
8677
8692
|
retention: RecordingRetentionSchema.optional()
|
|
8678
|
-
}).strict()
|
|
8693
|
+
}).strict().refine((config) => config.deviceDecision !== true || config.bands.length === 0, {
|
|
8694
|
+
message: "deviceDecision is a whole-config mode and carries no schedule: it cannot be combined with bands",
|
|
8695
|
+
path: ["bands"]
|
|
8696
|
+
});
|
|
8679
8697
|
/**
|
|
8680
8698
|
* Entity-relocation job state (storage entity-routing spec, Phase 4).
|
|
8681
8699
|
*
|
|
@@ -21458,11 +21476,7 @@ var CameraAudioStatusSchema = object({
|
|
|
21458
21476
|
});
|
|
21459
21477
|
/** Recording block — null when no recording cap is active for this device. */
|
|
21460
21478
|
var CameraRecordingStatusSchema = object({
|
|
21461
|
-
mode:
|
|
21462
|
-
"off",
|
|
21463
|
-
"continuous",
|
|
21464
|
-
"events"
|
|
21465
|
-
]),
|
|
21479
|
+
mode: RecordingStorageModeSchema,
|
|
21466
21480
|
active: boolean(),
|
|
21467
21481
|
storageBytes: number()
|
|
21468
21482
|
});
|
|
@@ -27916,11 +27930,10 @@ DeviceType.Camera, DeviceType.Sensor, DeviceType.Switch, method(object({ deviceI
|
|
|
27916
27930
|
var RecordingStatusSchema = object({
|
|
27917
27931
|
deviceId: number(),
|
|
27918
27932
|
enabled: boolean(),
|
|
27919
|
-
|
|
27920
|
-
|
|
27921
|
-
|
|
27922
|
-
|
|
27923
|
-
]),
|
|
27933
|
+
/** THE derived storage mode, from the one definition
|
|
27934
|
+
* (`deriveRecordingMode`) — never a second enum. A duplicated list is how
|
|
27935
|
+
* `on-device-decision` could have reached the recorder and not the status. */
|
|
27936
|
+
activeMode: RecordingStorageModeSchema,
|
|
27924
27937
|
nodeId: string(),
|
|
27925
27938
|
storageBytes: number()
|
|
27926
27939
|
});
|
|
@@ -8503,17 +8503,29 @@ var HHMM = /^([01]\d|2[0-3]):[0-5]\d$/;
|
|
|
8503
8503
|
/**
|
|
8504
8504
|
* DERIVED per-camera storage summary — the single field cheap consumers read
|
|
8505
8505
|
* (the viewer's status dot, the camera list) instead of walking `bands`:
|
|
8506
|
-
* - `off`
|
|
8507
|
-
* - `events`
|
|
8508
|
-
* - `continuous`
|
|
8509
|
-
*
|
|
8510
|
-
*
|
|
8511
|
-
*
|
|
8506
|
+
* - `off` — no band covers the camera (or it is disabled).
|
|
8507
|
+
* - `events` — every band records around triggers only.
|
|
8508
|
+
* - `continuous` — at least one band records continuously.
|
|
8509
|
+
* - `on-device-decision`— the DEVICE decides: recording runs for as long as the
|
|
8510
|
+
* camera raises its own `recording-signal` level (a robot that cleans). There
|
|
8511
|
+
* is no schedule to author, because there is no hour to program — see
|
|
8512
|
+
* {@link RecordingConfigSchema}`.deviceDecision`.
|
|
8513
|
+
*
|
|
8514
|
+
* NEVER authored: the recorder stamps it from the authoritative intent
|
|
8515
|
+
* (`bands` + `deviceDecision`) on every save (`activeModeForConfig`). Writing it
|
|
8516
|
+
* has no effect.
|
|
8517
|
+
*
|
|
8518
|
+
* `on-device-decision` is named for WHO decides, not for how the recording is
|
|
8519
|
+
* requested. `on-demand` was rejected: in this repo's vocabulary a "demand" is
|
|
8520
|
+
* something the operator makes (the live gate is the recorder's own "demand
|
|
8521
|
+
* window"), and a knob whose name suggests the operator starts it while the
|
|
8522
|
+
* device actually does is the D62 shape — a control nobody can predict.
|
|
8512
8523
|
*/
|
|
8513
8524
|
var RecordingStorageModeSchema = _enum([
|
|
8514
8525
|
"off",
|
|
8515
8526
|
"events",
|
|
8516
|
-
"continuous"
|
|
8527
|
+
"continuous",
|
|
8528
|
+
"on-device-decision"
|
|
8517
8529
|
]);
|
|
8518
8530
|
/**
|
|
8519
8531
|
* Le macro classi che possono aprire una finestra di registrazione — le stesse
|
|
@@ -8563,22 +8575,7 @@ var RecordingTriggersSchema = object({
|
|
|
8563
8575
|
* il livello: un contatto trovato già aperto al riavvio del runner non fa
|
|
8564
8576
|
* registrare.
|
|
8565
8577
|
*/
|
|
8566
|
-
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
8567
|
-
/**
|
|
8568
|
-
* La camera registra per tutta la durata del SEGNALE che lei stessa
|
|
8569
|
-
* pubblica — la cap `recording-signal` (`active: true` mentre il device è in
|
|
8570
|
-
* funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
|
|
8571
|
-
* resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
|
|
8572
|
-
* caduta, così una pulizia di quaranta minuti è UNA clip.
|
|
8573
|
-
*
|
|
8574
|
-
* Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
|
|
8575
|
-
* suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
|
|
8576
|
-
* riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
|
|
8577
|
-
* segnale mai abbassato (un evento perso) non può tenere aperta una
|
|
8578
|
-
* registrazione (D11). Vedi `recorder/addon/band-decision.ts`
|
|
8579
|
-
* (`holdTrigger` / `releaseTrigger`).
|
|
8580
|
-
*/
|
|
8581
|
-
deviceSignal: boolean().optional()
|
|
8578
|
+
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
8582
8579
|
});
|
|
8583
8580
|
/**
|
|
8584
8581
|
* Mode of a single recording band — the recorder per-band vocabulary.
|
|
@@ -8662,8 +8659,29 @@ var RecordingConfigSchema = object({
|
|
|
8662
8659
|
* "off" is the absence of a covering band, never a band value.
|
|
8663
8660
|
*/
|
|
8664
8661
|
bands: array(RecordingBandSchema).default([]),
|
|
8662
|
+
/**
|
|
8663
|
+
* THE device-decided intent: record for as long as the camera itself raises
|
|
8664
|
+
* `recording-signal` (`active: true` while the device is in function — a
|
|
8665
|
+
* robot that cleans). AUTHORED, unlike `mode`, and the only authored
|
|
8666
|
+
* recording intent that is not a band.
|
|
8667
|
+
*
|
|
8668
|
+
* It carries NO schedule on purpose. A band is an HOUR, and this feature has
|
|
8669
|
+
* no hour to program: the device decides. What it costs the operator is one
|
|
8670
|
+
* flag — "this camera can record on its own" — and what it buys is the same
|
|
8671
|
+
* hold/release the recorder already implements (D371, `holdTrigger` /
|
|
8672
|
+
* `releaseTrigger`): the window opens on the rise, stays open for the whole
|
|
8673
|
+
* job however long it is, and closes one pad after the fall.
|
|
8674
|
+
*
|
|
8675
|
+
* EXCLUSIVE with `bands` (below): two authorities deciding when the same
|
|
8676
|
+
* camera records is the D62 failure. `off` remains `enabled: false`, so an
|
|
8677
|
+
* operator switching this camera off is REPORTED off, never as broken.
|
|
8678
|
+
*/
|
|
8679
|
+
deviceDecision: boolean().optional(),
|
|
8665
8680
|
retention: RecordingRetentionSchema.optional()
|
|
8666
|
-
}).strict()
|
|
8681
|
+
}).strict().refine((config) => config.deviceDecision !== true || config.bands.length === 0, {
|
|
8682
|
+
message: "deviceDecision is a whole-config mode and carries no schedule: it cannot be combined with bands",
|
|
8683
|
+
path: ["bands"]
|
|
8684
|
+
});
|
|
8667
8685
|
/**
|
|
8668
8686
|
* Entity-relocation job state (storage entity-routing spec, Phase 4).
|
|
8669
8687
|
*
|
|
@@ -21446,11 +21464,7 @@ var CameraAudioStatusSchema = object({
|
|
|
21446
21464
|
});
|
|
21447
21465
|
/** Recording block — null when no recording cap is active for this device. */
|
|
21448
21466
|
var CameraRecordingStatusSchema = object({
|
|
21449
|
-
mode:
|
|
21450
|
-
"off",
|
|
21451
|
-
"continuous",
|
|
21452
|
-
"events"
|
|
21453
|
-
]),
|
|
21467
|
+
mode: RecordingStorageModeSchema,
|
|
21454
21468
|
active: boolean(),
|
|
21455
21469
|
storageBytes: number()
|
|
21456
21470
|
});
|
|
@@ -27904,11 +27918,10 @@ DeviceType.Camera, DeviceType.Sensor, DeviceType.Switch, method(object({ deviceI
|
|
|
27904
27918
|
var RecordingStatusSchema = object({
|
|
27905
27919
|
deviceId: number(),
|
|
27906
27920
|
enabled: boolean(),
|
|
27907
|
-
|
|
27908
|
-
|
|
27909
|
-
|
|
27910
|
-
|
|
27911
|
-
]),
|
|
27921
|
+
/** THE derived storage mode, from the one definition
|
|
27922
|
+
* (`deriveRecordingMode`) — never a second enum. A duplicated list is how
|
|
27923
|
+
* `on-device-decision` could have reached the recorder and not the status. */
|
|
27924
|
+
activeMode: RecordingStorageModeSchema,
|
|
27912
27925
|
nodeId: string(),
|
|
27913
27926
|
storageBytes: number()
|
|
27914
27927
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camstack/addon-export-hap",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.87",
|
|
4
4
|
"description": "HomeKit (HAP) exporter for CamStack devices. Publishes each exposed device as its own HomeKit accessory: cameras and doorbells with SRTP streaming, HomeKit Secure Video, motion, two-way audio, PTZ and battery; switches, lights, locks and sensors through a capability→service table.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"camstack",
|