# Bot actions: tasks, requests, notifications and CRM queries

> How to make the bot do the work — a complaint becomes a task for the location manager, a booking becomes a request, an order question becomes a query to your system.

Источник: https://jecheck.io/en/docs/bots/actions

Actions are what the bot can do on its own: create a task, submit a request, notify an employee, add a label or query your CRM. The bot calls an action when the situation matches the "when to call" description and all the required data has been collected. Actions are set up on the **Actions** tab of the bot editor.

![Bot actions: tasks, requests, notifications and CRM queries](/docs-media/en/bots/actions.jpg)

## Built-in actions

Every bot has them, no setup needed:

| Action | What it does |
|---|---|
| **Knowledge search** | looks for an answer in the instructions open to bots |
| **Call an employee** | hands the conversation to Conversations according to the handoff rules |
| **Customer details** | saves the name, phone and email to the customer card; if a customer with the same phone has already written in another channel, it's the same person |
| **Location choice** | remembers which location the conversation is about — tasks go to it |
| **Close conversation** | when the question is resolved — and asks for a rating |

## Custom actions

Click **Add** and choose a type:

| Type | When it's useful |
|---|---|
| **Create task** | a complaint, a breakdown, a forgotten item — a task for the location manager, an employee by position, a department, a specific employee or administrators |
| **Request in Processes** | the bot fills in a [process](/docs/tasks/processes) form — then the request follows the approval route |
| **Notify employees** | a new booking, an order, an urgent question — a notification in the app and the web dashboard |
| **Conversation label** | the bot marks the topic: "Delivery", "Feedback", "Job opening" — for filters and analytics |
| **External system request** | order status, available time slots, bonus balance — in your CRM or accounting system |

Each action has:

- **Name** — how the bot and scenarios refer to this action ("Customer complaint");
- **When to call** — a hint for the AI: in which cases and once which data has been collected;
- **What the bot asks the customer** — fields: label, type (string, text, number, yes/no, choice from a list, date, phone, email) and **required**. Without the required fields the action won't run — the bot asks for what's missing first;
- **Summarize to the customer and get consent before running** — the bot lists the collected data and runs the action only after a "yes";
- **No more than N times per conversation** — protection against repeats.

## Create task

- **Task title** — you can insert fields in curly braces: `Customer complaint: {what}`.
- **To**: location managers, an employee by position at the location, a department (the task goes into the department queue), a specific employee or administrators.
- **Priority** and **Deadline, hours**.
- **Task location** — from the conversation (the bot will ask the customer) or always the same location.
- **The assignee closes the task with a photo** — an "after" confirmation.
- **Tell the customer when the task is done** — see below.

The task description contains the collected data, the customer's name and phone, the channel and a link to the conversation. Photos the customer sent in the conversation are attached to the task. The task history shows the note "Customer request via chatbot".

### The customer learns that everything was fixed

If **Tell the customer when the task is done** is on, when the assignee closes the task, the bot itself writes to the customer: "Your request #128 has been resolved" — with the assignee's comment, if there is one. If the task is rejected, the customer gets a message that a decision has been made on their request.

> [!NOTE]
> WhatsApp and Instagram allow you to message a customer only within 24 hours of their last message. If the window is closed, the message won't be sent — the conversation will show a note about it.

## Request in Processes

Choose a published **Process** and the **Requester** — the employee on whose behalf the bot submits requests. The process form fields automatically become the bot's questions (the bot doesn't fill in files or employee pickers). The customer gets the request number, and a message when it's completed.

## External system request

To connect your CRM, booking system or accounting system:

- **Method** (GET, POST, PUT, PATCH) and **URL** — `https://` only. Fields are inserted into the URL like this: `https://crm.example.com/orders/{order}`.
- **Request body (JSON)** for POST/PUT/PATCH — leave empty to send all collected fields.
- **Response fields for the bot** — paths such as `status`, `order.total`: the bot sees only these. Empty — the whole response (up to 4,000 characters).
- **Headers** — for example, `Authorization`. Values are stored encrypted and aren't shown after saving.
- **Test request** — send a test request with sample values and see the response.

> [!WARNING]
> Requests to an internal network (`localhost`, `192.168.…`, `10.…`) and over `http://` are not allowed — the address must be reachable from the internet over https.

## How to link an action to a scenario

Mention the action by name in the scenario steps: "Call the "Customer complaint" action." This way the bot knows exactly when to call it. See [How to create and set up a bot](/docs/bots/create-bot).

## Frequently asked questions

### Did the bot create a task in the sandbox?

No. Tasks, requests and notifications are not created in the sandbox — the **Reasoning** block shows what would have been done. GET requests to external systems are executed.

### Where can I see what the bot has created?

In the conversation — the **Why this answer** button on a bot message; in the customer card — **Requests and tasks**; on the [Bot quality](/docs/bots/quality) screen — the **Bot actions** block.

### Can I limit how many tasks the bot creates?

Yes — **No more than N times per conversation** on each action. The default is 3.
