Examples & Troubleshooting
Examples
Set Up Multiple Environments
1# Create contexts for each environment2orcher config set-context local --server http://localhost:80803orcher config set-context staging --server https://staging.orcher.example.com --namespace staging4orcher config set-context production --server https://orcher.example.com --namespace prod56# Authenticate to production7orcher config use-context production8orcher auth login --device --provider github910# Switch between contexts11orcher config use-context staging12orcher workflow list1314orcher config use-context production15orcher workflow listStart and Monitor a Workflow
1# Run a workflow with parameters2orcher run process-order --param order_id=123 --param amount=99.9934# Check status5orcher workflow list --status running67# View execution journal8orcher workflow history wf-abc123910# Send an event11orcher workflow event wf-abc123 --name approval --payload '{"approved": true}'1213# View logs14orcher logs wf-abc123 --followMonitor Queue Health
1# Check queue depths2orcher queue depth --watch34# View queue statistics5orcher queue stats payment-tasks67# See active pollers8orcher queue pollers payment-tasks --verboseServer Management
1# Start server in foreground2orcher server start --foreground --log-level debug34# Check server health5orcher server status --verbose67# Restart gracefully8orcher server restart910# Force stop11orcher server stop --forceTroubleshooting
Connection Refused
The CLI tries gRPC first, then falls back to HTTP. If both fail:
1# Check server status2orcher server status34# Test connection to a specific context5orcher config test-connection --context productionAuthentication Issues
1# Check auth status2orcher auth status34# Re-authenticate5orcher auth logout6orcher auth login --device --provider github78# Use token directly9export ORCHER_TOKEN="your-token"10orcher workflow listDebug Mode
1# Enable verbose output for any command2orcher -v workflow list34# Combine with quiet to see only errors5orcher -q server startGetting Help
1# Show help for any command2orcher --help3orcher workflow --help4orcher server start --helpCommand Reference Summary
| Command | Alias | Description |
|---|---|---|
orcher new | n | Create projects, workflows, tasks |
orcher workflow | wf | Manage workflow executions |
orcher namespace | ns | Manage namespaces |
orcher server | — | Manage server processes |
orcher queue | q | View and manage task queues |
orcher run | — | Run workflows locally or remotely |
orcher describe | desc | Show detailed resource info |
orcher logs | — | View execution logs |
orcher test | — | Test workflows locally |
orcher status | — | Show resource status |
orcher config | — | Manage CLI configuration |
orcher auth | — | Manage authentication |
orcher dev | — | Development mode |