I have a lighting group light.ben_bedroom_uplighters and a toggle input_boolean.toggle_bedroom_ben_lights both set up as Herlpers.
I have defined an automation to toggle the toggle so far so good.
Now this is where I am stuck. I can do an automation that turns a single light on/off depending on the toggle. I can have an action per light
alias: Toggle Ben Bedroom Lights 1
description: ""
trigger:
- platform: state
entity_id:
- input_boolean.toggle_bedroom_ben_lights
from: "off"
to: "on"
id: power-on
- platform: state
entity_id:
- input_boolean.toggle_bedroom_ben_lights
id: power-off
from: "on"
to: "off"
condition: []
action:
- choose:
- conditions:
- condition: trigger
id: power-on
sequence:
- type: turn_on
device_id: a4659e3c5bb97053b6e86f0b98115608
entity_id: light.uplighter_l
domain: light
- type: turn_on
device_id: daf6c0d07ed5871c19a709ed2a820c91
entity_id: light.uplighter_r
domain: light
- conditions:
- condition: trigger
id: power-off
sequence:
- type: turn_off
device_id: a4659e3c5bb97053b6e86f0b98115608
entity_id: light.uplighter_l
domain: light
- type: turn_off
device_id: daf6c0d07ed5871c19a709ed2a820c91
entity_id: light.uplighter_r
domain: light
mode: single
But how do I change it so rather than doing entity_id: light.uplighter_l & entity_id: light.uplighter_r I simply turn the whole lighting group ( light.ben_bedroom_uplighters) on or off?
As a side note I actualy built this with the GUI editorl, not in YAMLl. I notice it uses device_id & entity_id. If I was building this from scratch in YAML do I need to look up all the device IDs and include both or can I just use entity ID. If there is a doc covering this that would be great.