Managing Endpoints

Create, update, test, and delete registered webhook endpoints, inspect the account-wide delivery log, resend failures, and rotate your signing secret

Registered endpoints are account-level webhook destinations: each one has a URL, an optional event filter, and its own whsec_… signing secret. Everything on this page can also be done from the dashboard under Account → Webhooks.

All endpoints require your API key in the X-API-Key header.

  • Up to 10 registered endpoints per account.
  • An empty (or omitted) events filter subscribes to all events — see the event taxonomy.
  • URLs: HTTPS strongly recommended (http allowed), max 2048 characters, private/internal addresses rejected.

Manage endpoints

POSThttps://api.anakin.io/v1/webhooks

Create a registered endpoint.

Request Body

{
  "url": "https://your-app.com/hooks/anakin",
  "description": "Production receiver",
  "events": ["job.completed", "job.failed"]
}
ParameterTypeDescription
url requiredstringThe URL we POST deliveries to.
descriptionstringA label shown in the dashboard and API listings.
eventsstring[]Event filter. Empty or omitted = all events.

Response

201 Created
{
  "id": "9b1c22e4-…",
  "url": "https://your-app.com/hooks/anakin",
  "description": "Production receiver",
  "events": ["job.completed", "job.failed"],
  "isActive": true,
  "secret": "whsec_…",
  "createdAt": "2026-07-13T10:00:00Z"
}

The response includes the endpoint's signing secret (whsec_…) — copy it into your receiver to verify deliveries. Creating an endpoint beyond the limit of 10, or with an invalid URL, returns 400.


GEThttps://api.anakin.io/v1/webhooks

List your registered endpoints.

200 OK
{
  "endpoints": [
    {
      "id": "9b1c22e4-…",
      "url": "https://your-app.com/hooks/anakin",
      "description": "Production receiver",
      "events": ["job.completed", "job.failed"],
      "isActive": true,
      "createdAt": "2026-07-13T10:00:00Z"
    }
  ]
}

PATCHhttps://api.anakin.io/v1/webhooks/{id}

Update an endpoint. All fields are optional — only the fields you send change.

Request Body

{
  "events": ["job.completed", "job.failed", "monitor.change"],
  "isActive": true
}
ParameterTypeDescription
urlstringNew destination URL.
descriptionstringNew label.
eventsstring[]Replaces the event filter. Empty = all events.
isActivebooleanfalse pauses deliveries to this endpoint without deleting it.

Response

200 OK

Returns the updated endpoint. A missing or non-owned endpoint returns 404.


DELETEhttps://api.anakin.io/v1/webhooks/{id}

Delete an endpoint. Deliveries to it stop immediately.

200 OK
{ "success": true }

POSThttps://api.anakin.io/v1/webhooks/{id}/test

Send a webhook.test event to the endpoint so you can verify reachability and signature handling before real traffic — same as the dashboard's Test button.

200 OK
{
  "deliveryId": "d_7c0f31…",
  "httpStatus": 200,
  "success": true
}

httpStatus is the status your endpoint returned.


Delivery log

Every delivery attempt — to registered endpoints, to per-request webhook_urls, and for monitor alerts — is recorded in one account-wide log, retained for 30 days.

GEThttps://api.anakin.io/v1/webhooks/deliveries

List recent deliveries across your account, newest first.

Query Parameters

ParameterTypeDescription
endpointIdstringOnly deliveries to one registered endpoint.
eventstringFilter by event type (e.g. job.failed).
statusstringpending, success, failed, or exhausted.
jobIdstringDeliveries produced by one job.
limitnumberMaximum rows to return.

Response

200 OK
{
  "deliveries": [
    {
      "id": "d_7c0f31…",
      "endpointId": "9b1c22e4-…",
      "event": "job.completed",
      "jobId": "job_abc123xyz",
      "url": "https://your-app.com/hooks/anakin",
      "status": "success",
      "httpStatus": 200,
      "attempts": 1,
      "createdAt": "2026-07-13T10:00:06Z"
    }
  ]
}
FieldTypeDescription
idstringDelivery ID — equals the X-Anakin-Delivery-Id header.
endpointIdstring | nullThe registered endpoint, or null for per-request webhook_url deliveries.
eventstringThe event type delivered.
jobIdstring | nullThe job that produced the event, when applicable.
statusstringpending, success, failed, or exhausted (retries used up).
httpStatusnumber | nullHTTP status your endpoint returned.
attemptsnumberDelivery attempts so far.
errorstring | nullFailure reason, when failed.
nextAttemptAtstring | nullWhen the next retry is scheduled (while pending).

GEThttps://api.anakin.io/v1/webhooks/{id}/deliveries

Same response shape, scoped to one registered endpoint.


POSThttps://api.anakin.io/v1/webhooks/deliveries/{id}/resend

Re-send a failed or exhausted delivery. The body and signature are byte-identical to the original (only X-Anakin-Timestamp is fresh), and X-Anakin-Delivery-Id is unchanged — so your de-duplication keeps working. Also available from the dashboard.

200 OK
{ "success": true }

Signing secret

Your account's default signing secret signs per-request webhook_url deliveries. (Registered endpoints each have their own secret, returned at creation.)

GEThttps://api.anakin.io/v1/webhooks/signing-secret
200 OK
{ "secret": "whsec_…" }

POSThttps://api.anakin.io/v1/webhooks/signing-secret/rotate

Generate a new default signing secret. Subsequent per-request deliveries are signed with the new secret — update your receiver with the returned value immediately.

200 OK
{ "secret": "whsec_…" }

Event list

GEThttps://api.anakin.io/v1/webhooks/events

The machine-readable event taxonomy — useful for building event pickers.

200 OK
{
  "events": [
    "job.completed",
    "job.failed",
    "batch.completed",
    "batch.failed",
    "wire.job.completed",
    "wire.job.failed",
    "monitor.change",
    "ai.search.completed",
    "ai.search.failed",
    "webhook.test"
  ]
}

Code Examples

# Create an endpoint (the response includes its whsec_… secret)
curl -X POST https://api.anakin.io/v1/webhooks \
  -H "X-API-Key: your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://your-app.com/hooks/anakin",
    "description": "Production receiver",
    "events": ["job.completed", "job.failed"]
  }'

# Fire a test delivery
curl -X POST https://api.anakin.io/v1/webhooks/9b1c22e4-.../test -H "X-API-Key: your_api_key"

# Inspect recent failures
curl "https://api.anakin.io/v1/webhooks/deliveries?status=failed&limit=20" -H "X-API-Key: your_api_key"

# Resend one
curl -X POST https://api.anakin.io/v1/webhooks/deliveries/d_7c0f31.../resend -H "X-API-Key: your_api_key"

# Rotate the default signing secret (per-request webhook_url deliveries)
curl -X POST https://api.anakin.io/v1/webhooks/signing-secret/rotate -H "X-API-Key: your_api_key"