Webhook Payload Formats
Reference for the inbound webhook payloads sent by Resend and SendGrid when your domain receives an email.
Resend Inbound Webhook
Resend sends inbound emails as JSON with Svix signature verification.
Headers
svix-id: msg_abc123
svix-timestamp: 1234567890
svix-signature: v1,g0hM9SsE+OTPJTGt/...
Content-Type: application/jsonPayload
{
"type": "email.received",
"created_at": "2025-01-15T10:30:00Z",
"data": {
"email_id": "em_abc123",
"from": "sender@example.com",
"to": "inbox@your-domain.com",
"subject": "Hello World",
"text": "Plain text body",
"html": "<p>HTML body</p>"
}
}Authentication Methods
- Svix signature (primary) — Verified using the webhook's shared secret
- Bearer token (fallback) —
Authorization: Bearer <shared-secret> - Legacy header (fallback) —
x-webhook-secret: <shared-secret>
SendGrid Inbound Parse
SendGrid sends inbound emails as multipart/form-data.
| Field | Description |
|---|---|
| from | Sender (e.g., Name <email>) |
| to | Recipient address |
| subject | Email subject |
| text | Plain text body |
| html | HTML body |
| envelope | JSON with sender/recipients |
Authentication Header
x-webhook-secret: <shared-secret>
# or
Authorization: Bearer <shared-secret>Webhook URL Format
After creating a webhook in the dashboard, use these URLs in your email provider:
Resend: https://your-domain.com/api/webhooks/<token>/resend
SendGrid: https://your-domain.com/api/webhooks/<token>/sendgridThe <token> is auto-generated and shown after webhook creation.