Getting started
APIs
Business SMS
Automation
Use cases
Create Trello Card for Voicemails Received
Send Call Data to Google Sheets
Slack Notifications from Call Events
Trigger SMS Messages from Your CRM
Webhooks allow Dash to send HTTP requests to a third-party web server, alerting that server of events occurring within Dash. Typically, events would be fired for new calls, when a call is answered, and when a call is finished, though other events will be added in the future.
The following Webhooks are available on all Dash accounts:
Webhooks are subscriptions to allowed events that, when the event occurs, the event data is sent to the URI set in the Webhook document.
Key | Description | Type | Default | Required |
---|---|---|---|---|
custom_data |
These properties will be added to the event and will overwrite existing values. | object() |
false |
|
enabled |
Is the webhook enabled and running | boolean() |
true |
false |
hook |
The trigger event for a request being made to 'callback_uri'. | string() |
true |
|
http_verb |
What HTTP method to use when contacting the server | `string('get' | 'post')` | post |
name |
A friendly name for the webhook | string() |
true |
|
retries |
Retry the request this many times (if it fails) | integer() |
2 |
false |
uri |
The 3rd party URI to call out to an event | string() |
true |
Here's what you can expect to receive when a webhook fires to your server:
Base Payload
Most of these fields should be present on all payloads.
Hook Specific
{
"data":{
"name":"Missed Call",
"hook":"notifications",
"include_subaccounts":false,
"http_verb":"get",
"retries":4,
"uri":"<https://hooks.zapier.com/hooks/catch/591668/xlwslm/>",
"type":"account",
"action":"doc_created",
"custom_data":{
"type":"missed_call"
},
"enabled":true,
"include_internal_legs":true,
"id":"51840ffc8bde832a1f5477def32cd665"
}
}
{
"data":{
"name":"Missed Call",
"hook":"notifications",
"include_subaccounts":false,
"http_verb":"get",
"retries":4,
"uri":"<https://hooks.zapier.com/hooks/catch/591668/xlwslm/>",
"type":"account",
"action":"doc_created",
"custom_data":{
"type":"missed_call"
},
"enabled":true,
"include_internal_legs":true,
"id":"51840ffc8bde832a1f5477def32cd665"
}
}
Creates a webhook using parameters passed in the payload.
Method: PUT
<https://public-api.virtualpbx.com:8443/v2/accounts/{{account_id}>}/webhooks
{
"data": {
"name": "My New Webhook",
"uri": "<http://my.server.net>",
"http_verb": "post",
"hook": "channel_destroy",
"retries": 4
}
}
List all webhooks on the account. Any webhooks with disable_reason, in summary, have been auto-disabled.
Method: GET
<https://public-api.virtualpbx.com:8443/v2/accounts/{{account_id}>}/webhooks
{
"data": {
"name": "Main Blacklist",
"numbers": {
"+14154846048": {}
}
}
}
Edit a webhook with any changes passed in the payload.
Method: POST
<https://public-api.virtualpbx.com:8443/v2/accounts/{{account_id}>}/webhooks/{{webhook_id}}
{
"data": {
"enabled": true,
"retiees": 4
}
}
Delete a webhook. This is permanent and unrecoverable.
Method: DELETE
<https://public-api.virtualpbx.com:8443/v2/accounts/{{account_id}>}/webhooks/{{webhook_id}}