cdpuk / ha-bestway

Home Assistant integration for Bestway / Lay-Z-Spa hot tubs
MIT License
59 stars 15 forks source link

Bad request 502 #40

Closed paducz closed 9 months ago

paducz commented 9 months ago

Version of the custom_component

Bestway device

Provide the model of your device. A link to the Bestway product page is sometimes useful.

Describe the bug

The integratiom has problem to retrieve data via API. Device is not available via HA

Logs

xlemassacre commented 9 months ago

I think its a problem from bestway, also have issues with the official app since today

paducz commented 9 months ago

You are maybe right, but from my side the offical app is working fine

paducz commented 9 months ago

Logger: homeassistant.config_entries Source: config_entries.py:429 First occurred: 11:14:47 (1 occurrences) Last logged: 11:14:47

Config entry 'username' for bestway integration not ready yet: Error communicating with API: 500, message='INTERNAL SERVER ERROR', url=URL('https://usapi.gizwits.com/app/bindings'); Retrying in background

PieDamen commented 9 months ago

Same here, App seems to be working correctly.

Logger: custom_components.bestway.coordinator Source: helpers/update_coordinator.py:233 Integration: Bestway (documentation, issues) First occurred: September 28, 2023 at 4:08:47 PM (3 occurrences) Last logged: 11:00:32 AM

Error fetching Bestway API data: Error communicating with API: Error fetching Bestway API data: Error communicating with API: 500, message='INTERNAL SERVER ERROR', url=URL('https://usapi.gizwits.com/app/bindings')

tried in postman and seems to be working here, getting this response: URL: https://usapi.gizwits.com/app/bindings

{"devices": [{"protoc": 3, "ws_port": 8080, "port_s": 8883, "gw_did": null, "host": "usm2m.gizwits.com", "sleep_duration": 3600, "port": 1883, "mcu_soft_version": "P182D102", "product_key": "REDACTED", "state_last_timestamp": 1695979943, "role": "owner", "is_sandbox": false, "type": "normal", "product_name": "Airjet", "is_disabled": false, "mcu_hard_version": "P180D100", "wifi_soft_version": "0402003A", "dev_alias": "SPA", "mesh_id": null, "is_online": true, "dev_label": [], "wss_port": 8880, "remark": "21", "did": "REDACTED", "mac": "REDACTED", "passcode": "REDACTED", "wifi_hard_version": "00ESP826", "is_low_power": false}]}

bsanya89 commented 9 months ago

I have exactly the same issue. Any workaround exist for this problem? From the app I am able to control the spa.

paducz commented 9 months ago

It is working now. Somewhere was more than 5 hours outage...closing this issue

cdpuk commented 9 months ago

FWIW the difference in behaviour is because the official app uses a different method of communication, so it's possible for that to work while the API used by the integration is having problems.