Skip to main content
POST
/
v1
/
webhooks
Create a webhook
curl --request POST \
  --url https://api.ledger.so/v1/webhooks \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "url": "<string>",
  "events": [
    "<string>"
  ]
}
'
{
  "ok": true,
  "data": {
    "id": "<string>",
    "url": "<string>",
    "events": [
      "customer.created"
    ],
    "status": "<string>",
    "createdAt": "2023-11-07T05:31:56Z",
    "updatedAt": "2023-11-07T05:31:56Z"
  }
}

Authorizations

Authorization
string
header
required

Pass your API key as a Bearer token: Authorization: Bearer ld_live_...

Body

application/json
url
string<uri>
required

The URL to receive webhook events

events
string[]
required

List of event types to subscribe to

Response

Webhook created

ok
enum<boolean>
required
Available options:
true
data
object
required