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

# Building Workflows

> Learn how to build multi-agent workflows that automate complex business processes.

## Overview

Workflows connect multiple agents into automated pipelines. This guide covers designing, testing, and deploying production-ready workflows.

***

## Workflow Builder

You can create workflows using three methods:

**Visual Builder**

The drag-and-drop workflow builder in the MINDBLIX dashboard:

1. Navigate to **Workflows** → **New Workflow**
2. Drag agent nodes onto the canvas
3. Connect nodes with data flow edges
4. Configure each step's parameters
5. Click **Deploy**

**YAML Definition**

Define workflows as YAML configuration files:

```yaml theme={null}
name: Customer Support Pipeline
version: "1.0"
trigger:
  type: webhook
  path: /support/incoming

steps:
  - id: classify
    agent: text-classifier
    input:
      text: "{{ trigger.body.message }}"
    output:
      category: "{{ result.category }}"

  - id: respond
    agent: support-agent
    depends_on: [classify]
    input:
      category: "{{ steps.classify.output.category }}"
      message: "{{ trigger.body.message }}"

  - id: notify
    agent: notification-agent
    depends_on: [respond]
    condition: "{{ steps.classify.output.category == 'urgent' }}"
    input:
      channel: "slack"
      message: "{{ steps.respond.output.response }}"

output:
  response: "{{ steps.respond.output.response }}"
  category: "{{ steps.classify.output.category }}"
```

**Python SDK**

Build workflows programmatically:

```python theme={null}
from mindblix import Workflow, Step

wf = Workflow(
    name="Customer Support Pipeline",
    trigger="webhook:/support/incoming"
)

classify = Step(
    id="classify",
    agent="text-classifier",
    input={"text": "{{ trigger.body.message }}"}
)

respond = Step(
    id="respond",
    agent="support-agent",
    depends_on=["classify"],
    input={
        "category": "{{ steps.classify.output.category }}",
        "message": "{{ trigger.body.message }}"
    }
)

wf.add_steps([classify, respond])
wf.deploy()
```

***

## Testing Workflows

**1. Unit Test**

Test individual steps in isolation with mock data.

**2. Integration Test**

Test the full workflow with sample inputs.

**3. Load Test**

Simulate high-volume traffic to verify performance.

**4. Deploy to Staging**

Deploy to a staging environment before production.

> [!TIP]
>
> Use the `--dry-run` flag when deploying to validate your workflow configuration without actually executing it.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.