The_Holocron:
I was looking into doing this with Wyze contact sensors controlling a virtual contact sensor via IFTTT, but it doesn’t appear that you can change the state of the virtual contact sensor on the ST side in this manner. I can control a virtual switch, which would then need to change the state of the virtual contact sensor.
Alternatively, it looks like you could do this with webCoRE, but I haven’t tested it.
This is actually very easy to do, and is the basis of the method that people use to trigger echo routines from smartthings.
All you need is a virtual device which is both a switch and a sensor.
Then when you turn the switch on in any fashion, the sensor will look like it’s open. When you turn the switch off, the sensor will look like it’s closed.
Here’s one of the more popular ones:
I put together some device handlers that take advantage of Alexa’s support for contact sensors:
Alexa now supports motion and contact sensors connected to a SmartThings Hub. Play a welcome message when the door opens, turn on a connected light when motion is detected, or ask, “Alexa, is the back door open?” To get started, connect a Works with SmartThings contact or motion sensor to the SmartThings Hub, following the manufacturer’s instructions, then link the SmartThings skill using the Alexa app.
These handlers can be triggered by SmartThings routines, while also showing up in Alexa as contact sensors.
Switch:
Button (momentary switch):
2 Likes