Skip to main content
POST
Create a webhook
This endpoint requires your private API key.
Once a webhook is created, events will be sent to it based on the criteria specified in the webhook. The data sent follows the Event schema and is sent as a JSON array in the POST request in the data field. Below is an example request body:

Body

application/json
url
string
required

The URL that the webhook will send events to.

Example:

"https://your-webhook-url.com"

enableBatching
boolean

Whether to enable batching for the webhook. Defaults to false.

Example:

true

eventTypes
string[]

The event types that the webhook will send. Defaults to ["*"] (all event types).

Example:
eventNames
string[]

The event names that the webhook will send. Defaults to ["*"] (all event names).

Example:
flatten
boolean

Whether to flatten the event data. This is useful for downstream systems that don't support nested data structures. Defaults to false.

Example:

true

Response

200 - application/json

The webhook has been successfully created. Requires private API key in Bearer token.

uuid
string
required

The UUID of the webhook. Automatically generated.

Example:

"123e4567-e89b-12d3-a456-426614174000"

url
string
required

The URL that the webhook will send events to.

Example:

"https://your-webhook-url.com"

enableBatching
boolean
required

Whether to enable batching for the webhook.

Example:

true

createdAt
string<date-time>
required

The date and time the webhook was created.

Example:

"2021-01-01T00:00:00.000Z"

eventTypes
string[]
required

The event types that the webhook will send. Use * to match all event types.

Example:
eventNames
string[]
required

The event names that the webhook will send. Use * to match all event names.

Example:
flatten
boolean
required

Whether to flatten the event data. This is useful for downstream systems that don't support nested data structures.

Example:

true