You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: source/_integrations/template.markdown
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1290,31 +1290,31 @@ light:
1290
1290
type: template
1291
1291
default: optimistic
1292
1292
set_effect:
1293
-
description: Defines an action to run when the light is given an effect command. Receives the variable `effect`. May also receive the variables `brightness`, and/or `transition`.
1293
+
description: Defines a set of actions (script) to run when the light is given an effect command. The script will only execute if the light is turned on with an `effect`. The `set_effect` script receives the variable `effect`. It may also receive variables `brightness` and/or `transition`.
1294
1294
required: inclusive
1295
1295
type: action
1296
1296
set_level:
1297
-
description: Defines an action to run when the light is given a brightness command. The script will only be called if the `turn_on` call only ha brightness, and optionally transition. Receives variables `brightness` and, optionally, `transition`.
1297
+
description: Defines a set of actions (script) to run when the light is given a brightness command. The script will only execute if the light is turned on with a `brightness`, `brightness_pct`, or `transition`. The `set_level` script receives the variables `brightness` and/or `transition`.
1298
1298
required: false
1299
1299
type: action
1300
1300
set_temperature:
1301
-
description: Defines an action to run when the light is given a color temperature command. Receives variable `color_temp`. May also receive variables `brightness` and/or `transition`.
1301
+
description: Defines a set of actions (script) to run when the light is given a color temperature command. The script will only execute if the light is turned on with a `color_temp` or `color_temp_kelvin`. The script receives the variables `color_temp` and `color_temp_kelvin`, and may also receive variables `brightness` and/or `transition`.
1302
1302
required: false
1303
1303
type: action
1304
1304
set_hs:
1305
-
description: "Defines an action to run when the light is given a hs color command. Available variables: `hs` as a tuple, `h` and `s`"
1305
+
description: Defines a set of actions (script) to run when the light is given a hs color command. The script will only execute if the light is turned on with an `hs_color`. The script receives the variables `hs` as a tuple, `h`, and `s`, and may also receive variables `brightness` and/or `transition`.
1306
1306
required: false
1307
1307
type: action
1308
1308
set_rgb:
1309
-
description: "Defines an action to run when the light is given an RGB color command. Available variables: `rgb` as a tuple, `r`, `g` and `b`."
1309
+
description: Defines a set of actions (script) to run when the light is given an RGB color command. The script will only execute if the light is turned on with an `rgbw_color`. The script receives the variables `rgb` as a tuple, `r`, `g`, and `b`, and may also receive `brightness` and/or `transition`.
1310
1310
required: false
1311
1311
type: action
1312
1312
set_rgbw:
1313
-
description: "Defines an action to run when the light is given an RGBW color command. Available variables: `rgbw` as a tuple, `rgb` as a tuple, `r`, `g`, `b`and `w`."
1313
+
description: Defines a set of actions (script) to run when the light is given an RGBW color command. The script will only execute if the light is turned on with `rgbw_color`. The script receives the variables `rgbw` and `rgb` as tuples, `r`, `g`, `b`, and `w`, and may also receive `brightness` and/or `transition`.
1314
1314
required: false
1315
1315
type: action
1316
1316
set_rgbww:
1317
-
description: "Defines an action to run when the light is given an RGBWW color command. Available variables: `rgbww` as a tuple, `rgb` as a tuple, `r`, `g``b`, `cw` and `ww`."
1317
+
description: Defines a set of actions (script) to run when the light is given an RGBWW color command. The script will only execute if the light is turned on with a `rgbww_color`. The script receives the variables `rgbww` and `rgb` as tuples, `r`, `g`, `b`, `cw`, and `ww`, and may also receive `brightness` and/or `transition`.
1318
1318
required: false
1319
1319
type: action
1320
1320
state:
@@ -1328,7 +1328,7 @@ light:
1328
1328
type: template
1329
1329
default: false
1330
1330
temperature:
1331
-
description: Defines a template to get the color temperature of the light.
1331
+
description: Defines a template to get the color temperature of the light. The template must return the color temperature in mireds. If you are using a `color_temp_kelvin` attribute from another source, convert the value to mireds by dividing 1000000 by the `color_temp_kelvin` result.
0 commit comments