Skip to content
This repository has been archived by the owner on Apr 17, 2020. It is now read-only.

401 Client Error: Unauthorized for url: https://amc-api.dss.husqvarnagroup.net/v1/mowers #21

Closed
detlefpoth opened this issue May 1, 2018 · 5 comments

Comments

@detlefpoth
Copy link

detlefpoth commented May 1, 2018

The grass is growing and wants to get cut again ;-)
But after the winter pause my pyhusmow does not work any more.
Finally I got the new token which is still valid until May 2nd.
The pyhusmow http server starts and confirms : logger configured.
But any browser command e.g. http://ipaddress:port/start on the defined ip and port gets the following response:

Try to execute /start
401 Client Error: Unauthorized for url: https://amc-api.dss.husqvarnagroup.net/v1/mowers
[ERROR] Retrying to send the command 2
Done
401 Client Error: Unauthorized for url: https://amc-api.dss.husqvarnagroup.net/v1/mowers
[ERROR] Retrying to send the command 1
Done
[ERROR] Failed to send the command
192.168.46.81 - - [01/May/2018 15:17:02] "GET /start HTTP/1.1" 500 -
Done

The password in the automaker.cfg is correct as the http server seems to be able to login.
The iOS APP using the same credentials works fine.

My husqvarna 310 does not like to be steered by the iPhone App as it is sending him out no matter what the weather conditions are. ;-)

Any ideas highly appreciated
Thanks
Detlef

@simlu
Copy link

simlu commented May 14, 2018

Any progress in resolving this yet?

Have you tried using curl to see if you can get any other endpoints to respond? Even though the endpoint indicates auth error it might just been moved / changed?

I haven't looked into the code, but can you find out what request method is used?

If you iPhone is jailbroken you should be able to see what requests are being made by monitor requests of the app (have only done it on android though)

@detlefpoth
Copy link
Author

detlefpoth commented May 14, 2018 via email

@simlu
Copy link

simlu commented May 15, 2018

Hi Detlef. Great you worked it out! This is Lukas though, not Chris - I'm not the creator of this project.

Important: I would recommend that you remove your personal information from your post as it is publicly exposed! Unless you enjoy spam email / phone calls :)

Feel free to close this ticket and open a new one if you have further problems! L~

@chrisz
Copy link
Owner

chrisz commented May 15, 2018

Hi @detlefpoth,

If you have the problem only on win10, maybe there is an issue specific to this os. I have no win10 to test.

I just tried to start the server with or without the token.cfg and all seems to be ok. If there is no token.cfg or if the token is expired, a new token is retrieved.

Chris

@detlefpoth
Copy link
Author

Hi Chris -

Thx for your feedback!
I will x-check how the next token update eof May will work out on my WIN10 and get back to you in case of an reoccurring retrieval issue.

Thx. & best
Detlef

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants