Skip to main content

Hotel search service built with Google's Agent Developer Kit (ADK) and MCP

Project description

MCP Hotel Search

A hotel search service built with Google's Agent Developer Kit (ADK) and Model Context Protocol (MCP). This service enables AI models to search for hotels using SerpAPI.

What is Model Context Protocol?

The Model Context Protocol (MCP) is a standard developed by Anthropic that enables AI models to use tools by defining a structured format for tool descriptions, calls, and responses. This project implements an MCP tool using Google's ADK that can be used by Claude and other MCP-compatible models.

Installation

# Install from PyPI
pip install mcp-hotel-search

# Or install from the project directory (development mode)
git clone https://github.com/arjunprabhulal/mcp-hotel-search.git
cd mcp-hotel-search
pip install -e .

Prerequisites

This project requires:

  • Google's Agent Developer Kit (google-ai-adk)
  • MCP Python SDK (mcp-python-sdk)
  • SerpAPI API key (google-search-results)
  • Python 3.9+

Usage

Once installed, you can run the server using the command-line entry point:

# Ensure SERP_API_KEY is set as an environment variable or in a .env file
mcp-hotel-search

Environment Variables

Set the SerpAPI key as an environment variable:

export SERP_API_KEY="your-api-key-here"

Alternatively, create a .env file in the directory where you run the server:

SERP_API_KEY=your_api_key_here

Features

  • MCP-compliant tool using Google's Agent Developer Kit (ADK) for hotel search functionality
  • Integration with SerpAPI Google Hotels
  • Support for searching hotels with specific check-in and check-out dates
  • Packaged for easy installation and use

MCP Tool

This package provides the following Model Context Protocol tool:

  • search_hotels: Search for hotels with parameters:
    • location: The city or location to search for hotels
    • check_in_date: Check-in date in YYYY-MM-DD format
    • check_out_date: Check-out date in YYYY-MM-DD format

License

This project is licensed under the MIT License - see the LICENSE file for details.

Author

Arjun Prabhulal

For more articles on AI/ML and Generative AI, follow me on Medium: https://medium.com/@arjun-prabhulal

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

mcp_hotel_search-0.1.1.tar.gz (5.6 kB view details)

Uploaded Source

Built Distribution

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

mcp_hotel_search-0.1.1-py3-none-any.whl (6.6 kB view details)

Uploaded Python 3

File details

Details for the file mcp_hotel_search-0.1.1.tar.gz.

File metadata

  • Download URL: mcp_hotel_search-0.1.1.tar.gz
  • Upload date:
  • Size: 5.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.11

File hashes

Hashes for mcp_hotel_search-0.1.1.tar.gz
Algorithm Hash digest
SHA256 0e7e79e84a37c5ae1e192e502e072062a91eef318ae688bd2aa57435dffa72e8
MD5 11dbe1d4eb13faae6a19dd3308c7462e
BLAKE2b-256 569356486acfd52b9eeeb6103930b0688b6fc7a0b0a4a6ced89a5364a491952a

See more details on using hashes here.

File details

Details for the file mcp_hotel_search-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for mcp_hotel_search-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a8da5c90605667a9bf7684d2653a2d137d2819d40aabadebe8b73fd3d7e93fd2
MD5 0833918fcbbb5ca57ab36c4fae7e5485
BLAKE2b-256 78f97a8ea80202013362e257857b7d3b52d77d0adf2d01cd78207ac23f08794f

See more details on using hashes here.

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