Skip to content
Docs

Deliveries

Replay a delivery

POST /v1/webhook/deliveries/{id}/replay sends a message again with fresh tries.

Overview

POST/v1/webhook/deliveries/{id}/replay

Sends a message again right away with a fresh set of tries. Use it after fixing your endpoint, for a message that was not sent because credits ran out, or to resend one your server lost. It works on delivered, failed, and dead deliveries.

The message keeps the same event id, so your idempotency check still applies. It costs 1 credit when your server accepts it, like any message. Replaying a message that was already delivered charges it again.

Request

Request
curl -sS -X POST "https://webhooks.gray3.io/v1/webhook/deliveries/whdlv_Zp41/replay" \
  -H "X-Gray-Project-Id: proj_your_project_id" \
  -H "Authorization: Bearer gray_whk_your_webhook_key"

Response

The delivery, now pending, in the same shape as in the list.

HTTP 200 — success envelope wraps the payload in data.

json
{
  "data": {
    "id": "whdlv_Zp41…",
    "eventId": "base:0x6f1e…c2a9:41:token_transfer:whsub_7Qm2…",
    "chainId": "base",
    "category": "token_transfer",
    "stage": "confirmed",
    "address": "0x8ba1f109551bD432803012645Ac136ddd64DBA72",
    "status": "pending",
    "attempts": 0,
    "nextAttemptAt": "2026-10-16T10:02:40.000Z",
    "createdAt": "2026-10-16T09:31:12.081Z"
  }
}

Errors

Errors use HTTP { "error": { "code", "message", "retryable" } }. Branch on code, not the message text.

CodeHTTPWhen
not_found404No delivery with this id in the project
conflict409The delivery is waiting to be sent or being sent right now
json
{
  "error": {
    "code": "not_found",
    "message": "Human-readable detail (may be sanitized).",
    "retryable": false
  }
}