IFTTT: How to Parameterised webhooks with google assistant ?

Alexa, Google Home and Siri

Moderator: leecollings

Post Reply
RapTile
Posts: 53
Joined: Saturday 10 March 2018 2:01
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

IFTTT: How to Parameterised webhooks with google assistant ?

Post by RapTile »

I want to tell my google assistant to change my TV input channel to HDMI1 or Netflix etc.
And i want IFTTT to send the correct command to Domoticz.

How can i make this possible?
The code below wont work because Set%20Level expects a number.

If You say "change tv input chanel to $", then Make a web request:

Code: Select all

https://<username>:<password>@<URL>:<PORT>/json.htm?type=command&param=switchlight&idx=<ID>&switchcmd=Set%20Level&level={{TextField}}
The lvl expects a number instead of text so i am wondering how this could be made possible.

the above code works for changing the TV volume but not switching the input because the volume is a number but the input channel is text.
I know the numbers that are being used by the TV API but i want to tell my google home to to switch an input channel instead of a number.

Thanks in advance for the support.
axel2906
Posts: 19
Joined: Wednesday 21 February 2018 20:38
Target OS: Raspberry Pi / ODroid
Domoticz version: V3.8926
Location: Brussels
Contact:

Re: IFTTT: How to Parameterised webhooks with google assistant ?

Post by axel2906 »

Did you find a solution to your problem ?

I've the same issue. I made 5 request but i want to do like you.
RPi3 - RfxComm - Milight - OWL160
Soepgroenten
Posts: 4
Joined: Wednesday 26 September 2018 22:31
Target OS: Windows
Domoticz version:
Contact:

Re: IFTTT: How to Parameterised webhooks with google assistant ?

Post by Soepgroenten »

One important thing...you need to encode your username and password...otherwise domoticz wont accept it..

Please take a look here for explanation.

https://www.domoticz.com/wiki/Domoticz_ ... horization

In short:
Just encode your username and password on this link, and copy/paste the results in your URL's
https://codebeautify.org/base64-encode
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest