regevbr / RaspiNukiBridge

Simple Nuki Bridge implementation using asyncio
MIT License
14 stars 3 forks source link

Invalid token #12

Open gonzzovela opened 1 year ago

gonzzovela commented 1 year ago

Hi,

THanks for add-on. Really cool as I have my HA close to the lock and it is a good way and simple to automate

I've gone throught all the process without problems but when installing the Nuki add-on, it does nto connect to the bridge.

Based on the logs of the bridge it looks like the token is not valid: "Invalid token. Please change token."

I get the token from the NukiBridge log:

then, I try to install the Nuki add-on and I enter: host 127.0.0.1 port: 8350 (defined in the configuration of the bridge) token: the one copied from the log

and the nuki add-on istallation fails, and I see on the bridge log these two lines: 2023-01-21 10:40:25.188|E|web_server.py:142|Invalid token. Please change token. 2023-01-21 10:40:25.225|E|web_server.py:142|Invalid token. Please change token.

I'm using: HA Supervised installed on Debian 11 HA 2022.12.3

The bridge seems to communicate well with the lock as I see on the logs the connection and state changes: 2023-01-21 10:41:25.340|I|nuki.py:221|Nuki: XX:XX:XX:XX, adapter: hci0, RSSI: -72 AdvertisementData(local_name='Nuki_XXXXXXX', manufacturer_data={ .....

Any guiadance on what the issue could be is appreciated.

Thanks!

hanshaider commented 1 year ago

Hi! I have exactly the same issue. Pairing worked like a charme, the bridge is communicationg with the lock (Nuki 3.0), but the error is 2023-02-01 10:58:34.891|E|web_server.py:142|Invalid token. Please change token. 2023-02-01 10:58:34.920|E|web_server.py:142|Invalid token. Please change token. when trying to setup the Nuki-Integration. Any ideas are very welcome! Thanks!

hanshaider commented 1 year ago

Sorry for the double post, but I found out, that the problem is probably NOT with the bridge...

When sending the API-calls directly from the browser to the bridge, the Lock works like a charme and no errors are thrown!

I keep on searching to solve this

cirolaferrara commented 1 year ago

When I try to connect official Nuki addon I have:

web_server.py:142|Invalid token. Please change token.

but with curl commands works:

# curl -s "http://192.168.1.249:8080/info?token=XXXX"

{"bridgeType": 2, "ids": {"hardwareId": 2887655684, "serverId": 2887655684}, "versions": {"appVersion": "0.1.0"}, "uptime": 4161, "currentTime": "2023-02-06T21:04:41Z", "serverConnected": false, "scanResults": [{"nukiId": "342a89e5", "type": 0, "name": "Nuki", "rssi": -91, "paired": true}]}

ardstuebck commented 1 year ago

Hi, i have the same issue with the Nuki-Integration: "Please change token"

gmendezg commented 1 year ago

Same problem.

http://192.168.0.199:8080/info?token=XYZ OK!

http://127.0.0.1:8080/info?token=XYZ OK!

Nuki integration Failed to connect!

LOG: 2023-02-24 16:32:27.777|E|web_server.py:142|Invalid token. Please change token. 2023-02-24 16:32:27.845|E|web_server.py:142|Invalid token. Please change token.

szger commented 1 year ago

Same here: web_server.py:142|Invalid token. Please change token.

itsyoshio commented 1 year ago

+1

gidi85c commented 3 months ago

+1