OpenFolia

Send a webhook a test event

POST
/webhooks/{webhookId}/test

Sends a signed ping event at once ({ type: "ping", idempotencyKey, occurredAt, data: { webhookId } }) and answers its delivery with the result (status succeeded or failed, lastStatusCode, lastError); it is in the log too. Sent as every delivery is (the address checked after resolving the host, the signature, no redirect, the timeout), also to a paused or disabled webhook, once: never retried, and never counted toward turning it off. While the receiver has an attempt in flight, waits after a failure, or its owner has as many in flight as allowed, it is 429 rate-limited with Retry-After, and nothing is sent. No body. Recorded as webhook.test. 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.

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/test'
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"        }      }    }  }}