Webhooks5 min read•Audience: Developers
Webhooks & Event Lifecycle
Handle asynchronous lifecycle events, verify cryptographic signatures using Svix, and prevent duplicate deliveries.
Key Takeaways
- PostBrix verifies incoming webhook events using standard Svix cryptographic signatures (svix-id, svix-timestamp, svix-signature).
- Integrated deduplication prevents processing the same event multiple times.
- Handle workspace updates, template approval lifecycles, and export completion notifications.
Verifying Webhook Signatures#
All webhook requests include three Svix verification headers:
svix-id: Unique message ID.svix-timestamp: Timestamp of delivery.svix-signature: Cryptographic HMAC-SHA256 signature.
Use the official svix library in Node.js to verify payloads before processing:
code
typescript
Supported Webhook Events#
project.published: Triggered when a team member publishes a template to production.template.exported: Emitted when a batch HTML export completes.workspace.member_added: Emitted when permissions are updated.
Frequently Asked Questions
What is the retry schedule for failed webhook deliveries?
Failed deliveries (non-2xx response) are automatically retried up to 5 times using exponential backoff over a 24-hour window.
How do I test webhooks in a local development environment?
Use a tunneling tool like ngrok or the Svix CLI to forward incoming webhook requests to your localhost server.