How can I use dzVents to process a webhook?
Posted: Friday 01 February 2019 16:46
Hi,
I use a system which is able to send a json object (using a webhook) when something happens (in my case, the message is sent when a device comes within WiFi range). I would like to receive that in Domoticz and process the information with dZvents.
Basically the system performs a HTTP POST to a specific URL and posts the content of the json to the webserver.
I wrote a small piece of code doing a webrequest and used a callback function to process the result.
That works fine with a prior request, but now I only receive results, with NO prior trigger from within Domoticz/dzVents
Is it possible to write a piece of dzVents-code which is able to receive the json in the webhook?
Processing the JSON is not the issue, getting it into dzVents is what I can't achieve.
Any help is appreciated!
Regards,
Marcel
I use a system which is able to send a json object (using a webhook) when something happens (in my case, the message is sent when a device comes within WiFi range). I would like to receive that in Domoticz and process the information with dZvents.
Basically the system performs a HTTP POST to a specific URL and posts the content of the json to the webserver.
I wrote a small piece of code doing a webrequest and used a callback function to process the result.
That works fine with a prior request, but now I only receive results, with NO prior trigger from within Domoticz/dzVents
Is it possible to write a piece of dzVents-code which is able to receive the json in the webhook?
Processing the JSON is not the issue, getting it into dzVents is what I can't achieve.
Any help is appreciated!
Regards,
Marcel