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

# Automations

> Native workspace workflows — triggers, actions, run history, and assistant webhook binding.

The **Automations** page is the workflow builder for your workspace. Build multi-step graphs with triggers, actions, test runs, and a full run history.

Your plan determines the included monthly automation runs. Runs beyond that allowance cost extra credits at the workspace's **Automation runs** rate; current rates are on the [Usage page](https://app.famulor.io/usage).

**AI steps** such as Custom Prompt, Extract Fields, and MCP Call Tool can use additional workspace credits. The charged amount appears in the run details and Test panel.

**Graph end:** A step with no outgoing connection completes the run successfully. Stop, Return variables, and Webhook respond end the run immediately and need no further connection.

## Automations vs. Agent Tools

Automations and Agent Tools are both ways for an assistant to act on outside systems, but at different moments. An automation is a fixed sequence of steps you (or Milian) design in advance — usually started by a background trigger like **On Call Completed**, though a Live automation can also be attached to an assistant as one callable action during a conversation (see **Calling an automation from a conversation** below). Either way, it runs the sequence you built, not something decided on the fly. For tools the assistant chooses and runs itself, live, the moment it needs them — looking something up, creating a record — see [Agent Tools](/assistants/agent-tools).

|                 | Automations (this page)                | Agent Tools                                |
| --------------- | -------------------------------------- | ------------------------------------------ |
| Runs            | Mostly in the background, on a trigger | Mid-conversation, while talking to someone |
| Steps chosen by | You or Milian, in advance              | The assistant, as it needs them            |

## Triggers

* **On Call Completed** — after a voice call ends (with analysis). Requires a **specific assistant**.
* **On Inbound Call** — when an inbound call starts.
* **Inject input variables** — provides assistant variables when a call starts. End with **Return variables**.
* **Email received** — when a new inbound email arrives.
* **Conversation started / ended** — messaging channel open / closed.
* **Message received** — every inbound message on a channel, not just the first.
* **Contact created** — a new Audience contact appears. Choose which sources trigger it: **Created manually** (the only one on by default), **CSV / file import**, **API**, and **CRM sync**. Leaving import and CRM sync off means a bulk import doesn't fire the automation for every row.
* **Incoming Webhook** — starts from the secure webhook URL shown in the trigger.
* **Booking created / cancelled / rescheduled**, **Manual**, **Schedule** (soon).
* **App events (Beta)** — connected apps such as Gmail or GitHub provide their own available triggers. Requires workspace **Beta Features**.

## Actions (plugins)

Organized as **Platform → type → action** (Famulor, AI, Time, WhatsApp, Telegram, X, HTTP, Slack, …).

* **AI:** Extract Fields, Custom Prompt
* **Time:** Delay For / Until, Get Current Date and Time, Convert Timezone, Format
* **Logic:** Condition, Filter, Switch, Random, Stop, Note, Set variable, Run Code, **Loop on Items**
* **Contacts:** Create/Update, Get by phone, List, Add tags/attributes
* **Calls:** Call Phone Number
* **Messaging:** SMS, workspace email, **Send Email (SMTP)** through a saved SMTP connection, channel messages on open conversations, and approved WhatsApp templates to E.164 numbers. The builder shows which actions use workspace messaging credits.
* **Knowledge:** Add / Delete / Get source
* **HTTP / webhooks:** HTTP Request, Slack / Discord / Teams Incoming Webhooks, **Webhook respond** (sync HTTP status/body for inbound webhooks)
* **CRM / SMTP / MCP connections:** reusable credentials under **Automations → Connections**. **Test Connection** verifies an SMTP relay and sends a test message to the configured address. Available integrations are listed in the connection picker.
* **Connected apps (Beta):** choose **Browse apps** in Connections to connect an available app. Its supported tools and triggers appear in the builder after connection. Requires workspace **Beta Features**.
* **Airtable actions:** List, **Find record**, **Search records**, **Find or create**, Get by id, Create / Create records (batch ≤10), Update, Delete.
* **MCP:** Call tool — connection + tool multi-select (or all) + agent prompt with flash variables; the agent picks the tool and fills arguments
* **Variables:** Return variables (for `call.variables`)

See the [Automation node reference](/automations/nodes) for every trigger and action's exact fields and behavior.

## Example automations

A trigger and a couple of actions are usually enough:

| Goal                   | Trigger           | Steps                                                                                   |
| ---------------------- | ----------------- | --------------------------------------------------------------------------------------- |
| Follow up after a call | On Call Completed | **Condition** on the call outcome → **Send WhatsApp Template** (or SMS) with next steps |
| Greet a new contact    | Contact created   | **Send WhatsApp Template**, or **Call Phone Number** to start a qualification call      |
| Remind about a booking | Booking created   | **Delay Until** the day before → **Send WhatsApp Template** with the appointment time   |

<Tip>
  Start with one trigger and one action, confirm it behaves the way you expect, then add branching. Reference trigger and step data (`{{data.call_id}}` from the trigger, `{{steps.step1.output}}` from an earlier step) instead of hardcoding values, branch with **Condition**/**Filter** rather than assuming an external call always succeeds, and use **Run test** on each step while you build — it runs against the connected app for real and fills Insert Variable with the actual output.
</Tip>

## Organizing automations

Automations support free-form **tags** for filtering and show the selected **assistant** when a trigger is assistant-specific. Create or update them through the UI, `POST/PATCH /api/v1/automations`, or MCP (`create_automation` / `update_automation`).

## Runs & failure alerts

The list page has **Automations** and **Runs** tabs. Use **Alert settings** to set a workspace inbox for failed runs and toggle alerts on/off.

When no custom email is set, alerts go to the workspace's configured support recipients and owners or admins. You can enable or disable failure alerts for each automation.

## Calling an automation from a conversation

An assistant can call an automation as a tool while a conversation is still in progress, not only once it ends. Under **Assistant → Settings → Automations → During conversation**, create an assistant-callable automation and describe, in plain language, when the assistant should use it — a free-text field the assistant reads before deciding to call it. The link connects automatically; build out the automation's steps, map its response, then switch the automation **Live**, since the assistant only calls automations that are Live.

This works the same way across voice, web chat, messaging, and email conversations, and an assistant can have more than one callable automation, each with its own description. Creating or unlinking one is an owner or admin action. It's separate from **On Call Completed** and the inbound triggers above, which fire outside the conversation instead of being called by the assistant itself.

## Assistant webhook binding

In the assistant Webhook card, choose **Automation** delivery and select an **On Call Completed** automation, or keep a custom HTTPS URL.

## Troubleshooting

**A WhatsApp step fails to send.** **WhatsApp Send Message** only works inside an already-open conversation (Meta's 24-hour service window). To reach someone outside it, use **Send WhatsApp Template** instead, and confirm that template is already approved for the sender you selected. See [WhatsApp](/channels/whatsapp#the-24-hour-window-and-templates) for the full window and approval rules.

**A step fails with an invalid number.** Actions expect E.164 (`+<country code><number>`) — add a country code before passing a national-format number through.

**A connector step fails on every run.** The underlying connection is likely disconnected or its token has expired. Reconnect it under **Automations → Connections**.
