Creates a new webhook endpoint. The response includes a signing secret that you should store securely - it will be used to verify that incoming webhooks are actually from Cobalt.
Example Request
curl -X POST https://api.usecobalt.com/v1/webhook \
-H 'Content-Type: application/json' \
-H 'client_id: ci_live_198908HJDKJSH98789OHKJL' \
-H 'client_secret: cs_live_9827hofdsklOYYHJLJh' \
-d '{
"webhook_url": "https://api.example.com/webhook"
}'
Example Response
{
"success": true,
"webhook_id": "wh_123456789",
"webhook_url": "https://api.example.com/webhook",
"webhook_secret": "whsec_abcdefghijklmnopqrstuvwxyz"
}
Store the webhook secret securely - you’ll need it to verify webhook signatures.
The URL where webhook events will be sent