Skip to main content
POST
/
api
/
webhooks
Register a webhook endpoint
curl --request POST \
  --url https://mag3nt.com/api/webhooks \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "url": "https://api.acme.com/hooks/mag3nt",
  "description": "<string>"
}
'
{
  "id": "wh_3b9fe670abcdef...",
  "url": "<string>",
  "description": "<string>",
  "status": "ACTIVE",
  "secret": "whsec_1a2b3c4d5e6f...",
  "note": "<string>"
}

Authorizations

Authorization
string
header
required

API key prefixed with 'Bearer sx_live_...'

Body

application/json
url
string<uri>
required

HTTPS endpoint that will receive events

Example:

"https://api.acme.com/hooks/mag3nt"

description
string

Optional label for this webhook

Response

Webhook registered (secret shown once)

Returned ONLY when a webhook is created. The secret is used to verify the X-mag3nt-Signature header on delivered events and cannot be retrieved again.

id
string
Example:

"wh_3b9fe670abcdef..."

url
string<uri>
description
string
status
string
Example:

"ACTIVE"

secret
string

HMAC signing secret (whsec_...). Store securely; shown once.

Example:

"whsec_1a2b3c4d5e6f..."

note
string