Webhooks
QStash Email Webhook
- Endpoint:
POST /api/qstash/send-email - Purpose: Receives messages from Upstash QStash and sends emails via AWS SES.
- Auth: Validates
Upstash-SignaturewhenQSTASH_VERIFY=true. - Environment:
QSTASH_TOKEN(publisher)QSTASH_CURRENT_SIGNING_KEY,QSTASH_NEXT_SIGNING_KEY(receiver)QSTASH_VERIFY=trueto enforce signature verification
{
"recipient": { "email": "user@example.com", "name": "User", "unsubscribeToken": "...optional" },
"campaignId": "campaign-id",
"site": { "subject": "Subject line" },
"branding": { "siteName": "Your Site", "siteUrl": "https://your.site", "logoUrl": "https://...", "supportEmail": "support@your.site" },
"featuredProducts": [{ "name": "Product", "url": "https://..." }],
"events": [{ "title": "Event", "date": "2025-01-01" }]
}