Hi, before anyone gives me a hard time, I have been up for more or less 3 days getting my neat new Home Assistant set-up up and running. So I’m not just being lazy.
But the official docs for IFTTT integration say the following:
To send events to Home Assistant, you will need to use the “Make a web request” action from the IFTTT Webhook applet.
To send events to Home Assistant, you will need to use the “Make a web request” action from the IFTTT Webhook applet.
See the documentation on how to configure automations to handle incoming data.
But I have no idea what this is referring to? There is no "Make a Web Request’ Applet under IFTTT’s list of available web hook applets. The nearest is maybe 'receive a web request - and that is an element in a recipe, where first you must select a trigger and then and action. (This then that, naturally.) But as we all know to ‘give’ is not the same as to receive - and there is no option in any of the available actions and or applets to enter the suggested information? So I seem to have fallen flat at the first hurdle?
I don’t mind reading docs. But it’s pretty helpful if they actually make any sense? I have read a lot of docs this last three days. I also searched the forum. But the vast majority of the posts I found were from people who already had IFTTT up and running and who were experiencing some compatibility issue or other, that has little relevance to my more basic predicament.
So the make web request is only available as an action with IFTTT. So if something happens to trigger your applet it can then make a request to your home assistant server.
If you want to use it the other way around so a home assistant automation triggers an IFTTT applet, you can create the IFTTT applet with the receive a web request trigger, which will give you a unique URL which you can use in a home assistant automation to trigger the applet.
I’m going to ask a big favour, just as an example. I have tried to follow several guides on how to get IFTTT up and working. But many seem to presuppose prior knowledge of how to edit config files - and even in some cases how to write what I presume is python code. I have neither. Currently the way I use IFFFT is just through Google home, or via location based services. So for example, if I say a simple phrase (If) then Google Assistant should preform a particular task (that). So for example if I say 'hey Google, Turn on the reading light, Google home will use the integrated Smart Life skill to turn on my reading light. Or if I leave home during the day, IFTTT will use location services to start my iRobot vacuum cleaner.
So lets say, for example I wanted to use Home Assistant, Location Services and IFTTT to achieve the same goal, like for example to turn on one of my Phillips Hue lights (say the bedroom) how exactly would I go about doing this step by step? Also what are the advantages of using IFTTT with home assistant? I haven’t set up any automations yet. But presumably I can use automations with Google Home/Alexa the same way I can use recipes with IFTTT?
For me I use IFTTT with home assistant to control devices by pressing buttons on my smartwatch. As IFTTT can only have five actions on the free tier, I only need to use one for home assistant as my smartwatch sends a single webhook to IFTTT but passes different data within the body of the webhook to home assistant which then triggers different actions depending on the data. The advantage of using IFTTT with home assistant is that it can integrate home assistant with lots of different platforms.
Google home and alexa will still be able to control your devices if you set them up with IFTTT.
I am assuming you can access your home assistant remotely as this is a prerequisite to using IFTTT and that you have installed the IFTTT integration in home assistant.
So there are two ways to go about this:
Home assistant can track your location and sends a command to IFTTT to turn on the light
In IFTTT set up a recipe using the webhooks applet and select ‘receive a web request’ as the trigger.
You should be given a URL under webhook settings when setting up this platform, if not you can find it by clicking explore, searching for ‘webhooks’ and clicking on settings.
For the event name put what you want the trigger to do - for example: turn_off_light
Now in home assistant:
Download file editor from the addon page in home assistant
Launch the file editor and select configuration.yaml
Add the following lines
ifttt:
key: YOUR_API_KEY - this is the URL from the IFTTT webhook
Next follow this section of the user guide to test your trigger using the event name you created in IFFT: IFTTT - Home Assistant
If this works you can then create an automation using the same process. I’m happy to help but let me know if the above works first.
IFTTT can track your location and sends a command to home assistant to turn on the light
For this one, you set up an IFTTT recipe that has the webhook service as the action. You will choose the action “make a web request” and then for the URL you will use the webhook URL displayed when you install IFTTT as an integration in home assistant.
In the body of your IFTTT recipe, you will put the following: ```
{ “action”: “call_service”, “service”: “light.turn_on”, “entity_id”: “light.living_room” } replacing action what you want to do for example turn_off_light and then replace service and and entity_id with the one’s for your Phillips hue light. You can find these values in home assistant on the developer page by selecting call service and finding the one for light.
Next you will set up an automation to trigger when it receives the webrequest.
You can copy the example shown in the docs: IFTTT - Home Assistant
You will replace the action value with the value of the action you are sending in the IFTTT body.
Tbh, not much. I guess if you find reusing existing applets useful? There is a lot of them. But if you’re mostly building your own applets there’s not much point. Home assistant has a much more powerful automation engine that you’ll likely find much more performant since it runs locally. And it looks like IFTTT boasts about 700 services? Whereas HA currently has almost 2000 integrations. Which doesn’t even include custom integrations you find here on the forum and in HACS. In terms of integration I have never found one that IFTTT can do and HA can’t, can’t say the same about the other way around back when I used to use it.
One key note in your question is the location services. I assume you have the IFTTT app installed which is then enabling location based triggers in IFTTT. You can do that but HA also has an app if you haven’t found it yet. And then you can create automations that trigger based on presence detection without involving IFTTT.
There used to be one reason to use IFTTT a long time ago, the ability to have custom phrases in Google Home. Before Google added routines the only way to make it so a phrase like “Bedroom on” turned on the right lights, outlets, etc. was to make an applet in IFTTT and pick that phrase. But these days google has routines for that. Make a routine, pick the phrase or phrases you want and then decide what it does. If you’re like me, 99% of your routines in google just say to turn on a particular scene or script you built in HA and have no other steps so all the automation can be managed in one place.
I suppose there is still one thing IFTTT can do that I haven’t seen an equivalent for anywhere else. IFTTT will let you make a phrase with a text/number ingredient and then extract that ingredient to use as an input in your actions. Which is pretty cool, I don’t really know why google hasn’t added that to routines. But I haven’t really had a need for it personally.
The only real advantage I can see with IFTTT and HA is integrating HA with a service that supports IFTTT but does not support HA. Here is looking at you MyQ and Chamberlain!
It would be nice if the MyQ integration in HA worked, but looks like MyQ has disabled access, sigh.