Skip to main content

Enqueue

The <Enqueue> verb enqueues the current call in a call queue.

Attributes

ATTRIBUTEDESCRIPTIONOPTIONSDEFAULT
action Defines an absolute or relative URL used to send a request when the call leaves the queue. It will be sent right away when the call is dequeued using <Leave> verb. When a call is dequeued using <Dial> verb, the request will be sent once the bridged calls disconnect. -
method HTTP request type used for action. GET, POST POST
waitUrl Specifies the URL to the TeXML document that will be executed when the call is waiting in the queue. Once all the commands from the flow are executed, the waitUrl is re-requested, and the TeXML document is run once again. Verbs that are supported in the waitUrl TeXML document: <Play>, <Say>, <Gather>, <Pause>, <Hangup>, <Redirect>, <Leave>. -
waitUrlMethod HTTP request type used for waitUrl. GET, POST POST

Examples

<?xml version="1.0" encoding="UTF-8"?>
<Response>
<Enqueue/>
</Response>

Expected callbacks

If waitUrl is set, the following callbacks are expected.

{
"AccountSid": "cb6cfbbc-eb00-41af-a3f3-0d7b32009e4b",
"CallSid": "v2:r3Cj9j-Hx7NAZETtYpdgktVUYKhsc8D1mSmzY8_6r4HHZYViWIs6Fw",
"CallSidLegacy": "v2:r3Cj9j-Hx7NAZETtYpdgktVUYKhsc8D1mSmzY8_6r4HHZYViWIs6Fw",
"QueueSid": "defcfbbc-eb00-41af-a3f3-0d7b32009e4b",
"QueuePosition": 1,
"CurrentQueueSize": 5,
"QueueTime": 0,
"AvgQueueTime": 10
}

Status callback HTTP attributes

ATTRIBUTEDESCRIPTION
AccountSidA unique identifier for the account generating this call.
CallSidA unique identifier for this call, generated by Telnyx.
CallSidLegacyA unique identifier for the call sent to keep backward compatibility.
QueueSidA unique identifier for the queue, generated by Telnyx.
QueuePositionA position of the call in the queue
CurrentQueueSizeA number of the calls in the queue
QueueTimeWaiting time in the queue. In case of WaitUrl callback it is set to 0 always