The HUD CLI provides a complete toolkit for creating, developing, and running MCP environments. Commands are organized into two main workflows:Documentation Index
Fetch the complete documentation index at: https://hud-f5fd7c15-feat-agent-orchestrator-cookbook.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Build & Ship
Directory-based commands for creating and sharing environments:
hud init— Create new environmenthud dev— Develop with hot‑reloadhud build— Build and generate lock filehud push— Share to registry
Run & Evaluate
Target-based commands for using environments and agents:
hud analyze— Inspect capabilities (fast/live)hud debug— 5‑phase compliance testhud run— Execute (Python module/command/Docker)hud eval— Run agents on tasks/datasetshud rft— Fine-tune models (BETA, invite-only)
Installation
Commands
Building Workflow
| Command | Input | Description | Example |
|---|---|---|---|
hud init | Directory | Create new environment | hud init my-env |
hud dev | Directory | Hot-reload development | hud dev . --interactive |
hud build | Directory | Build image & lock file | hud build . --tag v1.0 |
hud push | Directory | Share to registry | hud push . --tag prod |
Running Workflow
| Command | Input | Description | Example |
|---|---|---|---|
hud analyze | Image or config | Inspect tools & capabilities | hud analyze org/env |
hud debug | Image/dir/config | 5‑phase compliance test | hud debug my-env:latest |
hud run | Module/command/image | Execute server (local/remote) | hud run controller --reload |
hud eval | Tasks/dataset | Run agent on tasks | hud eval tasks.json claude |
hud rft | Tasks file | Fine-tune models (BETA, invite-only) | hud rft run tasks.json |
Other Commands
| Command | Description | Example |
|---|---|---|
hud get | Download HF dataset to tasks file | hud get hud-evals/2048-basic -o tasks.jsonl |
hud quickstart | Clone quickstart repo | hud quickstart |
hud cursor-list | List Cursor MCP servers | hud cursor-list |
hud version | Show CLI version | hud version |
hud clone | Clone any git repo (pretty output) | hud clone https://github.com/... |
hud set | Persist API keys to ~/.hud/.env | hud set HUD_API_KEY=... |
Complete Workflows
Building an Environment
Initialize
Create a new HUD environment with minimal boilerplate:Creates
Dockerfile, pyproject.toml, controller/ (MCP server), optional environment/ backend, tasks.json.Develop
Run with hot-reload and interactive testing:Your changes reload automatically. Test tools interactively with arrow keys.
Build
Create production image and lock file:Generates
hud.lock.yaml with metadata and labels image for reproducibility.Running an Environment
Common Usage
Docker Images
Arbitrary Commands (Python/Node/etc.)
Cursor Integration
Output Formats
Interactive (Default)
JSON
Markdown
CI/CD Example
Python Scripting
Exit Codes
| Code | Meaning | Description |
|---|---|---|
| 0 | Success | Command completed |
| 1 | General Error | Command failed |
| 2 | Usage Error | Invalid arguments |
| 3 | Connection Error | Failed to connect |
| 4 | Timeout | Operation timed out |
| 5 | Protocol Error | MCP violation |
Environment Variables
Next Steps
Building Commands
Init Command
Create new environments from scratch
Dev Command
Develop with hot-reload and interactive testing
Build Command
Build images and generate lock files
Push Command
Share environments to registry
Running Commands
Analyze Command
Inspect tools and capabilities
Debug Command
Test MCP protocol compliance
Run Command
Execute servers locally or remotely