CLI Reference
thresh provides a comprehensive set of commands for managing WSL development environments, AI-powered blueprint generation, MCP server integration, and fleet management via Thresh Hub.
New in v1.7.0
Thresh v1.7.0 introduces Hub authentication, remote node management, and cluster orchestration:
thresh auth login/logout/status/token— authenticate the CLI with Thresh Hubthresh node list/info/metrics/up/blueprints/remove— manage fleet nodes remotelythresh cluster list/create/info/add-node/remove-node/delete— organize nodes into clusters- Hub-managed stacks — deploy multi-service stacks through the Hub dashboard and API
New in v1.6.0
Thresh v1.6.0 introduces agent mode for connecting nodes to Thresh Hub:
thresh agent start/stop/status— manage the agent daemonthresh agent config— configure Hub URL, API key, transport, and HA failover- SignalR WebSocket connection with automatic REST fallback
- Real-time metrics streaming to Thresh Hub
New in v1.5.0
Thresh v1.5.0 introduces networking and storage features:
- Port mapping and forwarding for WSL environments
- Persistent volumes and bind mounts
- New commands:
thresh startandthresh stopfor lifecycle management - WSL configuration profiles for database optimization
New in v1.4.0
Thresh v1.4.0 introduces grouped blueprint commands for better organization:
thresh blueprints→thresh blueprint listthresh generate→thresh blueprint generate- New:
thresh blueprint deleteto remove generated blueprints
Quick Overview
| Command | Description |
|---|---|
up | Provision a new environment from a blueprint |
start | Start a stopped environment and apply port forwarding |
stop | Stop a running environment and remove port forwarding |
list | List all thresh-managed environments |
destroy | Remove an environment |
blueprint | Manage blueprints (list, generate, delete) |
blueprint list | List available blueprints |
blueprint generate | Generate custom blueprint using AI |
blueprint delete | Delete a generated blueprint |
chat | Interactive AI chat for environment planning |
auth | Authenticate CLI with Thresh Hub (v1.7.0) |
agent | Connect node to Thresh Hub (v1.6.0) |
node | Manage remote fleet nodes (v1.7.0) |
cluster | Organize nodes into clusters (v1.7.0) |
distros | List available distributions |
distro | Manage custom distributions |
config | Manage configuration settings |
wslconf | Manage WSL configuration profiles |
volume | Manage persistent volumes |
serve | Start MCP server |
metrics | Show performance metrics |
version | Show version information |
Command Categories
Environment Management
- up - Create new environments
- start - Start stopped environments (v1.5.0)
- stop - Stop running environments (v1.5.0)
- list - View all environments
- destroy - Remove environments
Blueprint Management
- blueprint - Manage blueprints (parent command)
- blueprint list - List available blueprints
- blueprint generate - Generate custom blueprints with AI
- blueprint delete - Delete generated blueprints
AI Features
- chat - Interactive AI assistant
Configuration
- config - Manage settings
- distro - Custom distributions
- distros - View distributions
- wslconf - WSL configuration profiles (v1.5.0)
Storage
- volume - Manage persistent volumes (v1.5.0)
Fleet Management
- auth - Authenticate with Thresh Hub (v1.7.0)
- agent - Connect to Thresh Hub (v1.6.0)
- node - Manage remote fleet nodes (v1.7.0)
- cluster - Organize nodes into clusters (v1.7.0)
Stacks (Hub-Managed)
- Stacks - Deploy multi-service stacks via Hub dashboard and API (v1.7.0)
Integration
- serve - MCP server for AI editors
Information
Global Options
All commands support these global options:
| Option | Description |
|---|---|
--help, -h | Show help information |
--verbose, -v | Enable verbose output |
--quiet, -q | Suppress non-error output |
--version | Show version information |
Getting Help
For any command, use --help to see detailed usage:
thresh --help # Show all commands
thresh up --help # Show help for 'up' command
thresh config --help # Show help for 'config' command
Exit Codes
thresh uses standard exit codes:
| Code | Meaning |
|---|---|
0 | Success |
1 | General error |
2 | Invalid arguments |
3 | WSL not available |
4 | Environment not found |
5 | Configuration error |
Examples
See individual command pages for detailed examples and use cases.