# Webhook Service Webhook delivery service with retry logic and dead letter queue. ## Features - Webhook registration and management - Event-based webhook delivery - Exponential backoff retry logic - Dead letter queue (DLQ) for failed deliveries - HMAC-SHA256 payload signing - Delivery attempt tracking ## API Endpoints - `POST /v1/webhooks` - Create webhook - `GET /v1/webhooks/:id` - Get webhook - `GET /v1/webhooks` - List webhooks - `PATCH /v1/webhooks/:id` - Update webhook - `DELETE /v1/webhooks/:id` - Delete webhook - `POST /v1/webhooks/:id/test` - Test webhook - `POST /v1/webhooks/:id/replay` - Replay webhooks - `GET /v1/webhooks/:id/attempts` - Get delivery attempts - `GET /v1/webhooks/dlq` - List DLQ entries - `POST /v1/webhooks/dlq/:id/retry` - Retry DLQ entry ## Retry Logic - Max retries: 3 - Exponential backoff: 1s, 2s, 4s - Failed deliveries moved to DLQ after max retries ## Webhook Signing Webhooks can be signed with HMAC-SHA256 using a secret: - Header: `X-Webhook-Signature` - Algorithm: HMAC-SHA256 - Secret: Provided during webhook creation ## Configuration - `REST_API_URL` - Main REST API URL - `KAFKA_BROKERS` or `NATS_URL` - Event bus connection - `DLQ_RETENTION_DAYS` - DLQ retention period (default: 30)