How I Built a Cross-Framework Restaurant Booking Agent with A2A and Strands Agents
Learn how to build agents that seamlessly communicate across different AI frameworks using the Agent-to-Agent (A2A) protocol

Imagine a world where AI agents built with any framework could communicate seamlessly, sharing capabilities and collaborating on complex tasks. This isn't a distant future; it's happening today with the Agent-to-Agent (A2A) protocol proposed by Google.
The Strands Agents A2A Restaurant Booking System demonstrates this revolutionary capability by simulating a realistic ecosystem where each restaurant and booking service has built their own agent using their preferred framework, yet they all communicate effortlessly through the A2A protocol.
The Agent Communication Challenge
Traditional AI applications are often siloed within their frameworks. A Strands agent can't easily communicate with a LangGraph agent, and neither can tap into Google ADK capabilities without complex integration work. This creates several problems:
- Framework Lock-in: Teams become constrained by their initial framework choice
- Duplicate Development: Similar capabilities get rebuilt across different frameworks
- Integration Complexity: Cross-framework communication requires custom protocols and adapters
- Limited Collaboration: Agents can't leverage specialized capabilities from other frameworks
Introducing the Agent-to-Agent (A2A) Protocol Proposed by Google
The A2A protocol proposed by Google solves these challenges by providing a standardized communication layer that enables agents from different frameworks to discover, communicate, and collaborate seamlessly. Think of it as HTTP for AI agents—a universal protocol that enables interoperability.
Key features of A2A include:
- Framework Agnostic: Works with any AI framework that implements the protocol
- Standardized Discovery: Agents can automatically discover and understand each other's capabilities
- Message Standards: Consistent message formats across different frameworks
- Task Management: Coordinated handling of complex, multi-step interactions
- Streaming Support: Real-time communication for responsive user experiences
Why A2A for Restaurant Booking?
This demonstration simulates a realistic scenario where each business independently chose their preferred AI framework for their own reasons:
- Sushi Maru: Chose Strands Agents for rapid deployment and simplicity
- Tokyo Ramen: Selected LangGraph for sophisticated conversation flows
- Takoyaki Taro: Adopted Google ADK for enterprise-grade reliability and Google Cloud integration
Rather than forcing all restaurants to rebuild their agents with the same framework, the A2A protocol enables them to communicate despite their different technical choices.
A2A Restaurant Booking Architecture
Step1: Agent Discovery

Step2: Task Execution

The demonstration system showcases cross-framework communication through four components:
1. Restaurant Booking Coordinator (Strands Agents)
The orchestrator that coordinates booking requests across multiple restaurant agents:
1class RestaurantBookingCoordinator:
2 def __init__(self):
3 self.restaurants = {
4 "Sushi Maru": "http://localhost:9001", # Strands Agent
5 "Tokyo Ramen": "http://localhost:9002", # LangGraph Agent
6 "Takoyaki Taro": "http://localhost:9003", # Google ADK Agent
7 }
8
9 self.agent = Agent(
10 name="Restaurant Booking Coordinator",
11 system_prompt="""You are a restaurant booking coordinator that helps users
12 check availability, make reservations, and cancel bookings across multiple
13 restaurants using A2A protocol.""",
14 tools=[check_availability, book_restaurant, cancel_booking],
15 )
2. Sushi Maru Agent (Strands Agents + A2A)
1def main():
2 # Create the Sushi Maru agent
3 strands_agent = Agent(
4 name="Sushi Maru Restaurant Agent",
5 description="Restaurant booking agent for Sushi Maru, specializing in authentic Japanese sushi",
6 tools=[check_availability, book_table],
7 )
8
9 # Expose via A2A protocol
10 a2a_server = A2AServer(
11 agent=strands_agent,
12 host="0.0.0.0",
13 port=9001,
14 version="0.0.1",
15 )
16
17 a2a_server.serve()
3. Tokyo Ramen Agent (LangGraph + A2A Bridge)
A LangGraph-based agent that bridges to the A2A protocol through custom executors:
1class TokyoRamenAgentExecutor:
2 """
3 Bridges LangGraph agent with A2A protocol by:
4 1. Converting A2A RequestContext to LangGraph query
5 2. Managing A2A task lifecycle (submit → work → complete)
6 3. Streaming LangGraph responses as A2A task updates
7 4. Handling different task states (working, input_required, completed)
8 """
9
10 async def execute(self, context: RequestContext, event_queue: EventQueue):
11 # Create A2A task updater
12 updater = TaskUpdater(event_queue, context.task_id, context.context_id)
13
14 # Extract user query from A2A message parts
15 query = context.get_user_input()
16
17 # Stream responses from LangGraph agent
18 async for item in self.agent.stream(query, context.context_id):
19 content = item["content"]
20 parts = [Part(root=TextPart(text=content))]
21
22 if item["is_task_complete"]:
23 await updater.complete(message=updater.new_agent_message(parts))
24 else:
25 await updater.update_status(TaskState.working,
26 message=updater.new_agent_message(parts))
4. Takoyaki Taro Agent (Google ADK + A2A Bridge)
A Google ADK agent integrated with A2A through protocol adapters:
1class TakoyakiTaroAgentExecutor:
2 """Google ADK Agent Executor for A2A protocol integration"""
3
4 async def execute(self, context: RequestContext, event_queue: EventQueue):
5 # Create ADK session for conversation continuity
6 session = await self._upsert_session(context.context_id)
7
8 # Convert A2A parts to Google GenAI format
9 genai_parts = convert_a2a_parts_to_genai(context.message.parts)
10
11 # Process with ADK
12 response = await self.runner.execute(
13 user_inputs=genai_parts,
14 session_id=session.session_id
15 )
16
17 # Convert response back to A2A format
18 a2a_parts = convert_genai_parts_to_a2a(response.parts)
19 await updater.complete(message=updater.new_agent_message(a2a_parts))
Real-World Communication Flow
Here's how the system handles a typical booking request:
User Request: "Check availability for 4 people on 2025-07-25 at 19:00"
- Agent Discovery: The coordinator discovers available restaurant agents via A2A protocol
1async def discover_restaurants(self):
2 for name, url in self.restaurants.items():
3 resolver = A2ACardResolver(httpx_client=client, base_url=url)
4 agent_card = await resolver.get_agent_card()
5 available_restaurants[name] = {"url": url, "card": agent_card}
2. Parallel Queries: The coordinator simultaneously queries all restaurant agents
3. Framework Translation: Each agent processes the request in its native framework:
- Sushi Maru: Direct Strands agent processing
- Tokyo Ramen: LangGraph state machine with conversation memory
- Takoyaki Taro: Google ADK with enterprise-grade session management
4. Response Aggregation: Results are collected and presented to the user:
1🍣 Sushi Maru: Available at 19:00 for 4 people
2🍜 Tokyo Ramen: Available at 19:00 for 4 people
3🐙 Takoyaki Taro: Fully booked at 19:00, available at 19:30
Key Implementation Insights
Protocol Standardization
The A2A protocol provides consistent interfaces across frameworks:
1# Standard agent card for discovery
2agent_card = AgentCard(
3 name="Tokyo Ramen Restaurant Agent",
4 description="Restaurant booking agent for Tokyo Ramen, fast casual Japanese ramen",
5 url="http://localhost:9002",
6 capabilities=AgentCapabilities(streaming=True),
7 skills=[check_skill, book_skill],
8)
Message Translation
Cross-framework communication requires message format translation:
1def convert_a2a_parts_to_genai(parts: List[Part]) -> List[types.Part]:
2 """Convert A2A Part types to Google GenAI Part types"""
3 genai_parts = []
4 for part in parts:
5 if isinstance(part.root, TextPart):
6 genai_parts.append(types.Part(text=part.root.text))
7 elif isinstance(part.root, FilePart):
8 genai_parts.append(types.Part(blob=types.Blob(
9 mime_type=part.root.file.mimeType,
10 data=part.root.file.bytes,
11 )))
12 return genai_parts
Beyond Restaurant Booking
The A2A pattern enables powerful applications across many domains:
Customer Support Ecosystem
- Strands agent for initial triage and FAQ handling
- LangGraph agent for complex troubleshooting workflows
- Google ADK agent for enterprise ticket management
Financial Analysis Platform
- Strands agent for rapid market data collection
- LangGraph agent for complex analytical reasoning
- Google ADK agent for regulatory compliance and reporting
Content Creation Pipeline
- Strands agent for research and fact-gathering
- LangGraph agent for structured content generation
- Google ADK agent for review and publication workflows
Getting Started with A2A
Prerequisites
- Python 3.11+
- Google Cloud credentials for ADK integration
- API keys for language models (Gemini recommended for consistency)
Installation
1# Clone the repository
2git clone https://github.com/asakohayase/strands-agents-a2a.git
3cd strands-agents-a2a
4
5# Install dependencies with uv
6uv install
7
8# Set up databases
9python setup_databases.py
Configuration
Set up your environment variables:
1GOOGLE_API_KEY=[your-api-key-here]
Running the Demo
- Start all restaurant agents (in separate terminals):
1# Terminal 1: Strands agent
2uv run sushi_maru_agent.py
3
4# Terminal 2: LangGraph agent
5uv run tokyo_ramen_agent.py
6
7# Terminal 3: Google ADK agent
8uv run takoyaki_taro_agent.py
2. Launch the coordinator:
1# Terminal 4: Coordinator
2uv run customer_coordinator.py
3. Interact with the system:
1👤 Request: Check availability for 4 people on 2025-07-25 at 19:00
2👤 Request: Book a table at Sushi Maru for 2 people on 2025-07-25 at 20:00 for John Smith
3👤 Request: Cancel booking at Tokyo Ramen for Alice Johnson on 2025-07-25 at 18:00
Future Enhancements
The A2A protocol opens exciting possibilities for expanding the restaurant booking system:
Multi-Modal Capabilities
- Voice-based booking through Google ADK speech recognition
- Image processing for menu photos via Strands vision tools
- Real-time availability updates through LangGraph streaming
Advanced Orchestration
- Smart load balancing across restaurant agents
- Fallback strategies when specific agents are unavailable
- Cross-restaurant recommendation engines
Enterprise Integration
- Payment processing through specialized financial agents
- CRM integration for customer history and preferences
- Analytics and reporting across the entire booking ecosystem
Conclusion
The Strands Agents A2A Restaurant Booking System demonstrates that we can build systems that leverage the unique strengths of each framework while maintaining seamless user experiences.
This cross-framework approach enables:
- Faster Development: Use the best tool for each job
- Better Maintainability: Framework-specific expertise stays isolated
- Enhanced Capabilities: Combine strengths from multiple ecosystems
- Future Flexibility: Add new frameworks without rebuilding existing components
The A2A protocol represents a significant step toward truly interoperable AI systems, where agents collaborate across framework boundaries to deliver more powerful and capable applications.
Resources
🚀 Try It Yourself
- GitHub Repository - Complete source code and setup instructions
📚 Learn More
- A2A Protocol Specification - Official protocol documentation
- Strands Agents Documentation - Strands framework guide
- LangGraph Documentation - LangGraph framework guide
- Google ADK Documentation - Google Agent Development Kit