A2A Protocol
Agent-to-agent interoperability protocols for discovery, messaging, and collaboration.
In plain words
A shared language that lets AI agents from different companies find each other, ask each other for help and report back.
Think of it like…
Contractors who work for different companies: each publishes a business card (skills, contact, how to pay), you send a work order, they update you on progress, ask for missing details and deliver a finished product, all without you seeing how their shop operates.
Where you’ve seen it
A company's orchestrating assistant needs a flight rebooked and expense policy checked. It finds the travel agency's agent through its Agent Card (skills: search_flights, rebook, requires OAuth), sends a task "rebook flight AI-203 to the next morning, max +₹3,000", and subscribes to streamed updates. The travel agent responds input-required ("Choose seat type"), receives the answer, completes the task and returns a booking artifact. The orchestrator never sees the agency's pricing tools or prompts, and a separate A2A call to the internal finance agent validates the policy.
Words you’ll hear
- Agent Card
- Metadata published by an agent: name, description, skills, endpoint, supported modes and auth requirements.
- Task
- A unit of work with an id and lifecycle states, handled by a remote agent.
- Message and parts
- Communication turns composed of typed content parts (text, file, data).
- Artifact
- A deliverable produced by a task (document, booking, dataset).
Visual diagram
Theory & deep dive
How A2A works
Discovery: an agent exposes its Agent Card at a well-known URL (or registers in a directory). The card lists identity, description, supported capabilities (streaming, push notifications), input and output modes, authentication schemes and a list of skills with descriptions and examples. A client agent (or its orchestrator) reads cards to choose the right remote agent.
Interaction: the client sends a message that creates a task; the remote agent may answer immediately or run asynchronously, returning status updates by streaming (server-sent events) or webhook push notifications for long jobs. Tasks pass through states such as submitted, working, input-required (the agent asks for more information or approval), completed, failed or cancelled. Messages contain parts (text, files by reference or inline, structured JSON), and results are returned as artifacts. Because everything uses ordinary HTTP, JSON-RPC and standard authentication, A2A fits existing enterprise infrastructure.
{"name": "Travel Agent", "url": "https://travel.example.com/a2a", "capabilities": {"streaming": true}, "skills": [{"id": "rebook", "description": "Rebook an existing flight within constraints", "examples": ["Move AI-203 to tomorrow morning, max +₹3,000"]}], "authentication": {"schemes": ["oauth2"]}}
A2A, MCP and the trust questions
A2A and MCP are complementary. MCP standardises how an agent connects to tools and data (functions with schemas, resources). A2A standardises how an agent talks to other agents, which have their own reasoning, memory and tools, and can negotiate, ask questions and work over long periods. A practical architecture: each agent uses MCP to reach its own tools, and A2A to delegate or collaborate with peer agents. Compared with the in-process patterns (handoffs, orchestrator-worker), A2A crosses process, vendor and trust boundaries.
Crossing trust boundaries raises issues. Authentication and authorisation: verify who is calling, grant least privilege, and don't forward user credentials broadly. Data minimisation: share only what the remote agent needs; treat remote responses as untrusted input (prompt-injection risk from another agent's output). Accountability: log tasks and artifacts, set contracts on what agents may do, and keep humans in the loop for consequential actions. Reliability: handle timeouts, retries, idempotency and partial results. The protocol is young and evolving, so check the current specification and ecosystem support before building on specific features.
Send the travel agent only the flight number, date and fare-difference limit, not the employee's full profile or expense history. If it needs more, it returns input-required and the orchestrator decides what to share.
How it works, step by step
Step 1 of 41. Decide if you need interop
Use A2A when agents are built by different teams or vendors and must collaborate; keep in-process patterns inside one system.
- Else
- simple handoffs
When to use it & trade-offs
What it is
The Agent2Agent (A2A) protocol, introduced by Google in 2025 and later moved to the Linux Foundation, is an open standard that lets independently built agents discover each other and collaborate across vendors, frameworks and organisations. Each agent publishes an Agent Card (a JSON description of who it is, what skills it offers, its endpoint and authentication needs). A client agent sends a task to a remote agent using JSON-RPC over HTTP; the task has a lifecycle (submitted, working, input-required, completed, failed, among others), exchanges messages made of typed parts (text, files, structured data), can stream progress, and produces artifacts as results. A2A treats remote agents as opaque: you don't see their internals, tools or memory, only their interface.
Why it matters: Companies increasingly run agents from different teams and vendors (a procurement agent, a travel agent, a finance agent), and need them to cooperate without custom integrations for every pair or exposing internal prompts and tools. A common protocol reduces integration cost and lets agents delegate to specialists across organisational boundaries. It also raises new questions about trust, authentication, data sharing and accountability.
When to reach for it
- Cross-team or cross-vendor agent collaboration
- Delegating to specialist agents you don't control
- Enterprise agent marketplaces and registries
When to avoid or be careful
- A2A for agents inside a single process
- Sharing full user profiles with every remote agent
- Trusting remote agent output without validation
Connecting agents and tools
Strengths: Standard discovery, task lifecycle and opaque interop.
Watch out: Network, trust and governance complexity.
Strengths: Standard tool and resource interface.
Watch out: Tools aren't agents; no negotiation or long-lived tasks.
Strengths: Simple; low latency.
Watch out: Doesn't cross vendor or organisational boundaries.
Interview signals & numbers to know
When this topic comes up
- “How do our agents talk to a partner's agent?”
- “A2A vs MCP”
- “What is an Agent Card?”
- Cross-organisation agents
- Opaque agent collaboration
Benchmarks & rules of thumb
- 5 – 9
- task states: the five core ones, plus canceled, rejected and auth-required in recent spec versions
- 2025
- year A2A was introduced
- JSON-RPC over HTTP
- transport basis
Common mistakes & follow-ups
Common interview mistakes
- Using A2A to call a tool that MCP (or a plain API) would serve better.
- Forwarding the user's full credentials to a third-party agent.
- Treating a remote agent's text as trusted instructions.
Likely interviewer follow-ups
- How are A2A and MCP different and how do they work together?
- What does an Agent Card contain?
- What are the security concerns of agent-to-agent communication?
Knowledge check
Put it into practice
Practice related interview Q&A
Apply A2A Protocol with generative AI interview Q&A and hands-on practice.