Skip to main content
A call queue in LaraCopilot holds inbound callers in a virtual waiting line and distributes them to available agents according to a routing strategy. Queues decouple the point where a call arrives (a DID number) from the people who answer it (extensions enrolled as agents), making it straightforward to scale agent pools up or down without changing how numbers are published. Each queue belongs to a single tenant and is identified by a short queue_number that the PBX uses internally.

Key fields

FieldTypeDescription
tenant_idintegerThe tenant that owns this queue. Required.
namestringHuman-readable label for the queue (e.g. Support Tier 1).
queue_numberstringShort internal number identifying the queue in the PBX. Max 20 characters.
strategystringCall distribution algorithm (e.g. ringall, leastrecent, roundrobin).
timeoutintegerSeconds to ring an agent before moving to the next one. Minimum 1.
statusstringOperational state of the queue (e.g. active, inactive).

Queue agents

Agents are extensions that have been enrolled in a queue. Each queue tracks its enrolled agents, and the agents array returned by the API lists all extensions currently assigned to that queue.
Removing an extension from the system does not automatically unenroll it from queues. Remove the extension from any queues it belongs to before deleting it to prevent routing errors.
Agents are selected according to the queue’s strategy. Common values include:
  • ringall — all available agents ring simultaneously; first to answer wins.
  • leastrecent — the agent who answered a call least recently is tried first.
  • roundrobin — agents are cycled through in order, one call at a time.

API examples

Create a queue

curl -X POST https://your-instance/api/queues \
  -H "Content-Type: application/json" \
  -d '{
    "tenant_id": 1,
    "name": "Support Tier 1",
    "queue_number": "800",
    "strategy": "leastrecent",
    "timeout": 30,
    "status": "active"
  }'

Retrieve a queue with its agents

curl https://your-instance/api/queues/5
Pair each inbound DID with a call queue for production traffic. Assign the DID a DidRoute that targets the queue, so callers always reach an available agent rather than a single extension that may be busy or offline.