A webhook is a method of augmenting or altering the behavior of a web page, or web application, with custom callbacks. These callbacks may be maintained, modified, and managed by third-party users and developers who may not necessarily be affiliated with the originating website or application.

To setup an Ubidots Webhook go the the Event tab into your Ubidots account:

Then create a new event selecting "+ Add event" to setup the Webhook:

Select the Device and the Variable with which you want to configure the conditions for your Webhook.  

Ubidots lets you setup the conditions of the Event in three ways:
Value, Has been Inactive, or Location:

  • Value
  • Has been inactive
  • Location

Then, select the WebHook event to interact with a 3rd party website:

Now you just need to setup a WebHook for your application.

The parameters required in the setup of a WebHook are:

  • URL: This is the server endpoint that will receive the webhook payload
  • Method: This is the HTTP method with which the payload will be handled. The methods allowed by Ubidots are:
  • Headers: Are used to differentiate between event types and payload identifiers. Webhooks can be delivered using different content-types:

1.- The application/json content type will deliver the JSON payload directly as the body of the POST.

2.- The application/x-www-form-urlencoded content type will send the JSON payload as a form parameter called "payload".

To get a better idea how to setup a WebHook, please reference the articles below:

Did this answer your question?