benzman81 / homebridge-nukiio

Nuki.io support for Homebridge: https://github.com/nfarina/homebridge
GNU General Public License v3.0
42 stars 5 forks source link

Connection to Nuki bridge failed #68

Closed panthertom closed 3 years ago

panthertom commented 3 years ago

Hello,

Thanks for providing the PlugIn.

Unfortunately I (interested layman!) can't access the bridge. I have read the IP address from my Fritzbox and checked it in the Nuki App, the port is listed there as 8080. So the URL / address is http://192.168.178.67:8080

I also took the token from the Nuki App. This is the 6-digit token. (I also tried the long token from the Web Nuki.io - this does not work either)

The NukiID is the ID of the opener. I did not enter the ID of the bridge anywhere. The bridge is connected to the network via a Fritz Access Point (mesh mode).

  1. In the protocol I get the following message (XXXXXX stands for the token) Process lock action '3' for Nuki lock '1B335CDA' (instance id '0') on Nuki bridge 'http://192.168.178.67:8080'. 11/9/2020, 8:46:51 AM] [NukiBridge] Send request to Nuki bridge 'http://192.168.178.67:8080' on '/lockAction' with '{"token": "XXXXXX", "nukiId": "1B335CDA", "deviceType":2, "action": "3"}'. 11/9/2020, 8:46:53 AM] [NukiBridge] Request to Nuki bridge 'http://192.168.178.67:8080' finished with status code '200' and body '{"success": false}'. null 11/9/2020, 8:46:53 AM] [NukiBridge] An error occured processing open action. Will retry now... [11/9/2020, 8:46:56 AM] [NukiBridge] Process lock action '3' for Nuki lock '1B335CDA' (instance id '0') on Nuki bridge 'http://192.168.178.67:8080'. 11/9/2020, 8:46:56 AM] [NukiBridge] Send request to Nuki bridge 'http://192.168.178.67:8080' on '/lockAction' with '{"token": "XXXXXX", "nukiId": "1B335CDA", "deviceType":2, "action": "3"}'. 11/9/2020, 8:46:57 AM] [NukiBridge] Request to Nuki bridge 'http://192.168.178.67:8080' finished with status code '200' and body '{"success": false}'. null

  2. In the browser I get for the IP address

  1. I opened the port 8080 for the bridge on my fritzbox.
  2. The PlugIn is running on Homebridge on a Synology.
  3. Calling the mentioned link (http://your-nuki-bridge-url/list?token=your-nuki-api-token) does not work, for this I used web.Nuki.io and the Nuki App.

Thanks for your support and help.

Thomas

20201109 Nuki Bridge panthertom

benzman81 commented 3 years ago

If http://your-nuki-bridge-url:port/list?token=your-nuki-api-token Does not work, then you the plugin cant work, too. Did you activate the developermode for the bridge?

panthertom commented 3 years ago

Hello benzman81, Thanks for your reply.

as far as I've understood the Dev Mode is activated as shown in the APP screenshot.

If this is not enough let me know how to do this

The home bridge Settings are unchanged (DebugMode = OFF) Thanks for your support.

Regards Thomas

benzman81 commented 3 years ago

The plugin works with local bridge api that needs to be enabled in the bridge setting ( turn on developer mode). Nuki web api is not used here.

panthertom commented 3 years ago

Hi, sorry for the dump question: How to do this? I've already put all setting in the NUKI App to ON (see my screenshot).

There are no other settings...

Thanks for your support. Thomas

panthertom commented 3 years ago

This is the result for the link in chrome: 20201109 Nuki Bridge panthertom link

benzman81 commented 3 years ago

Oh sorry, my bad :-) didnt check above. That must be it, nothing more to do. Now if you cannot reach the bridge in your browser using http://192.168.178.67:8080/list?token=fPSpez, the something is wrong.

panthertom commented 3 years ago

OK this link works. Result is text: [{"deviceType": 0, "nukiId": 374504437, "name": "Eingangstüre", "firmwareVersion": "2.9.2", "lastKnownState": {"mode": 2, "state": 3, "stateName": "unlocked", "batteryCritical": false, "batteryCharging": false, "batteryChargeState": 100, "doorsensorState": 4, "doorsensorStateName": "door state unknown", "timestamp": "2020-11-09T16:48:03+00:00"}}, {"deviceType": 2, "nukiId": XXXXX, "name": "Gartentüre"}]

panthertom commented 3 years ago

I have to check the NUKI ID (XXXXX)

benzman81 commented 3 years ago

Can you sho me your config?

panthertom commented 3 years ago

Hi, have you received my config data? Please drop me a line. Or if you need more information Thanks for your support

benzman81 commented 3 years ago

No, no data of you config here.

benzman81 commented 3 years ago

Die Bridge URL (bridge_url) in der PluginConfig muss so lauten: http://192.168.178.67:8080 Ohne irgendwas dahinter.

panthertom commented 3 years ago

Du bist Mein Held! Kaum macht man es richtig - schon funktioniert's. Nochmals Danke für das PlugIn und die Unterstützung. Ich nehme jetzt meine Configuration wieder raus.

benzman81 commented 3 years ago

gern.