
Batch-redeliver and ping Origin webhooks via the API
Recover missed deliveries with POST https://api.cursor.com/v1/origin/app/webhook/deliveries:batchRedeliver, and verify a receiver during setup with POST https://api.cursor.com/v1/origin/app/webhook/pings. Official reference: Origin API → Batch Redeliver Webhook Deliveries / Ping Webhook.
Origin is in Early Beta and subject to change. Authenticate with an app JWT. Availability: Early Beta per the API overview.
Batch redeliver
Asks Origin to send deliveries again. The request means "ensure a send is in flight for each of these," not "add another send." It returns one result per unique input rather than failing the batch on a bad entry, so a single expired ID cannot block the rest of a recovery page.
A 202 means the sends are queued; delivery itself is asynchronous — poll List Webhook Deliveries for outcomes.
Request body
| Field | Required | Meaning |
|---|---|---|
deliveryIds |
yes | Deliveries to send again. At most 100 unique entries (matches the pageSize ceiling on List Webhook Deliveries). Duplicates are removed, keeping first-seen order. An empty list, or more than 100 unique entries, returns InvalidArgument (HTTP 400). |
curl --request POST \
--url 'https://api.cursor.com/v1/origin/app/webhook/deliveries:batchRedeliver' \
--header 'Authorization: Bearer YOUR_APP_JWT' \
--header 'Content-Type: application/json' \
--data '{
"deliveryIds": [
"whd_01k2ja2000e0080000000000j9"
]
}'
Response fields
| Field | Meaning |
|---|---|
results |
One entry per unique delivery ID. |
results[].deliveryId |
Requested stable delivery ID. |
results[].outcome |
queued when a send was created; already_in_flight when a send was already running (a success, not an error); not_found for unknown IDs, IDs older than the seven-day retention window, or namespaces where your app is no longer installed. |
Example:
{
"results": [
{
"deliveryId": "whd_01k2ja2000e0080000000000j9",
"outcome": "queued"
}
]
}
Typical recovery loop: list with delivered=false, collect delivery IDs (pages of up to 100), call batch redeliver, then poll List Webhook Deliveries until deliveredAt is set or you accept a hard failure.
Ping webhook
Sends a test delivery to the authenticated app's webhook URL and reports what the receiver answered. Use it while setting an app up instead of waiting for a real event.
The receiver sees the production shape: the same headers and v1ed signature, verifiable against Origin's signing keys, with webhook-event-type set to ping and a payload naming the app. A ping belongs to no installation, so the webhook-installation-id header and the envelope's installationId are both absent.
Origin sends the ping once, synchronously, and reports the outcome in the response. There are no retries. A ping is not a domain event: it never appears in List Webhook Deliveries and cannot be redelivered. A receiver that fails is reported in the response rather than as an HTTP error. An app with no webhook URL configured returns FailedPrecondition (HTTP 400).
Request body
Send an empty JSON object. The request takes no fields.
curl --request POST \
--url 'https://api.cursor.com/v1/origin/app/webhook/pings' \
--header 'Authorization: Bearer YOUR_APP_JWT' \
--header 'Content-Type: application/json' \
--data '{}'
Response fields
| Field | Meaning |
|---|---|
deliveryId |
The test delivery's webhook-id, matching the header the receiver saw. |
eventId |
Event ID inside the signed envelope. |
delivered |
True when the receiver answered with a 2xx before the delivery timeout. Always present. |
responseStatusCode |
HTTP status the receiver answered with, or 0 when no response arrived (connection failed or timed out). Always present. |
Example:
{
"deliveryId": "whd_01k2ja2000e0080000000000j9",
"eventId": "evt_01k2ja2000e0080000000000r5",
"delivered": true,
"responseStatusCode": 200
}
Base URL: https://api.cursor.com/v1/origin.