Create Queue

API Details

Creates a queue for the brand. Eligibility expressions are worker-scoped (e.g. email == '...', not worker.email == ...). Set includeAiAgents to true when AI agents should be eligible. Prefer maxReservedAgents of 1 for queues with auto-accepted tasks.

Rate Limit

Limit TypeValue
Requests per second10

If you exceed this limit, you will receive a 429 Rate Limit Exceeded response.

Body Params

Request body for creating a new queue.

string
required
length ≥ 1

Display name of the queue.

string
enum
required

Task ordering strategy for this queue. FIFO = tasks sorted by priority, highest priority assigned first. LIFO = most recent task assigned first.

Allowed:
integer
required
≥ 1

Maximum number of agents that can be reserved from this queue simultaneously. Should generally be 1 for queues containing auto-accepted tasks (e.g. auto-accepted inbound calls, transfers, power dial, or progressive dial) -- reserving multiple agents can create a confusing experience where one agent accepts while others' reservations are rescinded.

boolean
required

Whether this queue appears in the internal transfer list (a manual transfer destination in the agent desktop). Setting this to false hides it from that list without affecting routing eligibility.

string

Optional description of the queue's purpose.

string
required
length ≥ 1

Twilio TaskRouter worker eligibility expression that decides which agents are eligible for this queue, e.g. "email == '[email protected]'". Queue eligibility expressions are worker-scoped: reference worker attributes directly (e.g. email, teams), not prefixed with worker. -- that prefix is used in routing-rule agent expressions, not queue eligibility expressions.

boolean

Whether AI agents are eligible for tasks in this queue. Must be explicitly set to true for AI agents to be eligible, even if the eligibility expression would otherwise match them.

sla
object

Service level agreement target: the expected maximum time for tasks in this queue to be accepted, broken down into time components.

Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json