Calls
Place an outbound call with a text-to-speech / IVR flow
place an outbound call that speaks text to the callee, plays hosted audio, and can collect keypad input and branch on it
post/calls
Request
- Base URLhttps://api.commpeak.com/portal
- URLhttps://api.commpeak.com/portal/calls
- AuthAPI key in header Authorization
Request body
Example request
{
"flow": [
{
"action": "say",
"text": "This is a call from CommPeak"
},
{
"action": "say",
"text": "A new incident has been created"
},
{
"action": "say",
"text": "To acknowledge press 1, to escalate press 2"
},
{
"action": "gather",
"callback_url": "https://demo.example.com/dtmf",
"num_digits": 1,
"on_digit": {
"1": "acknowledged",
"2": "escalate"
},
"on_timeout": "no-input",
"timeout": 10
},
{
"action": "say",
"id": "no-input",
"text": "You have not entered any input. Good bye"
},
{
"action": "hangup"
},
{
"action": "say",
"id": "acknowledged",
"text": "Thank you, this is acknowledged"
},
{
"action": "hangup"
},
{
"action": "playback",
"id": "escalate",
"url": "https://demo.example.com/escalation-notice.wav"
},
{
"action": "dial",
"recipient_phone": "12125551234"
},
{
"action": "hangup"
}
],
"recipient_phone": "12125551234",
"sender": "12125551200",
"status_callback_url": "https://demo.example.com/call-status",
"voice": "en_US-amy-medium"
}Response
Successful Response
Example response
{
"call_status": "queued",
"call_uuid": "01d1e10f-9eb2-4543-a711-3707906010e2",
"status": true
}Changes
No recorded changes to this operation across all 1 revision of this API.