Webhooks
Webhooks let IvozProvider notify external HTTP services about call events in real time. Whenever a
subscribed event happens on a matching call, IvozProvider sends an HTTP POST request to the
configured endpoint with a customizable JSON payload.
Hint
Webhooks can be enabled per Brand basis via Features.
Configurable fields
- Name
Used to identify this webhook.
- Description
Optional free text describing the webhook purpose.
- URL
Endpoint that will receive the HTTP
POSTrequest every time a subscribed event is triggered.- Direction
Restricts the webhook to calls of a given direction:
Inbound: only incoming calls.
Outbound: only outgoing calls.
Both: incoming and outgoing calls (default).
Events
Each webhook subscribes to one or more call events. A POST request is sent every time a subscribed
event happens on a matching call:
- Start
Sent when a new call starts.
- Ringing
Sent when the destination starts ringing.
- Answer
Sent when the call is answered.
- End
Sent when the call ends.
- Update CLID
Sent when the caller line identification (CLID) is updated during the call.
Template
The body of the POST request is defined by the Template field: a valid JSON document where
{{placeholder}} marks are replaced with the actual call values before the request is sent.
Hint
A default template is provided when creating a new webhook. You can adapt it freely as long as the result is valid JSON.
Available placeholders
These are the placeholders that can be used in the template at brand level:
|
Event that triggered the request (start, ring, answer, end, updateClid). |
|
Event timestamp. |
|
Call-ID of the SIP dialog. |
|
Internal ID of the client involved in the call. |
|
Name of the client involved in the call. |
|
Internal ID of the involved DDI. |
|
Internal ID of the carrier used (outbound calls). |
|
Internal ID of the DDI provider used (inbound calls). |
|
Call direction (inbound/outbound). |
|
Caller number in E.164. |
|
Callee number in E.164. |
|
Name of the carrier used (outbound calls). |
|
Name of the DDI provider used (inbound calls). |
|
Webhook identifier. |
Assignment levels
Brand operators can define webhooks at two different levels:
- Client level
Configured in each client configuration (Webhooks section). Applies to every call of that client, regardless of the DDI involved.
- DDI level
Configured in a specific DDI. Applies only to calls of that DDI.
Hint
The available placeholders and events are the same at both levels; only the scope of matching calls changes.