I use dummy switches for a lot of my automation, the basic layout is to create a switch template (there are a lot more options you can enable, this is a super basic example):
Thank you. Where do I do this at within the UI of Home Assistant?
Example: When I do my automations I go to Configuration > Automations > Add Automation.
You first have to define a template device and then you treat that device like any other in Home Assistant. You can read up on template switches at HERE.
Once you have the template device added and you either restart HASS or reload template entities from the Configuration -> Server Controls section then you just create your automation and turn on/off the device like you would a discovered switch.
Question, the link you sent and many other instructions links I read say to add to “configuration.yaml”. Which I have been doing, but my configuration.yaml is getting quite long now with code. Is there a best practise method to organise new files that relate to configuration.yaml? So example, for lights only, can I create a new file and make my edits in there? Or does every single code have to be within the single configuration.yaml file?
Yes, you can (and probably should) break it up. You can read how to do that HERE. I use a combo of reading other files and reading the contents of subfolders, depending on what I’m doing. Because I have so many template entities defined, I actually use a folder full of them, it’s easier for me to manage:
I did the light: !include devices/light.yaml and moved my light code there.
Now my Zigbee Lights have become unavailable via Deconz. Wifi lights are ok, but Zigbee has killed my devices.
Thank you, that does bring it to Alexa so that’s fantastic to know. But it brings it into the actions of Alexa. I want it to be trigger in Alexa to then action Alexa Say “Name has arrived home”