Overview
Webhooks are HTTP callbacks that notify your application when specific events occur in the DAL system. Instead of polling our API for updates, you can register a webhook endpoint to receive instant notifications.Available Events
The list of supported DAL webhook events is available here.Setting Up Webhooks
1. Configure Your Endpoint
First, you need to set up a webhook endpoint in your application that can receive HTTP POST requests. Your endpoint should:- Accept JSON payloads
- Return HTTP 200 status for successful processing
- Handle the handshake challenge (see below)
- Process webhook events within 5 seconds
2. Register with DAL
Contact your DAL administrator to register your webhook endpoint. You’ll need to provide:- Webhook URL: The HTTPS endpoint where you want to receive webhooks
- Shared Secret: A secret key used for HMAC signature verification
- Tenant Name: Your organization’s tenant identifier
3. Handle the Handshake
When you register a webhook, DAL will send a handshake event to verify your endpoint is working. Your endpoint must:- Receive the handshake event
- Verify the HMAC signature (see Security section)
- Return the challenge string in the response
Webhook Statuses
DAL tracks the status of your webhook integration to ensure reliable delivery of events. Understanding webhook statuses helps you monitor the health of your integration and troubleshoot issues.Available Statuses
Active
Status:Active
When your webhook is in Active status:
- Webhook events are being sent to your endpoint normally
- All configured events (EntityStatusUpdate, MonitoredEntityUpdate, etc.) will be delivered
- Handshake verification is passing
- Your endpoint is responding successfully to webhook requests
Paused
Status:Paused
When your webhook is in Paused status:
- Webhook events are not being sent to your endpoint but are being tracked by our system
- Events are queued and will be dispatched on your demand when the status returns to
Active - This status is automatically set by DAL when issues are detected
- This status indicates that handshake verification is failing or webhook delivery is consistently failing
- Handshake Failures: After 3 consecutive handshake failures, DAL automatically pauses your webhook to prevent further failed attempts
- Delivery Failures: After 5 consecutive failed webhook delivery attempts, DAL automatically pauses your webhook
Active, queued events will be retried on your demand, not automatically.
Disabled
Status:Disabled
When your webhook is in Disabled status:
- Webhook events are not being sent to your endpoint nor tracked
- This status is manually set by a DAL administrator or when you are newly onboarded to Dal and did not set up webhooks yet
- Events are not queued while disabled
Status Transitions
Webhook statuses can transition based on system behavior and administrative actions:Automatic Transitions
-
Active → Paused:
- Occurs automatically when handshake verification fails 3 consecutive times
- Occurs automatically when webhook delivery fails after 5 attempts
- Events are queued but not dispatched
-
Paused → Active:
- Occurs automatically when a handshake verification succeeds after being paused
- Failed handshake counter is reset to 0
- Queued events will be retried once status becomes Active [ On Demand ]
Manual Transitions
-
Any Status → Disabled:
- Set manually by DAL administrators
- Used to completely stop webhook delivery
- Events are not queued while disabled
-
Disabled → Active:
- Set manually by DAL administrators
- Used to enable webhook delivery after setting up your intergration or after maintenance if was turned off
-
Paused → Disabled:
- Set manually by DAL administrators
- Used when you want to stop queuing events while paused
Understanding Status Behavior
When Webhook is Active:- All events are delivered immediately
- Failed deliveries are retried up to 5 times
- Handshake verification runs periodically to ensure endpoint health
- Events are queued but not delivered
- Failed handshake counter tracks consecutive failures
- Once handshake succeeds, status automatically returns to Active and queued events can be dispatched as per your request
- Maximum of 3 consecutive handshake failures triggers Paused status
- No events are delivered or queued
- Status must be manually changed by administrator
- Used for maintenance or when you want to completely stop webhook delivery
Monitoring Your Webhook Status
You can check your webhook status programmatically using the Get Webhook Status API endpoint, or contact your DAL administrator. They can:- View your current webhook status
- Check failed handshake counts
- Review webhook delivery logs
- Manually change your webhook status if needed
Security
HMAC Signature Verification
All webhook requests include an HMAC signature in thex-signature header. You must verify this signature to ensure the request came from DAL.
Signature Generation:
Testing Your Integration
1. Test Webhook Endpoint
Use the integration test endpoint to verify your webhook is working:IntegrationTestUpdate event to your registered webhook URL.
2. Verify Handshake
When you register your webhook, DAL will automatically send a handshake event. Make sure your endpoint:- Receives the handshake
- Verifies the signature
- Returns the correct response format
Best Practices
1. Idempotency
Webhook events may be delivered multiple times. Implement idempotency in your webhook handler to avoid processing the same event twice. Example:2. Error Handling
Always return HTTP 200 for successful processing, even if you encounter errors. Log errors internally and handle them appropriately.3. Timeout Handling
Process webhook events quickly. DAL has a 5-second timeout for webhook responses.4. Logging
Log all webhook events for debugging and audit purposes:Troubleshooting
Common Issues
- Invalid Signature: Ensure you’re using the correct shared secret and computing the HMAC signature properly.
- Handshake Failure: Make sure your endpoint returns the exact challenge string in the handshake response.
- Timeout Errors: Process webhook events quickly and return a response within 5 seconds.
-
Missing Headers: Ensure your endpoint can receive the
x-signatureheader.
Debug Mode
Enable debug logging in your webhook handler to troubleshoot issues:Support
If you encounter issues with webhook integration:- Check the webhook test endpoint to verify connectivity
- Review your signature verification implementation
- Ensure your endpoint handles all required event types
- Contact your DAL administrator for assistance
API Reference
Test Webhook Endpoint
POST/crm/webhook/test
Triggers an integration test webhook event.
Headers:
x-tenant: Your tenant nameContent-Type: application/json
Health Check
GET/crm/webhook/health
Check if the webhook service is running.
Response:
Get Webhook Status
GET/crm/webhook/status
Retrieve the current webhook status for your tenant. This endpoint allows you to check whether your webhook integration is Active, Paused, or Disabled.
Headers:
x-tenant: Your tenant namex-api-key: Your API key
Active- Webhooks are being sent normallyPaused- Webhook delivery is temporarily paused (events are queued)Disabled- Webhook delivery is disabled (events are not queued)
- Monitor webhook integration health
- Troubleshoot webhook delivery issues
- Verify webhook status after configuration changes