# Overview

Canonical URL: https://developers.iagenify.com/sdk/workflows/
Language: en

A name, a trigger, steps and the edges between them. Everything that can be checked is checked when you save it — because a workflow fails where nobody is watching.

Status: 30 steps · 23 types · validated on save

```javascript
{
  name: "Weekly digest",
  trigger: { type: "cron", cron: "0 8 * * 1" },
  steps: [
    { id: "read",  type: "storage.query",  config: { … } },
    { id: "write", type: "model.generate", config: { … } },
  ],
  edges: [
    { from: "__trigger", to: "read" },
    { from: "read", to: "write" },
  ],
}
```

| Name | Type | Requirement | Description |
| --- | --- | --- | --- |
| `name` | string | required | What it is called. |
| `trigger` | object | required | `manual` · `cron` · `webhook` · `mail`. |
| `steps` | array | required | One to 30 steps. |
| `edges` | array |  | The graph. Absent means the order of `steps` is the chain. |

## Step identifiers {#ids}

A letter, then letters, digits, underscores or dashes, 40 characters at most, unique in the workflow. They are what templates and edges name, so they are worth choosing readably: `draft`, `approve`, `send`.

## Templates {#templates}

| Written | Reads |
| --- | --- |
| `{{input.since}}` | The run's input. |
| `{{steps.read.output.result}}` | An upstream step's output. |

A reference to a step the workflow does not hold, or to one that is **not upstream**, is refused when the workflow is saved — see [Errors](/sdk/workflows/errors).

## Three step types require a human step {#approval}

> **mail.send, hosting.deploy and domain.records**
>
> Each one acts outside the account, and a run has nobody to ask. A human step must be upstream on the path that reaches it — and a definition without one is refused when you save it.

## The rest of this branch {#pages}

- [Edges and branches](/sdk/workflows/edges): The graph, and what each shape requires.
- [Templates](/sdk/workflows/templates): Reading input and upstream outputs.
- [Errors](/sdk/workflows/errors): Every refusal, and what it means.

- [Workflow steps](/sdk/workflows/steps): The 23 types.
- [Warnings](/sdk/workflows/warnings): What a step says without failing.

```python
{
    "name": "Weekly digest",
    "trigger": {"type": "cron", "cron": "0 8 * * 1"},
    "steps": [
        {"id": "read", "type": "storage.query", "config": {}},
        {"id": "write", "type": "model.generate", "config": {}},
    ],
    "edges": [
        {"from": "__trigger", "to": "read"},
        {"from": "read", "to": "write"},
    ],
}
```
