REST-based protocol for AI agent communication. Send messages, delegate tasks, and coordinate multi-agent workflows. Supports all data modalities.
ACP (Agent Communication Protocol) is a REST-based protocol that enables AI agents to communicate, coordinate tasks, and exchange information in real-time. It’s designed for asynchronous, reliable communication between agents regardless of their underlying framework or deployment location.
ACP supports sending and receiving all types of data:
Agent A ACP Queue Agent B
│
├──→ POST /api/acp/messages ──→ [Queue] ──→ GET /webhook ──→ Process
│ ↓
└─← Response with messageId [Persist]
↓
[Deliver]
ACP integrates with the 6-dimension ontology:
groupId| Aspect | ACP | MCP | A2A |
|---|---|---|---|
| Primary Use | Agent messaging | Resource access | Task coordination |
| Architecture | REST/HTTP | Protocol/Tools | Framework integration |
| Real-time | Async queuing | Streaming | Sync & async |
| Stateful | Stateless | Stateful | State-dependent |
How this protocol maps to the 6-dimension ontology
ACPs operate within group boundaries with group-scoped message queues
Each agent has a role-based access control determining what messages it can send/receive
Agents are represented as things with type: 'intelligence_agent' and properties.protocols.acp
Messages create transacted connections between agents
Each message triggers a communication_event with metadata.protocol: 'acp'
Message content can be indexed and searched via embeddings
Send text, images, audio, video, and structured data between agents
Built for asynchronous communication with guaranteed delivery
Agents can delegate work to other agents with tracking
Intelligent routing of messages based on agent capabilities
Coordinate work across planning, execution, and verification agents
Query multiple specialist agents in parallel for different data needs
Break down complex tasks and delegate subtasks to specialized agents
Enable dynamic conversation and negotiation between AI systems
// Send ACP message from one agent to another
const message = {
from: "agent_planner_123",
to: "agent_researcher_456",
contentType: "application/json",
body: {
task: "Research competitive landscape",
deadline: "2025-10-31",
resources: ["web_search", "reports_database"]
},
timestamp: Date.now()
};
const response = await fetch('/api/acp/messages', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-Agent-ID': 'agent_planner_123'
},
body: JSON.stringify(message)
});
const result = await response.json();
console.log(`Message sent: ${result.messageId}`);
// Server handler for incoming ACP messages
import { mutation } from "./_generated/server";
export const receiveMessage = mutation({
args: {
messageId: v.string(),
fromAgentId: v.string(),
toAgentId: v.string(),
contentType: v.string(),
body: v.any()
},
handler: async (ctx, args) => {
// Create a thing for this message
const thingId = await ctx.db.insert("things", {
type: "message",
name: `Message from ${args.fromAgentId}`,
groupId: ctx.auth?.getOrganizationId?.(),
properties: {
protocols: {
acp: {
messageId: args.messageId,
contentType: args.contentType,
body: args.body
}
}
},
status: "active",
createdAt: Date.now(),
updatedAt: Date.now()
});
// Log as event
await ctx.db.insert("events", {
type: "communication_event",
groupId: ctx.auth?.getOrganizationId?.(),
actorId: args.fromAgentId,
targetId: thingId,
metadata: {
protocol: "acp",
action: "message_received",
contentType: args.contentType
},
timestamp: Date.now()
});
return thingId;
}
});
// Delegate a task using ACP
const taskDelegation = {
from: "agent_orchestrator_789",
to: "agent_executor_012",
taskType: "execute_plan",
taskData: {
planId: "plan_abc123",
steps: [
{ id: 1, action: "validate", resource: "data_source_1" },
{ id: 2, action: "transform", resource: "data_source_2" },
{ id: 3, action: "publish", resource: "output_sink" }
]
},
metadata: {
priority: "high",
timeout: 3600000, // 1 hour
retryPolicy: "exponential"
}
};
// Create connection for this delegation
const delegationId = await ctx.db.insert("connections", {
type: "delegated_to",
fromId: args.fromAgentId,
toId: args.toAgentId,
groupId: ctx.auth?.getOrganizationId?.(),
metadata: {
protocol: "acp",
taskType: taskDelegation.taskType,
taskData: taskDelegation.taskData
},
validFrom: Date.now(),
validTo: Date.now() + 3600000
});