> For the complete documentation index, see [llms.txt](https://docs.xenioo.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.xenioo.com/conversations/queues.md).

# Queues

Queues let you organize incoming conversations and route them to the right agents using the distribution strategy that best fits your team's workflow. Each queue is an **account-level** resource — it spans all bots and channels on your account, giving you a single place to manage conversation distribution.

{% hint style="info" %}
Queue Configuration requires the **Queue Management** feature to be enabled on your subscription plan. Only account owners and admin members with the manage permission can create or edit queues.
{% endhint %}

## Accessing the Queues Page

The **Queues** entry appears as a top-level item in the Designer navigation bar, alongside Dashboard, My Bots, My Users, and Templates. It is visible only when your subscription plan includes the Queue Management feature and your account role grants the necessary permissions.

## Queue List View

<figure><img src="/files/FOP0QETN5a4pvNaKT4js" alt=""><figcaption></figcaption></figure>

The Queues page opens with a list of all queues configured on your account.

### List Columns

| Column             | Description                                                                                                       |
| ------------------ | ----------------------------------------------------------------------------------------------------------------- |
| **Display Name**   | The operator-facing label for the queue.                                                                          |
| **Strategy**       | The distribution strategy used to route conversations (shown as a colored badge).                                 |
| **Conversations**  | \[TODO]                                                                                                           |
| **Channels**       | Count of channels assigned to the queue.                                                                          |
| **Agents**         | Count of agents assigned to the queue.                                                                            |
| **Max Queue Size** | Maximum number of conversations the queue will accept. `0` means unlimited.                                       |
| **Status**         | Active/Paused toggle. A paused queue stops accepting new conversations while existing ones continue to be worked. |

### Available Actions

* **+ Add New Queue**: Opens the create form for a new queue.
* **Search**: Filter the queue list by name using the search bar in the top-right corner.
* **Row menu (⋮)**: Each row provides contextual actions:
  * **Edit**: Open the queue configuration form.
  * **Pause / Resume**: Toggle the queue status between Active and Paused.
  * **Delete**: Remove the queue (requires confirmation). A queue **cannot be deleted** if it still has conversations associated with it.

### Pagination

The list supports pagination. Use the **Queues per page** selector at the bottom to control how many queues are displayed per page (default: 10).

## Creating a Queue

1. Click **+ Add New Queue** on the Queues page.
2. Fill in the configuration form (see [Queue Configuration Form](#queue-configuration-form) below).
3. Click **Save**.

A confirmation toast appears on success and the list reloads with the new queue.

## Editing a Queue

1. Click the **⋮** menu on the queue row you want to edit.
2. Select **Edit**.
3. Modify the desired fields in the configuration form (the form is the same as Add New Queue).
4. Click **Save**.

## Queue Configuration Form

The create/edit form has three sections: **General**, **Channels**, and **Agents**.

<figure><img src="/files/b3kdksTah6QyYnaXYDzP" alt=""><figcaption></figcaption></figure>

### General

**Display Name** is required. It is the operator-facing label for the queue.

**Description** is optional. Use it to describe the queue's purpose.

**Distribution Strategy** is required. It controls how conversations are assigned to agents. See [Distribution Strategies](#distribution-strategies).

**Max Queue Size** is optional. It limits concurrent conversations in the queue. Set it to `0` for unlimited conversations.

### Channels

<figure><img src="/files/Ic8v81B2mpda7XMO7e1a" alt=""><figcaption></figcaption></figure>

Assign one or more of your account's published channels to the queue. Conversations arriving through these channels will be routed into this queue.

* Use the multi-select picker to add or remove channels.
* Each channel can only appear once per queue (no duplicates).

### Agents

<figure><img src="/files/J3LKufQKYiF2Di87sFqR" alt=""><figcaption></figcaption></figure>

Assign agents (team members with operator rights) to the queue. Each agent assignment carries queue-specific settings:

**Agent** is required. The team member must have conversation-level operator rights.

**Priority** is required. Set it from `1` (highest) to `10` (lowest).

**Max Concurrent** is required. It sets the agent's simultaneous conversation limit for this queue. The minimum value is `1`.

* Click **+ Add Agent** to add a new agent row.
* Use the **⋮** menu on each agent row to remove the assignment.
* An agent cannot be assigned to the same queue more than once.

## Distribution Strategies

The distribution strategy determines how the queue assigns incoming conversations to available agents. Three strategies are supported:

| Strategy         | Behavior                                                                                          |
| ---------------- | ------------------------------------------------------------------------------------------------- |
| **Round Robin**  | Agents are selected in a rotating order, ensuring an even distribution of conversations.          |
| **Least Active** | The agent with the fewest active conversations is selected first, balancing workload dynamically. |
| **Random**       | An agent is selected at random from the available pool.                                           |

{% hint style="info" %}
The distribution strategy works together with each agent's **Priority** setting. Higher-priority agents (lower number) are considered first within the selected strategy.
{% endhint %}

## Queue Status

Each queue has an operational status that controls whether it accepts new conversations:

| Status     | Behavior                                                                                                                      |
| ---------- | ----------------------------------------------------------------------------------------------------------------------------- |
| **Active** | The queue is fully operational and accepts new incoming conversations.                                                        |
| **Paused** | The queue stops accepting **new** conversations. Conversations already in the queue continue to be worked by assigned agents. |

Toggle the status directly from the list view using the **Status** toggle switch, or from the queue configuration form.

{% hint style="warning" %}
Pausing a queue does **not** remove or reassign existing conversations — it only prevents new ones from entering. Use this when you need to temporarily stop routing to a queue without losing ongoing work.
{% endhint %}

## Deleting a Queue

1. Click the **⋮** menu on the queue row.
2. Select **Delete**.
3. Confirm the deletion in the dialog.

{% hint style="danger" %}
A queue can only be deleted if it has **no conversations** currently associated with it. If conversations are present, the delete action is blocked both in the UI and on the server side.
{% endhint %}

## Validation Rules

The following validation rules are enforced both in the form (client-side) and on the server:

| Field                                | Rule                                                           |
| ------------------------------------ | -------------------------------------------------------------- |
| Display Name                         | Enter a name for the queue.                                    |
| Distribution Strategy                | Choose `Round Robin`, `Least Active`, or `Random`.             |
| Max Queue Size                       | Enter `0` or a higher number. Use `0` for unlimited.           |
| Agent → Priority                     | Choose a value from `1` to `10`.                               |
| Agent → Max Concurrent Conversations | Enter `1` or a higher number.                                  |
| Agent                                | Choose an account team member. Add each agent only once.       |
| Channels                             | Choose available account channels. Add each channel only once. |
