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

# Routines

> Record a browser or desktop task once, and Duvo replays the same steps every time. The Agent steps in only where a step needs judgment.

> [!NOTE]
>
> **Beta** — Routines are in beta and may change. Ask your Duvo account team to turn them on for your team.

A Routine is a task you record once — in a browser or on a Windows desktop — that Duvo replays step by step. The clicks, typing, and navigation run exactly as recorded, without the Agent working out each move. The Agent takes over only for a step that needs judgment, or a step that can't be replayed as recorded, and then the Routine continues.

That makes a Routine the most reliable way to automate a fixed sequence of screens: the same steps, in the same order, every Run. Runs are faster too, because most steps need no reasoning.

## Routines and Skills

Both are recorded or written once and attached to an Agent. They differ in who decides each step.

| | Skill | Routine |
| - | - | - |
| **What it is** | Guidance the Agent reads and follows | Recorded steps Duvo replays |
| **Who does each step** | The Agent, using its own judgment | Duvo, step by step; the Agent only where a step needs judgment |
| **Best for** | Tasks that change from case to case | The same screens in the same order every time |
| **When the page changes** | The Agent adapts | The affected step goes to the Agent; the rest still replays |

Use a **Routine** when the task is a stable, repeatable sequence: entering an order into a portal, exporting the same report, updating a record in a desktop app. Use a **Skill** when the task needs interpretation along the way. An Agent can have both: its AOP decides what to do, and a Routine does the mechanical part.

## Record a Routine

Routines live on the **Routines** tab of **Skills and Files**, in the Resources section of the left sidebar. Click **Add Routine** and choose how to record.

![The Add Routine menu on the Routines tab, with Record Browsing Routine and Record Computer-Use Routine](https://mintcdn.com/duvo-d8027998/9FwBGMSUbKlbUexr/images/user-guide/skills/routines-add-routine-menu.png?fit=max\&auto=format\&n=9FwBGMSUbKlbUexr\&q=85\&s=32b9326577c9abab07865950f4290ac2)

If **Record Browsing Routine** isn't in the menu, browser recording isn't turned on for your team. Ask your Duvo account team.

> [tab] Browsing Routine
>
> **1. Open the recorder**
>
> Choose **Record Browsing Routine**. A browser opens in an embedded window. Navigate to the page where the task starts.
>
> **2. Sign in if needed**
>
> If the site asks you to sign in, fill a saved [Login](https://docs.duvo.ai/user-guide/resources/my-logins.md) instead of typing it:
>
> 1. In the bar above the browser, click **Fill Login**. It sits next to **Logins**, **Cancel**, and **Start Recording**.
> 2. Find the Login for this site. Logins are listed by website and username.
> 3. Click **All** to fill the username, password, and one-time code. To fill one field at a time, click **Username**, **Password**, or **OTP**.
>
> ![The recorder with Fill Login open in the bar above the browser, listing a saved Login with All, Username, and Password buttons](https://mintcdn.com/duvo-d8027998/9FwBGMSUbKlbUexr/images/user-guide/skills/routines-fill-login.png?fit=max\&auto=format\&n=9FwBGMSUbKlbUexr\&q=85\&s=522cf3d602aa78ea8de205016eadfcc4)
>
> If a button turns red, Duvo couldn't find that field. Click the field on the page, then try again. Don't have a Login for this site yet? Click **Logins** in the same bar to add one without leaving the recorder.
>
> **Fill Login** works before and during recording. Passwords and one-time codes are never stored in the Routine; when it runs, one-time codes are generated fresh.
>
> **3. Record the task**
>
> Click **Start Recording** and do the task once, the way you want it done. When you finish, click **Stop Recording**. A recording stops on its own after 30 minutes.
>
> **4. Name the Routine**
>
> Enter a **Routine Name** and a **Routine Description**, then click **Save Routine**.

> [tab] Computer-Use Routine
>
> **1. Choose a desktop**
>
> Choose **Record Computer-Use Routine**, then pick the desktop to record on: one of your [Windows Remote Desktop](https://docs.duvo.ai/user-guide/connections/available-connections/windows-remote-desktop.md) connections, or the Duvo sandbox.
>
> **2. Record the task**
>
> Once the desktop is ready, open the apps you need, click **Start Recording**, and do the task exactly how you want it done. Made a mistake? Click **Undo** to drop your last action. When you finish, click **Stop Recording**.
>
> **3. Name the Routine**
>
> Duvo turns your recording into a Routine. Enter a name and a description, then save it.

![The final recording step, with the Routine Name and Routine Description fields](https://mintcdn.com/duvo-d8027998/9FwBGMSUbKlbUexr/images/user-guide/skills/routines-name-step.png?fit=max\&auto=format\&n=9FwBGMSUbKlbUexr\&q=85\&s=ecb1abff5fa6e819367e0db5f979c114)

> [!TIP]
>
> Write the description for the Agent. It decides when to run the Routine from its name and description, the same way it chooses a Skill. Say what the Routine does and when to use it — for example, "Creates a supplier in the ERP. Use when the AOP asks to add a new supplier."

### What Gets Replayed and What Goes to the Agent

Duvo replays clicks, typing, keyboard shortcuts, and navigation as recorded. A few kinds of steps go to the Agent instead:

* **Choices that depend on the task.** If you clicked a specific product or order while recording, the Agent picks the right one for the current task rather than repeating your choice.
* **Values that change from task to task.** The Agent fills in the value for the current task, such as this order's number instead of the one you typed while recording.
* **Sign-in.** Sign-in steps use the Login attached to the Agent, not the values from your recording.
* **Steps that can't be replayed.** If a button or field is missing, renamed, or can't be told apart from another, the Agent does that one step. One broken step costs one step, not the whole Routine.

After the Agent handles a step, the Routine continues from the next one.

> [!NOTE]
>
> A computer-use Routine also needs each step's window. If a window is missing, the Agent tries to open it. If it still doesn't appear, the Routine stops and the Run reports the failure. If the desktop's screen resolution differs from the recording, the Agent does the remaining steps itself instead of replaying them.

## Attach a Routine to an Agent

Attach a Routine the same way you attach a Skill:

**1. Open the Agent**

Open the Agent in the [Agent Builder](https://docs.duvo.ai/user-guide/building-assignments/assignment-builder.md).

**2. Add it from Skills and Files**

On the **Skills & Files** row, click the add button. In **Select Skills and Files**, open the **Skills** tab — Routines are marked with a **Routine** badge.

**3. Confirm**

Select the Routine and click **Confirm**.

![The Select Skills and Files dialog, with a Routine marked by its Routine badge](https://mintcdn.com/duvo-d8027998/9FwBGMSUbKlbUexr/images/user-guide/skills/routines-select-skills-and-files.png?fit=max\&auto=format\&n=9FwBGMSUbKlbUexr\&q=85\&s=d476bbd96b82eafd39090ff932f78ac5)

The Agent needs the same kind of Connection the Routine was recorded on:

* **Browsing Routine** — [Enterprise Browser](https://docs.duvo.ai/user-guide/connections/available-connections/browser.md).
* **Recorded on a Windows Remote Desktop** — a [Windows Remote Desktop](https://docs.duvo.ai/user-guide/connections/available-connections/windows-remote-desktop.md) connection.
* **Recorded on the Duvo sandbox** — [Computer Use](https://docs.duvo.ai/user-guide/connections/available-connections/computer-use.md).

Until the Agent has that Connection, the Routine is listed but can't be selected. Hover over it to see which Connection to add.

You don't need to name the Routine in the AOP. The Agent runs it when the task matches its description. To make sure it runs, say so in the step it belongs to — for example, "Create the supplier with the **Create supplier** Routine."

## Check a Run

When a Run uses a Routine, the Run page shows a **Routine execution** panel with the share of expected steps that Duvo replayed. Expand it to see how many steps ran, how many went to the Agent, any errors, and whether the Routine completed.

A Routine that keeps handing the same step to the Agent is a sign that the page or app changed, or that the step depends on the task. Record a new Routine and attach it in place of the old one, or record only the fixed part of the task and leave the rest to the Agent.

## Tips for Reliable Routines

> [!TIP]
>
> * **Record one task per Routine.** Split a long process into Routines for each fixed stretch, and let the AOP decide between them.
> * **Make decisions before you record.** Do the judgment part first, then record the mechanical part that follows.
> * **Avoid stray clicks.** Every action becomes a step that Duvo replays.
> * **Use realistic values.** They show the Agent what kind of value belongs in each field.

For how replay finds the right element on a page, and how to keep browser work running after a redesign, see [Browsing That Survives UI Changes](https://docs.duvo.ai/best-practices/browsing-that-survives-ui-changes.md).

## Related

> [card] [Skills Overview](https://docs.duvo.ai/user-guide/skills/skills-overview.md)
>
> How Skills give Agents specialized knowledge.

> [card] [Recording Browsing Skills](https://docs.duvo.ai/user-guide/skills/recording-browsing-skills.md)
>
> Record a browser task as a Skill the Agent follows with judgment.

> [card] [Computer Use](https://docs.duvo.ai/user-guide/connections/computer-use-overview.md)
>
> Let Agents work in Windows desktop apps.

> [card] [Logins and Secrets](https://docs.duvo.ai/user-guide/resources/my-logins.md)
>
> Save the Logins that Routines sign in with.


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