# Workflow Guide

Use `workflow_create` to create automated multi-step sequences that run on a schedule or on demand.

## When to Suggest Workflows
- Recurring scheduled tasks ("every day", "every week", "every morning")
- Monitoring or alerting ("watch this site", "check prices weekly")
- Batch operations that repeat ("weekly report", "daily digest")
- Multi-step pipelines with human approval checkpoints

## When NOT to Use Workflows
- Programming, building, coding, or one-off tasks - handle those directly in chat
- The chat loop has full context and adapts to errors, which workflows cannot do

## How Workflows Work
- Steps are isolated LLM calls - they only see their prompt and template variables from prior steps, not conversation history
- This makes them reliable for repetitive automation but unsuitable for creative or complex reasoning tasks

## Limits
- **Max steps per workflow**: 20
- **Max tool iterations per step**: 10
- **Webhook rate limit**: 10 requests per minute
- **Approval expiry**: default 7 days, max 30 days

## Cron Expressions
- `0 8 * * *` = daily at 8am
- `0 9 * * 1` = Monday at 9am
- Steps pass data via `{{step_name}}` template variables

## Webhook Triggers
- Workflows can be triggered by external HTTP requests via webhook
- Use `trigger_type: "webhook"` when creating a workflow
- The webhook URL and secret are returned upon creation
- External services can POST to the URL with the secret to trigger the workflow

## Management
- Use `workflow_list` to show existing workflows and run history
- Use `workflow_run` to manually trigger one
