set_light
Control a single Hue light's brightness, color temperature, color xy, effect, gradient, timed effect, and transition settings. Pass only attributes to update.
Instructions
Update one light. Pass only the attributes you want to change.
Use list_lights() to discover what each light supports — it returns
effects.available, timed_effects.available, and (for gradient strips)
a gradient block with points_capable and mode_values.
brightnessis 0–100 (percent). Setting brightness on an off light does NOT turn it on; passon=Trueas well.color_temp_mirekis the CIE mired value; the per-light valid range is reported bylist_lights()ascolor_temp_range_mirek(commonly 153–500, i.e. ~6500K–2000K). Setting this clears any active colour.color_xyis a 2-element list[x, y]in CIE 1931 colour space, clamped to the light's gamut. Setting this clears any active colour temperature.effectis one of the values fromeffects.available(e.g.no_effect,candle,fire,prism,sparkle,opal,glisten). Passno_effectto stop a running effect.gradient_pointsis a list of[x, y]CIE 1931 points (typically 2–5, capped by the light'sgradient.points_capable). Only meaningful for gradient-capable strips like the Hue Play Gradient lightstrip.gradient_modeis one of the light'sgradient.mode_values—interpolated_palette(default smooth blend),interpolated_palette_mirrored,random_pixelated, orsegmented_palette.timed_effectissunrise,sunset, orno_effect. Usetimed_effect_duration_msto set how long the effect runs.transition_msis the fade duration in milliseconds for on/off, dimming, and colour changes.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| on | No | ||
| effect | No | ||
| color_xy | No | ||
| light_id | Yes | ||
| brightness | No | ||
| timed_effect | No | ||
| gradient_mode | No | ||
| transition_ms | No | ||
| gradient_points | No | ||
| color_temp_mirek | No | ||
| timed_effect_duration_ms | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||