Closed muhkuh666 closed 8 months ago
Yes, Sinds this morning is the FoxEss data no longer available in HA. In the FoxEss Cloud App is everything normal.
I can confirm, mine also stopped working. Maybe FoxESS updated something and this integration is no longer working.
From the logs I found so far:
Unexpected error fetching FoxESS data: Expecting value: line 1 column 1 (char 0) Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 300, in _async_refresh self.data = await self._async_update_data() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 256, in _async_update_data return await self.update_method() ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/foxess/sensor.py", line 125, in async_update_data token = await authAndgetToken(hass, username, hashedPassword) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/foxess/sensor.py", line 251, in authAndgetToken response = json.loads(restAuth.data) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/json/__init__.py", line 346, in loads return _default_decoder.decode(s) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/json/decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/json/decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
_ENDPOINT_ADDRESSBOOK = "https://www.foxesscloud.com/c/v0/device/addressbook?deviceID=" { "errno": 41809, "result": null }
Btw, there's also an API https://www.foxesscloud.com/public/i18n/en/OpenApiDocument.html now. Maybe switch to that instead of getting values from portal? Under user profile can generate API key
Btw, there's also an API https://www.foxesscloud.com/public/i18n/en/OpenApiDocument.html now. Maybe switch to that instead of getting values from portal? Under user profile can generate API key
But how to add this to Home assistant? Is there an intergration?
Btw, there's also an API https://www.foxesscloud.com/public/i18n/en/OpenApiDocument.html now. Maybe switch to that instead of getting values from portal? Under user profile can generate API key
But how to add this to Home assistant? Is there an intergration?
That would require total refactoring of this integration or completely new one. Most likely quickest solution is to adapt/fixt the existing and for future releases switch to API
Btw, there's also an API https://www.foxesscloud.com/public/i18n/en/OpenApiDocument.html now. Maybe switch to that instead of getting values from portal? Under user profile can generate API key
But how to add this to Home assistant? Is there an intergration?
That would require total refactoring of this integration or completely new one. Most likely quickest solution is to adapt/fixt the existing and for future releases switch to API
API is restricted to 20 calls per day by default ;) Number of calls per day:20 Remaining calls for today:20
Btw, there's also an API https://www.foxesscloud.com/public/i18n/en/OpenApiDocument.html now. Maybe switch to that instead of getting values from portal? Under user profile can generate API key
But how to add this to Home assistant? Is there an intergration?
That would require total refactoring of this integration or completely new one. Most likely quickest solution is to adapt/fixt the existing and for future releases switch to API
API is restricted to 20 calls per day by default ;) Number of calls per day:20 Remaining calls for today:20
How do you call the API?
They actually restricted the API now. You do need to send the Timestamp and Signature flag. The signature flag can be computed as described in the API demo:
timestamp = round(time.time() * 1000)
signature = fr'{_url}\r\n{_token}\r\n{timestamp}'
But i'm unsure about the token for the initial login request. You could use the API for this but then you're really restricted
Same issues here. Hope it gonna be fixed soon
I don't think there is a "fix", they basically secured their API 😓
Hate that so much. I created the dashboard yesterday for hours.
Same issues,
Same issue
Same here. First errors at 18:55 GMT on 19th Dec, and then from 02:44 GMT on 20th Dec it's stopped working completely.
Yes, they change API access on 20th Dec
We need a Superhero now :(
Does Foxess_modbus work for now?
I received the following from Fox support:
Regarding this issues raised this morning re API requests and the impact on 3rd party apps. The changes relate to the migration to V2 of the Fox Cloud and the implications for 3rd party solutions were not fully considered and none of this was known to the UK team until this morning. The was certainly not about taking out the competition as some have suggested. We will come up with a solution.
So I guess we'll see if they are able to provide a fix...
I received the following from Fox support:
Regarding this issues raised this morning re API requests and the impact on 3rd party apps. The changes relate to the migration to V2 of the Fox Cloud and the implications for 3rd party solutions were not fully considered and none of this was known to the UK team until this morning. The was certainly not about taking out the competition as some have suggested. We will come up with a solution.
So I guess we'll see if they are able to provide a fix...
Thanks for your information. Tried to send an email too but i think the foxess email server is overloaded 👯
I received the following from Fox support:
Regarding this issues raised this morning re API requests and the impact on 3rd party apps. The changes relate to the migration to V2 of the Fox Cloud and the implications for 3rd party solutions were not fully considered and none of this was known to the UK team until this morning. The was certainly not about taking out the competition as some have suggested. We will come up with a solution.
So I guess we'll see if they are able to provide a fix...
I'm just impressed they have a support team, given some of the shocking UI decisions I've seen on their portal!
Thanks for the info.
Called FoxEss Germany now. I gave them my inverter Number. They gonna Update the Inverter now. It takes an hour then it should run again. Hope the best.
_ENDPOINT_ADDRESSBOOK = "https://www.foxesscloud.com/c/v0/device/addressbook?deviceID=" { "errno": 41809, "result": null }
41809 error code corresponds to 'invalid token'.
Called FoxEss Germany now. I gave them my inverter Number. They gonna Update the Inverter now. It takes an hour then it should run again. Hope the best.
Sorry can you make it more precise? What to update? What did you request them?
I've been having a little poke around - from what I can see two values in localStorage get set:
The token then gets used as a header for auth (token header on requests)
if you remove token, then you have to login again - probably expected really if you remove access, the page just hangs - changing the value ends up redirecting you to: https://www.foxesscloud.com/error/noPermissions
As the token is set client side (localstorage), I assume there will be a way to get this and use it to auth.
I've yet to work out where the token gets set in localStorage, but I suspect there will be a way to get the token and then use it
Called FoxEss Germany now. I gave them my inverter Number. They gonna Update the Inverter now. It takes an hour then it should run again. Hope the best.
Sorry can you make it more precise? What to update? What did you request them?
Sure.
I requested that my home assistant don't work since last night because they updated the API. ive asked him if he knows the third party integration. He approved. So he said to me that he starts a new OTA update for my inverter. I take approx one hour then everything should work again.
@macxq needs to make contact with Craig Wollaston at FoxESS UK so that he can be added to the list of developers who need access to the cloud API. I have contact details if he needs them, but Craig has posted on the FoxESS Solar/Battery Owners Group on Facebook. Nothing end users can do at this point.
@macxq needs to make contact with Craig Wollaston at FoxESS UK so that he can be added to the list of developers who need access to the cloud API. I have contact details if he needs them, but Craig has posted on the FoxESS Solar/Battery Owners Group on Facebook. Nothing end users can do at this point.
I wasn't aware of the FB group! Thanks!
@macxq needs to make contact with Craig Wollaston at FoxESS UK so that he can be added to the list of developers who need access to the cloud API. I have contact details if he needs them, but Craig has posted on the FoxESS Solar/Battery Owners Group on Facebook. Nothing end users can do at this point.
I wasn't aware of the FB group! Thanks!
Yep, lots of discussion about this issue as it's also broken a key third party app as well as some Python automations. Seems like FoxESS UK weren't aware of it either, so someone's woken up to a lot of angry customers.
Called FoxEss Germany now. I gave them my inverter Number. They gonna Update the Inverter now. It takes an hour then it should run again. Hope the best.
Update doesnt solve it in my case!
@muhkuh666 that would also be super unexpected. The issue here occurs once you request the Fox Cloud API. There is no communication to the Inverter at all:
Scripts <-X--> Fox Cloud <---> Inverter
The new API they have exposed has some significant limitations, particularly in terms of how many times it can be called in a day. A limit of 20 calls per day is a substantial restriction – this only allows for fetching data four times a day 🤦.Screenshot 2023-12-20 at 13 55 28
I do not think it is worthwhile to migrate to the new API. Additionally, I cannot promise that I will have the time and knowledge to fix the existing solution
Called FoxEss Germany now. I gave them my inverter Number. They gonna Update the Inverter now. It takes an hour then it should run again. Hope the best.
Update doesnt solve it in my case!
Same. Wont work
Same for me. I was surprised today morning. I think this is a time to move to modbus or other local solution.
Same for me. I was surprised today morning. I think this is a time to move to modbus or other local solution.
Ok what would "other local solution" be like, I have no Idea what to use?
This is a pain I now have no way to track my usage so will have move over to getting the date over 485 https://github.com/StealthChesnut/HA-FoxESS-Modbus
This is a pain I now have no way to track my usage so will have move over to getting the date over 485 https://github.com/StealthChesnut/HA-FoxESS-Modbus
Anyone know if this integration works in S-G2 Series?
ok, that means now out of the cloud and get the data locally from Modbus (RS485 to WIFI EW11).
The new API they have exposed has some significant limitations, particularly in terms of how many times it can be called in a day. A limit of 20 calls per day is a substantial restriction – this only allows for fetching data four times a day 🤦.Screenshot 2023-12-20 at 13 55 28
I do not think it is worthwhile to migrate to the new API. Additionally, I cannot promise that I will have the time and knowledge to fix the existing solution
I believe that limitation is for individual user API keys. They have asked for any developers with third party integrations to contact them so that they can try and find a solution for those use cases. Appreciate that you may not have time, though, in which case it looks like everyone will have to move to a ModBus solution.
Same problem where. Can some one point me where I can ask for increase the API call to more than 20 ? To try to help find a way to communicate online to our fox inverters
Like said. It sound complicated to patch this way.
Same problem where. Can some one point me where I can ask for increase the API call to more than 20 ? To try to help find a way to communicate online to our fox inverters
Like said. It sound complicated to patch this way.
Increasing your API calls won't solve the problem. The integration needs to be updated to use secure API signatures, and then Fox needs to grant access to that signature. The only viable solution right now is to switch to ModBus and use a different integration.
On another side my Foxess connects by WIFI to Cloud and I have found some integration for that too (ModBUS LAN). Have you checked that?
On another side my Foxess connects by WIFI to Cloud and I have found some integration for that too (ModBUS LAN). Have you checked that?
Integrations that use ModBus are unaffected by the API changes. Direct LAN integration (using the inverter ethernet port) has been disabled in the most recent firmware for some inverters.
I think about that -> https://www.youtube.com/watch?v=jRTE9UZkpHU But I understand that maybe it was off from my inverter. Yes? I will test it later today and let you know here. Maybe it will work. I have ETH port and modbus port too, but so far I use only WIFI.
I think about that -> https://www.youtube.com/watch?v=jRTE9UZkpHU But I understand that maybe it was off from my inverter. Yes?
This is the ModBus integration. The only way to get your inverter data into HA now.
Same problem where. Can some one point me where I can ask for increase the API call to more than 20 ? To try to help find a way to communicate online to our fox inverters Like said. It sound complicated to patch this way.
Increasing your API calls won't solve the problem. The integration needs to be updated to use secure API signatures, and then Fox needs to grant access to that signature. The only viable solution right now is to switch to ModBus and use a different integration.
The API is the correct way if they increase the number of calls. The way here is a brilliant way of doing it. That I say thank you. Because used to work supper nice. Modbus is the local way of doing it. But requires more hardware. Need to check if can connect by usb a ethernet card.
I think about that -> https://www.youtube.com/watch?v=jRTE9UZkpHU But I understand that maybe it was off from my inverter. Yes?
This is the ModBus integration. The only way to get your inverter data into HA now.
But i dont work with the new Firmware right? Because Ethernet is deactivated. I got the foxess smart lan dongle. But it doesnt shows IP Adress or Mac adress in Inverter or Router.
Same problem where. Can some one point me where I can ask for increase the API call to more than 20 ? To try to help find a way to communicate online to our fox inverters Like said. It sound complicated to patch this way.
Increasing your API calls won't solve the problem. The integration needs to be updated to use secure API signatures, and then Fox needs to grant access to that signature. The only viable solution right now is to switch to ModBus and use a different integration.
The API is the correct way if they increase the number of calls. The way here is a brilliant way of doing it. That I say thank you. Because used to work supper nice. Modbus is the local way of doing it. But requires more hardware. Need to check if can connect by usb a ethernet card.
I don't disagree that a cloud integration is easier (it's what I've been using), but I say again that increasing the number of API calls will not solve the problem. FoxESS has blocked access to all third party cloud apps and integrations as of last night. There is a meeting tomorrow or Friday with some of the developers of those apps to see how it can be resolved. I don't know if @macxq is taking part in that call.
I think about that -> https://www.youtube.com/watch?v=jRTE9UZkpHU But I understand that maybe it was off from my inverter. Yes?
This is the ModBus integration. The only way to get your inverter data into HA now.
But i dont work with the new Firmware right? Because Ethernet is deactivated. I got the foxess smart lan dongle. But it doesnt shows IP Adress or Mac adress in Inverter or Router.
ModBUS still works fine. The LAN port on the inverter doesn't work with newer firmware. I don't know what the smart LAN dongle is.
Hello,
is someone else expecting no values with the up to date HA Foxess?