API reference
Webhooks
Receive signed, retried email events (sent, delivered, delayed, bounced, complained, failed, received) at your own endpoints.
No operations match this filter.
/webhooksList webhook endpoints
List webhook endpoints
curl https://sendhq.cc/api/v1/webhooks \
-X GET \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"data": [],
"count": 0,
"eventTypes": [
"email.sent",
"email.delivered",
"email.delivery_delayed",
"email.bounced",
"email.complained",
"email.failed",
"email.received"
]
}/webhooksCreate a webhook endpoint
Subscribe an https URL to email events. Omit `events` to receive every event type. The response includes the signing secret (`whsec_…`). Each delivery is signed with the Standard Webhooks scheme (`webhook-id`, `webhook-timestamp`, `webhook-signature`) and retried up to 8 times over about 27 hours. Up to 10 endpoints per workspace.
curl https://sendhq.cc/api/v1/webhooks \
-X POST \
-H "Authorization: Bearer $SENDHQ_API_KEY" \
-H "Content-Type: application/json" \
-d '{"url":"https://example.com/webhooks/sendhq","events":["email.delivered","email.bounced"],"description":"Production"}'{
"id": "wh_…",
"url": "https://example.com/webhooks/sendhq",
"events": [
"email.delivered",
"email.bounced"
],
"status": "enabled",
"secret": "whsec_…"
}/webhooks/:idRetrieve a webhook endpoint and its secret
Retrieve a webhook endpoint and its secret
curl https://sendhq.cc/api/v1/webhooks/id_value \
-X GET \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"id": "wh_…",
"url": "https://example.com/webhooks/sendhq",
"events": [],
"status": "enabled",
"secret": "whsec_…"
}/webhooks/:idUpdate, enable, or disable a webhook endpoint
Update, enable, or disable a webhook endpoint
curl https://sendhq.cc/api/v1/webhooks/id_value \
-X PATCH \
-H "Authorization: Bearer $SENDHQ_API_KEY" \
-H "Content-Type: application/json" \
-d '{"status":"disabled"}'{
"id": "wh_…",
"status": "disabled"
}/webhooks/:idDelete a webhook endpoint and its delivery log
Delete a webhook endpoint and its delivery log
curl https://sendhq.cc/api/v1/webhooks/id_value \
-X DELETE \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"ok": true
}/webhooks/:id/rotate-secretRotate an endpoint signing secret
Rotate an endpoint signing secret
curl https://sendhq.cc/api/v1/webhooks/id_value/rotate-secret \
-X POST \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"id": "wh_…",
"secret": "whsec_…"
}/webhooks/:id/testSend a signed webhook.test event now
Send a signed webhook.test event now
curl https://sendhq.cc/api/v1/webhooks/id_value/test \
-X POST \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"delivery": {
"id": "msg_…",
"eventType": "webhook.test",
"status": "succeeded",
"attempts": 1
},
"ok": true
}/webhooks/:id/deliveriesList delivery attempts for an endpoint
List delivery attempts for an endpoint
curl https://sendhq.cc/api/v1/webhooks/id_value/deliveries \
-X GET \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"data": [],
"count": 0
}/webhooks/:id/deliveries/:deliveryIdRetrieve one delivery and its payload
Retrieve one delivery and its payload
curl https://sendhq.cc/api/v1/webhooks/id_value/deliveries/deliveryId_value \
-X GET \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"id": "msg_…",
"eventType": "email.delivered",
"status": "succeeded",
"attempts": 1,
"payload": {
"type": "email.delivered",
"created_at": "2026-10-29T12:00:00.000Z",
"data": {
"email_id": "em_…"
}
}
}/webhooks/:id/deliveries/:deliveryId/retryRetry a delivery now
Retry a delivery now
curl https://sendhq.cc/api/v1/webhooks/id_value/deliveries/deliveryId_value/retry \
-X POST \
-H "Authorization: Bearer $SENDHQ_API_KEY"{
"delivery": {
"id": "msg_…",
"status": "succeeded",
"attempts": 2
},
"ok": true
}