Evohome error HTTP client error at retrieve user account info

For heating/cooling related questions in Domoticz

Moderator: leecollings

gordonb3
Posts: 111
Joined: Saturday 31 March 2018 22:24
Target OS: Linux
Domoticz version: Custom
Location: Delft, NL
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by gordonb3 »

Unsure where you found that API key, but the code in Domoticz does in fact use the 0Auth method that Joe Zwack mentioned for logging on. If you want to do manual checking you should use the headers as set in the code rather than fall back to some old method that Honeywell plans to phase out.
patvandijk
Posts: 8
Joined: Thursday 10 April 2014 17:20
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by patvandijk »

@gordonb3, not sure what to do, when I try

curl -X POST -H "Content-Type: application/json" -H "Authorization : Basic YjAxM2FhMjYtOTcyNC00ZGJkLTg4OTctMDQ4YjlhYWRhMjQ5OnRlc3Q=" -H "Accept : application/json, application/xml, text/json, text/x-json, text/javascript, text/xml" -H "charsets: utf-8" -d '{
"username": "...",
"password": "...",
"installationInfo-Type": "application%2Fx-www-form-urlencoded;charset%3Dutf-8",
"Host": "rs.alarmnet.com%2F",
"Cache-Control" : "no-store%20no-cache",
"Pragma" : "no-cache",
"grant_type" : "password",
"scope" : "EMEA-V1-Basic%20EMEA-V1-Anonymous%20EMEA-V1-Get-Current-User-Account",
"Connection=Keep-Alive",
}' 'https://tccna.honeywell.com/Auth/OAuth/Token'

I get

{"error":"unsupported_grant_type"}

Any idea how I can test this using curl?
gordonb3
Posts: 111
Joined: Saturday 31 March 2018 22:24
Target OS: Linux
Domoticz version: Custom
Location: Delft, NL
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by gordonb3 »

Don't have time to verify right now, but you appear to be converting the POST data to json where it is in fact URI parameter type data. You should not use (not encoded) double quotes in the POST data, assignments must be made by using an equal sign instead of a colon and parameters should be separated by an ampersand.
japie101
Posts: 8
Joined: Tuesday 03 March 2015 10:42
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by japie101 »

I am actually experiencing the same issue as patvandijk.

I upgraded from Evohome v1 towards the latest Wifi version yesterday, but I am unable to get the new version working via the web API option in Domoticz.

Running Domoticz Version: 4.10184 on a Raspberry Pi 2 which is running Domoticz for years now.
No problems at all with the internet connectivity.

018-11-11 13:30:34.721 Error: (Evohome-new) HTTP client error at retrieve installation!
2018-11-11 13:30:34.721 Error: (Evohome-new) failed to retrieve installation info from server
2018-11-11 13:31:34.727 Status: (Evohome-new) connect to Evohome server
2018-11-11 13:31:37.034 Error: (Evohome-new) HTTP client error at retrieve installation!
2018-11-11 13:31:37.034 Error: (Evohome-new) failed to retrieve installation info from server
2018-11-11 13:32:37.040 Status: (Evohome-new) connect to Evohome server
2018-11-11 13:32:38.959 Error: (Evohome-new) HTTP client error at retrieve installation!
2018-11-11 13:32:38.959 Error: (Evohome-new) failed to retrieve installation info from server
2018-11-11 13:33:38.965 Status: (Evohome-new) connect to Evohome server
gordonb3
Posts: 111
Joined: Saturday 31 March 2018 22:24
Target OS: Linux
Domoticz version: Custom
Location: Delft, NL
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by gordonb3 »

That one confuses me. Did you have it running with Evohome v1 (with an RFG100) before, or is this your first attempt to add Evohome to Domoticz?

Note that your error is in fact not the same. The message you receive implies that you already had a successful login and it also retrieved your user ID from the user_info call. Your connection to the portal therefore is apparently working. I'm seeing two possible options here:
1. you may have a networking issue you're not aware off (because of its size installation info will be fragmented, unlike the first two calls)
2. the portal may be returning an unexpected HTTP return code (possible to see when you enable debugging as described a few posts back)
japie101
Posts: 8
Joined: Tuesday 03 March 2015 10:42
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by japie101 »

Ran the debug option, actually running into the same error as seen in this thread before.

2018-11-11 18:51:57.363 Error: (Evohome-new) HTTP client error at retrieve installation!
2018-11-11 18:51:57.363 Error: (Evohome-new) failed to retrieve installation info from server
2018-11-11 18:51:57.361 Debug: HTTP 403: Forbidden. The request is valid, but the server is refusing action
gordonb3
Posts: 111
Joined: Saturday 31 March 2018 22:24
Target OS: Linux
Domoticz version: Custom
Location: Delft, NL
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by gordonb3 »

We actually seem to have various causes for the client failing, some of them local and not returning any debug info, and some of them remote with the portal server returning an error. Most of the latter ones appear to be related to account settings, most commonly language for some reason being set to Hungarian. One user stated that deleting his Honeywell account and recreating it from scratch solved the issue.
japie101
Posts: 8
Joined: Tuesday 03 March 2015 10:42
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by japie101 »

Update from my side, I managed to get this working within Domoticz.
What I did:

On the My Total connect page https://international.mytotalconnectcomfort.com/
I logged in and removed my complete setup, first starting with the thermostat, then location, then my complete account (there are buttons to do this actually).

So my complete account was removed, and after this I created the same account (actually using exactly the same email and password credentials)
First the account, then the location (located in NL), and at last the thermostat using the MAC and code.

After this was all added back, I enabled Domoticz Evohome over API again (which I already configured, but was turned off for the time being since it was not working) and it was learning all my zones straight away! No issues at all.

To summarize, there is really something strange with on the Honeywell portal.
Hope this helps for others.
gordonb3
Posts: 111
Joined: Saturday 31 March 2018 22:24
Target OS: Linux
Domoticz version: Custom
Location: Delft, NL
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by gordonb3 »

Thanks. Quite frustrating this....

@Patrick
Checked with curl. Should work like this:

Get your authentication token:

Code: Select all

uname_enc=<your_email_address>
passwd_enc=<your_password> (encode 'special' characters)

pdata="installationInfo-Type=application%2Fx-www-form-urlencoded;charset%3Dutf-8"
pdata="${pdata}&Host=rs.alarmnet.com%2F"
pdata="${pdata}&Cache-Control=no-store%20no-cache"
pdata="${pdata}&Pragma=no-cache"
pdata="${pdata}&grant_type=password"
pdata="${pdata}&scope=EMEA-V1-Basic%20EMEA-V1-Anonymous%20EMEA-V1-Get-Current-User-Account"
pdata="${pdata}&Username=${uname_enc}"
pdata="${pdata}&Password=${passwd_enc}"
pdata="${pdata}&Connection=Keep-Alive"


curl -X POST -H "Content-Type: application/json" -H "Authorization : Basic YjAxM2FhMjYtOTcyNC00ZGJkLTg4OTctMDQ4YjlhYWRhMjQ5OnRlc3Q=" -H "Accept : application/json, application/xml, text/json, text/x-json, text/javascript, text/xml" -H "charsets: utf-8" -d "${pdata}" 'https://tccna.honeywell.com/Auth/OAuth/Token'
Look in the output for the value of "access_token" and copy it's value

Get user information:

Code: Select all

access_token=<access_token data from previous command>

curl -X GET -H "Content-Type: application/json" -H "Authorization : bearer ${access_token}" -H "Accept : application/json, application/xml, text/json, text/x-json, text/javascript, text/xml" -H "charsets: utf-8" -H "applicationId: b013aa26-9724-4dbd-8897-048b9aada249" 'https://tccna.honeywell.com/WebAPI/emea/api/v1/userAccount'
This will get you your Honeywell User ID

Get installation information:

Code: Select all

userID=<value of userID from previous command>

curl -X GET -H "Content-Type: application/json" -H "Authorization : bearer ${access_token}" -H "Accept : application/json, application/xml, text/json, text/x-json, text/javascript, text/xml" -H "charsets: utf-8" -H "applicationId: b013aa26-9724-4dbd-8897-048b9aada249" "https://tccna.honeywell.com/WebAPI/emea/api/v1/location/installationInfo?userId=${userId}&includeTemperatureControlSystems=True"
If all of this works the rest of the call should work as well
DanD
Posts: 159
Joined: Saturday 05 March 2016 9:59
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: UK
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by DanD »

Hi,

Thought I'd post my recent experiences. I've been helping a friend get their new Evohome system set-up in Domoticz using the "Web API" hardware device. Although their account was all working OK via IOS/Android apps, we just couldn't get it to work within Domoticz and kept on getting the similar error messages that others have experienced in the log:

Error: (EvoWeb) HTTP client error at retrieve installation!
Error: (EvoWeb) failed to retrieve installation info from server

We tried switching languages via account settings on the Honeywell website, but still got same errors. We even tested out adding myself as additional user to their account and I could access their system OK via my account details in Domoticz. However, the reverse (adding them as an additional user to my account) didn't help. Finally, we tried deleting their account on the Honeywell website and then adding again and this fixed it! It's now all working OK in Domoticz.

Dan
Windows 7, Raspberry Pi3, Honeywell Evohome Wifi, HGI80 + RFBee(s)
jordipalet
Posts: 12
Joined: Sunday 09 December 2018 10:33
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by jordipalet »

HI,

I just installed my Evohome Wifi and configured Domoticz hardware via Web API.

It seems to be working, recognized automatically the devices, but I'm getting some errors. This is the actual log:

2018-12-13 21:34:56.575 Error: (EvoHome) login failed with message: attempt_limit_exceeded
2018-12-13 21:42:57.502 Error: (EvoHome) login failed with message: invalid_grant
2018-12-13 21:45:08.933 Error: RxQueue: cannot retrieve hardware with id: 4
2018-12-13 21:52:58.426 Error: (EvoHome) login failed with message: invalid_grant
2018-12-13 22:04:59.272 Error: (EvoHome) login failed with message: attempt_limit_exceeded
2018-12-13 22:19:00.332 Error: (EvoHome) login failed with message: invalid_grant
2018-12-13 22:35:01.282 Error: (EvoHome) login failed with message: invalid_grant
2018-12-13 22:53:02.254 Error: (EvoHome) login failed with message: invalid_grant
2018-12-13 23:13:03.233 Error: (EvoHome) login failed with message: invalid_grant

Any hint on this?

Also, if somebody can confirm, it seems that having just the Evohome Wifi, the main difference in using the "via scripting" vs the Web API is that the scripting allows to control independently the zones, as it will create also devices for the temperature set points for each zone?

Is this correct or I'm missunderstanding https://wiki.domoticz.com/wiki/Evohome# ... vice_Zones

Any other advantage of the scripting?

Thanks!
gordonb3
Posts: 111
Joined: Saturday 31 March 2018 22:24
Target OS: Linux
Domoticz version: Custom
Location: Delft, NL
Contact:

Re: Evohome error HTTP client error at retrieve user account info

Post by gordonb3 »

Honeywell added some restrictions to their portal. I don't know how many devices you use for connecting and/or how many installations you added in Domoticz, but you are doing way too many login attempts. Since you're only showing the errors I can't see if you're doing something that you shouldn't, like constantly resetting the hardware (by changing settings).
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest