# Automation

Automatically allocates clients among the operators that are in active status. The "On shift" status is considered active.

Each operator has an activity settings menu.

<div data-with-frame="true"><figure><img src="/files/gQvZsiBLH8w3E4BIGz6S" alt="" width="563"><figcaption></figcaption></figure></div>

**Overview of statuses:**

* <mark style="color:green;">**Online**</mark>  is an active status. When working with automatic customer allocation, the operator must set this status in his personal account. The status tab is available on any page of the Salebot project.
* <mark style="color:yellow;">**Break**</mark> is set during a break to temporarily stop the allocation of customers to an employee.
* <mark style="color:red;">**Offline**</mark> is the status when the allocation does not work. As a rule, it is set if the employee is not on shift or has completed the working day.

When working with auto-allocation, pay attention to the employee statuses for the correct operation of customer allocation.

If the employee statuses are not "Online," then the allocation will not work.

## Enabling

Go to the "Employees" section →"Automation" → Activate the switch for automatic customer allocation.

<div data-with-frame="true"><figure><img src="/files/6aZ7BqZ1oKf0CIWQ7DxQ" alt=""><figcaption></figcaption></figure></div>

### Operating mode

You can specify the operating mode of the allocation around the clock or set the operating mode of your company.

<div data-with-frame="true"><figure><img src="/files/F6V1pasDVIQv9NPzZNvC" alt="" width="222"><figcaption></figcaption></figure></div>

In the example, the round-the-clock operation mode is active.

If you select the “Period” mode, you will need to set the working time.

<div data-with-frame="true"><figure><img src="/files/2rUwyzC2934dUcRWzQPd" alt="" width="228"><figcaption></figcaption></figure></div>

Weekends are the choice of days on which the automatization system will not work. In the example, Saturday and Sunday are selected as weekends.

<div data-with-frame="true"><figure><img src="/files/85G4WDaIZG6r34E3qIU9" alt="" width="563"><figcaption></figcaption></figure></div>

### How it works

When the system is turned on, customers who write to your bot will automatically be attached to the operators who are ON SHIFT.

The system allocates customers equally among all operators. For example, if there are 5 operators on a shift and 55 customers have arrived, each operator will get 11 customers.

At the end of the working day, the customers who write stop being attached to the operators and are already considered NIGHT CUSTOMERS. Overnight customers are distributed evenly at the beginning of the next working day among the operators who took the shift BEFORE the working day.

{% hint style="info" %}
For example: 30 clients arrived overnight, and the working day should start at 6:00. The operator Bogdan took over at 5:55 a.m. and the operator Ruslan took over at 5:57 a.m.. So they were not assigned any customers. When the working day started at 6 a.m., Bogdan and Ruslan each had 15 customers. After that the operator Philippe took over at  6:05 a.m., but the new customers were just starting to fall for him.
{% endhint %}

If the operator writes to a FREE customer himself, the customer will automatically be assigned to him.

The operator who is on a break does not receive new customers, however, customers who are already connected to the operator will get to him.

There are also weekends when auto allocation does not work.

## Settings for operators

<div data-with-frame="true"><figure><img src="/files/eLIgUXiMthbL6zVDNkZg" alt="" width="563"><figcaption></figcaption></figure></div>

Operator settings section Employees → Automation

1. **To display customer allocation buttons for operators** — The setting allows the operator to assign the customer to himself, transfer him or abandon the customer.
2. **Display the "Awaiting response" and "Available Clients" sections for operators** — choose whether to display the "Awaiting Response" and "Available Customers" icons in the left bar in the customer dialogue. If this feature is enabled, the sections will be displayed as shown in the screenshot below:

<div data-with-frame="true"><figure><img src="/files/VcXvSQ9z0CJTHN6Azcf3" alt="" width="563"><figcaption></figcaption></figure></div>

<div data-with-frame="true"><figure><img src="/files/3wJBVN1xsADs8tzvzHiB" alt="" width="563"><figcaption></figcaption></figure></div>

3. **To remove operators from a shift** is to automatically remove operators from a shift at the end of the working day. The end of the working day is the time specified in the work schedule.
4. **Allocate customers equally over a certain time interval** - when activated, the system distributes customers equally over the entire working day.

{% hint style="info" %}
For example, if 300 customers came in all day, and there were 6 operators on shift, then on that day everyone got 50 customers.

You can also specify a time interval (for example, 10 minutes), the system will equally distribute the customers who came during this period (the last 10 minutes).

For example: there were 2 operators on shift, and an interval of 10 minutes was set. During the period of 10:40 - 10:50, 50 clients arrived, and each operator received 25 clients. Then, at 11:00, the third operator would take over., and from 11:00 a.m. to 11:10 a.m., 60 more customers would arrive. They would be evenly allocated among three operators — 20 people each. So this would help to avoid overloading one employee.

If you set the interval to 1 minute, and customers arrive with an interval of 1 minute or more, they will be allocated among different operators, rather than getting to the first one.
{% endhint %}

4. **Do not allocate customers if the bot has responded** - if the customer has written a message and received a response from the bot, then such a customer will not be allocated to the operator according to the set auto-allocation settings.

All employees can be operators in a chat with Customers. It means that if an employee does not have the standard operator role, he will also see customers and be able to respond to them.

5. **Allow the operator to delete customers** - deleting customers by operators is prohibited, by default. If necessary, you can grant this permission to your operators. Then they will be able to delete customers.

{% hint style="info" %}
Note!

After installing all the settings, do not forget to save the changes.
{% endhint %}

The “Clear employee attachment” button removes the attachment of customers to operators. It does not apply to those customers who arrived less than a day ago.

<div data-with-frame="true"><figure><img src="/files/jgeqSn3KhyyF4QKT3cPK" alt="" width="368"><figcaption></figcaption></figure></div>

All employees who have access to your project are located on the "Employees" tab.

<div data-with-frame="true"><figure><img src="/files/hL7Q1WuxKXtZRxMJKSWf" alt=""><figcaption></figcaption></figure></div>

The list of project employees.

If you hover over the three dots to the right of the employee, a context menu with the Edit and Delete commands will be available.

<div data-with-frame="true"><figure><img src="/files/eG77hsFVfpORLUsQHz2g" alt=""><figcaption></figcaption></figure></div>

Editing an employee's card with the Operator role

You can work with both standard employee roles and custom created fields. In such roles, you can set up access rights with flexible settings.

{% hint style="info" %}
You can learn more about how to create your role [here](https://docs.salebot.pro/administrirovanie/nastraivaemye-roli).
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.mavibot.ai/crm/setting/automation.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
