Skip to main content

Initiating a Call

POST /telephony/calls/@channelKey/


Example URL

https://system_domain/api/v2/telephony/calls/@channelKey/


Request Body Parameters (form-data)

ParameterTypeRequiredDescription
actionstringYesUse the value create_call to initiate a call.
directionstringYesCall direction: incoming for incoming calls, outgoing for outgoing calls.
phonestring
number
YesPhone number.
call_statusstringNoCall status; see description below.
pbx_call_idstring
number
NoCall ID from PBX.
pbx_user_ids[]arrayNoUser IDs from PBX.
user_ids[]arrayNoSystem staff IDs with telephony access.
group_ids[]arrayNoIDs of staff groups in the system with telephony access.
audio_recordfile (mp3/mp4/wav/ogg)NoCall recording.
commentstringNoComment for the ticket.

Description of call_status Parameter

Available values:

  1. ringing
  2. in-progress
  3. canceled
  4. missed
  5. failed
  6. answered
  7. busy

Statuses ringing and in-progress are active call statuses, meaning a call card will be displayed to the user. The other statuses are final call statuses and will hide the call card.

info

Only one of the following parameters can be passed at a time: user_ids / group_ids / pbx_user_ids.

These parameters determine which users will see the call card. If none of these parameters are specified, the call card will be shown to all staff members with access to the telephony module. If only one employee is specified/found, they will automatically be assigned as the assignee/performer of the ticket/call.


Example Request Body (form-data)

Request to initiate a call

KeyValue
actioncreate_call
directionincoming
phone+79998887766
call_statusringing
user_ids[]1,2,3
commentImportant call!

Example Response
{
"data": {
"call_id": 123,
"pbx_call_id": null,
"user_id": 0,
"pbx_user_id": null,
"call_status": "ringing",
"audio_record": null,
"ticket_id": 4567
}
}