DEV Community

weiwuji
weiwuji

Posted on

A2A Protocol: When Your Agent Starts Talking to Other Agents

The Pain: Your agent can fetch email, calculate rates, write reports — but it only works alone. A full flow like "check rate → ask client → update quote → send email" makes it run in circles, breaking at every handoff.
What You'll Learn: A2A (Agent-to-Agent) protocol — one of 2026's three agent-interconnect protocols — and how multi-agent collaboration actually works.


Hot-Term Primer: The "Three Protocols" of 2026 Agent Interconnect

Three acronyms are everywhere lately. Let's demystify them in 30 seconds:

Protocol Full Name Solves Analogy
MCP Model Context Protocol Agent ↔ Tool USB
A2A Agent-to-Agent Agent ↔ Agent Phone
AG-UI Agent User Interface Agent ↔ Human Screen

Why did these protocols suddenly explode in 2026?

Three reasons stacked:

  1. Agents moved from single-point to systems: in 2025 everyone built "one agent doing one thing"; in 2026 it's "many agents collaborating on a full workflow" — collaboration needs standards
  2. Big-tech competition drove standardization: Anthropic pushed MCP, Google pushed A2A, OpenAI/Microsoft followed — whoever's standard wins owns the agent ecosystem entry
  3. Commercial necessity: companies won't pay for an "island agent," but they'll pay for a "collaborative, extensible, swappable" agent system — protocols are that system's interface standard

In one line: the protocol layer is 2026's main battleground for agent infrastructure — MCP manages tools, A2A manages collaboration, AG-UI manages interaction.


2026 Agent Interconnect: 3 Protocols
MCP (tool) / A2A (agent) / AG-UI (human) — the protocol trio.


The Problem: The "Flow Breakage" of a Solo Agent

My logistics agent started as a monolith — one agent handling everything. Facing a complete business flow, it broke constantly:

User: check shipping cost for this batch, then tell the client the latest quote

Solo agent processing:
① Check rate ✅
② Generate quote ✅
③ "Tell the client" → STUCK here
   It knows to send an email, but not who the sender is, what template to use,
   or whether there's prior correspondence
   → asks user, or guesses, or errors out
Enter fullscreen mode Exit fullscreen mode

Root cause: a monolith crams all capabilities into one "brain," but each step's knowledge (rate DB for quoting, email SOP for sending) belongs to different scenes. Mixed in one context, they interfere.


What Is A2A: The "Standard Conversation Protocol" Between Agents

A2A (Agent-to-Agent), led and open-sourced by Google, defines a standard for how agents discover each other, launch tasks, pass results, and report status.

Core concepts:

Concept Role
Agent Card Each agent's "business card" — what it can do, how to invoke it
Task Inter-agent task (stateful: pending/running/completed/failed)
Message Message exchange within a task (input, output, events)
Artifact Files/data produced (reports, quotes, analysis)

Analogy: A2A is the "HTTP + REST" of the agent world — define a uniform request/response format, and any A2A-implementing agent can collaborate with any other.


Multi-Agent Collaboration
Scheduler decomposes tasks → dispatches to specialized agents.


My Practice: No SDK, But "Agent Division of Labor" First

I haven't adopted the A2A SDK layer yet (project not big enough), but I immediately applied its core idea — split big tasks into multiple collaborating agents.

I split my logistics business into 4 "specialist agents":

Agent Specialty Handles
Email Agent IMAP/SMTP receive, classify, reply
Quoting Agent rate DB / history rate lookup, quotes
Report Agent data sources in-transit / daily / monthly
Scheduler Agent routing decides who gets which task

Collaboration flow (hand-written "protocol"):

# Simplified: inter-agent task passing (mimics A2A Task semantics)
class AgentTask:
    def __init__(self, from_agent, to_agent, action, payload):
        self.from_agent = from_agent
        self.to_agent = to_agent
        self.action = action        # e.g. "calc_rate" / "send_email"
        self.payload = payload      # e.g. {"origin": "SH", "dest": "NY"}
        self.status = "pending"     # pending → running → completed/failed

# Scheduler dispatches "calc rate" to the quoting agent
task = AgentTask(
    from_agent="scheduler",
    to_agent="quoting_agent",
    action="calc_rate",
    payload={"origin": "SH", "dest": "NY", "weight": 100},
)
result = quoting_agent.handle(task)
# returns {"status": "completed", "artifact": {"rate": 3.5, "currency": "USD"}}
Enter fullscreen mode Exit fullscreen mode

Each agent does only what it's best at — clean context, no interference. That's A2A's core value: even without its protocol, adopt its "division of labor" thinking.


The Payoff: From "Flow Breakage" to "Pipeline Collaboration"

After splitting into multi-agents, the flow that used to break became:

User: check rate and inform the client

Scheduler Agent:
  ① Recognize task → split into two subtasks
  ② Dispatch "check rate" to Quoting Agent → get result
  ③ Dispatch "send email" to Email Agent → sent
  ④ Aggregate → reply to user

Fully automatic, zero breakage.
Enter fullscreen mode Exit fullscreen mode
Dimension Mono Agent Multi-Agent
Full-flow completion 60% (handoffs break) 95%+
Context interference high (all scenes mixed) low (each agent independent)
Fault localization hard (one brain) easy (per agent)
Adding capability change everything add one agent

Practical conclusion: multi-agent collaboration's value isn't "looking advanced" — it's "each agent has clean context, does its own job, and the flow never breaks."


Mono vs Multi-Agent
Collaboration is 2026's theme — not solo agents.


When to Move to Real A2A

Like MCP, if you manually schedule a few agents in your own project, the "division of labor" thinking above is enough. Real A2A is for:

  1. Cross-team / cross-org agent collaboration — your agent calling another company's agent
  2. Dynamic capability discovery — you don't know who can do the task; you need "Agent Card" discovery
  3. Heterogeneous agent interop — agents from different frameworks (LangGraph / self-built / CrewAI) collaborating

Where You Are Now

You're no longer the anxious developer whose "one agent does everything" breaks at every seam. You're becoming an architect who builds business systems with task decomposition + agent division of labor.

MCP solves "agents using tools," A2A solves "agents using other agents." In 2026, together they form the "infrastructure layer" of agent engineering — and now that you understand them, you're half a step ahead.

Remember: solo agents are a 2025 story. Collaboration is 2026's theme.


About the author: Wu Ji (无记) — AI & digitalization practitioner focused on Agent engineering, Loop Engineering, and digital transformation. Practical, hands-on tutorials — follow along and it just works.

Top comments (0)