# Using agents in Flows

AI is not only a chat surface. **Draft with AI** is a
[flow action](../flows/actions.md), so automation can generate its own copy.

## Adding the step

1. Open a flow and add a step.
2. Choose **Draft with AI**.
3. Write the instruction under **What should it write?**

The step is named automatically, so a later step can read its draft as
`{{steps.run_ai_agent}}` — use **Insert variable** on the field that sends it
rather than typing the name.

The draft is written from the run's own data, so the instruction can describe the
job rather than restate the context.

## Drafting and sending are separate steps

The action stores text and stops. It never sends, tags, or writes anything on its
own. Follow it with the step that acts:

- **Draft with AI**, then **Send email** using the stored variable
- **Draft with AI**, then **Add private note** on the customer's timeline
- **Draft with AI**, then **Post to Slack or Lark** so the team sees the summary

Keeping the two apart means the send still obeys your sender, template, and
suppression rules, and a bad draft can never turn into an unintended action.

## How this differs from the AI workforce

The [AI employees](agents.md) you chat with have tools and can take
confirmation-gated actions on your behalf. The flow action is narrower on
purpose: text in, text out, no side effects.

## Related

- [AI-powered flows](../flows/ai-powered.md)
- [Flow actions](../flows/actions.md)
- [CoreX Agents](agents.md)
