> ## Documentation Index
> Fetch the complete documentation index at: https://docs.relayhub.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Routines and automations

> The difference between a bot routine and an automation, and when to use each one

RelayHub has two ways to do work again without a new request from you: a routine of a bot and an automation. Both can start on a schedule or on an event in one of your apps. The difference is what does the work. A bot does the work of a routine with its AI model. An automation runs a fixed flow of steps.

## Routines

A routine is work that a bot does on a schedule or when an event arrives in one of your apps. For example: "Every weekday at 9 AM, read the new invoices and tell me what is late."

Each run of a routine is a task of the bot. The bot reads the instruction of the routine and decides the steps itself. It uses its AI model, its tools, its computer, its connections and its memory. When the situation changes, the bot changes its steps.

You add a routine on the bot page: click **Details**, then **Routines**. You can also ask the bot in the chat, for example "make this a routine every weekday at 8". The bot can also propose a routine on a card. To use Bots, you need the Agents permission. See [Routines, groups and helpers](https://docs.relayhub.ai/bots/routines-groups-helpers.md).

## Automations

An automation is a flow of fixed steps. In the sidebar, open the **Automate** group and click **Automations**. A flow starts with a trigger, for example a webhook, a schedule or a request from the chat. Then it runs its steps in order, for example a Slack message, a Salesforce update or a RelayHub skill.

Each run of a flow does the same steps. A step can use AI, but the flow does not choose its own steps. You build a flow in the visual editor, or you describe it in plain words to the **Automation Wizard**. Access to Automations is on by default. An administrator can turn it off for one user. See [Automations](https://docs.relayhub.ai/integrations/automation-hub.md).

## Differences between routines and automations

In RelayHub, a bot does the work of a routine, and a flow does the work of an automation. This table shows the differences.

| | Routine | Automation |
| - | - | - |
| What it is | Work that a bot does again, as a task of the bot | A flow of fixed steps that connects a trigger to actions |
| Who creates it | The owner of the bot, in the **Routines** tab or in the chat with the bot. The bot can propose a routine. | A user with access to Automations, in the visual editor or with the **Automation Wizard** |
| What starts it | A schedule in plain words, for example "Every weekday at 9 AM", or one event in a connected app, for example a new Gmail message | The trigger of the flow, for example a webhook, a schedule or a request from the chat. The **Schedules** screen can also start a flow. |
| What does the work | The bot. It reads the instruction, plans the steps, uses its tools and its computer, and writes a report. | The steps of the flow, in a fixed order. The flow does not plan or change its steps. |
| Where you see the runs | On the bot page: the **Now** tab and **Earlier tasks**. The report reaches you by the delivery that you chose for the routine. | In the run history of the flow, in the visual editor. A schedule on the **Schedules** screen also keeps its own run history. |
| Cost | Each run uses the AI model of the bot. The cost counts toward the monthly spend limit of the bot, \$50 by default. | A flow does not use the spend limit of a bot. An AI step or a skill step in the flow uses an AI model. |
| Approvals | The bot obeys its **Permissions**. It asks you first before a risky action, for example a payment or an email to another person. | A flow shows no approval cards. After you publish a flow and turn it on, each run does its steps without a question. |

## When to use a routine

Use a routine when the work needs judgment. Examples:

* The bot must read, compare or summarize, and tell you only what is important.
* The steps can be different from one run to the next.
* The work uses websites or desktop apps on the computer of the bot.
* You want the report in the chat of the bot, with its memory of earlier runs.

## When to use an automation

Use an automation when the steps are always the same. Examples:

* You move data from one app to another app, for example from a form to a CRM.
* Another system calls a webhook, and the flow must do the same steps each time.
* You want the same result on each run, with no decision by an AI model.

When you ask a bot for recurring work, the bot makes a routine. It builds an automation only when you ask for an automation by name.

## Routines and automations together

An automation can send a task to a bot. Open the settings of the bot, then **Connections**, then **Give it tasks from another app**. Copy the link and the key into the flow. The flow then starts the work, and the bot does the part that needs judgment. See [Connections and saved logins](https://docs.relayhub.ai/bots/connections.md).

## Related pages

* [Routines, groups and helpers](https://docs.relayhub.ai/bots/routines-groups-helpers.md): add, change and pause the routines of a bot
* [Automations](https://docs.relayhub.ai/integrations/automation-hub.md): build, publish and start flows
* [Automation Wizard](https://docs.relayhub.ai/integrations/automation-wizard.md): build a flow from a description in plain words
* [Schedules](https://docs.relayhub.ai/integrations/schedule-hub.md): run skills and flows on a schedule, and see the routines of your bots
* [Permissions and approvals](https://docs.relayhub.ai/bots/permissions.md): choose what a bot may do without asking
* [Bot settings](https://docs.relayhub.ai/bots/settings.md): the AI model and the monthly spend limit of a bot


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.