Set up a HTTP Webhook integration

Created:
March 13, 2023
Updated:
September 18, 2024

The HTTP Webhook Integration allows FireTail to send alert and incident notifications to a HTTP endpoint, making it easy to connect with external systems, custom applications, or third-party services. You can customize the content of webhook notifications to fit your needs. When an alert or incident occurs, FireTail posts the relevant data to the specified webhook URL, automating alert handling and integrating seamlessly into your existing incident response workflows. To set up an integration:

1. Navigate to Integrations on the FireTail platform.

2. Click HTTP Webhook.

3. Enter the Required Details:

  • Name of Integration: Enter a unique name to identify this integration.
  • Secret Value: Enter the secret value used for authenticating the webhook.
  • Webhook URL: Enter your HTTPS endpoint where the alert notifications will be sent.

4. (Optional) You can also customize the payload, which is the content sent in the webhook notification. Tokens, which are placeholders embedded in the payload, dynamically insert relevant data such as alert details, timestamps and so on. You can edit these tokens to customize the information displayed in the notification. For a full list of tokens, go to Dynamic variables. Learn how to Customize notifications.

5. Click Submit to create the integration.

The integration is created and listed under the existing integrations tab You can now select this integration as a notification method when you create an alert or create an incident.

Verify the Webhook

You can verify the validity of your webhook by using Python. Use the script below:


import hmac
import hashlib

def verify_webhook(request_body, request_headers, webhook_secret):
    digester = hmac.new(bytes(webhook_secret, 'utf-8'), request_body, hashlib.sha512)
    calculated_signature = digester.hexdigest()
    if calculated_signature != request_headers.get('x-ft-sign', None):
        raise("Invalid webhook signature")
    return True