Webhook
The Webhook trigger receives JSON and other data in the body of an HTTP POST request message.
For the Webhook to receive a JSON-formatted request body, you must configure the message schema to match the expected data (see Output Keys, below).
The Webhook trigger has two output ports. The success port (✔) can send a message if the trigger initiates successfully. The failure port (x) can send a message if the trigger fails to initiate.
Parameters
- Webhook URL: The URL of the webhook. This parameter is auto-generated when you save the workflow. Once generated, you can click the clipboard icon to copy.
Output Keys
See Also
Configuring the Webhook Schema
For the webhook to receive a JSON-formatted request body, you must configure the message schema to match the expected data, as follows:
- Under the Output Keys tab, click Import Webhook Keys from JSON.
- In the Import Webhook Keys from JSON dialog, enter a valid JSON schema, and click Parse.
The imported keys appear under "Webhook Keys", prefixed with the webhook parent property.
Other Keys
Key | Description |
---|---|
time | Event time |
source | Event type |
error.type |
(Failure port only) Error type:
|
error.message | (Failure port only) Error message |
message | (Success port only) Message content |
Working with non-JSON Data
In addition to JSON-formatted data, webhook triggers can receive text, xml, and other data. The following table explains how non-JSON data is formatted to output keys.
Content-Type |
Message Encoding |
---|---|
text/* | Remains in text to the message key. |
application/xml | Formatted as text to the message key. |
application/x-www-form-urlencoded | Formatted as text to the message key. |
application/* or other | Base64 to the message key. |