HTTP Callback unstable

Hey guys,

I created a webhook in Home Assistant as described here:

This webhook works well, I can trigger it with ‘curl -d “” http://192.168.178.4/api/webhook/nuki_opener

I registered that webhook as callback within my Nuki Bridge (current firmware). When freshly registered everything works. Someone rings my door, the Opener tells the Bridge and the Bridge uses the callback to call my webhook.

But then suddenly this stops working and when I delete and re-register that webhook it is back working. And it looks like calling any Bridge api (log, callback:list) is also enough that it gets back working…

I currently do not know what the log says if it is in “not working” mode. Will check that next time. // Edit: the log shows the POST but it is not triggered against the webhook.

{"timestamp": "2020-06-07T09:02:36+00:00", "type": "HTTP-Post", "nukiId": "myID"},

And if I execute the curl command directly afterwards, the webhook is working as excepted.

Any ideas?

Best,
Dirk

So it is definitely the case that it stops working with the callback after a time. If I manually access the bridge (i.e. by calling /log) it is back working.

@Stephan can you help here?

Can you check if your Bridge already updated to the latest firmware?
Anyway if you could provide Bridge-logs from after it stopped working (with timestamp where you expected the callback) that would be helpful.

Yes it has the latest firmware, also Nuki Opener and Nuki Fob has latest firmware. Any hints how to get the logs?

@Stephan just a ping …

with the /log command quoted above (see also https://developer.nuki.io/page/nuki-bridge-http-api-1-12/4#heading--log
Would be helpful to compare with our testings regarding long-time stability of the Bridge API / callbacks.

Hi @Stephan

{"timestamp": "2020-10-10T09:23:21+00:00", "type": "HTTP-Log"},
{"timestamp": "2020-10-10T09:23:19+00:00", "nukiId": "XYZ", "type": "BLE-Disconnected", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:23:19+00:00", "nukiId": "XYZ", "type": "BLE-Disconnect", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:23:19+00:00", "nukiId": "XYZ", "type": "BLE-ConnectionTimeout"},
{"timestamp": "2020-10-10T09:23:14+00:00", "nukiId": "XYZ", "type": "BLE-CommandComplete", "pairIndex": 0},
{"timestamp": "2020-10-10T09:23:14+00:00", "nukiId": "XYZ", "type": "SSE-KeyturnerResponse", "pairIndex": 0, "bytes": 245},
{"timestamp": "2020-10-10T09:23:14+00:00", "nukiId": "XYZ", "type": "BLE-SendingSSE", "pairIndex": 0, "bytes": 56},
{"timestamp": "2020-10-10T09:23:14+00:00", "nukiId": "XYZ", "type": "BLE-TurnOnNotific", "pairIndex": 0},
{"timestamp": "2020-10-10T09:23:14+00:00", "nukiId": "XYZ", "type": "BLE-Connected", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:23:14+00:00", "type": "BLE-Connect", "macAddr": "XYZ"},
{"timestamp": "2020-10-10T09:23:14+00:00", "nukiId": "XYZ", "type": "BLE-Connect", "pairIndex": 0},
{"timestamp": "2020-10-10T09:23:14+00:00", "nukiId": "XYZ", "type": "SSE-KeyturnerRequest", "pairIndex": 0, "bytes": 56},
{"timestamp": "2020-10-10T09:23:11+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:22:52+00:00", "nukiId": "XYZ", "type": "BLE-Disconnected", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:22:52+00:00", "nukiId": "XYZ", "type": "BLE-Disconnect", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:22:52+00:00", "nukiId": "XYZ", "type": "BLE-ConnectionTimeout"},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "BLE-CommandComplete", "pairIndex": 0},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "SSE-KeyturnerResponse", "pairIndex": 0, "bytes": 237},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "BLE-AlreadyConnected", "pairIndex": 0},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "SSE-KeyturnerRequest", "pairIndex": 0, "bytes": 56},
{"timestamp": "2020-10-10T09:22:47+00:00", "type": "SSE-KeyturnerEventResp"},
{"timestamp": "2020-10-10T09:22:47+00:00", "type": "HTTP-Post", "nukiId": "XYZ"},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "SSE-KeyturnerEventReq"},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "BLE-ReadStates", "pairIndex": 0},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "BLE-TurnOnNotific", "pairIndex": 0},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "BLE-Connected", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:22:47+00:00", "type": "BLE-Connect", "macAddr": "XYZ"},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "BLE-Connect", "pairIndex": 0},
{"timestamp": "2020-10-10T09:22:47+00:00", "nukiId": "XYZ", "type": "BLE-StateChanged", "pairIndex": 0},
{"timestamp": "2020-10-10T09:22:41+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:22:11+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:21:41+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:21:10+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:20:41+00:00", "type": "HTTP-Log"},
{"timestamp": "2020-10-10T09:20:40+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:20:10+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:19:40+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:19:10+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:18:40+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:18:10+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:17:40+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:17:13+00:00", "type": "HTTP-Log"},
{"timestamp": "2020-10-10T09:17:09+00:00", "type": "HTTP-List"},
{"timestamp": "2020-10-10T09:16:47+00:00", "nukiId": "XYZ", "type": "BLE-Disconnected", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:16:47+00:00", "nukiId": "XYZ", "type": "BLE-Disconnect", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:16:47+00:00", "nukiId": "XYZ", "type": "BLE-ConnectionTimeout"},
{"timestamp": "2020-10-10T09:16:42+00:00", "type": "HTTP-Post", "nukiId": "XYZ"},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-ReadStates", "pairIndex": 0},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-Retry", "pairIndex": 0, "count": 1},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-TurnOnNotific", "pairIndex": 0},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-Connected", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:16:42+00:00", "type": "BLE-Connect", "macAddr": "XYZ"},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-Connect", "pairIndex": 0},
{"timestamp": "2020-10-10T09:16:42+00:00", "type": "BLE-EarlyDisconnect", "nukiId": "XYZ"},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-TurnOnNotific", "pairIndex": 0},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-Connected", "pairIndex": 0, "bleHandle": "0001"},
{"timestamp": "2020-10-10T09:16:42+00:00", "type": "BLE-Connect", "macAddr": "XYZ"},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-Connect", "pairIndex": 0},
{"timestamp": "2020-10-10T09:16:42+00:00", "nukiId": "XYZ", "type": "BLE-StateChanged", "pairIndex": 0}

I ring the door, leads to first HTTP-Post at 9:16:42 that is not working. Then I used ‘curl -d “” http://192.168.178.4/api/webhook/nuki_opener’ against Home Assistant to trigger the Home Assistan service manually and again ring the door with HTTP-Post at 9:22:47 and it is back working…

But I am not sure if this a Nuki or a Home Assistant Problem… Maybe you can point me into the right direction…

@Stephan I definitely need support here. The webhook on Home Assistant site is stable and running. Whenever I call it via curl it works as expected. But as already said the Nuki Bridge is not triggering this webhook. This leads to the situation that Nuki is not really working. How can we proceed here?

@Stephan :face_with_head_bandage: