List deliveries
Page through an endpoint’s delivery history — failures pipe straight into resend.
List webhook deliveries
One row per logical delivery — the latest attempt of each event sent to this endpoint — newest first, cursor-paginated. Each item carries the derived delivery state plus the webhook_id/event_id pair, exactly the shape Resend deliveries accepts: filter with status=failed, then pipe the items straight into resend.
GET /v3/webhooks/{id}/deliveries
Query parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
status | string (CSV) | Optional | Comma-separated delivery states to include: delivered, failed, pending, retrying. Omit for all states. |
since | ISO-8601 | Optional | Window start. Default: 24 hours ago; reaches back at most 90 days (earlier values are clamped). |
until | ISO-8601 | Optional | Window end. Default: now. |
cursor | string | Optional | Opaque pagination cursor from the previous response’s next_cursor. |
limit | integer | Optional | Results per page, 1–100. Default 25. |
Delivery states
delivered— your endpoint answered 2xx.retrying— the latest attempt failed but the automatic retry schedule is still running.failed— final: retries are exhausted or your endpoint refused with a permanent4xx. These are the resendable ones.pending— a manual resend is in flight.
Response
Returns { items, has_more, next_cursor, total_count }. Each item is { webhook_id, event_id, event, attempts, last_status, last_attempt_at, state } — event is the source event type, attempts counts organic retries plus manual resends, and last_status is the HTTP status of the latest attempt (null when it never completed: network error, timeout or in-flight). Pass next_cursor back as cursor for the next page; total_count is the full match count in the window. Endpoint-test attempts have no source event and are excluded.
Responses
| Status | Description |
|---|---|
200 | OK. Cursor-paginated delivery list, newest first. |
400 | Validation error — an unknown status value, a malformed timestamp, or limit out of range. |
401 | Missing or invalid API key. |
404 | No webhook with this id on your account. |
Code examples
# Failed deliveries of the last 7 days, resend-ready
curl -G https://api.wemail.io/v3/webhooks/9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c/deliveries \
-H "Authorization: Bearer afn_live_…" \
--data-urlencode "status=failed" \
--data-urlencode "since=2026-08-23T00:00:00Z" \
--data-urlencode "limit=50"
# Next page: pass next_cursor back as cursor
curl -G https://api.wemail.io/v3/webhooks/9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c/deliveries \
-H "Authorization: Bearer afn_live_…" \
--data-urlencode "status=failed" \
--data-urlencode "cursor=2026-08-29T08:11:02.000Z|evt_01J8ZQ3K9WVA7M2P"import { WemailClient } from "@wemailio/sdk";
const wemail = new WemailClient(process.env.WEMAIL_API_KEY);
// List failures, then pipe them straight into resend.
const page = await wemail.webhooks.listWebhookDeliveries({
id: "9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c",
status: "failed",
since: new Date("2026-08-23T00:00:00Z"),
limit: 50,
});
if (page.items.length > 0) {
await wemail.webhooks.resendWebhookDeliveries({
resendWebhookDeliveriesRequest: {
deliveries: page.items.map(({ webhookId, eventId }) => ({ webhookId, eventId })),
},
});
}import os
from datetime import datetime, timezone
from wemail import WemailClient, ResendWebhookDeliveriesRequest
wemail = WemailClient(api_key=os.environ["WEMAIL_API_KEY"])
page = wemail.webhooks.list_webhook_deliveries(
"9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c",
status="failed",
since=datetime(2026, 8, 23, tzinfo=timezone.utc),
limit=50,
)
if page.items:
wemail.webhooks.resend_webhook_deliveries(ResendWebhookDeliveriesRequest.from_dict({
"deliveries": [{"webhook_id": d.webhook_id, "event_id": d.event_id} for d in page.items],
}))<?php
$wemail = new \Wemail\WemailClient(getenv('WEMAIL_API_KEY'));
// listWebhookDeliveries($id, $status, $since, $until, $cursor, $limit)
$page = $wemail->webhooks()->listWebhookDeliveries(
'9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c', 'failed', '2026-08-23T00:00:00Z', null, null, 50
);wemail = Wemail::Client.new(api_key: ENV["WEMAIL_API_KEY"])
page = wemail.webhooks.list_webhook_deliveries(
"9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c",
status: "failed", since: "2026-08-23T00:00:00Z", limit: 50
)client, _ := wemail.NewClient(os.Getenv("WEMAIL_API_KEY"))
// Generated layer (client.API.*): pass the key in the context.
ctx := context.WithValue(context.Background(), wemail.ContextAccessToken, os.Getenv("WEMAIL_API_KEY"))
since, _ := time.Parse(time.RFC3339, "2026-08-23T00:00:00Z")
page, _, err := client.API.WebhooksAPI.
ListWebhookDeliveries(ctx, "9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c").
Status("failed").Since(since).Limit(50).Execute()
for _, d := range page.Items {
fmt.Println(d.EventId, d.State, d.Attempts)
}WemailClient wemail = new WemailClient(System.getenv("WEMAIL_API_KEY"));
// listWebhookDeliveries(id, status, since, until, cursor, limit)
WebhookDeliveryListPage page = wemail.webhooks().listWebhookDeliveries(
UUID.fromString("9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c"),
"failed", OffsetDateTime.parse("2026-08-23T00:00:00Z"), null, null, 50);
for (WebhookDelivery d : page.getItems()) System.out.println(d.getEventId() + " " + d.getState());var wemail = new WemailClient(Environment.GetEnvironmentVariable("WEMAIL_API_KEY"));
var page = await wemail.Webhooks.ListWebhookDeliveriesAsync(
Guid.Parse("9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c"),
status: "failed", since: DateTime.Parse("2026-08-23T00:00:00Z").ToUniversalTime(), limit: 50);
foreach (var d in page.Items) Console.WriteLine(quot;{d.EventId} {d.State}");{
"items": [
{
"webhook_id": "9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c",
"event_id": "evt_01J8ZQ3K9WVA7M2P",
"event": "bounced",
"attempts": 7,
"last_status": 500,
"last_attempt_at": "2026-08-29T08:11:02.000Z",
"state": "failed"
},
{
"webhook_id": "9b2f6c1e-4a8d-4f3b-9c7e-2d1a5b8e0f4c",
"event_id": "evt_01J8ZQ4T2XNC8R5D",
"event": "delivered",
"attempts": 3,
"last_status": 503,
"last_attempt_at": "2026-08-29T08:09:47.000Z",
"state": "retrying"
}
],
"has_more": true,
"next_cursor": "2026-08-29T08:09:47.000Z|evt_01J8ZQ4T2XNC8R5D",
"total_count": 132
}