Many times your IFTTT applets are just what you need for your smart applications… if you could just add a small delay to better time some of the actions.
Adding a delay to your IFTTT applets is very easy with Apilio: you’ll need to daisy-chain them and this article will show you how.
Adding a delay to your IFTTT actions is something that Apilio can help you with. This is how things work:
- Something happens and an applet on IFTTT triggers a few actions, one after the other
- Something happens and an applet on IFTTT lets Apilio know
- Apilio sends events to IFTTT at specific times, taking into account your delays, so things can be executed by IFTTT when you want to
- IFTTT runs the actions when they receive the event from Apilio
We are basically making a sandwich where IFTTT is the bread and Apilio is the PB&J
No coding is needed, you just need to specify the delay in Apilio and connect your IFTTT applets.
In this example, I’m not going to setup any conditions in Apilio, I’m assuming you are doing that in IFTTT. My example is as follows:
- If my phone connects to my home wifi
- Then turn the foyer lights on
- And, 5 minutes later, turn the foyer lights off
Go to https://app.apilio.com/logicblocks and create a new Logicblock. You just need to give it a name at this point, for example “foyer_lights”. We’ll use this name shortly. Save your logicblock.
For example, I want to start my routine when my phone connects to my home wifi. I will setup an applet that if my phone connects to a specific wifi, then I will initiate a Logicblock evaluation in Apilio:
You’ll need to setup an applet that starts with your desired triggers, and that calls Apilio at the end. The “THEN” part calls Apilio’s Logicblock that you created on the second step, “foyer_lights”.
Go back to Apilio and edit your “foyer_lights” Logicblock. We are going to add the two actions we want to execute: turn the lights on and then, 5 minutes later, turn the lights off. These two IFTTT actions are just event names that will be sent to IFTTT to orchestrate your actions at your desired times. 5 minutes is: 5 * 60 seconds = 300 seconds.
These are the two actions you’ll have in the Logicblock:
Your applet that catches the first event, foyer_light_on looks like this:
In my example, I’m using a LIFX lightbulb, but you could replace it with any other service.
And the second action, the one that is being delayed, is using the second event, foyer_light_off.
IFTTT will receive this event 5 minutes after the other, thus delaying this action.
Great work, now when your phone connects to your home wifi, the foyer lights will turn on for a bit when you get home.
Find the applet you need on our list and just enable it, these don’t count towards the 3-applet limit:
I can hear you say: “But Anna, isn’t it wasteful to turn the lights on if it’s daytime?” Glad you asked! I think you are going to like this expanded example: