Subscribing
Managed over the REST API — per-endpoint detail in
API Reference → Webhooks. Scopes: webhooks:read to view,
webhooks:write to create, edit, enable and disable, and webhooks:delete to delete.
The admin center manages the same subscriptions. See Webhook Integrations for the click path — everything below works either way.
Create a subscription
curl -X POST https://api.account.telebroad.com/api/public/v1/webhooks \
-H "Authorization: Bearer $TB_KEY" \
-H 'Content-Type: application/json' \
-d '{
"name": "SMS to helpdesk",
"url": "https://example.com/telebroad/hook",
"type": "AccountSMS",
"enabled": true
}'
The fields you send in the request body:
| Field | Required | Notes |
|---|---|---|
name | yes | For your own reference. Max 255 characters. |
url | yes | http or https, must include a host. Max 1024 characters. |
type | yes | One event type. GET /webhooks/types lists the valid values. You'll receive this back as webhookType on each delivered event (except AccountRealTimeCalls). |
description | no | Free text. |
enabled | no | Defaults to false. |
Response: 201. The new subscription's path comes back in the response's
Location header — a standard HTTP header that points to a newly created resource
(here, /webhooks/{id}).
One type per subscription
Each subscription is for exactly one event type — there is no "all events" option. To receive more than one kind of event, create a separate subscription for each; to get both SMS and ended calls, for example, create two.
Those subscriptions can share the same URL. Each event we send you includes
a webhookType field that names which event it is, so when several arrive at one URL
your code can tell them apart — with one exception: AccountRealTimeCalls has no
webhookType. If you want real-time-calls alongside another event, give it its
own URL so you can still tell which is which.
An unknown type is rejected at create time rather than saved.
Turn delivery on and off
curl -X POST .../webhooks/2074/disable -H "Authorization: Bearer $TB_KEY"
curl -X POST .../webhooks/2074/enable -H "Authorization: Bearer $TB_KEY"
Disabling keeps the subscription and its settings but stops delivery. While it's off you won't be notified of anything that happens — and re-enabling does not catch you up on what you missed; you only receive events from that point onward.
Update a subscription
curl -X PATCH .../webhooks/2074 \
-H "Authorization: Bearer $TB_KEY" \
-H 'Content-Type: application/json' \
-d '{"url": "https://example.com/telebroad/hook/v2"}'
PUT and PATCH both merge — any field you leave out stays as it was. There
is no replace-everything variant. Unknown fields are rejected, so a typo like
"enable": true (instead of enabled) returns an error instead of being
silently ignored.
Delete a subscription
curl -X DELETE .../webhooks/2074 -H "Authorization: Bearer $TB_KEY"
Response: 204 with an empty body — the subscription is permanently deleted.
If you might want it back later, disable it instead;
deleting can't be undone.
Discover the types
curl .../webhooks/types -H "Authorization: Bearer $TB_KEY"
{ "data": ["AccountRealTimeCalls", "AccountEndedCalls", "UserEndedCalls", "AccountSMS", "AccountAITranscription"] }
Read the vocabulary from here rather than hardcoding it from this page.