OpenFolia

Send a failed delivery again

POST
/webhooks/{webhookId}/deliveries/{deliveryId}/retry

Puts a failed delivery back to pending and sends it again with a full set of attempts, by the same rules as every delivery; its attempts so far stay counted. Only one of a webhook that is active, still sent its event and owned by whom it was made for. Answers the delivery. No body. Recorded as webhook.retry. Needs webhook.manage, and is recorded in the audit log (never a secret, never the URL’s path or query).

Authorization

bearer
headerAuthorizationBearer <JWT>

A service account's token (ccms_sat_…, issued by POST /service-accounts/{id}/tokens), or, for local use and demo mode, the server's shared CCMS_API_TOKEN.

Path Parameters

webhookId*string

The webhook’s ID (a UUID). One that names no webhook is 404.

deliveryId*string

The delivery’s ID (a UUID), of this webhook.

Header Parameters

X-Ccms-User?string

Demo mode only (CCMS_AUTH_MODE=demo): the user ID to act as. The bearer token is still required; without demo mode the header is refused (400).

Response Body

application/vnd.api+json
  1. response
data*

One event sent to one subscriber, with its attempts.

Example Request
curl -X POST 'http://localhost:3000/webhooks/string/deliveries/string/retry'
Example Response
{  "data": {    "type": "WebhookDelivery",    "id": "string",    "attributes": {      "event": "manual.released",      "idempotencyKey": "string",      "payload": {        "property1": null,        "property2": null      },      "status": "pending",      "attempts": -9007199254740991,      "lastAttemptAt": "2019-08-24T14:15:22Z",      "lastStatusCode": -9007199254740991,      "lastError": "http-status",      "deliveredAt": "2019-08-24T14:15:22Z",      "sentHeaders": [        "string"      ],      "createdAt": "2019-08-24T14:15:22Z"    },    "relationships": {      "webhook": {        "data": {          "type": "Webhook",          "id": "string"        }      }    }  }}