IFTTT integration help

Hello.

Apologies if this has been answered before.

I am playing with the hubitat / IFTTT integration. My goal is that when the front door opens, a linked wemo switch turns on the front porch lights. That's pretty easy to do and I have the applet running in IFTTT.

Now I want to make that applet a bit smarter.

I would like that it checks the hubitat mode and if it is "night", then it progresses to turn on the wemo switch, otherwise, it terminates the request.

I think I can use the filter option in IFTTT to do that but I can't find how to query the hubitat mode. Is that possible?

If that's not possible, what would be another way to do that?

Thank you.

As far as I know, IFTTT cannot read the mode directly. A virtual dimmer or switch could be possibly be used for this by setting a certain dimmer level by mode, and reading it in IFTTT, but not sure if that would work in IFTTT… Otherwise, a switch could be activated via rule when mode is night and shared with IFTTT. If IFTTT can detect a switch on + sensor open, that would possibly work.

However, in Hubitat, it would be easy to do.

One option would be to setup a virtual front door sensor device and a rule that only sets it to open when the appropriate mode is active, and to close anytime. Then this virtual device would be shared with IFTTT and it would only turn on the Wemo switch when that mode is active.

Makes sense?

I had this exact same setup and it worked great. But after living with WeMo for a year without the flexibility of other native huhitat devices, a few weeks ago I finally swapped them out for GE/Jasco zwave switches. So glad I did. So much easier.

4 Likes

Yeah if possible I would avoid IFTTT altogether. I mean why involve the cloud if you don't have to.

3 Likes

I'll assume you want to run this using the IFTTT Maker Channel. The Maker channel is more of a "If this happens, then do that" type of interface. So you can't use it to query the hubitat device. You could however use it to see if the front door opened or closed on the hubitat, and simply run the applet based on that. I've written a quick nodejs script that you can use that will run in the background to check for this. You can then use the Maker channel to run that script when the door opens or closes.

Thank you Sebastien.

What you describe makes complete sense. I just can't figure out how to set the basic rule for the virtual sensor.

Would you be able to print me in the right direction?

Thank you

1 Like

Thank you.

I presume you are talking about the webhooks. I just linked my account and will read on how that works.

I would use Rule Machine and this rule. It will only run in « Night » mode and at that time will synchronize the Virtual Switch with the Real Switch (Kitchen Center… in this example).

The Virtrual switch is the one that should be shared in IFTTT for this to work.

Thank you. I got it to work.

Your tip showed me a world of capabilities I was unaware of. So thank you.

I will get busy automating!

1 Like

I wish there was a way to get the current switch state of a Hubitat device in IFTTT. Using IFTTT for a presence routine trigger, because its presence detection seems quicker, more accurate, and reliable than Hubitat app.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.