dehsgr / node-red-contrib-alphaess

This provides a node for retrieving information from Alpha ESS photovoltaic systems.
ISC License
14 stars 0 forks source link

login in error #6

Closed str3000 closed 2 years ago

str3000 commented 2 years ago

problem since today verson: 1.6.0

error: 16.10.2022, 13:38:36node: Alpha EES Monitoring msg : string[163] "There was an error during login operation into Alpha ESS monitoring portal: SyntaxError: Unexpected end of JSON input↵↵We got the following unprocessable body:↵"

dehsgr commented 2 years ago

Alpha ESS changed the underlying web portal API. Currently I don't see an option to get this working again. Any help on reverse engineering how new authentication scheme (authsignature/authtimestamp) works is really appreciated...

dehsgr commented 2 years ago

Signature verification and anti-crawl data functionality are added in all APIs of AlphaCloud.

That's our issue now (since Alpha Cloud v5.0.0.2).

dehsgr commented 2 years ago

I just published an update working around this issue with additional data retrievable via browsers debugging console (see commit 2efa623. Updated README.md accordingly.

Not sure how long this works and when additional auth data will become invalid. This is only a hack for getting around this for the moment until there will be more information available to solve this issue.

str3000 commented 2 years ago

iI make the update to 1.6.1 and same behavior..

16 Oct 18:12:48 - [warn] [alphaess-monitoring:Alpha EES Monitoring] There was an error during login operation into Alpha ESS monitoring portal: SyntaxError: Unexpected end of JSON input

We got the following unprocessable body:

dehsgr commented 2 years ago

@str3000 so I assume you didn't read the README.md as mentioned here. You've to fetch authsignature and authtimestamp yourself from your browser's debug console and give that data to the node too... ;-)

str3000 commented 2 years ago

your right i, sorry

str3000 commented 2 years ago

Node running again. Thanks for the super fast fix.

You write it and I think also this method will only work for a short time. Hopefully .... Have a nice evening!

dehsgr commented 2 years ago

Thank you! You're welcome. Have a nice evening too!

dehsgr commented 2 years ago

Published a fix with v.1.7.0. Thanks for reporting and supporting.