> This is a page from the ElevenLabs documentation. For an index of the documentation, fetch https://elevenlabs.io/docs/llms.txt.

# Steps

A step is one action in a routine. Add one with **Add step** in the toolbar, or with the **+** under a step to add it right after that step. Select a step to open its settings. What a step returns, its output, is available to the steps after it.

> **Info**
>
> Routines are in beta and not yet available in every workspace. To request access, contact your
> account manager.

## HTTP request

Use it to call another service's API, like your CRM's.

Calls a URL with the method, headers, and JSON body you set. Use `{input_name}` placeholders to put the step's inputs into the URL, header values, and body, such as `https://api.example.com/customers/{customer_id}`.

Add any credentials the API needs, such as an API key, as headers from your workspace secrets, or use an auth connection. When a request sends credentials, write its host out in the URL rather than filling it in from an input, so credentials only go to that host.

![HTTP request step with a GET URL that uses the customer\_id input, an Authorization header from a
workspace secret, and Test request](/docs/_fern-files/_img/edaf3cb4d3337fde847a9ce67647f72dfcbf8d71442ab1e10f12e28973baf105.webp)

The step fails when the service returns an error. To handle a response yourself instead, such as 404 not found, add it under **Expected statuses** in the **Retry** tab. Server errors are retried automatically.

The output is the status code and the response body:

```json
{
  "status_code": 200,
  "body": {
    "id": "cus_8Hk2pQ",
    "tier": "vip",
    "email": "jane.doe@example.com"
  }
}
```

You can select **Test request** to send the request once with sample values and choose which response fields become the step's outputs, or add the fields yourself.

![Test HTTP request dialog with a 200 response and the name and email fields selected as
outputs](/docs/_fern-files/_img/a631230d6a55535d67d91ce663726ead7690dc515edc0f991cefebcc86e5e661.webp)

## Tool

Use it to reuse an action you've set up for your agents. It runs one of your workspace [tools](/docs/eleven-agents/customization/tools): an integration such as your CRM, a webhook tool that calls your own API, a code tool that runs your JavaScript on ElevenLabs, or a tool from an MCP server. Tools that only work during a live conversation, such as client and system tools, can't run in a routine.

The step's inputs are the tool's parameters, and its output is the tool's response. Select **Test tool** to run it once with sample values. An MCP tool runs only when its server doesn't require approval for the call.

![Tool step running the create\_support\_ticket webhook tool, with its parameters set from variables
and a fixed value](/docs/_fern-files/_img/1aee5b8f829734f68f7d9f49fb8cf404b0529a25c929a70b95ee69fa186d3cf9.webp)

## Agent

Use it to have one of your agents handle a task with its own tools and knowledge base: look things up, take actions, write a reply, or decide what happens next.

Runs one of your agents on the **Instructions** you write, which can include the step's inputs as [dynamic variables](/docs/eleven-agents/customization/personalization/dynamic-variables), such as `{{customer_name}}`. The agent reads the instructions and replies once, in text, using its tools and knowledge base. Routines run in the background, so the agent can't use client tools. Each reply is saved as a conversation you can open from the run.

![Agent step with instructions that use the customer\_name input and a structured output with two
fields](/docs/_fern-files/_img/3312059e6d5a97983e06c58b6bd9689e544be81496e22afe0296d611d53f707b.webp)

The output is the agent's reply as `text`. To give later steps something to branch on, define fields under **Structured output** instead, such as a yes or no decision and a category:

```json
{
  "needs_callback": true,
  "category": "billing"
}
```

## Outbound call

Use it to have one of your agents call someone.

Places a call from one of the phone numbers you've added to ElevenAgents. Choose the **Voice agent** and **From number**, and set **To number** to the number to dial. **Agent variables** pass details to the agent, such as the customer's name, so it can use them on the call.

> **Warning**
>
> Outbound calling is regulated differently by country, state, and industry, so the right calling
> hours and attempt limits depend on who you call and why. You are responsible for outbound calling
> compliance, including consents and opt-outs, what the agent says, and managing next steps, and for
> setting limits that match the rules where your contacts live. See the [ElevenAgents Terms](https://elevenlabs.io/agents-terms) and the [TCPA guidance](/docs/eleven-agents/legal/tcpa)
> for details.

![Outbound call step with its voice agent, from and to numbers, calling hours, and
outputs](/docs/_fern-files/_img/e2e6a7ada7a3ecf1a0b44d65cc92e286b0f8f091eb3a727d8c095dcba1b59511.webp)

#### Calling hours

The step only dials inside its **Calling hours**, which default to 08:00 to 21:00 every day. If
your contacts are in different time zones, set **Time zone** to each contact's own, such as from
your CRM. Outside calling hours, the step waits for the next window, or fails, depending on
**Outside calling hours**.

#### Wait for the call to end

On by default. When the call ends, the step's output has its `outcome` (`completed`,
`voicemail`, `no_answer`, `busy`, `failed`, or `timed_out`) and the conversation, like the
[Conversation ended](/docs/eleven-agents/operate/routines/triggers#conversation-ended) trigger:

```json
{
  "outcome": "completed",
  "conversation_id": "conv_2301k6r4mz8tf0q7h5c9w1n3bx6e",
  "to_number": "+14155550123",
  "status": "done",
  "analysis": {
    "call_successful": "success",
    "transcript_summary": "The customer confirmed their appointment for Monday at 3 PM."
  }
}
```

An unanswered call has no transcript or analysis, so add a condition on `outcome` first, for
example to send a text when nobody answers.

#### Agents with Zero Retention Mode or encryption

The step can call with an agent that has Zero Retention Mode or conversation encryption on, but
it can't return that call's transcript or analysis, including opt-outs such as do-not-call
requests. Its output only has the call's `outcome`, `conversation_id`, and `status`. Opt-outs
from these calls aren't recorded, so you're responsible for honoring them.

Outbound call steps never retry, so nobody is called twice by mistake.

## Wait

Use it to pause before the next step, such as following up a day later.

Pauses the run for a set time, or until a time, such as 24 hours before an appointment. A wait can last up to 30 days.

When the time has already passed, such as an appointment that already started, the step can **Skip** the steps after it (the default), or **Continue without waiting**.