[APP][Pro] Nuki Direct

What happens if you call this URL from a device within the same network as your Nuki bridge?

https://api.nuki.io/discover/bridges

I’ll get back to you! @Phuturist
I get {“bridges”:[{“bridgeId”:841547821,“dateUpdated”:“2020-04-25T15:45:04Z”}],“errorCode”:0}

There is something wrong with that. It’s susposed to look like this:

{"bridges":[{"bridgeId":500008,"ip":"192.168.0.1","port":8080,"dateUpdated":"2018-08-29T17:57:52Z"}],"errorCode":0}

Did you enable the HTTP API in your Nuki Bridge?

1 Like

@Phuturist edit. I fiddled something around in my router and now it shows {“bridges”:[{“bridgeId”:841547821,“ip”:“192.168.178.45”,“port”:8080,“dateUpdated”:“2020-04-26T16:04:06Z”}],“errorCode”:0}

Is your Nuki on the same VLAN as Homey? If not, that is why it isnt working. If so there is something wrong with your Nuki bridge and cloud connection and you need to contact Nuki support about it. This is from the HTTP Bridge API documentation:

Calling the URL https://api.nuki.io/discover/bridges returns a JSON array with all bridges which
have been connected to the Nuki Servers through the same IP address than the one calling the URL
within the last 30 days. The array contains the local IP address, port, the ID of each bridge and the
date of the last change of the entry in the JSON array.

Example:

Copy

{
 "bridges": [
 {
 "bridgeId":2117604523,"ip":"192.168.1.50","port":8080,"dateUpdated":"2017-06-14T06:53:44Z"
 }
 ],
 "errorCode":0
}

Once a bridge has been discovered on the LAN the API can be activated and the API token retrieved
by calling the /auth command. The user has to confirm this request by pressing the button on the
bridge. For more details see the description of the /auth command.

Hi all,

Thanks for the app. Would love to use it, but I’m not even getting to the point of an added lock. Any ideas about this?

And when no error is shown it is searching for devices but says there are none found. Which is weird cause the lock is definitely connected to the bridge.

Did you follow the instructions and specifically these steps?

And if so, are you sure you are using the correct token to authenticate?

And now available in the Homey Community App Store!

1 Like

Yes, I did.
About the press; long press until the light starts coming on? Or one single short press? Not that it made a difference. I tried both.

About the correct token: How do I know that and where do I find the right token and change the token if it’s not right? Maybe I’m missing something but I haven’t read anything about checking for or changing a token.

Thanks for your help.

i got my nuki installed the first time. i installed app from the new community app store. htttp api was already enabled. first try i got a timeout (i think because my wifi is very slow) 2nd time i was connected via cellphone to homey and then it worked. i pressed multiple times long and short and then the nuki was shown.maybe this helps you

Unfortunately I cannot get it to work. Now it does search but I get a time-out from the network. No idea why. Sometimes it seems to connect but it says ‘no devices found’. I have a fully equiped smart home with no communication problems so a network problem seems unlikely. I see someone having the same issue above, with no solution, so I guess I can’t try anything else?

What do you see when you access https://api.nuki.io/discover/bridges from a device within the same LAN as your Nuki Bridge?

{“bridges”:[{“bridgeId”:965134910,“ip”:“192.168.2.30”,“port”:8080,“dateUpdated”:“2020-05-15T10:35:35Z”}],“errorCode”:0}

Wht do you see when you access ‘http://192.168.2.30/auth’ from a device in the same LAN after you pushed the button on the bridge?

Niets. Geen verbinding mogelijk.
Zou de bridge een probleem hebben? Hij werkt overigens met de Nuki app wel ok.

Sorry. English. Nothing. No connection possible.

Sorry, wrong URL, try: http://192.168.2.30:8080/auth

First few times nothing. Hence the time out I guess. Keeps loading.

Then a few times a 503 error.

And the last time this;
{“success”: false}

It worked! After many many times doing the same thing. :wink:

Don’t know how or why. But well… thanks for the help!

There may still be an issue with your Bridge causing my app to not function optimal. Error 503 indicates a problem with your Nuki Bridge. If you have the 2nd gen Bridge you should update it to the latest firmware.

I did. It has all the latest firmware. I’ll contact Nuki about it. It is a review sample for media so they’ll probably send a new one.

A side question; will you add open/closed possibilities like the Athom app in the near future?