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

# Rules

Set a rule once and it acts on any robot that reports the signal, whatever the maker.

{% hint style="warning" %}
**Draft.** Some details on this page are still being confirmed and may change. Questions? Email <info@dextoros.app>.
{% endhint %}

Rules apply to every robot, not one brand. Set a rule once and it acts on any robot that reports the signal.

A rule has one trigger (**When**) and one action (**Then**). Build one by dragging a trigger and an action into the rule, or by tapping them. Blocks you haven't used wait in the **Or** tray.

## Triggers

| Trigger                     | Fires when                                           |
| --------------------------- | ---------------------------------------------------- |
| **Battery below threshold** | A robot's battery drops below the threshold you set. |
| **Offline for 5 minutes**   | A robot has been offline for 5 minutes or more.      |

The battery threshold ranges from 5% to 60% and defaults to **20%**. The rule fires only when the battery is below the threshold, not equal to it.

## Actions

| Action            | What it does                           |
| ----------------- | -------------------------------------- |
| **Send to dock**  | Sends the robot to its dock to charge. |
| **Alert on-call** | Pages the on-call operator.            |

## Examples

{% columns %}
{% column %}

### Keep batteries healthy

**When battery below threshold, send to dock.**

Every AMR, quadruped or mobile manipulator that reports a battery level docks itself before it runs out, whichever vendor built it.
{% endcolumn %}

{% column %}

### Know when a robot drops out

**When offline for 5 minutes, alert on-call.**

The on-call operator is paged for any robot that stops responding.
{% endcolumn %}
{% endcolumns %}

{% hint style="info" %}
If you pair **Offline for 5 minutes** with **Send to dock**, an offline robot can't receive the command straight away. It docks when it reconnects.
{% endhint %}

Before you save, the rule preview shows how each robot would respond, for example **1 of 4 robots would dock**.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.dextoros.app/automation/rules.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
