Skip to main content

Travel recommendations MCP Server

Project description

🌍 Expedia Travel Recommendations MCP Server

This project provides an MCP (Model Context Protocol) server that exposes Expedia Travel Recommendations (hotels, flights, activities, and cars) via both stdio and streamable-http protocols—ideal for LLM integrations and web-based applications.


✨ Features

  • 🔌 MCP server integration for Expedia's travel recommendation APIs
  • 📦 Supports both stdio and streamable-http protocols
  • 🏨 Hotel, ✈️ Flight, 🗺️ Activity, and 🚗 Car rental recommendations
  • 🔐 API key-based secure access

🛠 Prerequisites

  • Python 3.11+
  • Expedia API key

⚡ Running the MCP Server

Run with stdio protocol (LLM Integration)

export EXPEDIA_API_KEY="your_api_key_here"
uvx expedia_travel_recommendations_mcp --protocol "stdio"

Run with streamable-http protocol (Web Clients)

export EXPEDIA_API_KEY="your_api_key_here"
uvx expedia_travel_recommendations_mcp --protocol "streamable-http"

Access it at: http://0.0.0.0:9900/mcp


🐳 Running with Docker

Using Docker Compose (Recommended)

docker run \
  -p 9900:9900 \
  -e EXPEDIA_API_KEY=your_api_key_here \
  <your-dockerhub-username>/expedia-travel-recommendations-mcp:latest 

Accessible at: http://0.0.0.0:9900/mcp


⚙️ MCP Client Configuration

Using streamable-http (Recommended)

{
  "mcpServers": {
    "expedia-recommendation": {
      "url": "http://localhost:9900/mcp"
    }
  }
}

Using stdio

{
	"mcpServers": {
	 "expedia-travel-recommendations": { 
	   "command": "uvx", 
	   "args": [
	     "expedia_travel_recommendations_mcp", 
	     "--protocol", 
	     "stdio" 
	   ],
	   "env": { 
	     "EXPEDIA_API_KEY": "your_api_key_here" 
	   }
	 }
	}
}

🧪 Example Query (Hotel)

{
  "query": {
    "destination": "Seattle",
    "check_in": "2025-05-01",
    "check_out": "2025-05-05",
    "property_types": ["HOTEL", "RESORT"],
    "amenities": ["POOL", "SPA"],
    "guest_rating": "WONDERFUL",
    "sort_type": "CHEAPEST"
  }
}

🔗 API Endpoints

These are exposed when using the streamable-http protocol.

  • POST /expedia/hotels → Hotel recommendations
  • POST /expedia/flights → Flight recommendations
  • POST /expedia/activities → Activity recommendations
  • POST /expedia/cars → Car rental recommendations

🧑‍💻 Example Clients

See the examples/ folder for client scripts.

1️⃣ stdio-based Client

Make sure the virtual env is activated (install.sh must be run first):

source install_env/bin/activate
python examples/mcp_client_stdio.py

2️⃣ streamable-http Client

Ensure MCP server is running:

python examples/mcp_client_streamable_http.py

📄 License

Licensed under the Apache License 2.0.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

expedia_travel_recommendations_mcp-1.0.0.tar.gz (18.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file expedia_travel_recommendations_mcp-1.0.0.tar.gz.

File metadata

File hashes

Hashes for expedia_travel_recommendations_mcp-1.0.0.tar.gz
Algorithm Hash digest
SHA256 4f56f2e426ae3f5b70c28177598e86125f4bbb91c9fac300f4d6ed51eb94ce27
MD5 44b45b63eb407269b5b012d7c248b6b6
BLAKE2b-256 23ef69f1e4d4480f24c8845f35b51dc564dd5aaa4e673427f01955841e431914

See more details on using hashes here.

Provenance

The following attestation bundles were made for expedia_travel_recommendations_mcp-1.0.0.tar.gz:

Publisher: publish.yaml on ExpediaGroup/expedia-travel-recommendations-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file expedia_travel_recommendations_mcp-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for expedia_travel_recommendations_mcp-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9d224a0b8913b69a8532e3463fb24ef7c460119c5e65992682659744275e0e0a
MD5 26dfa4982eb78d0c5348856feb92f032
BLAKE2b-256 fc472937a63aa8be674a63246033bd3bcc7ad668beb158aad8f68812ed14884a

See more details on using hashes here.

Provenance

The following attestation bundles were made for expedia_travel_recommendations_mcp-1.0.0-py3-none-any.whl:

Publisher: publish.yaml on ExpediaGroup/expedia-travel-recommendations-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page