Curae Platform
API referencePlatform Webhooks

Create a Platform webhook endpoint

Creates a webhook endpoint for the API key's customer account. The signing secret is returned only in this response.

POST
/api/platform/v1/webhook-endpoints

Creates a webhook endpoint for the API key's customer account. The signing secret is returned only in this response.

Authorization

platformApiKey
headerAuthorizationBearer <token>

Curae Platform API key using the format Bearer . Keys are opaque credentials such as cae_live_..., not JWTs.

Header Parameters

Idempotency-Key?string

Optional idempotency key to make this mutation safe to retry. Replays of the same (apiKey, key) within 24h return the original response.

Match^[A-Za-z0-9_-]+$
Lengthlength <= 255

Request Body

application/json
  1. body
url*string
Formaturi
eventTypes*array<|>

The event types the endpoint subscribes to. May be empty: a deletion-only endpoint, which receives only the event types every ACTIVE endpoint is always sent (connection.revoked, connection.expired and records.deleted), which need no subscription.

Items0 <= items

Response Body

Created webhook endpoint

application/json
  1. response
id*string
Formatuuid
resourceType*string
url*string
Formaturi
eventTypes*array<>

The event types the endpoint subscribes to. Empty for a deletion-only endpoint, which receives only the event types every ACTIVE endpoint is always sent.

Items0 <= items
status*string
Value in"ACTIVE""DISABLED""SUSPENDED"
consecutiveFailures*integer
Range0 <= value
lastDeliveryAttemptAt*string
Formatdate-time
lastSuccessfulDeliveryAt*string
Formatdate-time
createdAt*string
Formatdate-time
updatedAt*string
Formatdate-time
_version*string

Strong ETag-compatible version that changes only when the customer-visible configuration (url, eventTypes, status) changes. Operational fields (consecutiveFailures, lastDeliveryAttemptAt, lastSuccessfulDeliveryAt) mutate on every outbound delivery and do NOT affect _version, so conditional GET requests return 304 Not Modified for unchanged configuration even on busy endpoints.

_links*
signingSecret*string

Plaintext signing secret returned only once at endpoint creation.

Example Request
curl -X POST 'https://api.curaeai.com/api/platform/v1/webhook-endpoints' \  -H 'Content-Type: application/json' \  -d '{  "url": "http://example.com",  "eventTypes": []}'
Example Response
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "resourceType": "WebhookEndpoint",  "url": "http://example.com",  "eventTypes": [],  "status": "ACTIVE",  "consecutiveFailures": 0,  "lastDeliveryAttemptAt": "2019-08-24T14:15:22Z",  "lastSuccessfulDeliveryAt": "2019-08-24T14:15:22Z",  "createdAt": "2019-08-24T14:15:22Z",  "updatedAt": "2019-08-24T14:15:22Z",  "_version": "string",  "_links": {    "self": {      "href": "string"    }  },  "signingSecret": "string"}