@digital-alchemy/hass 0.3.12 → 0.3.14
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/dynamic.d.ts +71 -984
- package/dist/dynamic.js +60 -104
- package/dist/dynamic.js.map +1 -1
- package/dist/extensions/entity.extension.d.ts +6 -6
- package/dist/extensions/entity.extension.js.map +1 -1
- package/dist/helpers/device.helper.d.ts +1 -1
- package/dist/helpers/utility.helper.d.ts +8 -3
- package/dist/helpers/utility.helper.js +1 -1
- package/dist/helpers/utility.helper.js.map +1 -1
- package/package.json +1 -1
package/dist/dynamic.d.ts
CHANGED
|
@@ -1,95 +1,68 @@
|
|
|
1
1
|
import { PICK_ENTITY } from "./helpers";
|
|
2
|
-
export type TFloorId =
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export type
|
|
6
|
-
area: true;
|
|
7
|
-
};
|
|
8
|
-
export type TLabelId = string & {
|
|
9
|
-
label: string;
|
|
10
|
-
};
|
|
11
|
-
export type TDeviceId = string & {
|
|
12
|
-
device: true;
|
|
13
|
-
};
|
|
2
|
+
export type TFloorId = "example_floor" | "example_floor_2";
|
|
3
|
+
export type TAreaId = "example_area" | "empty_area";
|
|
4
|
+
export type TLabelId = "example_label" | "example_label_2";
|
|
5
|
+
export type TDeviceId = "example_device" | "example_device_2";
|
|
14
6
|
export type TZoneId = string & {
|
|
15
7
|
zone: true;
|
|
16
8
|
};
|
|
17
|
-
/**
|
|
18
|
-
* ## THIS FILE IS INTENDED TO BE REPLACED
|
|
19
|
-
*
|
|
20
|
-
* ! IF YOU STILL SEE THIS IN YOUR `node_modules`, run `npx type-writer`
|
|
21
|
-
*
|
|
22
|
-
* The purpose it to represent the configuration of Home Assistant
|
|
23
|
-
*
|
|
24
|
-
* - entities, with their available attributes & states
|
|
25
|
-
* - services, and what parameters they take
|
|
26
|
-
*
|
|
27
|
-
* This information is TYPES ONLY, and is used to add type safety to
|
|
28
|
-
* methods exported from this library through the use of utility types that
|
|
29
|
-
* take advantage of this information
|
|
30
|
-
*
|
|
31
|
-
* A post-install hook will regenerate these with real values.
|
|
32
|
-
*
|
|
33
|
-
* The service definition is the switch, light, scene domains from a previously generated file.
|
|
34
|
-
* These are required to make typescript happy for internal library definitions
|
|
35
|
-
*/
|
|
36
9
|
export declare const ENTITY_SETUP: {
|
|
37
10
|
readonly binary_sensor: {
|
|
38
|
-
readonly
|
|
11
|
+
readonly example_binary_sensor: {
|
|
39
12
|
readonly attributes: {
|
|
40
|
-
readonly friendly_name: "
|
|
13
|
+
readonly friendly_name: "Example binary sensor";
|
|
41
14
|
};
|
|
42
15
|
readonly context: {
|
|
43
|
-
readonly id: "
|
|
16
|
+
readonly id: "abc123";
|
|
44
17
|
readonly parent_id: any;
|
|
45
18
|
readonly user_id: any;
|
|
46
19
|
};
|
|
47
|
-
readonly entity_id: "binary_sensor.
|
|
48
|
-
readonly last_changed: "2024-
|
|
49
|
-
readonly last_updated: "2024-
|
|
20
|
+
readonly entity_id: "binary_sensor.example_binary_sensor";
|
|
21
|
+
readonly last_changed: "2024-01-01T01:01:01.000000+00:00";
|
|
22
|
+
readonly last_updated: "2024-01-01T01:01:01.000000+00:00";
|
|
50
23
|
readonly state: "on";
|
|
51
24
|
};
|
|
52
25
|
};
|
|
53
26
|
readonly button: {
|
|
54
|
-
readonly
|
|
27
|
+
readonly example_button: {
|
|
55
28
|
readonly attributes: {
|
|
56
|
-
readonly friendly_name: "
|
|
29
|
+
readonly friendly_name: "Example button";
|
|
57
30
|
};
|
|
58
31
|
readonly context: {
|
|
59
|
-
readonly id: "
|
|
32
|
+
readonly id: "abc123";
|
|
60
33
|
readonly parent_id: any;
|
|
61
34
|
readonly user_id: any;
|
|
62
35
|
};
|
|
63
|
-
readonly entity_id: "button.
|
|
64
|
-
readonly last_changed: "2024-
|
|
36
|
+
readonly entity_id: "button.example_button";
|
|
37
|
+
readonly last_changed: "2024-01-01T01:01:01.000000+00:00";
|
|
65
38
|
};
|
|
66
39
|
};
|
|
67
40
|
readonly calendar: {
|
|
68
|
-
readonly
|
|
41
|
+
readonly example_calendar: {
|
|
69
42
|
readonly attributes: {
|
|
70
|
-
readonly friendly_name: "
|
|
43
|
+
readonly friendly_name: "Example calendar";
|
|
71
44
|
readonly offset_reached: false;
|
|
72
45
|
};
|
|
73
46
|
readonly context: {
|
|
74
|
-
readonly id: "
|
|
47
|
+
readonly id: "abc123";
|
|
75
48
|
readonly parent_id: any;
|
|
76
49
|
readonly user_id: any;
|
|
77
50
|
};
|
|
78
|
-
readonly entity_id: "calendar.
|
|
79
|
-
readonly last_changed: "
|
|
80
|
-
readonly last_updated: "
|
|
51
|
+
readonly entity_id: "calendar.example_calendar";
|
|
52
|
+
readonly last_changed: "2024-01-01T01:01:01.000000+00:00";
|
|
53
|
+
readonly last_updated: "2024-01-01T01:01:01.000000+00:00";
|
|
81
54
|
readonly state: "off";
|
|
82
55
|
};
|
|
83
56
|
};
|
|
84
57
|
readonly light: {
|
|
85
|
-
readonly
|
|
58
|
+
readonly example_light: {
|
|
86
59
|
readonly attributes: {
|
|
87
60
|
readonly brightness: 255;
|
|
88
61
|
readonly color_mode: "color_temp";
|
|
89
62
|
readonly color_temp: 253;
|
|
90
63
|
readonly color_temp_kelvin: 3952;
|
|
91
64
|
readonly dynamics: "none";
|
|
92
|
-
readonly friendly_name: "
|
|
65
|
+
readonly friendly_name: "Example light";
|
|
93
66
|
readonly hs_color: readonly [26.835, 35.746];
|
|
94
67
|
readonly max_color_temp_kelvin: 6535;
|
|
95
68
|
readonly max_mireds: 500;
|
|
@@ -102,1038 +75,152 @@ export declare const ENTITY_SETUP: {
|
|
|
102
75
|
readonly xy_color: readonly [0.424, 0.366];
|
|
103
76
|
};
|
|
104
77
|
readonly context: {
|
|
105
|
-
readonly id: "
|
|
78
|
+
readonly id: "abc123";
|
|
106
79
|
readonly parent_id: any;
|
|
107
|
-
readonly user_id:
|
|
80
|
+
readonly user_id: any;
|
|
108
81
|
};
|
|
109
|
-
readonly entity_id: "light.
|
|
110
|
-
readonly last_changed: "
|
|
111
|
-
readonly last_updated: "
|
|
82
|
+
readonly entity_id: "light.example_light";
|
|
83
|
+
readonly last_changed: "2024-01-01T01:01:01.000000+00:00";
|
|
84
|
+
readonly last_updated: "2024-01-01T01:01:01.000000+00:00";
|
|
112
85
|
readonly state: "on";
|
|
113
86
|
};
|
|
114
87
|
};
|
|
115
88
|
readonly scene: {
|
|
116
|
-
readonly
|
|
89
|
+
readonly example_scene: {
|
|
117
90
|
readonly attributes: {
|
|
118
|
-
readonly friendly_name: "
|
|
91
|
+
readonly friendly_name: "Example scene";
|
|
119
92
|
};
|
|
120
93
|
readonly context: {
|
|
121
|
-
readonly id: "
|
|
94
|
+
readonly id: "abc123";
|
|
122
95
|
readonly parent_id: any;
|
|
123
|
-
readonly user_id:
|
|
96
|
+
readonly user_id: any;
|
|
124
97
|
};
|
|
125
|
-
readonly entity_id: "scene.
|
|
126
|
-
readonly last_changed: "
|
|
127
|
-
readonly last_updated: "
|
|
128
|
-
readonly state: "
|
|
98
|
+
readonly entity_id: "scene.example_scene";
|
|
99
|
+
readonly last_changed: "2024-01-01T01:01:01.000000+00:00";
|
|
100
|
+
readonly last_updated: "2024-01-01T01:01:01.000000+00:00";
|
|
101
|
+
readonly state: "2024-01-01T01:01:01.000000+00:00";
|
|
129
102
|
};
|
|
130
103
|
};
|
|
131
104
|
readonly sensor: {
|
|
132
|
-
readonly
|
|
105
|
+
readonly example_sensor: {
|
|
133
106
|
readonly attributes: {
|
|
134
|
-
readonly friendly_name: "
|
|
135
|
-
readonly managed_by: "home-automation";
|
|
136
|
-
readonly scene: "high";
|
|
107
|
+
readonly friendly_name: "Example sensor";
|
|
137
108
|
};
|
|
138
109
|
readonly context: {
|
|
139
|
-
readonly id: "
|
|
110
|
+
readonly id: "abc123";
|
|
140
111
|
readonly parent_id: any;
|
|
141
112
|
readonly user_id: any;
|
|
142
113
|
};
|
|
143
|
-
readonly entity_id: "sensor.
|
|
144
|
-
readonly last_changed: "2024-
|
|
145
|
-
readonly last_updated: "2024-
|
|
114
|
+
readonly entity_id: "sensor.example_sensor";
|
|
115
|
+
readonly last_changed: "2024-01-01T01:01:01.000000+00:00";
|
|
116
|
+
readonly last_updated: "2024-01-01T01:01:01.000000+00:00";
|
|
146
117
|
readonly state: "High";
|
|
147
118
|
};
|
|
148
119
|
};
|
|
149
120
|
readonly switch: {
|
|
150
|
-
readonly
|
|
121
|
+
readonly example_switch: {
|
|
151
122
|
readonly attributes: {
|
|
152
|
-
readonly friendly_name: "
|
|
123
|
+
readonly friendly_name: "Example switch";
|
|
153
124
|
};
|
|
154
125
|
readonly context: {
|
|
155
|
-
readonly id: "
|
|
126
|
+
readonly id: "abc123";
|
|
156
127
|
readonly parent_id: any;
|
|
157
|
-
readonly user_id:
|
|
128
|
+
readonly user_id: any;
|
|
158
129
|
};
|
|
159
|
-
readonly entity_id: "switch.
|
|
160
|
-
readonly last_changed: "2024-01-01T01:
|
|
161
|
-
readonly last_updated: "2024-01-01T01:
|
|
130
|
+
readonly entity_id: "switch.example_switch";
|
|
131
|
+
readonly last_changed: "2024-01-01T01:01:01.000000+00:00";
|
|
132
|
+
readonly last_updated: "2024-01-01T01:01:01.000000+00:00";
|
|
162
133
|
readonly state: "off";
|
|
163
134
|
};
|
|
164
135
|
};
|
|
165
136
|
};
|
|
137
|
+
export type TRawDomains = "binary_sensor" | "button" | "calendar" | "light" | "scene" | "sensor" | "switch";
|
|
138
|
+
export type TRawEntityIds = "binary_sensor.example_binary_sensor" | "button.example_button" | "calendar.example_calendar" | "light.example_light" | "scene.example_scene" | "sensor.example_sensor" | "switch.example_switch";
|
|
139
|
+
export type REGISTRY_SETUP = {
|
|
140
|
+
area: {
|
|
141
|
+
_example_area: "sensor.example_sensor";
|
|
142
|
+
_empty_area: never;
|
|
143
|
+
};
|
|
144
|
+
label: {
|
|
145
|
+
_example_label_2: "switch.example_switch";
|
|
146
|
+
_example_label: "switch.example_switch";
|
|
147
|
+
};
|
|
148
|
+
floor: {
|
|
149
|
+
_example_floor_2: "button.example_button" | "button.example_button";
|
|
150
|
+
_example_floor: "button.example_button" | "button.example_button";
|
|
151
|
+
};
|
|
152
|
+
device: {
|
|
153
|
+
_example_device_2: "button.example_button" | "button.example_button";
|
|
154
|
+
_example_device: "button.example_button" | "button.example_button";
|
|
155
|
+
};
|
|
156
|
+
};
|
|
166
157
|
export type iCallService = {
|
|
167
158
|
switch: {
|
|
168
|
-
/**
|
|
169
|
-
* ## Turn off
|
|
170
|
-
*
|
|
171
|
-
* Turns a switch off.*/
|
|
172
159
|
turn_off(service_data: {
|
|
173
160
|
entity_id: string | string[];
|
|
174
161
|
}): Promise<void>;
|
|
175
|
-
/**
|
|
176
|
-
* ## Turn on
|
|
177
|
-
*
|
|
178
|
-
* Turns a switch on.*/
|
|
179
162
|
turn_on(service_data: {
|
|
180
163
|
entity_id: string | string[];
|
|
181
164
|
}): Promise<void>;
|
|
182
|
-
/**
|
|
183
|
-
* ## Toggle
|
|
184
|
-
*
|
|
185
|
-
* Toggles a switch on/off.*/
|
|
186
165
|
toggle(service_data: {
|
|
187
166
|
entity_id: string | string[];
|
|
188
167
|
}): Promise<void>;
|
|
189
168
|
};
|
|
190
169
|
light: {
|
|
191
|
-
/**
|
|
192
|
-
* ## Turn on
|
|
193
|
-
*
|
|
194
|
-
* Turn on one or more lights and adjust properties of the light, even when they are turned on already.*/
|
|
195
170
|
turn_on(service_data: {
|
|
196
|
-
/**
|
|
197
|
-
* ## Transition
|
|
198
|
-
*
|
|
199
|
-
* Duration it takes to get to next state.
|
|
200
|
-
*
|
|
201
|
-
* @example undefined
|
|
202
|
-
*
|
|
203
|
-
* ## Selector
|
|
204
|
-
*
|
|
205
|
-
* ```yaml
|
|
206
|
-
* number:
|
|
207
|
-
min: 0
|
|
208
|
-
max: 300
|
|
209
|
-
unit_of_measurement: seconds
|
|
210
|
-
|
|
211
|
-
* ```*/
|
|
212
171
|
transition?: number;
|
|
213
|
-
/**
|
|
214
|
-
* ## Color
|
|
215
|
-
*
|
|
216
|
-
* The color in RGB format. A list of three integers between 0 and 255 representing the values of red, green, and blue.
|
|
217
|
-
*
|
|
218
|
-
* @example undefined
|
|
219
|
-
*
|
|
220
|
-
* ## Selector
|
|
221
|
-
*
|
|
222
|
-
* ```yaml
|
|
223
|
-
* color_rgb: null
|
|
224
|
-
|
|
225
|
-
* ```*/
|
|
226
172
|
rgb_color?: unknown;
|
|
227
|
-
/**
|
|
228
|
-
* ## RGBW-color
|
|
229
|
-
*
|
|
230
|
-
* The color in RGBW format. A list of four integers between 0 and 255 representing the values of red, green, blue, and white.
|
|
231
|
-
*
|
|
232
|
-
* @example [255, 100, 100, 50]
|
|
233
|
-
*
|
|
234
|
-
* ## Selector
|
|
235
|
-
*
|
|
236
|
-
* ```yaml
|
|
237
|
-
* object: null
|
|
238
|
-
|
|
239
|
-
* ```*/
|
|
240
173
|
rgbw_color?: Record<string, unknown> | unknown[];
|
|
241
|
-
/**
|
|
242
|
-
* ## RGBWW-color
|
|
243
|
-
*
|
|
244
|
-
* The color in RGBWW format. A list of five integers between 0 and 255 representing the values of red, green, blue, cold white, and warm white.
|
|
245
|
-
*
|
|
246
|
-
* @example [255, 100, 100, 50, 70]
|
|
247
|
-
*
|
|
248
|
-
* ## Selector
|
|
249
|
-
*
|
|
250
|
-
* ```yaml
|
|
251
|
-
* object: null
|
|
252
|
-
|
|
253
|
-
* ```*/
|
|
254
174
|
rgbww_color?: Record<string, unknown> | unknown[];
|
|
255
|
-
|
|
256
|
-
* ## Color name
|
|
257
|
-
*
|
|
258
|
-
* A human-readable color name.
|
|
259
|
-
*
|
|
260
|
-
* @example undefined
|
|
261
|
-
*
|
|
262
|
-
* ## Selector
|
|
263
|
-
*
|
|
264
|
-
* ```yaml
|
|
265
|
-
* select:
|
|
266
|
-
translation_key: color_name
|
|
267
|
-
options:
|
|
268
|
-
- homeassistant
|
|
269
|
-
- aliceblue
|
|
270
|
-
- antiquewhite
|
|
271
|
-
- aqua
|
|
272
|
-
- aquamarine
|
|
273
|
-
- azure
|
|
274
|
-
- beige
|
|
275
|
-
- bisque
|
|
276
|
-
- blanchedalmond
|
|
277
|
-
- blue
|
|
278
|
-
- blueviolet
|
|
279
|
-
- brown
|
|
280
|
-
- burlywood
|
|
281
|
-
- cadetblue
|
|
282
|
-
- chartreuse
|
|
283
|
-
- chocolate
|
|
284
|
-
- coral
|
|
285
|
-
- cornflowerblue
|
|
286
|
-
- cornsilk
|
|
287
|
-
- crimson
|
|
288
|
-
- cyan
|
|
289
|
-
- darkblue
|
|
290
|
-
- darkcyan
|
|
291
|
-
- darkgoldenrod
|
|
292
|
-
- darkgray
|
|
293
|
-
- darkgreen
|
|
294
|
-
- darkgrey
|
|
295
|
-
- darkkhaki
|
|
296
|
-
- darkmagenta
|
|
297
|
-
- darkolivegreen
|
|
298
|
-
- darkorange
|
|
299
|
-
- darkorchid
|
|
300
|
-
- darkred
|
|
301
|
-
- darksalmon
|
|
302
|
-
- darkseagreen
|
|
303
|
-
- darkslateblue
|
|
304
|
-
- darkslategray
|
|
305
|
-
- darkslategrey
|
|
306
|
-
- darkturquoise
|
|
307
|
-
- darkviolet
|
|
308
|
-
- deeppink
|
|
309
|
-
- deepskyblue
|
|
310
|
-
- dimgray
|
|
311
|
-
- dimgrey
|
|
312
|
-
- dodgerblue
|
|
313
|
-
- firebrick
|
|
314
|
-
- floralwhite
|
|
315
|
-
- forestgreen
|
|
316
|
-
- fuchsia
|
|
317
|
-
- gainsboro
|
|
318
|
-
- ghostwhite
|
|
319
|
-
- gold
|
|
320
|
-
- goldenrod
|
|
321
|
-
- gray
|
|
322
|
-
- green
|
|
323
|
-
- greenyellow
|
|
324
|
-
- grey
|
|
325
|
-
- honeydew
|
|
326
|
-
- hotpink
|
|
327
|
-
- indianred
|
|
328
|
-
- indigo
|
|
329
|
-
- ivory
|
|
330
|
-
- khaki
|
|
331
|
-
- lavender
|
|
332
|
-
- lavenderblush
|
|
333
|
-
- lawngreen
|
|
334
|
-
- lemonchiffon
|
|
335
|
-
- lightblue
|
|
336
|
-
- lightcoral
|
|
337
|
-
- lightcyan
|
|
338
|
-
- lightgoldenrodyellow
|
|
339
|
-
- lightgray
|
|
340
|
-
- lightgreen
|
|
341
|
-
- lightgrey
|
|
342
|
-
- lightpink
|
|
343
|
-
- lightsalmon
|
|
344
|
-
- lightseagreen
|
|
345
|
-
- lightskyblue
|
|
346
|
-
- lightslategray
|
|
347
|
-
- lightslategrey
|
|
348
|
-
- lightsteelblue
|
|
349
|
-
- lightyellow
|
|
350
|
-
- lime
|
|
351
|
-
- limegreen
|
|
352
|
-
- linen
|
|
353
|
-
- magenta
|
|
354
|
-
- maroon
|
|
355
|
-
- mediumaquamarine
|
|
356
|
-
- mediumblue
|
|
357
|
-
- mediumorchid
|
|
358
|
-
- mediumpurple
|
|
359
|
-
- mediumseagreen
|
|
360
|
-
- mediumslateblue
|
|
361
|
-
- mediumspringgreen
|
|
362
|
-
- mediumturquoise
|
|
363
|
-
- mediumvioletred
|
|
364
|
-
- midnightblue
|
|
365
|
-
- mintcream
|
|
366
|
-
- mistyrose
|
|
367
|
-
- moccasin
|
|
368
|
-
- navajowhite
|
|
369
|
-
- navy
|
|
370
|
-
- navyblue
|
|
371
|
-
- oldlace
|
|
372
|
-
- olive
|
|
373
|
-
- olivedrab
|
|
374
|
-
- orange
|
|
375
|
-
- orangered
|
|
376
|
-
- orchid
|
|
377
|
-
- palegoldenrod
|
|
378
|
-
- palegreen
|
|
379
|
-
- paleturquoise
|
|
380
|
-
- palevioletred
|
|
381
|
-
- papayawhip
|
|
382
|
-
- peachpuff
|
|
383
|
-
- peru
|
|
384
|
-
- pink
|
|
385
|
-
- plum
|
|
386
|
-
- powderblue
|
|
387
|
-
- purple
|
|
388
|
-
- red
|
|
389
|
-
- rosybrown
|
|
390
|
-
- royalblue
|
|
391
|
-
- saddlebrown
|
|
392
|
-
- salmon
|
|
393
|
-
- sandybrown
|
|
394
|
-
- seagreen
|
|
395
|
-
- seashell
|
|
396
|
-
- sienna
|
|
397
|
-
- silver
|
|
398
|
-
- skyblue
|
|
399
|
-
- slateblue
|
|
400
|
-
- slategray
|
|
401
|
-
- slategrey
|
|
402
|
-
- snow
|
|
403
|
-
- springgreen
|
|
404
|
-
- steelblue
|
|
405
|
-
- tan
|
|
406
|
-
- teal
|
|
407
|
-
- thistle
|
|
408
|
-
- tomato
|
|
409
|
-
- turquoise
|
|
410
|
-
- violet
|
|
411
|
-
- wheat
|
|
412
|
-
- white
|
|
413
|
-
- whitesmoke
|
|
414
|
-
- yellow
|
|
415
|
-
- yellowgreen
|
|
416
|
-
|
|
417
|
-
* ```*/
|
|
418
|
-
color_name?: "homeassistant" | "aliceblue" | "antiquewhite" | "aqua" | "aquamarine" | "azure" | "beige" | "bisque" | "blanchedalmond" | "blue" | "blueviolet" | "brown" | "burlywood" | "cadetblue" | "chartreuse" | "chocolate" | "coral" | "cornflowerblue" | "cornsilk" | "crimson" | "cyan" | "darkblue" | "darkcyan" | "darkgoldenrod" | "darkgray" | "darkgreen" | "darkgrey" | "darkkhaki" | "darkmagenta" | "darkolivegreen" | "darkorange" | "darkorchid" | "darkred" | "darksalmon" | "darkseagreen" | "darkslateblue" | "darkslategray" | "darkslategrey" | "darkturquoise" | "darkviolet" | "deeppink" | "deepskyblue" | "dimgray" | "dimgrey" | "dodgerblue" | "firebrick" | "floralwhite" | "forestgreen" | "fuchsia" | "gainsboro" | "ghostwhite" | "gold" | "goldenrod" | "gray" | "green" | "greenyellow" | "grey" | "honeydew" | "hotpink" | "indianred" | "indigo" | "ivory" | "khaki" | "lavender" | "lavenderblush" | "lawngreen" | "lemonchiffon" | "lightblue" | "lightcoral" | "lightcyan" | "lightgoldenrodyellow" | "lightgray" | "lightgreen" | "lightgrey" | "lightpink" | "lightsalmon" | "lightseagreen" | "lightskyblue" | "lightslategray" | "lightslategrey" | "lightsteelblue" | "lightyellow" | "lime" | "limegreen" | "linen" | "magenta" | "maroon" | "mediumaquamarine" | "mediumblue" | "mediumorchid" | "mediumpurple" | "mediumseagreen" | "mediumslateblue" | "mediumspringgreen" | "mediumturquoise" | "mediumvioletred" | "midnightblue" | "mintcream" | "mistyrose" | "moccasin" | "navajowhite" | "navy" | "navyblue" | "oldlace" | "olive" | "olivedrab" | "orange" | "orangered" | "orchid" | "palegoldenrod" | "palegreen" | "paleturquoise" | "palevioletred" | "papayawhip" | "peachpuff" | "peru" | "pink" | "plum" | "powderblue" | "purple" | "red" | "rosybrown" | "royalblue" | "saddlebrown" | "salmon" | "sandybrown" | "seagreen" | "seashell" | "sienna" | "silver" | "skyblue" | "slateblue" | "slategray" | "slategrey" | "snow" | "springgreen" | "steelblue" | "tan" | "teal" | "thistle" | "tomato" | "turquoise" | "violet" | "wheat" | "white" | "whitesmoke" | "yellow" | "yellowgreen";
|
|
419
|
-
/**
|
|
420
|
-
* ## Hue/Sat color
|
|
421
|
-
*
|
|
422
|
-
* Color in hue/sat format. A list of two integers. Hue is 0-360 and Sat is 0-100.
|
|
423
|
-
*
|
|
424
|
-
* @example [300, 70]
|
|
425
|
-
*
|
|
426
|
-
* ## Selector
|
|
427
|
-
*
|
|
428
|
-
* ```yaml
|
|
429
|
-
* object: null
|
|
430
|
-
|
|
431
|
-
* ```*/
|
|
175
|
+
color_name?: "homeassistant" | "yellowgreen";
|
|
432
176
|
hs_color?: Record<string, unknown> | unknown[];
|
|
433
|
-
/**
|
|
434
|
-
* ## XY-color
|
|
435
|
-
*
|
|
436
|
-
* Color in XY-format. A list of two decimal numbers between 0 and 1.
|
|
437
|
-
*
|
|
438
|
-
* @example [0.52, 0.43]
|
|
439
|
-
*
|
|
440
|
-
* ## Selector
|
|
441
|
-
*
|
|
442
|
-
* ```yaml
|
|
443
|
-
* object: null
|
|
444
|
-
|
|
445
|
-
* ```*/
|
|
446
177
|
xy_color?: Record<string, unknown> | unknown[];
|
|
447
|
-
/**
|
|
448
|
-
* ## Color temperature
|
|
449
|
-
*
|
|
450
|
-
* Color temperature in mireds.
|
|
451
|
-
*
|
|
452
|
-
* @example undefined
|
|
453
|
-
*
|
|
454
|
-
* ## Selector
|
|
455
|
-
*
|
|
456
|
-
* ```yaml
|
|
457
|
-
* color_temp:
|
|
458
|
-
min_mireds: 153
|
|
459
|
-
max_mireds: 500
|
|
460
|
-
|
|
461
|
-
* ```*/
|
|
462
178
|
color_temp?: unknown;
|
|
463
|
-
/**
|
|
464
|
-
* ## Color temperature
|
|
465
|
-
*
|
|
466
|
-
* Color temperature in Kelvin.
|
|
467
|
-
*
|
|
468
|
-
* @example undefined
|
|
469
|
-
*
|
|
470
|
-
* ## Selector
|
|
471
|
-
*
|
|
472
|
-
* ```yaml
|
|
473
|
-
* number:
|
|
474
|
-
min: 2000
|
|
475
|
-
max: 6500
|
|
476
|
-
step: 100
|
|
477
|
-
unit_of_measurement: K
|
|
478
|
-
|
|
479
|
-
* ```*/
|
|
480
179
|
kelvin?: number;
|
|
481
|
-
/**
|
|
482
|
-
* ## Brightness value
|
|
483
|
-
*
|
|
484
|
-
* Number indicating brightness, where 0 turns the light off, 1 is the minimum brightness, and 255 is the maximum brightness.
|
|
485
|
-
*
|
|
486
|
-
* @example undefined
|
|
487
|
-
*
|
|
488
|
-
* ## Selector
|
|
489
|
-
*
|
|
490
|
-
* ```yaml
|
|
491
|
-
* number:
|
|
492
|
-
min: 0
|
|
493
|
-
max: 255
|
|
494
|
-
|
|
495
|
-
* ```*/
|
|
496
180
|
brightness?: number;
|
|
497
|
-
/**
|
|
498
|
-
* ## Brightness
|
|
499
|
-
*
|
|
500
|
-
* Number indicating the percentage of full brightness, where 0 turns the light off, 1 is the minimum brightness, and 100 is the maximum brightness.
|
|
501
|
-
*
|
|
502
|
-
* @example undefined
|
|
503
|
-
*
|
|
504
|
-
* ## Selector
|
|
505
|
-
*
|
|
506
|
-
* ```yaml
|
|
507
|
-
* number:
|
|
508
|
-
min: 0
|
|
509
|
-
max: 100
|
|
510
|
-
unit_of_measurement: '%'
|
|
511
|
-
|
|
512
|
-
* ```*/
|
|
513
181
|
brightness_pct?: number;
|
|
514
|
-
/**
|
|
515
|
-
* ## Brightness step value
|
|
516
|
-
*
|
|
517
|
-
* Change brightness by an amount.
|
|
518
|
-
*
|
|
519
|
-
* @example undefined
|
|
520
|
-
*
|
|
521
|
-
* ## Selector
|
|
522
|
-
*
|
|
523
|
-
* ```yaml
|
|
524
|
-
* number:
|
|
525
|
-
min: -225
|
|
526
|
-
max: 255
|
|
527
|
-
|
|
528
|
-
* ```*/
|
|
529
182
|
brightness_step?: number;
|
|
530
|
-
/**
|
|
531
|
-
* ## Brightness step
|
|
532
|
-
*
|
|
533
|
-
* Change brightness by a percentage.
|
|
534
|
-
*
|
|
535
|
-
* @example undefined
|
|
536
|
-
*
|
|
537
|
-
* ## Selector
|
|
538
|
-
*
|
|
539
|
-
* ```yaml
|
|
540
|
-
* number:
|
|
541
|
-
min: -100
|
|
542
|
-
max: 100
|
|
543
|
-
unit_of_measurement: '%'
|
|
544
|
-
|
|
545
|
-
* ```*/
|
|
546
183
|
brightness_step_pct?: number;
|
|
547
|
-
/**
|
|
548
|
-
* ## White
|
|
549
|
-
*
|
|
550
|
-
* Set the light to white mode.
|
|
551
|
-
*
|
|
552
|
-
* @example undefined
|
|
553
|
-
*
|
|
554
|
-
* ## Selector
|
|
555
|
-
*
|
|
556
|
-
* ```yaml
|
|
557
|
-
* constant:
|
|
558
|
-
value: true
|
|
559
|
-
label: Enabled
|
|
560
|
-
|
|
561
|
-
* ```*/
|
|
562
184
|
white?: unknown;
|
|
563
|
-
/**
|
|
564
|
-
* ## Profile
|
|
565
|
-
*
|
|
566
|
-
* Name of a light profile to use.
|
|
567
|
-
*
|
|
568
|
-
* @example relax
|
|
569
|
-
*
|
|
570
|
-
* ## Selector
|
|
571
|
-
*
|
|
572
|
-
* ```yaml
|
|
573
|
-
* text: null
|
|
574
|
-
|
|
575
|
-
* ```*/
|
|
576
185
|
profile?: string;
|
|
577
|
-
/**
|
|
578
|
-
* ## Flash
|
|
579
|
-
*
|
|
580
|
-
* Tell light to flash, can be either value short or long.
|
|
581
|
-
*
|
|
582
|
-
* @example undefined
|
|
583
|
-
*
|
|
584
|
-
* ## Selector
|
|
585
|
-
*
|
|
586
|
-
* ```yaml
|
|
587
|
-
* select:
|
|
588
|
-
options:
|
|
589
|
-
- label: Long
|
|
590
|
-
value: long
|
|
591
|
-
- label: Short
|
|
592
|
-
value: short
|
|
593
|
-
|
|
594
|
-
* ```*/
|
|
595
186
|
flash?: "long" | "short";
|
|
596
|
-
/**
|
|
597
|
-
* ## Effect
|
|
598
|
-
*
|
|
599
|
-
* Light effect.
|
|
600
|
-
*
|
|
601
|
-
* @example undefined
|
|
602
|
-
*
|
|
603
|
-
* ## Selector
|
|
604
|
-
*
|
|
605
|
-
* ```yaml
|
|
606
|
-
* text: null
|
|
607
|
-
|
|
608
|
-
* ```*/
|
|
609
187
|
effect?: string;
|
|
610
188
|
entity_id: string | string[];
|
|
611
189
|
}): Promise<void>;
|
|
612
|
-
/**
|
|
613
|
-
* ## Turn off
|
|
614
|
-
*
|
|
615
|
-
* Turn off one or more lights.*/
|
|
616
190
|
turn_off(service_data: {
|
|
617
|
-
/**
|
|
618
|
-
* ## Transition
|
|
619
|
-
*
|
|
620
|
-
* Duration it takes to get to next state.
|
|
621
|
-
*
|
|
622
|
-
* @example undefined
|
|
623
|
-
*
|
|
624
|
-
* ## Selector
|
|
625
|
-
*
|
|
626
|
-
* ```yaml
|
|
627
|
-
* number:
|
|
628
|
-
min: 0
|
|
629
|
-
max: 300
|
|
630
|
-
unit_of_measurement: seconds
|
|
631
|
-
|
|
632
|
-
* ```*/
|
|
633
191
|
transition?: number;
|
|
634
|
-
/**
|
|
635
|
-
* ## Flash
|
|
636
|
-
*
|
|
637
|
-
* Tell light to flash, can be either value short or long.
|
|
638
|
-
*
|
|
639
|
-
* @example undefined
|
|
640
|
-
*
|
|
641
|
-
* ## Selector
|
|
642
|
-
*
|
|
643
|
-
* ```yaml
|
|
644
|
-
* select:
|
|
645
|
-
options:
|
|
646
|
-
- label: Long
|
|
647
|
-
value: long
|
|
648
|
-
- label: Short
|
|
649
|
-
value: short
|
|
650
|
-
|
|
651
|
-
* ```*/
|
|
652
192
|
flash?: "long" | "short";
|
|
653
193
|
entity_id: string | string[];
|
|
654
194
|
}): Promise<void>;
|
|
655
|
-
/**
|
|
656
|
-
* ## Toggle
|
|
657
|
-
*
|
|
658
|
-
* Toggles one or more lights, from on to off, or, off to on, based on their current state.*/
|
|
659
195
|
toggle(service_data: {
|
|
660
|
-
/**
|
|
661
|
-
* ## Transition
|
|
662
|
-
*
|
|
663
|
-
* Duration it takes to get to next state.
|
|
664
|
-
*
|
|
665
|
-
* @example undefined
|
|
666
|
-
*
|
|
667
|
-
* ## Selector
|
|
668
|
-
*
|
|
669
|
-
* ```yaml
|
|
670
|
-
* number:
|
|
671
|
-
min: 0
|
|
672
|
-
max: 300
|
|
673
|
-
unit_of_measurement: seconds
|
|
674
|
-
|
|
675
|
-
* ```*/
|
|
676
196
|
transition?: number;
|
|
677
|
-
/**
|
|
678
|
-
* ## Color
|
|
679
|
-
*
|
|
680
|
-
* The color in RGB format. A list of three integers between 0 and 255 representing the values of red, green, and blue.
|
|
681
|
-
*
|
|
682
|
-
* @example [255, 100, 100]
|
|
683
|
-
*
|
|
684
|
-
* ## Selector
|
|
685
|
-
*
|
|
686
|
-
* ```yaml
|
|
687
|
-
* color_rgb: null
|
|
688
|
-
|
|
689
|
-
* ```*/
|
|
690
197
|
rgb_color?: unknown;
|
|
691
|
-
|
|
692
|
-
* ## Color name
|
|
693
|
-
*
|
|
694
|
-
* A human-readable color name.
|
|
695
|
-
*
|
|
696
|
-
* @example undefined
|
|
697
|
-
*
|
|
698
|
-
* ## Selector
|
|
699
|
-
*
|
|
700
|
-
* ```yaml
|
|
701
|
-
* select:
|
|
702
|
-
translation_key: color_name
|
|
703
|
-
options:
|
|
704
|
-
- homeassistant
|
|
705
|
-
- aliceblue
|
|
706
|
-
- antiquewhite
|
|
707
|
-
- aqua
|
|
708
|
-
- aquamarine
|
|
709
|
-
- azure
|
|
710
|
-
- beige
|
|
711
|
-
- bisque
|
|
712
|
-
- blanchedalmond
|
|
713
|
-
- blue
|
|
714
|
-
- blueviolet
|
|
715
|
-
- brown
|
|
716
|
-
- burlywood
|
|
717
|
-
- cadetblue
|
|
718
|
-
- chartreuse
|
|
719
|
-
- chocolate
|
|
720
|
-
- coral
|
|
721
|
-
- cornflowerblue
|
|
722
|
-
- cornsilk
|
|
723
|
-
- crimson
|
|
724
|
-
- cyan
|
|
725
|
-
- darkblue
|
|
726
|
-
- darkcyan
|
|
727
|
-
- darkgoldenrod
|
|
728
|
-
- darkgray
|
|
729
|
-
- darkgreen
|
|
730
|
-
- darkgrey
|
|
731
|
-
- darkkhaki
|
|
732
|
-
- darkmagenta
|
|
733
|
-
- darkolivegreen
|
|
734
|
-
- darkorange
|
|
735
|
-
- darkorchid
|
|
736
|
-
- darkred
|
|
737
|
-
- darksalmon
|
|
738
|
-
- darkseagreen
|
|
739
|
-
- darkslateblue
|
|
740
|
-
- darkslategray
|
|
741
|
-
- darkslategrey
|
|
742
|
-
- darkturquoise
|
|
743
|
-
- darkviolet
|
|
744
|
-
- deeppink
|
|
745
|
-
- deepskyblue
|
|
746
|
-
- dimgray
|
|
747
|
-
- dimgrey
|
|
748
|
-
- dodgerblue
|
|
749
|
-
- firebrick
|
|
750
|
-
- floralwhite
|
|
751
|
-
- forestgreen
|
|
752
|
-
- fuchsia
|
|
753
|
-
- gainsboro
|
|
754
|
-
- ghostwhite
|
|
755
|
-
- gold
|
|
756
|
-
- goldenrod
|
|
757
|
-
- gray
|
|
758
|
-
- green
|
|
759
|
-
- greenyellow
|
|
760
|
-
- grey
|
|
761
|
-
- honeydew
|
|
762
|
-
- hotpink
|
|
763
|
-
- indianred
|
|
764
|
-
- indigo
|
|
765
|
-
- ivory
|
|
766
|
-
- khaki
|
|
767
|
-
- lavender
|
|
768
|
-
- lavenderblush
|
|
769
|
-
- lawngreen
|
|
770
|
-
- lemonchiffon
|
|
771
|
-
- lightblue
|
|
772
|
-
- lightcoral
|
|
773
|
-
- lightcyan
|
|
774
|
-
- lightgoldenrodyellow
|
|
775
|
-
- lightgray
|
|
776
|
-
- lightgreen
|
|
777
|
-
- lightgrey
|
|
778
|
-
- lightpink
|
|
779
|
-
- lightsalmon
|
|
780
|
-
- lightseagreen
|
|
781
|
-
- lightskyblue
|
|
782
|
-
- lightslategray
|
|
783
|
-
- lightslategrey
|
|
784
|
-
- lightsteelblue
|
|
785
|
-
- lightyellow
|
|
786
|
-
- lime
|
|
787
|
-
- limegreen
|
|
788
|
-
- linen
|
|
789
|
-
- magenta
|
|
790
|
-
- maroon
|
|
791
|
-
- mediumaquamarine
|
|
792
|
-
- mediumblue
|
|
793
|
-
- mediumorchid
|
|
794
|
-
- mediumpurple
|
|
795
|
-
- mediumseagreen
|
|
796
|
-
- mediumslateblue
|
|
797
|
-
- mediumspringgreen
|
|
798
|
-
- mediumturquoise
|
|
799
|
-
- mediumvioletred
|
|
800
|
-
- midnightblue
|
|
801
|
-
- mintcream
|
|
802
|
-
- mistyrose
|
|
803
|
-
- moccasin
|
|
804
|
-
- navajowhite
|
|
805
|
-
- navy
|
|
806
|
-
- navyblue
|
|
807
|
-
- oldlace
|
|
808
|
-
- olive
|
|
809
|
-
- olivedrab
|
|
810
|
-
- orange
|
|
811
|
-
- orangered
|
|
812
|
-
- orchid
|
|
813
|
-
- palegoldenrod
|
|
814
|
-
- palegreen
|
|
815
|
-
- paleturquoise
|
|
816
|
-
- palevioletred
|
|
817
|
-
- papayawhip
|
|
818
|
-
- peachpuff
|
|
819
|
-
- peru
|
|
820
|
-
- pink
|
|
821
|
-
- plum
|
|
822
|
-
- powderblue
|
|
823
|
-
- purple
|
|
824
|
-
- red
|
|
825
|
-
- rosybrown
|
|
826
|
-
- royalblue
|
|
827
|
-
- saddlebrown
|
|
828
|
-
- salmon
|
|
829
|
-
- sandybrown
|
|
830
|
-
- seagreen
|
|
831
|
-
- seashell
|
|
832
|
-
- sienna
|
|
833
|
-
- silver
|
|
834
|
-
- skyblue
|
|
835
|
-
- slateblue
|
|
836
|
-
- slategray
|
|
837
|
-
- slategrey
|
|
838
|
-
- snow
|
|
839
|
-
- springgreen
|
|
840
|
-
- steelblue
|
|
841
|
-
- tan
|
|
842
|
-
- teal
|
|
843
|
-
- thistle
|
|
844
|
-
- tomato
|
|
845
|
-
- turquoise
|
|
846
|
-
- violet
|
|
847
|
-
- wheat
|
|
848
|
-
- white
|
|
849
|
-
- whitesmoke
|
|
850
|
-
- yellow
|
|
851
|
-
- yellowgreen
|
|
852
|
-
|
|
853
|
-
* ```*/
|
|
854
|
-
color_name?: "homeassistant" | "aliceblue" | "antiquewhite" | "aqua" | "aquamarine" | "azure" | "beige" | "bisque" | "blanchedalmond" | "blue" | "blueviolet" | "brown" | "burlywood" | "cadetblue" | "chartreuse" | "chocolate" | "coral" | "cornflowerblue" | "cornsilk" | "crimson" | "cyan" | "darkblue" | "darkcyan" | "darkgoldenrod" | "darkgray" | "darkgreen" | "darkgrey" | "darkkhaki" | "darkmagenta" | "darkolivegreen" | "darkorange" | "darkorchid" | "darkred" | "darksalmon" | "darkseagreen" | "darkslateblue" | "darkslategray" | "darkslategrey" | "darkturquoise" | "darkviolet" | "deeppink" | "deepskyblue" | "dimgray" | "dimgrey" | "dodgerblue" | "firebrick" | "floralwhite" | "forestgreen" | "fuchsia" | "gainsboro" | "ghostwhite" | "gold" | "goldenrod" | "gray" | "green" | "greenyellow" | "grey" | "honeydew" | "hotpink" | "indianred" | "indigo" | "ivory" | "khaki" | "lavender" | "lavenderblush" | "lawngreen" | "lemonchiffon" | "lightblue" | "lightcoral" | "lightcyan" | "lightgoldenrodyellow" | "lightgray" | "lightgreen" | "lightgrey" | "lightpink" | "lightsalmon" | "lightseagreen" | "lightskyblue" | "lightslategray" | "lightslategrey" | "lightsteelblue" | "lightyellow" | "lime" | "limegreen" | "linen" | "magenta" | "maroon" | "mediumaquamarine" | "mediumblue" | "mediumorchid" | "mediumpurple" | "mediumseagreen" | "mediumslateblue" | "mediumspringgreen" | "mediumturquoise" | "mediumvioletred" | "midnightblue" | "mintcream" | "mistyrose" | "moccasin" | "navajowhite" | "navy" | "navyblue" | "oldlace" | "olive" | "olivedrab" | "orange" | "orangered" | "orchid" | "palegoldenrod" | "palegreen" | "paleturquoise" | "palevioletred" | "papayawhip" | "peachpuff" | "peru" | "pink" | "plum" | "powderblue" | "purple" | "red" | "rosybrown" | "royalblue" | "saddlebrown" | "salmon" | "sandybrown" | "seagreen" | "seashell" | "sienna" | "silver" | "skyblue" | "slateblue" | "slategray" | "slategrey" | "snow" | "springgreen" | "steelblue" | "tan" | "teal" | "thistle" | "tomato" | "turquoise" | "violet" | "wheat" | "white" | "whitesmoke" | "yellow" | "yellowgreen";
|
|
855
|
-
/**
|
|
856
|
-
* ## Hue/Sat color
|
|
857
|
-
*
|
|
858
|
-
* Color in hue/sat format. A list of two integers. Hue is 0-360 and Sat is 0-100.
|
|
859
|
-
*
|
|
860
|
-
* @example [300, 70]
|
|
861
|
-
*
|
|
862
|
-
* ## Selector
|
|
863
|
-
*
|
|
864
|
-
* ```yaml
|
|
865
|
-
* object: null
|
|
866
|
-
|
|
867
|
-
* ```*/
|
|
198
|
+
color_name?: "homeassistant" | "yellowgreen";
|
|
868
199
|
hs_color?: Record<string, unknown> | unknown[];
|
|
869
|
-
/**
|
|
870
|
-
* ## XY-color
|
|
871
|
-
*
|
|
872
|
-
* Color in XY-format. A list of two decimal numbers between 0 and 1.
|
|
873
|
-
*
|
|
874
|
-
* @example [0.52, 0.43]
|
|
875
|
-
*
|
|
876
|
-
* ## Selector
|
|
877
|
-
*
|
|
878
|
-
* ```yaml
|
|
879
|
-
* object: null
|
|
880
|
-
|
|
881
|
-
* ```*/
|
|
882
200
|
xy_color?: Record<string, unknown> | unknown[];
|
|
883
|
-
/**
|
|
884
|
-
* ## Color temperature
|
|
885
|
-
*
|
|
886
|
-
* Color temperature in mireds.
|
|
887
|
-
*
|
|
888
|
-
* @example undefined
|
|
889
|
-
*
|
|
890
|
-
* ## Selector
|
|
891
|
-
*
|
|
892
|
-
* ```yaml
|
|
893
|
-
* color_temp: null
|
|
894
|
-
|
|
895
|
-
* ```*/
|
|
896
201
|
color_temp?: unknown;
|
|
897
|
-
/**
|
|
898
|
-
* ## Color temperature
|
|
899
|
-
*
|
|
900
|
-
* Color temperature in Kelvin.
|
|
901
|
-
*
|
|
902
|
-
* @example undefined
|
|
903
|
-
*
|
|
904
|
-
* ## Selector
|
|
905
|
-
*
|
|
906
|
-
* ```yaml
|
|
907
|
-
* number:
|
|
908
|
-
min: 2000
|
|
909
|
-
max: 6500
|
|
910
|
-
step: 100
|
|
911
|
-
unit_of_measurement: K
|
|
912
|
-
|
|
913
|
-
* ```*/
|
|
914
202
|
kelvin?: number;
|
|
915
|
-
/**
|
|
916
|
-
* ## Brightness value
|
|
917
|
-
*
|
|
918
|
-
* Number indicating brightness, where 0 turns the light off, 1 is the minimum brightness, and 255 is the maximum brightness.
|
|
919
|
-
*
|
|
920
|
-
* @example undefined
|
|
921
|
-
*
|
|
922
|
-
* ## Selector
|
|
923
|
-
*
|
|
924
|
-
* ```yaml
|
|
925
|
-
* number:
|
|
926
|
-
min: 0
|
|
927
|
-
max: 255
|
|
928
|
-
|
|
929
|
-
* ```*/
|
|
930
203
|
brightness?: number;
|
|
931
|
-
/**
|
|
932
|
-
* ## Brightness
|
|
933
|
-
*
|
|
934
|
-
* Number indicating the percentage of full brightness, where 0 turns the light off, 1 is the minimum brightness, and 100 is the maximum brightness.
|
|
935
|
-
*
|
|
936
|
-
* @example undefined
|
|
937
|
-
*
|
|
938
|
-
* ## Selector
|
|
939
|
-
*
|
|
940
|
-
* ```yaml
|
|
941
|
-
* number:
|
|
942
|
-
min: 0
|
|
943
|
-
max: 100
|
|
944
|
-
unit_of_measurement: '%'
|
|
945
|
-
|
|
946
|
-
* ```*/
|
|
947
204
|
brightness_pct?: number;
|
|
948
|
-
/**
|
|
949
|
-
* ## White
|
|
950
|
-
*
|
|
951
|
-
* Set the light to white mode.
|
|
952
|
-
*
|
|
953
|
-
* @example undefined
|
|
954
|
-
*
|
|
955
|
-
* ## Selector
|
|
956
|
-
*
|
|
957
|
-
* ```yaml
|
|
958
|
-
* constant:
|
|
959
|
-
value: true
|
|
960
|
-
label: Enabled
|
|
961
|
-
|
|
962
|
-
* ```*/
|
|
963
205
|
white?: unknown;
|
|
964
|
-
/**
|
|
965
|
-
* ## Profile
|
|
966
|
-
*
|
|
967
|
-
* Name of a light profile to use.
|
|
968
|
-
*
|
|
969
|
-
* @example relax
|
|
970
|
-
*
|
|
971
|
-
* ## Selector
|
|
972
|
-
*
|
|
973
|
-
* ```yaml
|
|
974
|
-
* text: null
|
|
975
|
-
|
|
976
|
-
* ```*/
|
|
977
206
|
profile?: string;
|
|
978
|
-
/**
|
|
979
|
-
* ## Flash
|
|
980
|
-
*
|
|
981
|
-
* Tell light to flash, can be either value short or long.
|
|
982
|
-
*
|
|
983
|
-
* @example undefined
|
|
984
|
-
*
|
|
985
|
-
* ## Selector
|
|
986
|
-
*
|
|
987
|
-
* ```yaml
|
|
988
|
-
* select:
|
|
989
|
-
options:
|
|
990
|
-
- label: Long
|
|
991
|
-
value: long
|
|
992
|
-
- label: Short
|
|
993
|
-
value: short
|
|
994
|
-
|
|
995
|
-
* ```*/
|
|
996
207
|
flash?: "long" | "short";
|
|
997
|
-
/**
|
|
998
|
-
* ## Effect
|
|
999
|
-
*
|
|
1000
|
-
* Light effect.
|
|
1001
|
-
*
|
|
1002
|
-
* @example undefined
|
|
1003
|
-
*
|
|
1004
|
-
* ## Selector
|
|
1005
|
-
*
|
|
1006
|
-
* ```yaml
|
|
1007
|
-
* text: null
|
|
1008
|
-
|
|
1009
|
-
* ```*/
|
|
1010
208
|
effect?: string;
|
|
1011
209
|
entity_id: string | string[];
|
|
1012
210
|
}): Promise<void>;
|
|
1013
211
|
};
|
|
1014
212
|
scene: {
|
|
1015
|
-
/**
|
|
1016
|
-
* ## Reload
|
|
1017
|
-
*
|
|
1018
|
-
* Reloads the scenes from the YAML-configuration.*/
|
|
1019
213
|
reload(service_data: {}): Promise<void>;
|
|
1020
|
-
/**
|
|
1021
|
-
* ## Apply
|
|
1022
|
-
*
|
|
1023
|
-
* Activates a scene with configuration.*/
|
|
1024
214
|
apply(service_data: {
|
|
1025
|
-
/**
|
|
1026
|
-
* ## Entities state
|
|
1027
|
-
*
|
|
1028
|
-
* List of entities and their target state.
|
|
1029
|
-
*
|
|
1030
|
-
* @example light.kitchen: "on"
|
|
1031
|
-
light.ceiling:
|
|
1032
|
-
state: "on"
|
|
1033
|
-
brightness: 80
|
|
1034
|
-
|
|
1035
|
-
*
|
|
1036
|
-
* ## Selector
|
|
1037
|
-
*
|
|
1038
|
-
* ```yaml
|
|
1039
|
-
* object: null
|
|
1040
|
-
|
|
1041
|
-
* ```*/
|
|
1042
215
|
entities: Partial<Record<PICK_ENTITY, unknown>> | unknown[];
|
|
1043
|
-
/**
|
|
1044
|
-
* ## Transition
|
|
1045
|
-
*
|
|
1046
|
-
* Time it takes the devices to transition into the states defined in the scene.
|
|
1047
|
-
*
|
|
1048
|
-
* @example undefined
|
|
1049
|
-
*
|
|
1050
|
-
* ## Selector
|
|
1051
|
-
*
|
|
1052
|
-
* ```yaml
|
|
1053
|
-
* number:
|
|
1054
|
-
min: 0
|
|
1055
|
-
max: 300
|
|
1056
|
-
unit_of_measurement: seconds
|
|
1057
|
-
|
|
1058
|
-
* ```*/
|
|
1059
216
|
transition?: number;
|
|
1060
217
|
}): Promise<void>;
|
|
1061
|
-
/**
|
|
1062
|
-
* ## Create
|
|
1063
|
-
*
|
|
1064
|
-
* Creates a new scene.*/
|
|
1065
218
|
create(service_data: {
|
|
1066
|
-
/**
|
|
1067
|
-
* ## Scene entity ID
|
|
1068
|
-
*
|
|
1069
|
-
* The entity ID of the new scene.
|
|
1070
|
-
*
|
|
1071
|
-
* @example all_lights
|
|
1072
|
-
*
|
|
1073
|
-
* ## Selector
|
|
1074
|
-
*
|
|
1075
|
-
* ```yaml
|
|
1076
|
-
* text: null
|
|
1077
|
-
|
|
1078
|
-
* ```*/
|
|
1079
219
|
scene_id: string;
|
|
1080
|
-
/**
|
|
1081
|
-
* ## Entities state
|
|
1082
|
-
*
|
|
1083
|
-
* List of entities and their target state. If your entities are already in the target state right now, use `snapshot_entities` instead.
|
|
1084
|
-
*
|
|
1085
|
-
* @example light.tv_back_light: "on"
|
|
1086
|
-
light.ceiling:
|
|
1087
|
-
state: "on"
|
|
1088
|
-
brightness: 200
|
|
1089
|
-
|
|
1090
|
-
*
|
|
1091
|
-
* ## Selector
|
|
1092
|
-
*
|
|
1093
|
-
* ```yaml
|
|
1094
|
-
* object: null
|
|
1095
|
-
|
|
1096
|
-
* ```*/
|
|
1097
220
|
entities?: Record<string, unknown> | unknown[];
|
|
1098
|
-
/**
|
|
1099
|
-
* ## Snapshot entities
|
|
1100
|
-
*
|
|
1101
|
-
* List of entities to be included in the snapshot. By taking a snapshot, you record the current state of those entities. If you do not want to use the current state of all your entities for this scene, you can combine the `snapshot_entities` with `entities`.
|
|
1102
|
-
*
|
|
1103
|
-
* @example - light.ceiling
|
|
1104
|
-
- light.kitchen
|
|
1105
|
-
|
|
1106
|
-
*
|
|
1107
|
-
* ## Selector
|
|
1108
|
-
*
|
|
1109
|
-
* ```yaml
|
|
1110
|
-
* entity:
|
|
1111
|
-
multiple: true
|
|
1112
|
-
|
|
1113
|
-
* ```*/
|
|
1114
221
|
snapshot_entities?: string;
|
|
1115
222
|
}): Promise<void>;
|
|
1116
|
-
/**
|
|
1117
|
-
* ## Activate
|
|
1118
|
-
*
|
|
1119
|
-
* Activates a scene.*/
|
|
1120
223
|
turn_on(service_data: {
|
|
1121
|
-
/**
|
|
1122
|
-
* ## Transition
|
|
1123
|
-
*
|
|
1124
|
-
* Time it takes the devices to transition into the states defined in the scene.
|
|
1125
|
-
*
|
|
1126
|
-
* @example undefined
|
|
1127
|
-
*
|
|
1128
|
-
* ## Selector
|
|
1129
|
-
*
|
|
1130
|
-
* ```yaml
|
|
1131
|
-
* number:
|
|
1132
|
-
min: 0
|
|
1133
|
-
max: 300
|
|
1134
|
-
unit_of_measurement: seconds
|
|
1135
|
-
|
|
1136
|
-
* ```*/
|
|
1137
224
|
transition?: number;
|
|
1138
225
|
entity_id: string | string[];
|
|
1139
226
|
}): Promise<void>;
|