Help

Webhooks

Webhook is a special type of trigger. Whereas other types of triggers ask periodically a given service whether there are new bundles placed at disposal, webhooks allow to send information from the service to Integromat as soon as there are new bundles available. If your scenario contains a webhook, you have the possibility to schedule the scenario to run Immediately. If you do so, your scenario will be executed immediately after Integromat receives new data.

Creating custom webhooks

Any application that is connected to Internet and allows to send HTTP requests can send webhooks to Integromat. To connect such an app to Integromat, add the Custom WebHook trigger from the Gateway package to your scenario. When setting the trigger,click on the Add button next to the Webhook field and enter a name for the new webhook.

PRO TIP: Once you create a webhook, you can use it in more than one scenario at the same time. Each scenario may contain different modules and have different schedule. Data are duplicated, that´s why the individual scenarios do not influence each other.

In the next step, you have to tell Integromat what structure the incoming data have. That´s what the data structure is for. To create a data structure, click on the Add button located in the Data stucture field. You have the option of creating it manually or using a built-in generator that will create the data structure based on sample data. For more information about data structures please read the Data structures section. If you create a data structure, Integromat will use it to validate incoming data and you can be absolutely sure that no unexpected data arrive into your scenario.

Once you create a webhook, you can click the Show button to display a unique URL at which Integromat listens. The data sent to this address are first validated and then passed on for processing to a scenario.

IMPORTANT: At the moment of delivering a webhook notification, there must be at least one scenario that listens for the webhook data. If the scenario is not active, the data are stored in the queue. Once you activate the scenario, all bundles waiting in the queue will be processed sequentially.

Supported incoming data formats

Integromat supports 3 formats of incoming data - Query String, Form Data and JSON. Integromat validates all incoming data against a selected data structure and then depending on the settings of the scenario, the data are either stored in the queue for processing or processed immediately.

If any data do not pass the validation, Integromat returns a 400 HTTP status code and specifies in the body of the HTTP response the reason why the incoming data failed the validation checks. If the validation of the incoming data succeeds, Integromat returns a '200 Accepted' status in response.

Incoming data examples

Query String

GET https://hook.integromat.com/yourunique32characterslongstring?name=Integromat&job=automate

Form Data

POST https://hook.integromat.com/yourunique32characterslongstring
Content-Type: application/x-www-form-urlencoded

name=Integrobot&job=automate

JSON

POST https://hook.integromat.com/yourunique32characterslongstring
Content-Type: application/json

{"name": "Integrobot", "job": "automate"}

Data processing in scenarios

Regardless of how you schedule your scenario, all incoming data are first saved in the queue. This is done because Integromat uses transaction processing to execute all scenarios. Thus, it may happen that a scenario terminates in its rollback phase and data will be added back to the queue. In such a situation, you have the possibility to fix the scenario and rerun it again. The data stored in the queue are counted into your storage space limit.

Queue states

In order to view a list of received incoming data, go to the Detail screen of a particular organization and click the Storage circle. The list shows for which scenarios the data were saved. The data can be deleted at any time.

IMPORTANT: Incoming webhooks data are always stored in the queue irrespective of the Data are confidential option settings. As soon as the data are processed in a scenario, they are permanently deleted from our systems.

Rate this article: