OK let’s do this the simplest way possible and then later other community members can help you if you want to do some of the more complicated stuff.
create a routine called “good night” in SmartThings that does all the actions that you want. When you are finished, anytime you tap the Goodnight routine button in the smartthings mobile apps your “good night” routine will run. So now the routine exists. But we want to be able to use it by telling echo to do it, instead of having to open the mobile app and tap the routine tile.
Check to make sure your New routine shows up on the routines list in your mobile app before continuing.
Two) create a virtual switch called “nighttime”. Again, other people can help you if you’re not sure that you got that part Right, but it sounds like you did. For the purposes of this example, we’ll call that switch “Nighttime” just so it’s clear what we’re talking about each time. You can actually call it anything you want.
Check to make sure your new switch shows up on the things list in your mobile app before continuing.
When you finish this step, you should be able to go to the things list in the SmartThings mobile app and see a switch called “nighttime.” But at this point, that switch doesn’t actually do anything.
So now we have a routine, and we have a switch. We need a smartapp to tie them together so that turning on the switch activates the routine.
Three) now you’re going to install one of the officially published smart apps called "Switch Activates Home Phrase " (routines used to be called “Hello Home Phrases” when this smartapp was first written.)
Open the SmartThings mobile app.
Click on the colored star asterisk in the lower right to open the Marketplace.
Choose “Lights and Switches.”
Scroll down until you see “Switch Activates Home Phrase”
and install that by clicking on install in the upper right and following the instructions.
The smartapp has a setup wizard that will let you pick the switch (“nighttime”) and the routine (which this smartapp calls a “phrase”) you want to connect to it (“good night”)
On each screen click “done” in the upper right, until you have completed installing the Smartapp.
When you finish this process, every time you toggle that switch, SmartThings will execute that routine. So if you went to the thing screen in the mobile app and tapped the “Nighttime” switch, your “good night” routine would run.
- So now everything is set up, we just need to give echo permission to ask SmartThings to change the “nighttime” switch. So authorize Echo to use the “nighttime” switch following the FAQ instructions. Again, if you don’t know how to do that, others will help you.
After that, when you say “Alexa, turn on Nighttime” Alexa will tell SmartThings to flip that switch, and the “good night” routine will run.
“Alexa helper” is just a newer, fancier version of “switch activates home phrase,” which has more options and let you set up six switches at a time. But you can use the older version to do one switch at a time and it works just as well.