webhooks.vapi() verifies the HMAC-SHA256 signature Vapi sends in x-vapi-signature on every request.
/trigger/vapi.ts
event.message.type.
Set up Vapi
- Start
trigger devor deploy, then copy the endpoint’s Webhook URL from the Webhooks page. - Choose Generate secret on the Trigger.dev endpoint and copy the value.
- In the Vapi Dashboard, open Integrations > Server Configuration and choose Add Custom Credential. Choose HMAC and set:
- Secret Key: the secret you generated
- Algorithm: SHA256
- Signature Header:
x-vapi-signature - Timestamp Header: leave empty
- Payload Format: the request body only, with no timestamp
- Set the webhook URL as the server URL on your assistant, phone number or Server Configuration, and attach the credential by its
credentialId. Vapi only sends the credential when the server URL comes from your saved configuration, not from an API request. - Send a test event from Vapi, or use the endpoint’s Test tab, and check the endpoint’s Deliveries tab. See Verify the connection if nothing arrives.

