Distributed task queue and agent coordinator for OpenClaw multi-agent systems. Route tasks to specialized agents by capability matching, track task lifecycle, handle async handoffs, rebalance loads, and manage dead letters. Use when: (1) Creating tasks programmatically or from heartbeats, (2) Routing work to specialized agents based on capabilities, (3) Monitoring task status and completion, (4) Coordinating multi-step workflows across agents, (5) Handling async agent work without blocking main sessions.
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
A direct command skips the review prompt. Inspect the source before running it.
Distributed task queue and agent coordinator for OpenClaw multi-agent systems. Route tasks to specialized agents by capability matching, track task lifecycle, handle async handoffs, rebalance loads, and manage dead letters. Use when: (1) Creating tasks programmatically or from heartbeats, (2) Routing work to specialized agents based on capabilities, (3) Monitoring task status and completion, (4) Coordinating multi-step workflows across agents, (5) Handling async agent work without blocking main sessions.
Task Router
Distributed task queue for OpenClaw multi-agent systems. Central coordination, async handoffs, capability-based routing.
Quick Start
# Install skill
clawhub install task-router
# Register an agent
task agent register watson --capabilities "research analysis" --max-concurrent 3
# Create a task
task create --type research --title "Competitor analysis" --priority high
# Router runs automatically via heartbeat# Check task status
task list --status pending
task show task-abc123
What This Does
Core Functions:
Enqueue: Create tasks from any session (main or sub-agent)
Route: Match tasks to agents by capabilities
Track: Monitor task lifecycle (pending → active → complete/failed)
Async Coordination: Hand off work, check back later
Dead Letter: Handle timeouts and failures
Rebalance: Move stuck tasks, retry with fallbacks
Use Cases:
Heartbeat creates research task → auto-routes to research agent
Main agent spawns work → goes async, checks later
Multi-step workflows: Task A output → Task B input
Agent failure → task reassigned to backup agent
Load balancing across multiple agents with same capabilities
router:check_interval:30# Seconds between router runsdefault_ttl:3600# Default task timeoutmax_retries:2strategies:default:least-loaded# round-robin | least-loaded | priorityby_type:research:least-loadedimage_gen:round-robinurgent:priorityhealth:agent_timeout:300# Mark agent unhealthy after secondstask_timeout:warning:1800# Alert at 30 mincritical:3600# Fail at 1 hournotifications:on_complete:trueon_fail:truechannels: [main_session] # Could add Discord, etc.
~/.openclaw/task-router/dead-letter/
├── task-failed-001.yaml # Task with final error state
├── task-failed-002.yaml
└── index.yaml # Summary for admin review
# Review failed tasks
task dead-letter list
task dead-letter show task-failed-001
# Actions
task dead-letter retry task-failed-001 # Force retry
task dead-letter reassign task-failed-001 --to watson
task dead-letter archive task-failed-001 # Ack and archive
Best Practices
Task Design:
Keep payloads JSON-serializable (no circular refs)