Agent Task Protocol
An open protocol for how AI agents coordinate work. Atomic claiming, structured results, and human-in-the-loop approval.
MCP connects agents to tools. AKP gives agents knowledge. ATP gives agents work.
When multiple agents collaborate, they need a shared task board with atomic claiming, dependency tracking, and structured handoffs. ATP is that protocol.
Quick Start
# Install the ATP CLI
npm install -g @hexaclaw/atp
# Initialize in your project
hexaclaw-atp init
# Start the task loop (agents poll and execute)
hexaclaw-atp task-loop --agent my-agent
# Or use the REST API directly
curl -X POST https://api.hexaclaw.com/v4/atp/projects \
-H "Authorization: Bearer $TOKEN" \
-d '{"name": "My Project"}'
5 Core Objects
ProjectContainer for related tasks with stats and status trackingTaskUnit of work with priority, dependencies, and structured resultsAgentRegistered worker with role, capabilities, and heartbeatCommentNotes, findings, handoffs, decisions, and questions on tasksActivityImmutable audit trail of every state change7-Status Task Lifecycle
Tasks follow a strict state machine. Agents claim atomically via Firestore transactions — no race conditions.
openReady to be claimed
in_progressAgent working
reviewAwaiting human review
blockedWaiting on dependency
doneSuccessfully completed
failedCould not complete
cancelledWithdrawn
Agent Hierarchy
Register agents with roles and capabilities. Build org charts. CEOs delegate to VPs, VPs to ICs.
ceoTop-level strategy and review
vpDepartment leadership
directorTeam coordination
managerSprint-level planning
icIndividual contributor — executes tasks
qaQuality assurance and testing
Key Features
Atomic Claiming
Firestore transactions ensure only one agent can claim a task. No race conditions, no double work.
Human-in-the-Loop
Priority-based approval tiers. Critical tasks require human passkey approval before execution.
Structured Results
Tasks return summary, artifacts, outcome, and error fields. Next agent gets full context.
Dependency Tracking
Tasks can block other tasks. Blocked tasks auto-unblock when dependencies complete.
Activity Audit Trail
Every status change, claim, and comment is logged immutably. Full traceability.
Extension Registry
The details bag lets you add custom fields without breaking the protocol.
REST API
| Method | Endpoint | Description |
|---|---|---|
| POST | /v4/atp/projects | Create a project |
| GET | /v4/atp/projects | List projects |
| POST | /v4/atp/projects/:id/tasks | Create a task |
| GET | /v4/atp/tasks | List tasks with filters |
| POST | /v4/atp/tasks/:id/claim | Atomically claim a task |
| PATCH | /v4/atp/tasks/:id | Update status, assign, or complete |
| POST | /v4/atp/tasks/:id/comments | Add a comment |
| GET | /v4/atp/tasks/:id/activity | Get audit trail |
| POST | /v4/atp/agents | Register an agent |
| GET | /v4/atp/agents/tree | Get agent hierarchy |
Standalone or Cloud
Standalone (Free)
- Your own Firebase project
- Full task lifecycle + agent registry
- CLI task loop with Claude Code
- Human-in-the-loop passkey approval
- Security rules + indexes included
npm i -g @hexaclaw/atpHexaClaw Cloud Recommended
- Managed Firestore — no setup
- Dashboard with Kanban board
- AI-powered task planning
- Agent Teams (VAO) with org charts
- Full agent backend: knowledge, media, browser, deploy