@camstack/types 1.2.548 → 1.2.550
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 +33 -0
- package/dist/addon/addon-instance.d.ts +24 -0
- package/dist/addon/build-addon-route-provider.d.ts +2 -0
- package/dist/addon.js +5 -5
- package/dist/addon.mjs +5 -5
- package/dist/automation/index.d.ts +4 -3
- package/dist/automation/recipe.d.ts +12105 -604
- package/dist/automation/scheduler.d.ts +7 -0
- package/dist/automation/step-runner.d.ts +70 -0
- package/dist/automation/trace.d.ts +252 -145
- package/dist/automation/wait-until.d.ts +32 -0
- package/dist/automation/when-site.d.ts +1 -1
- package/dist/capabilities/accessories.cap.d.ts +1 -1
- package/dist/capabilities/actions.cap.d.ts +1 -178
- package/dist/capabilities/addon-routes.cap.d.ts +3 -0
- package/dist/capabilities/battery.cap.d.ts +2 -2
- package/dist/capabilities/capability-definition.d.ts +47 -1
- package/dist/capabilities/climate-control.cap.d.ts +8 -1
- package/dist/capabilities/core-blocks.cap.d.ts +119 -8723
- package/dist/capabilities/customize-catalog.d.ts +3 -1
- package/dist/capabilities/customize-spec.d.ts +26 -2
- package/dist/capabilities/device-manager.cap.d.ts +6 -0
- package/dist/capabilities/event-emitter.cap.d.ts +99 -3
- package/dist/capabilities/event-vocabulary.d.ts +99 -0
- package/dist/capabilities/fan-control.cap.d.ts +248 -0
- package/dist/capabilities/fan-presets.cap.d.ts +172 -536
- package/dist/capabilities/group-active.cap.d.ts +1 -1
- package/dist/capabilities/group-commands.cap.d.ts +1 -1
- package/dist/capabilities/group-status.cap.d.ts +1 -1
- package/dist/capabilities/heating-valve.cap.d.ts +1 -1
- package/dist/capabilities/hero-layout.cap.d.ts +2 -0
- package/dist/capabilities/humidifier.cap.d.ts +5 -0
- package/dist/capabilities/humidity-sensor.cap.d.ts +1 -1
- package/dist/capabilities/index.d.ts +5 -4
- package/dist/capabilities/media-player.cap.d.ts +7 -0
- package/dist/capabilities/oauth-integration.cap.d.ts +8 -0
- package/dist/capabilities/pet-fountain.cap.d.ts +5 -0
- package/dist/capabilities/power-meter.cap.d.ts +5 -5
- package/dist/capabilities/power-source.cap.d.ts +5 -0
- package/dist/capabilities/running-state.cap.d.ts +2 -2
- package/dist/capabilities/schedulers.cap.d.ts +1 -178
- package/dist/capabilities/sso-bridge.cap.d.ts +3 -0
- package/dist/capabilities/switch.cap.d.ts +1 -1
- package/dist/capabilities/temperature-sensor.cap.d.ts +1 -1
- package/dist/capabilities/timed-run.cap.d.ts +19 -5
- package/dist/capabilities/user-management.cap.d.ts +4 -0
- package/dist/capabilities/water-heater.cap.d.ts +7 -0
- package/dist/client.js +7 -11
- package/dist/client.mjs +7 -11
- package/dist/{composed-stable-id-DrGLxjVF.js → composed-stable-id-CDNLq7Y8.js} +27 -10
- package/dist/{composed-stable-id-DFNyOFzz.mjs → composed-stable-id-CPp3votu.mjs} +27 -10
- package/dist/composition/composition-report.d.ts +6 -0
- package/dist/composition/evaluate-field.d.ts +7 -0
- package/dist/composition/field-kinds.d.ts +12 -1
- package/dist/composition/helpers/index.d.ts +1 -1
- package/dist/composition/helpers/source-pick.d.ts +0 -5
- package/dist/composition/power-source-link.d.ts +15 -0
- package/dist/composition/state-fields.d.ts +2 -0
- package/dist/composition/validate-composition.d.ts +15 -1
- package/dist/device/base-device-provider.d.ts +13 -0
- package/dist/device/device-control-resolution.d.ts +1 -33
- package/dist/device/device-kind.d.ts +36 -0
- package/dist/device/device-management.d.ts +3 -0
- package/dist/device/device-type.d.ts +27 -10
- package/dist/device/hero/hero-fragment.d.ts +2 -0
- package/dist/device/hero/hero-layout.d.ts +1 -3
- package/dist/device/hero/hero-look.d.ts +18 -12
- package/dist/device/hero/hero-scene.d.ts +9 -3
- package/dist/device/index.d.ts +2 -1
- package/dist/device/power-switch.d.ts +82 -0
- package/dist/device/schema-fields.d.ts +10 -1
- package/dist/generated/addon-api.d.ts +7 -0
- package/dist/generated/addon-cap-facts.d.ts +1 -1
- package/dist/generated/cap-input-defaults.d.ts +1 -1
- package/dist/generated/collection-array-methods.d.ts +1 -1
- package/dist/generated/customize-catalog.d.ts +257 -8
- package/dist/generated/method-access-map.d.ts +1 -1
- package/dist/generated/method-device-selectors.d.ts +1 -1
- package/dist/{implemented-methods-M5aguGon.mjs → implemented-methods-5YMDeE3f.mjs} +1 -1
- package/dist/{implemented-methods-8AU92riC.js → implemented-methods-Cj65uy2F.js} +1 -1
- package/dist/index.d.ts +11 -6
- package/dist/index.js +2386 -494
- package/dist/index.mjs +2312 -488
- package/dist/interfaces/addon-routes.d.ts +13 -0
- package/dist/interfaces/config-ui.d.ts +15 -24
- package/dist/node.js +2 -2
- package/dist/node.mjs +2 -2
- package/dist/{sleep-D_NpiLFP.mjs → sleep-D0roI_CZ.mjs} +50 -1
- package/dist/{sleep-vzHEmsrO.js → sleep-dcR4vBFG.js} +50 -1
- package/package.json +1 -1
|
@@ -8,6 +8,12 @@ export interface AddonHttpRequest {
|
|
|
8
8
|
readonly query: Record<string, string>;
|
|
9
9
|
readonly body: unknown;
|
|
10
10
|
readonly headers: Record<string, string>;
|
|
11
|
+
/**
|
|
12
|
+
* The integration instance the request addresses, on a route declared
|
|
13
|
+
* `perInstance`. A path with no instance segment names the default instance,
|
|
14
|
+
* whose id is the addon id. Absent on every other route.
|
|
15
|
+
*/
|
|
16
|
+
readonly instanceId?: string;
|
|
11
17
|
/** Populated for 'authenticated' and 'admin' routes */
|
|
12
18
|
readonly user?: {
|
|
13
19
|
readonly id: string;
|
|
@@ -51,6 +57,13 @@ export interface IAddonHttpRoute {
|
|
|
51
57
|
readonly access: RouteAccess;
|
|
52
58
|
readonly description?: string;
|
|
53
59
|
readonly rateLimit?: RouteRateLimit;
|
|
60
|
+
/**
|
|
61
|
+
* The route exists once per integration instance of the addon. The hub then
|
|
62
|
+
* serves it at `/addon/<addonId>/instances/<instanceId>/<path>` as well as at
|
|
63
|
+
* `/addon/<addonId>/<path>` (the default instance), and the handler reads
|
|
64
|
+
* which one from `request.instanceId`.
|
|
65
|
+
*/
|
|
66
|
+
readonly perInstance?: boolean;
|
|
54
67
|
readonly handler: (request: AddonHttpRequest, reply: AddonHttpReply) => Promise<void>;
|
|
55
68
|
}
|
|
56
69
|
/**
|
|
@@ -509,22 +509,21 @@ export interface ConfigNodeMultiSelectField extends ConfigFieldBase {
|
|
|
509
509
|
maxItems?: number;
|
|
510
510
|
}
|
|
511
511
|
/**
|
|
512
|
-
* Declarative
|
|
513
|
-
*
|
|
514
|
-
*
|
|
515
|
-
*
|
|
516
|
-
*
|
|
517
|
-
* an empty set on the live cluster and left pickers blank).
|
|
512
|
+
* Declarative filter for `device-select` / `device-multiselect`. The field
|
|
513
|
+
* carries ONLY this filter; the renderer asks `deviceManager.search` for the
|
|
514
|
+
* devices that pass it. There is deliberately NO server-computed option list
|
|
515
|
+
* on the field (that path depended on `deviceManager.getAllBindings`, which
|
|
516
|
+
* returned an empty set on the live cluster and left pickers blank).
|
|
518
517
|
*
|
|
519
|
-
* Match rule (
|
|
520
|
-
*
|
|
521
|
-
* - `caps` → the device
|
|
518
|
+
* Match rule (every provided clause must hold; an absent/empty filter
|
|
519
|
+
* matches every device):
|
|
520
|
+
* - `caps` → the device provides ANY of these capabilities.
|
|
522
521
|
* - `types` → the device's `type` is one of these.
|
|
523
|
-
* `excludeDeviceId`
|
|
524
|
-
* settings host the field —
|
|
522
|
+
* `excludeDeviceId` / `excludeTypes` are always subtracted (typically the
|
|
523
|
+
* device whose settings host the field — a camera must not list itself).
|
|
525
524
|
*/
|
|
526
525
|
export interface DeviceSelectFilter {
|
|
527
|
-
/** Keep devices
|
|
526
|
+
/** Keep devices that provide ANY of these capabilities. */
|
|
528
527
|
readonly caps?: readonly string[];
|
|
529
528
|
/** Keep devices whose `type` is one of these `DeviceType` strings. */
|
|
530
529
|
readonly types?: readonly string[];
|
|
@@ -535,8 +534,8 @@ export interface DeviceSelectFilter {
|
|
|
535
534
|
readonly excludeTypes?: readonly string[];
|
|
536
535
|
}
|
|
537
536
|
/**
|
|
538
|
-
* Pick a SINGLE device from the live device catalogue
|
|
539
|
-
*
|
|
537
|
+
* Pick a SINGLE device from the live device catalogue, narrowed by
|
|
538
|
+
* `deviceFilter` (see {@link DeviceSelectFilter}).
|
|
540
539
|
* Stored value is the chosen device id as a string.
|
|
541
540
|
*/
|
|
542
541
|
export interface ConfigDeviceSelectField extends ConfigFieldBase {
|
|
@@ -544,22 +543,14 @@ export interface ConfigDeviceSelectField extends ConfigFieldBase {
|
|
|
544
543
|
deviceFilter?: DeviceSelectFilter;
|
|
545
544
|
}
|
|
546
545
|
/**
|
|
547
|
-
* Pick MULTIPLE devices from the live device catalogue — the
|
|
548
|
-
*
|
|
546
|
+
* Pick MULTIPLE devices from the live device catalogue — the sibling of
|
|
547
|
+
* `device-select` (same `deviceFilter`). Stored
|
|
549
548
|
* value is a `string[]` of device ids.
|
|
550
549
|
*/
|
|
551
550
|
export interface ConfigDeviceMultiSelectField extends ConfigFieldBase {
|
|
552
551
|
type: 'device-multiselect';
|
|
553
552
|
deviceFilter?: DeviceSelectFilter;
|
|
554
553
|
maxItems?: number;
|
|
555
|
-
/**
|
|
556
|
-
* Devices sharing this location are listed FIRST, under a "Suggested"
|
|
557
|
-
* heading, and the location / type facet chips are shown — the shape the
|
|
558
|
-
* linked-devices picker needs (D356): a catalogue of hundreds narrowed by
|
|
559
|
-
* where and what before the free-text search, and the room's own devices
|
|
560
|
-
* offered without being linked on anybody's behalf. `null` = no suggestion.
|
|
561
|
-
*/
|
|
562
|
-
suggestLocation?: string | null;
|
|
563
554
|
}
|
|
564
555
|
/**
|
|
565
556
|
* Pick a SINGLE `notification-output` target from the live catalog
|
package/dist/node.js
CHANGED
|
@@ -21,8 +21,8 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
21
21
|
enumerable: true
|
|
22
22
|
}) : target, mod));
|
|
23
23
|
//#endregion
|
|
24
|
-
const require_composed_stable_id = require("./composed-stable-id-
|
|
25
|
-
const require_implemented_methods = require("./implemented-methods-
|
|
24
|
+
const require_composed_stable_id = require("./composed-stable-id-CDNLq7Y8.js");
|
|
25
|
+
const require_implemented_methods = require("./implemented-methods-Cj65uy2F.js");
|
|
26
26
|
let node_crypto = require("node:crypto");
|
|
27
27
|
let node_fs = require("node:fs");
|
|
28
28
|
node_fs = __toESM(node_fs);
|
package/dist/node.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as errMsg } from "./composed-stable-id-
|
|
2
|
-
import { Fn as getFfmpegArtifact, In as getFfmpegDownloadUrl, Ln as canonicalHash, Mn as chooseFfmpegBinary, Nn as ffmpegBinaryName, Pn as FFMPEG_RELEASE, R as compositionSourceKey, Rn as Fmp4BoxSplitter, Un as buildFfmpegArgs, a as CUSTOMIZATION_BLOCK_NAME_PREFIX, jn as FFMPEG_PATH_ENV, qn as isSoftwareDecode, t as implementedMethodsOf } from "./implemented-methods-
|
|
1
|
+
import { s as errMsg } from "./composed-stable-id-CPp3votu.mjs";
|
|
2
|
+
import { Fn as getFfmpegArtifact, In as getFfmpegDownloadUrl, Ln as canonicalHash, Mn as chooseFfmpegBinary, Nn as ffmpegBinaryName, Pn as FFMPEG_RELEASE, R as compositionSourceKey, Rn as Fmp4BoxSplitter, Un as buildFfmpegArgs, a as CUSTOMIZATION_BLOCK_NAME_PREFIX, jn as FFMPEG_PATH_ENV, qn as isSoftwareDecode, t as implementedMethodsOf } from "./implemented-methods-5YMDeE3f.mjs";
|
|
3
3
|
import { createHash, createHmac, randomUUID, timingSafeEqual } from "node:crypto";
|
|
4
4
|
import * as fs from "node:fs";
|
|
5
5
|
import { chmodSync, copyFileSync, createWriteStream, existsSync, mkdirSync, readFileSync, readdirSync, realpathSync, renameSync, rmSync, unlinkSync, writeFileSync } from "node:fs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as EventCategory } from "./event-category-78tcBemo.mjs";
|
|
2
|
-
import { a as DeviceType, i as DeviceRole, s as errMsg } from "./composed-stable-id-
|
|
2
|
+
import { a as DeviceType, i as DeviceRole, s as errMsg } from "./composed-stable-id-CPp3votu.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
//#region src/audio/audio-chunk-format.ts
|
|
5
5
|
/**
|
|
@@ -9020,6 +9020,50 @@ var ACTUATOR_CAP_VOCABULARY = {
|
|
|
9020
9020
|
value: false
|
|
9021
9021
|
},
|
|
9022
9022
|
args: { oscillating: false }
|
|
9023
|
+
},
|
|
9024
|
+
{
|
|
9025
|
+
id: "fan.horizontalOscillateOn",
|
|
9026
|
+
method: "setOscillationAxis",
|
|
9027
|
+
label: t("Horizontal oscillation on", "Oscillazione orizzontale attiva"),
|
|
9028
|
+
phrase: t("Start the horizontal oscillation of {device}", "Attiva l’oscillazione orizzontale di {device}"),
|
|
9029
|
+
icon: "move-horizontal",
|
|
9030
|
+
args: {
|
|
9031
|
+
axis: "horizontal",
|
|
9032
|
+
oscillating: true
|
|
9033
|
+
}
|
|
9034
|
+
},
|
|
9035
|
+
{
|
|
9036
|
+
id: "fan.horizontalOscillateOff",
|
|
9037
|
+
method: "setOscillationAxis",
|
|
9038
|
+
label: t("Horizontal oscillation off", "Oscillazione orizzontale spenta"),
|
|
9039
|
+
phrase: t("Stop the horizontal oscillation of {device}", "Ferma l’oscillazione orizzontale di {device}"),
|
|
9040
|
+
icon: "move-horizontal",
|
|
9041
|
+
args: {
|
|
9042
|
+
axis: "horizontal",
|
|
9043
|
+
oscillating: false
|
|
9044
|
+
}
|
|
9045
|
+
},
|
|
9046
|
+
{
|
|
9047
|
+
id: "fan.verticalOscillateOn",
|
|
9048
|
+
method: "setOscillationAxis",
|
|
9049
|
+
label: t("Vertical oscillation on", "Oscillazione verticale attiva"),
|
|
9050
|
+
phrase: t("Start the vertical oscillation of {device}", "Attiva l’oscillazione verticale di {device}"),
|
|
9051
|
+
icon: "move-vertical",
|
|
9052
|
+
args: {
|
|
9053
|
+
axis: "vertical",
|
|
9054
|
+
oscillating: true
|
|
9055
|
+
}
|
|
9056
|
+
},
|
|
9057
|
+
{
|
|
9058
|
+
id: "fan.verticalOscillateOff",
|
|
9059
|
+
method: "setOscillationAxis",
|
|
9060
|
+
label: t("Vertical oscillation off", "Oscillazione verticale spenta"),
|
|
9061
|
+
phrase: t("Stop the vertical oscillation of {device}", "Ferma l’oscillazione verticale di {device}"),
|
|
9062
|
+
icon: "move-vertical",
|
|
9063
|
+
args: {
|
|
9064
|
+
axis: "vertical",
|
|
9065
|
+
oscillating: false
|
|
9066
|
+
}
|
|
9023
9067
|
}
|
|
9024
9068
|
],
|
|
9025
9069
|
state: [{
|
|
@@ -13829,6 +13873,10 @@ var CAP_STATE_LEAVES = Object.freeze({
|
|
|
13829
13873
|
"path": "lastEvent.eventType",
|
|
13830
13874
|
"valueType": "string"
|
|
13831
13875
|
},
|
|
13876
|
+
{
|
|
13877
|
+
"path": "lastEvent.sourceId",
|
|
13878
|
+
"valueType": "string"
|
|
13879
|
+
},
|
|
13832
13880
|
{
|
|
13833
13881
|
"path": "lastEvent.timestamp",
|
|
13834
13882
|
"valueType": "number"
|
|
@@ -15707,6 +15755,7 @@ function createDeviceProxy(api, binding, opts) {
|
|
|
15707
15755
|
setPreset: (input) => dispatch("fan-control", "fanControl", "setPreset", "mutation", input),
|
|
15708
15756
|
setDirection: (input) => dispatch("fan-control", "fanControl", "setDirection", "mutation", input),
|
|
15709
15757
|
setOscillating: (input) => dispatch("fan-control", "fanControl", "setOscillating", "mutation", input),
|
|
15758
|
+
setOscillationAxis: (input) => dispatch("fan-control", "fanControl", "setOscillationAxis", "mutation", input),
|
|
15710
15759
|
getStatus: (input) => dispatch("fan-control", "fanControl", "getStatus", "query", input)
|
|
15711
15760
|
};
|
|
15712
15761
|
const featureProbeInterface = { getStatus: (input) => dispatch("feature-probe", "featureProbe", "getStatus", "query", input) };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_event_category = require("./event-category-BC4RRerT.js");
|
|
2
|
-
const require_composed_stable_id = require("./composed-stable-id-
|
|
2
|
+
const require_composed_stable_id = require("./composed-stable-id-CDNLq7Y8.js");
|
|
3
3
|
let zod = require("zod");
|
|
4
4
|
//#region src/audio/audio-chunk-format.ts
|
|
5
5
|
/**
|
|
@@ -9020,6 +9020,50 @@ var ACTUATOR_CAP_VOCABULARY = {
|
|
|
9020
9020
|
value: false
|
|
9021
9021
|
},
|
|
9022
9022
|
args: { oscillating: false }
|
|
9023
|
+
},
|
|
9024
|
+
{
|
|
9025
|
+
id: "fan.horizontalOscillateOn",
|
|
9026
|
+
method: "setOscillationAxis",
|
|
9027
|
+
label: t("Horizontal oscillation on", "Oscillazione orizzontale attiva"),
|
|
9028
|
+
phrase: t("Start the horizontal oscillation of {device}", "Attiva l’oscillazione orizzontale di {device}"),
|
|
9029
|
+
icon: "move-horizontal",
|
|
9030
|
+
args: {
|
|
9031
|
+
axis: "horizontal",
|
|
9032
|
+
oscillating: true
|
|
9033
|
+
}
|
|
9034
|
+
},
|
|
9035
|
+
{
|
|
9036
|
+
id: "fan.horizontalOscillateOff",
|
|
9037
|
+
method: "setOscillationAxis",
|
|
9038
|
+
label: t("Horizontal oscillation off", "Oscillazione orizzontale spenta"),
|
|
9039
|
+
phrase: t("Stop the horizontal oscillation of {device}", "Ferma l’oscillazione orizzontale di {device}"),
|
|
9040
|
+
icon: "move-horizontal",
|
|
9041
|
+
args: {
|
|
9042
|
+
axis: "horizontal",
|
|
9043
|
+
oscillating: false
|
|
9044
|
+
}
|
|
9045
|
+
},
|
|
9046
|
+
{
|
|
9047
|
+
id: "fan.verticalOscillateOn",
|
|
9048
|
+
method: "setOscillationAxis",
|
|
9049
|
+
label: t("Vertical oscillation on", "Oscillazione verticale attiva"),
|
|
9050
|
+
phrase: t("Start the vertical oscillation of {device}", "Attiva l’oscillazione verticale di {device}"),
|
|
9051
|
+
icon: "move-vertical",
|
|
9052
|
+
args: {
|
|
9053
|
+
axis: "vertical",
|
|
9054
|
+
oscillating: true
|
|
9055
|
+
}
|
|
9056
|
+
},
|
|
9057
|
+
{
|
|
9058
|
+
id: "fan.verticalOscillateOff",
|
|
9059
|
+
method: "setOscillationAxis",
|
|
9060
|
+
label: t("Vertical oscillation off", "Oscillazione verticale spenta"),
|
|
9061
|
+
phrase: t("Stop the vertical oscillation of {device}", "Ferma l’oscillazione verticale di {device}"),
|
|
9062
|
+
icon: "move-vertical",
|
|
9063
|
+
args: {
|
|
9064
|
+
axis: "vertical",
|
|
9065
|
+
oscillating: false
|
|
9066
|
+
}
|
|
9023
9067
|
}
|
|
9024
9068
|
],
|
|
9025
9069
|
state: [{
|
|
@@ -13829,6 +13873,10 @@ var CAP_STATE_LEAVES = Object.freeze({
|
|
|
13829
13873
|
"path": "lastEvent.eventType",
|
|
13830
13874
|
"valueType": "string"
|
|
13831
13875
|
},
|
|
13876
|
+
{
|
|
13877
|
+
"path": "lastEvent.sourceId",
|
|
13878
|
+
"valueType": "string"
|
|
13879
|
+
},
|
|
13832
13880
|
{
|
|
13833
13881
|
"path": "lastEvent.timestamp",
|
|
13834
13882
|
"valueType": "number"
|
|
@@ -15707,6 +15755,7 @@ function createDeviceProxy(api, binding, opts) {
|
|
|
15707
15755
|
setPreset: (input) => dispatch("fan-control", "fanControl", "setPreset", "mutation", input),
|
|
15708
15756
|
setDirection: (input) => dispatch("fan-control", "fanControl", "setDirection", "mutation", input),
|
|
15709
15757
|
setOscillating: (input) => dispatch("fan-control", "fanControl", "setOscillating", "mutation", input),
|
|
15758
|
+
setOscillationAxis: (input) => dispatch("fan-control", "fanControl", "setOscillationAxis", "mutation", input),
|
|
15710
15759
|
getStatus: (input) => dispatch("fan-control", "fanControl", "getStatus", "query", input)
|
|
15711
15760
|
};
|
|
15712
15761
|
const featureProbeInterface = { getStatus: (input) => dispatch("feature-probe", "featureProbe", "getStatus", "query", input) };
|