---
title: "Replay a settled webhook delivery"
description: "PubNio API webhooks.replayDelivery: replay a settled webhook delivery. Request fields, examples in five clients, errors, and idempotency."
---

> Documentation Index
> Fetch the complete documentation index at: https://pubnio.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Replay a settled webhook delivery

Replay a settled webhook delivery with [`POST /api/v1/workspaces/{workspaceId}/webhook-endpoints/{endpointId}/deliveries/{deliveryId}/replay`](https://pubnio.com/api/v1/docs#tag/webhooks/POST/api/v1/workspaces/{workspaceId}/webhook-endpoints/{endpointId}/deliveries/{deliveryId}/replay). Requires a signed-in workspace owner, in the web app or the CLI; API keys are not accepted and MCP cannot call it.

## Request

Resets a delivered, failed, or cancelled delivery to pending with zero attempts and queues it for the dispatcher. A pending or sending delivery returns 409.

| Parameter     | In   | Type | Required |
| ------------- | ---- | ---- | -------- |
| `workspaceId` | path | UUID | Yes      |
| `endpointId`  | path | UUID | Yes      |
| `deliveryId`  | path | UUID | Yes      |

## Response

- HTTP 202: `WebhookDelivery` with `id`, `workspaceId`, `endpointId`, `eventId`, `eventType`, `status`, `attemptCount`, `createdAt`, `nextAttemptAt`, `lastAttemptAt`, `lastHttpStatus`, `lastError`, `completedAt`.
  - `eventType`: `post.delivery.published`, `post.delivery.provider_draft`, `post.delivery.failed`, `post.delivery.unresolved`, `post.delivery.cancelled`, `post.scheduled`, `post.published`, `post.partial`, `post.failed`, `post.cancelled`, `inbox.message.received`, `inbox.comment.received`, `inbox.review.new`, `inbox.review.updated`, `inbox.review.deleted`, `inbox.review.restored`, `inbox.review.replied`, `inbox.mention.received`, `inbox.message.sent`, `inbox.message.delivered`, `inbox.message.read`, `inbox.message.edited`, `inbox.message.deleted`, `inbox.reaction.received`, `inbox.referral.received`, `inbox.conversation.started`, `analytics.post.synced`, `analytics.account.synced`, `ads.operation.succeeded`, `ads.operation.failed`, `ads.campaign.activated`, `ads.campaign.paused`, `ads.budget.changed`, `ads.kill_switch.activated`, `ads.lead.received`, `ads.campaign.status_changed`, `ads.ad_group.status_changed`, `ads.ad.status_changed`, `ads.ad_account.status_changed`, `ads.ad.review.approved`, `ads.ad.review.rejected`, `ads.sync.failed`, `ads.sync.recovered`, `ads.initial_sync.completed`, `schedule.assignment.changed`, `account.connected`, `account.disconnected`, `account.permissions_changed`, `account.restricted`, `account.recovered`, `billing.subscription.updated`, `billing.credit.topped_up`, `billing.credit.low`, `billing.spend_cap.reached`, `billing.invoice.payment_failed`, `billing.subscription.duplicate_refunded`, `webhook.test`
  - `status`: `pending`, `sending`, `delivered`, `failed`, `cancelled`

The [OpenAPI document](https://pubnio.com/api/v1/openapi) has each field's type.

## Examples

### TypeScript

```ts
const delivery = await workspace.webhooks.replayDelivery(
  endpointId,
  deliveryId,
);
```

Create this client with a signed-in person's `accessToken`, not an `apiKey`.

### Python

The Python SDK authenticates with a workspace API key, which this operation does not accept, so it has no method for it.

### cURL

```sh
curl -X POST "https://pubnio.com/api/v1/workspaces/$WORKSPACE_ID/webhook-endpoints/$ENDPOINT_ID/deliveries/$DELIVERY_ID/replay" \
  -H "Authorization: Bearer $PUBNIO_TOKEN"
```

### CLI

```sh
pnio webhooks replay-delivery "$ENDPOINT_ID" "$DELIVERY_ID"
```

### MCP execute

```js
async () => {
  const endpointId = "<endpointId>";
  const deliveryId = "<deliveryId>";
  const response = await codemode.request({
    method: "POST",
    path: `/api/v1/workspaces/${codemode.workspaceId}/webhook-endpoints/${endpointId}/deliveries/${deliveryId}/replay`,
  });
  return response.data;
};
```

## Errors

- [`webhook-delivery-not-replayable`](https://pubnio.com/docs/problems/webhook-delivery-not-replayable/): HTTP 409, Webhook delivery not replayable

It also declares the problems [most operations](https://pubnio.com/docs/reference/#shared-problems) declare.

## Idempotency

No key, so a retried `POST` is not deduplicated. Read the current state before you retry.

## Limits

- API keys and MCP cannot call it. A signed-in person runs it from the CLI after `pnio auth login` or in the web app.

## Related

- [Webhooks operations](https://pubnio.com/docs/reference/#webhooks)
- [Webhooks](https://pubnio.com/docs/webhooks/)
- [Webhook events](https://pubnio.com/docs/webhook-events/)

Source: https://pubnio.com/docs/reference/webhooks-replay-delivery/index.mdx
