Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Smartlock: 502 Bad Gateway #200

Open
developerGM opened this issue Nov 19, 2024 · 11 comments
Open

Smartlock: 502 Bad Gateway #200

developerGM opened this issue Nov 19, 2024 · 11 comments

Comments

@developerGM
Copy link

From some days I have a problem with this nuki integration.
I have changed the router but I have connected to new Wifi the Nuki Bridge.
The nuki app works perfectly but in HA I have this log

Error while fetching list of devices via web API: Traceback (most recent call last): File "/config/custom_components/nuki_ng/nuki.py", line 439, in _update web_list = await self.api.web_list() ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/nuki_ng/nuki.py", line 297, in web_list resp = await self.web_async_json( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/nuki_ng/nuki.py", line 186, in web_async_json return await self.async_json( ^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/nuki_ng/nuki.py", line 41, in async_json raise HomeAssistantError(f"Http response for {response.request.url}: {response.status_code} {response.reason}") homeassistant.exceptions.HomeAssistantError: Http response for https://api.nuki.io/smartlock: 502 Bad Gateway

@KHOne23
Copy link

KHOne23 commented Nov 21, 2024

Same Problem here, State of Lock is wrong. Its open and shows locked. Started Yesterday
Edit after Restart WIFI Access Point it worked again

@developerGM
Copy link
Author

Yes, every day I see in the log many times become unavailable...than available again.
I have locked the internal IP on the router so I am sure that this not change.
I don't know why

@kvj
Copy link
Owner

kvj commented Nov 29, 2024

Based on the stack trace, it's not a device and/or integration issue, but a Nuki Web API endpoint availability. If Nuki Web API isn't stable these days, try to disable it (remove Web token from the configuration)

@developerGM
Copy link
Author

Ok I can disable in these days and remove webtoken, but I need to insert again with new token? or I can't use the integration for some days?

@kvj
Copy link
Owner

kvj commented Nov 29, 2024

The integration will work. Web API is only needed for the following:
image

@developerGM
Copy link
Author

Sorry, can you explain how do.
I open in ha the Nuki integration...and here I see 2 devices (Nuki and Nuki Web API)
click on Nuki Web API and disable all configuration switches?

@kvj
Copy link
Owner

kvj commented Nov 29, 2024

No, you need to remove the integration and add it again, leaving the web token field empty

@kvj
Copy link
Owner

kvj commented Nov 29, 2024

Well, if you don't have a Nuki bridge (I'm not aware of your setup) and Web API is the only option for you - then you're out of luck. I don't know what's happening to the Nuki Web infrastructure

@developerGM
Copy link
Author

Ok, I added integration using bridge token.
Let's see if it still loses connection
thanks

@limakilo-root
Copy link

Ok, I added integration using bridge token. Let's see if it still loses connection thanks

Post a feedback, if anything changes. I do run into the same issues.
TY

@developerGM
Copy link
Author

Confirm that with this modification it works.

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

No branches or pull requests

4 participants