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

# Workflows

> Understand how your agent's workflow is structured

## What Is a Workflow?

A workflow is the step-by-step plan your agent follows to complete a task. When you describe what you want and hit **Build**, Decisional turns it into a sequence of steps that run one after another.

Each step is a node. Each node is connected to the next step by an edge, which shows what happens next.

## Nodes

Nodes are the building blocks of a workflow. Each node owns one piece of work: starting the run, reading or transforming data, calling an app, asking for a decision, or generating output.

When an agent runs, Decisional executes the nodes in order and passes data from one step to the next through the workflow edges. This keeps the agent's process inspectable: you can see what each step did, what it received, what it produced, and where the run paused or failed.

### Node Types

Workflows are made up of different node types, each handling a specific kind of work:

<CardGroup cols={2}>
  <Card title="Trigger Node" icon="bolt">
    The starting point of every workflow. Defines how the agent gets activated — manual run, schedule, webhook, or an event from a connected app.
  </Card>

  <Card title="Task Node" icon="list-check">
    The core workhorse. Reads data, processes information, makes decisions, and produces output. Most of your workflow logic lives here.
  </Card>

  <Card title="Action Node" icon="paper-plane">
    Takes an action in an external app or system of record. Action nodes are flagged during testing so you can approve before they execute.
  </Card>

  <Card title="Gate Node" icon="user-check">
    Pauses the workflow for a human decision. Use gates before final sends, publishes, record updates, or other steps that require sign-off.
  </Card>

  <Card title="AI Node" icon="microchip-ai">
    Runs a bounded AI model step to classify, summarize, extract, transform, or generate content from inputs passed through the workflow.
  </Card>

  <Card title="Agent Node" icon="robot">
    Runs an agentic step inside a managed computer with model access, tools, files, and the right harness for the task. Use this when a workflow step needs judgment, tool use, or multi-step reasoning.
  </Card>
</CardGroup>

## Viewing Your Workflow

After your agent builds, click the **Workflow** tab to see the visual graph. Each node is displayed with:

* Its **name** and a short description of what it does
* Its **type** (trigger, task, action, AI, agent, gate)
* **Connections** showing the flow of data between steps

You can zoom, pan, and click on any node to see its details and the code it runs.

## Agent Nodes

Agent Nodes let a workflow run an agentic step, not just call a model. The node gives the model a harness: instructions, context, files, compute, and the tools it needs to complete that part of the workflow.

This is useful for:

* **Tool-backed reasoning** — inspect files, call tools, compare results, and decide what should happen next
* **Computer work** — operate in a managed environment with files, code, and execution context
* **Multi-step investigation** — break down an ambiguous task, gather missing context, and produce a decision or artifact
* **Workflow repair** — diagnose why a step failed and attempt the next best fix when the issue is technical

The Agent Node takes input from previous nodes, works inside its harness, and produces output that flows to the next step.

## AI Nodes

AI Nodes run a bounded model step inside the workflow. Use an AI Node when the job is clear, the required inputs are already available, and the step does not need an agent harness or tool use.

This is useful for:

* **Classification** — categorize emails, tickets, or documents into types
* **Summarization** — condense long content into key points
* **Extraction** — pull structured data from unstructured text
* **Generation** — write responses, draft emails, or create content

The AI Node takes input from previous nodes and returns model output that flows to the next step.

## Gate Nodes

Gate Nodes are explicit human approval checkpoints in a workflow. They do not run code or produce new output fields. Instead, they pause the workflow before downstream nodes run, then pass the same input data forward after the gate is approved.

Use a Gate Node when the workflow needs a named person or group to make a decision before continuing, such as manager approval before sending a customer email, finance approval before updating a record, or legal approval before publishing generated content.

Gate Nodes are different from approval flags on Action Nodes:

| Approval type            | How it works                                                                                                                      |
| ------------------------ | --------------------------------------------------------------------------------------------------------------------------------- |
| **Action Node approval** | A simple approval pause attached to a specific action, often used before a write, send, publish, or external-system update.       |
| **Gate Node**            | A standalone workflow checkpoint with designated owners, approval instructions, voting rules, and optional public approval links. |

### Gate Owners

Each Gate Node has one or more owners. Owners are the only people who can approve or reject that gate. The gate can be configured in two modes:

| Owner mode                  | What happens                                                                                              |
| --------------------------- | --------------------------------------------------------------------------------------------------------- |
| **Any owner can approve**   | The first owner approval resolves the gate and the workflow continues. A rejection fails the gate.        |
| **All owners must approve** | Every listed owner must approve before the workflow continues. A rejection from any owner fails the gate. |

Gate settings can also include approval instructions, which are shown to approvers with the request, and shareable public links so external approvers can review without signing in.

During build runs, Gate Nodes are skipped for observability. During test and live runs, they pause execution until the approval rule is satisfied or the gate is rejected.

## How Workflows Get Built

You do not need to design workflows manually. Here's the process:

1. **You describe** what you want in plain English
2. **Decisional generates** the workflow — choosing node types, wiring them together, and writing the logic
3. **You review** the workflow in the visual viewer
4. **You can modify** the workflow in Operator Mode

If you need to make changes after building, use Operator Mode in the Decisional web app for configuration-level edits.

## Action Node Approvals

Action nodes are special because they affect external systems or records. During testing and configured review flows:

* Your agent **pauses** before executing each action node
* You see a **preview** of what the action will do
* You can **approve** or **reject** each action individually

This gives you a review point before sensitive actions touch real data or apps.

Approval behavior is controlled by the agent's approval mode, workspace tool policy, and any explicit gate nodes in the workflow. A live agent can ask for approvals, bypass eligible approvals, or block actions depending on that policy.

<Card title="Approvals and Policy" icon="user-check" href="/agents/approvals">
  Learn how Ask approvals, Bypass approvals, global settings, and tool policies work.
</Card>
