Skip to content

Local Development (Python)

Looking for Java? See Java Local Development | 📘 Looking for TypeScript? See TypeScript Local Development

Develop MCP Mesh agents locally with Python

Development Workflow

graph LR
    A[Install] --> B[Scaffold]
    B --> C[Run]
    C --> D[Call & Debug]
    D --> C

Guides

Guide What You'll Learn
Getting Started Install meshctl CLI and Python SDK
Scaffold Agents Generate agents with meshctl scaffold
Run Agents Start agents with hot reload, debug mode
Inspect the Mesh View agents, tools, and dependencies
Call & Debug Tools Call tools and trace distributed calls
Troubleshooting Common issues and solutions

Quick Reference

# Install CLI
npm install -g @mcpmesh/cli

# Set up Python (at project root)
python3 -m venv .venv
source .venv/bin/activate
pip install "mcp-mesh>=0.8,<0.9"
deactivate  # meshctl auto-detects .venv

# Scaffold (interactive wizard)
meshctl scaffold

# Run
meshctl start main.py
meshctl start -w main.py          # hot reload
meshctl start --debug main.py     # debug mode

# Inspect
meshctl list                      # agents
meshctl list --tools              # all tools
meshctl status                    # wiring details

# Call
meshctl call get_weather '{"city":"London"}'
meshctl call --trace get_weather  # with tracing

# Debug
meshctl trace <trace-id>          # view call tree
meshctl logs my-agent -f          # follow logs
meshctl man --list                # built-in docs