Docs/Getting started/Quickstart

Quickstart

Get from zero to a running production-safe multi-agent workflow in under 5 minutes. No configuration required. Compliance, cost governance, and durable execution are on by default.

Sandbox first
Use mode='sandbox' to run full workflows with zero real API spend. Perfect for learning and development.

Prerequisites

Python 3.11+. Use MESHFLOW_MOCK=1 for local offline runs, or set an LLM provider key such as ANTHROPIC_API_KEY.

Step-by-step

1
Install MeshFlow
Install via pip. No platform dependencies.
bash
pip install meshflow
2
Choose a provider
Use Anthropic by default, or run offline with the mock provider.
bash
export ANTHROPIC_API_KEY=sk-ant-...
# or for a no-key local run:
export MESHFLOW_MOCK=1
3
Create your first workflow
The 7-line promise. Production-safe out of the box.
python
# workflow.py
from meshflow import Workflow, Agent, CostCap

wf = Workflow(cost_cap=CostCap(usd=5.00), mode="sandbox")
wf.add(Agent(name="researcher", role="researcher"), Agent(name="analyst", role="researcher"), Agent(name="writer", role="executor"))
result = wf.run("Write a competitive analysis of Flowise")
print(result.output)
4
Inspect the result
Every result includes output, token usage, cost, run ID, and ledger location.
python
print(result.output) # final agent output
print(result.cost_usd) # e.g. 0.0042
print(result.run_id) # replay / audit lookup key
print(result.ledger_db) # audit ledger database
Remove sandbox for production
Drop mode='sandbox'when you're ready to ship. All guardrails remain active automatically.

What just happened?

Behind those 7 lines, MeshFlow compiles the agents into a governed Team, applies a standard policy with the requested CostCap, routes sandbox runs through the offline provider, and records every step into the replay/audit ledger.

You didn't configure any of it. That's the point.