IFTTT Webhook - Server returning 401

Topics (not sure which fora)
when not sure where to post, post here and mods will move it to right forum.

Moderators: leecollings, remb0

Post Reply
Falken
Posts: 6
Joined: Thursday 22 February 2018 21:20
Target OS: Raspberry Pi / ODroid
Domoticz version: 3.8934
Contact:

IFTTT Webhook - Server returning 401

Post by Falken »

Hi!

I have configured a working Domoticz setup with access from the WAN-side of things.
However, when I create a request like this: https://myip:443/json.htm?type=command& ... l&level=10, the server returns a 401 when coming from the outside my network.

If I visit the adress above from inside my network, the actual switch (A Xiaomi Robot Vaccum) starts its cleaning.
So, does any body know how to set up IFTTT properly so that I dont get a 401?

THANK YOU so much in advance.
Falken
Posts: 6
Joined: Thursday 22 February 2018 21:20
Target OS: Raspberry Pi / ODroid
Domoticz version: 3.8934
Contact:

Re: IFTTT Webhook - Server returning 401

Post by Falken »

No one?
User avatar
Phantom
Posts: 87
Joined: Saturday 31 December 2016 14:47
Target OS: Raspberry Pi / ODroid
Domoticz version: 4.11652
Location: The Netherlands
Contact:

Re: IFTTT Webhook - Server returning 401

Post by Phantom »

Hey, what did you use to protect your domoticz from the outside?
If you did that in domoticz at settings and then local networks then you need to add an username and password in the url else you will get the 401 message.

for example https://user:secretpassword@myip/json.h ... l&level=10
ThomasZA
Posts: 2
Joined: Friday 20 May 2022 23:10
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: IFTTT Webhook - Server returning 401

Post by ThomasZA »

I get the same error from IFTTT - I have tried supplying my credentials in the URL both as plain text, and as base64 encoded.

From my phone via cellular data, it works (both of the above options)... from my LAN it works.... from IFTTT - it does not work.... from a friend in Australia and a friend in Canada - it does not work... (I am in South Africa)

This used to work (a long time ago though) with base64 encoded credentials. I am only now looking at this again loooooooooong after its stopped working.

Strange that international access seems to get 401 - whilst locally it works (and no - I do not have anything doing geo-blocking)

I use the below format (IDX, url and credentials changed obviously....)
https://domoticz.place.co.za/json.htm?u ... itchcmd=On
redswan
Posts: 16
Joined: Monday 23 October 2017 17:07
Target OS: Raspberry Pi / ODroid
Domoticz version: 2024.5
Contact:

Re: IFTTT Webhook - Server returning 401

Post by redswan »

Hi,
I had the same problem and finally found that using the format

http://<username:password@>domoticz-ip<:port>/json.htm?api-call

worked for me. You also need to change the authentication method in "settings/website protection" to "basic-auth".

However base64 encoded credentials don't work for me. I'm not sure of the utility of encoding the credentials as it's very easy to decode then, unless of course I've totally misunderstood the concept ;)
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest