Webhooks Overview
Webhooks, introduced in Release 9.7, are able to trigger releases as a reaction to specific HTTP requests made by an external source. This can potentially reduce the load of Release, while also reducing the pressure on external systems caused by polling methods where release triggers had to actively make requests to the third party system.
The core components of Release webhooks are:
HTTP endpoints for Webhooks are event sources that listen to HTTP requests and publish events of type events.HttpRequestEvent
.
Events encapsulate the data flowing from HTTP endpoints for webhooks and into webhook event triggers and tasks.
Webhook event triggers and tasks are event consumers. They subscribe to an HTTP endpoint for webhooks, and when a matching event arrives they execute their predetermined action.
Webhook event triggers create a release from a Template, like other trigger types.
Webhook event tasks will behave as gate tasks and transition to a Completed state.
HTTP endpoints for webhooks publish events to the messaging system's queue. Events in the messaging system's queue are picked up and dispatched to the webhook event triggers and tasks subscribed to the endpoint that published that event.
HTTP Endpoint for Webhooks
- HTTP endpoints for webhooks are Connections used to open a specific HTTP endpoint on Release.
- An HTTP endpoint for webhooks can be listening to either GET requests with no content, or POST requests with a JSON payload.
- HTTP endpoints for webhooks are not protected by the regular system authentication, but they can be protected with custom authentication methods.
- The external system that is configured to send webhook events to Release must be able to reach Release.
- There are various possible ways to expose your Release system to an external system, and which approach you choose will depend on your infrastructure.
For more information, see HTTP endpoint for Webhooks.
Webhook Event Triggers
Webhook event triggers are a class of release triggers that execute upon receiving an event from the event source to which they are subscribed.
When configuring a webhook event trigger, the user can define, for each required template variable, which value to use. It can be a manually entered value, a value from a folder variable, a value from a global variable, or the value of a property of the received event.
Refer to the full article regarding Webhook event triggers for more information.
Webhook Event Tasks
Webhook event tasks are a type of custom script tasks that wait for a matching event from the event source to which they are subscribed.
Webhook event tasks act as gate tasks for external business events.
Refer to the full article regarding Webhook event tasks for more information.
Webhook Messaging System
JMS (Java Message Service) support for Webhooks has been removed as of Release 25.3. Webhooks now rely on an internal queue mechanism. As a result, external queue systems such as RabbitMQ, ActiveMQ, and their configuration files are no longer used and will be ignored.
Event sources and webhook event triggers receive and publish events by default using an internal queue.
Webhook Samples
See the xlr-webhooks-samples repository for example webhook integrations in the form of as-code templates.