Here is my thing configuration (replace the xxxxxxxxxx with your thingId)
UID: httplistener:HttpListener:xxxxxxxxxx
label: Doorbell Webhook
thingTypeUID: httplistener:HttpListener
configuration:
jsonConfig: |-
{
"channels": [
{
"key":"user_id",
"kind": "STATE",
"state": "req.body.json.user_id"
},
{
"key":"event_type",
"kind": "STATE",
"state": "req.body.json.event_type"
},
{
"key":"device_id",
"kind": "STATE",
"state": "req.body.json.device_id"
},
{
"key":"home_id",
"kind": "STATE",
"state": "req.body.json.home_id"
},
{
"key":"home_name",
"kind": "STATE",
"state": "req.body.json.home_name"
},
{
"key":"camera_id",
"kind": "STATE",
"state": "req.body.json.camera_id"
},
{
"key":"event_id",
"kind": "STATE",
"state": "req.body.json.event_id"
},
{
"key":"subevent_id",
"kind": "STATE",
"state": "req.body.json.subevent_id"
},
{
"key":"snapshot_url",
"kind": "STATE",
"state": "req.body.json.snapshot_url"
},
{
"key":"vignette_url",
"kind": "STATE",
"state": "req.body.json.vignette_url"
},
{
"key":"session_id",
"kind": "STATE",
"state": "req.body.json.session_id"
},
{
"key":"push_type",
"kind": "STATE",
"state": "req.body.json.push_type"
}
]
}
Then I defined on https://dev.netatmo.com an app.
Set Redirect URI & Webhook URI to (also defined a port forwarding listen_port_webhook → openhab_external_listen_port on my router):
https://my_external_url:listen_port_webhook/httplistener/xxxxxxxxxx)
Additionally I had to configure the nginx proxy:
location = /httplistener/xxxxxxxxxx {
auth_basic off;
proxy_pass https://internal_openhab_uri:https_internal_openhab_port/httplistener/xxxxxxxxxx;
}