loading…
Search for a command to run...
loading…
Provides weather-aware travel planning tools that fetch 3-day forecasts and generate structured itineraries using a multi-agent orchestration system. It exposes
Provides weather-aware travel planning tools that fetch 3-day forecasts and generate structured itineraries using a multi-agent orchestration system. It exposes specialized agents for weather data and trip planning to any MCP-compliant client.
A multi-agent travel planning system built with Google Agent Development Kit (ADK) that exposes its tools via the Model Context Protocol (MCP).
The system uses a root agent with two sub-agents — a weather agent and a travel plan agent — to create weather-aware 3-day travel itineraries. The tools are also exposed through an MCP server, making them accessible to any MCP-compliant client.
┌─────────────────────────────────────────────────┐
│ Root Agent │
│ (travel_planner) │
│ │
│ Orchestrates the travel planning workflow: │
│ gather info → check weather → create plan │
│ │
│ ┌─────────────────┐ ┌──────────────────────┐ │
│ │ Weather Agent │ │ Travel Plan Agent │ │
│ │ │ │ │ │
│ │ get_weather() │ │ create_travel_plan()│ │
│ │ (Open-Meteo API)│ │ (itinerary builder) │ │
│ └─────────────────┘ └──────────────────────┘ │
└─────────────────────────────────────────────────┘
▼ exposed via ▼
┌─────────────────────────────────────────────────┐
│ MCP Server (stdio) │
│ │
│ Wraps ADK FunctionTools and exposes them as │
│ MCP tools accessible to any MCP client │
│ │
│ Tools: get_weather, create_travel_plan │
└─────────────────────────────────────────────────┘
travel-planner-mcp-server/
├── travel_planner/ # ADK multi-agent package
│ ├── __init__.py
│ ├── agent.py # Root agent (orchestrator with sub-agents)
│ ├── sub_agents/
│ │ ├── __init__.py
│ │ ├── weather_agent.py # Weather specialist sub-agent
│ │ └── travel_plan_agent.py # Travel planning specialist sub-agent
│ └── tools/
│ ├── __init__.py
│ ├── weather_tools.py # Open-Meteo API weather tool
│ └── travel_tools.py # Travel plan generation tool
├── mcp_server.py # MCP server exposing ADK tools
├── adk_client_agent/ # Example ADK agent consuming the MCP server
│ └── mcp_travel_client/
│ ├── __init__.py
│ └── agent.py
├── pyproject.toml
├── requirements.txt
├── .env.example
└── README.md
Clone the repository:
git clone <repo-url>
cd travel-planner-mcp-server
Install dependencies:
pip install -r requirements.txt
Configure environment:
cp .env.example .env
# Edit .env and add your Google API key
This uses the root agent with its sub-agents through the ADK web UI:
adk web
# Select "travel_planner" in the browser UI
The root agent will:
This exposes the tools via MCP protocol for any MCP client to consume:
python mcp_server.py
The MCP server exposes two tools:
get_weather — Fetches 3-day weather forecast for a location using Open-Meteo APIcreate_travel_plan — Generates a structured 3-day travel itinerary templateThis demonstrates an ADK agent consuming the MCP server:
cd adk_client_agent
adk web
# Select "mcp_travel_client" in the browser UI
Add to your MCP client configuration (e.g., Claude Desktop, Cursor, etc.):
{
"mcpServers": {
"travel-planner": {
"command": "python3",
"args": ["/path/to/mcp_server.py"]
}
}
}
get_weatherFetches a 3-day weather forecast using the Open-Meteo API (free, no API key required).
Parameters:
| Parameter | Type | Description |
|---|---|---|
location |
string | City or place name (e.g., "Paris", "Tokyo") |
date |
string | Start date in YYYY-MM-DD format |
Returns: Temperature (C/F), conditions, precipitation, wind speed, and UV index for 3 days.
create_travel_planGenerates a structured 3-day travel itinerary template.
Parameters:
| Parameter | Type | Description |
|---|---|---|
location |
string | Destination city or place |
start_date |
string | Trip start date (YYYY-MM-DD) |
weather_summary |
string | Weather conditions summary |
interests |
string | Travel interests (default: "general sightseeing") |
Returns: Day-by-day itinerary structure with time slots, meals, and tips.
This project demonstrates Pattern 2 from the ADK documentation: Building an MCP server with ADK tools.
FunctionTool wraps the Python tool functionsadk_to_mcp_tool_type() converts ADK tool schemas to MCP formatlist_tools and executes them via call_toolMIT
Добавь это в claude_desktop_config.json и перезапусти Claude Desktop.
{
"mcpServers": {
"travel-planner-mcp-server": {
"command": "npx",
"args": []
}
}
}