Skip to main content

MCP Server for Online Boutique AI Assistant - exposing microservices via Model Context Protocol

Project description

Online Boutique AI Assistant MCP Server

PyPI version Python License: MIT Downloads

Model Context Protocol (MCP) Server for Online Boutique AI Assistant

Expose microservices through the standardized Model Context Protocol, enabling any MCP client to access complete e-commerce functionality.

๐Ÿ“ฆ Available on PyPI

Table of Contents

  1. Features
  2. Architecture
  3. Installation
  4. Usage
  5. Available Functions
  6. Configuration
  7. Development
  8. Requirements
  9. Use Cases
  10. Contributing
  11. License

Features

  • Complete E-commerce: 18 microservice functions for products, cart, checkout, payments, shipping
  • Standard MCP Protocol: Works with any MCP client (Claude, ChatGPT, custom tools)
  • Google ADK Integration: Built using Google Agent Development Kit patterns
  • Dynamic Configuration: Environment variable based configuration
  • Production Ready: Comprehensive logging and error handling

Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚   MCP Client    โ”‚โ”€โ”€โ”€โ”€โ”‚  MCP Server      โ”‚โ”€โ”€โ”€โ”€โ”‚  Microservices      โ”‚
โ”‚ (Any LLM/Agent) โ”‚    โ”‚ (This Package)   โ”‚    โ”‚ (Online Boutique)   โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Installation

Install from PyPI:

pip install ai-boutique-assit-mcp

Or install from source:

git clone https://github.com/arjunprabhulal/ai-boutique-assit-mcp.git
cd ai-boutique-assit-mcp
pip install -e .

Usage

1. Start MCP Server

# Standalone HTTP server
botiq-mcp-server --port 8080

2. Connect with ADK Agent

from google.adk.agents import Agent
from google.adk.tools.mcp_tool import McpToolset, SseConnectionParams

agent = Agent(
    name="boutique_assistant",
    model="gemini-2.0-flash",
    instruction="You are a helpful e-commerce assistant.",
    tools=[
        McpToolset(
            connection_params=SseConnectionParams(
                url="http://localhost:8080/mcp"
            )
        )
    ]
)

Available Functions

The MCP server exposes 18 e-commerce functions:

Products & Catalog

  • list_products() - Browse all products
  • search_products(query) - Search product catalog
  • get_product(product_id) - Get product details
  • get_product_with_image(product_id) - Product with image
  • filter_products_by_price(max_price_usd) - Price filtering

Shopping Cart

  • add_item_to_cart(user_id, product_id, quantity) - Add to cart
  • get_cart(user_id) - View cart contents
  • empty_cart(user_id) - Clear cart

Checkout & Orders

  • place_order(user_id, currency, address, email, credit_card) - Complete purchase
  • initiate_checkout() - Start checkout process

Shipping & Logistics

  • get_shipping_quote(address, items) - Calculate shipping
  • ship_order(address, items) - Arrange shipping

Payment & Currency

  • charge_card(amount, credit_card) - Process payment
  • get_supported_currencies() - Available currencies
  • convert_currency(from_amount, to_currency) - Currency conversion

Communication

  • send_order_confirmation(email, order) - Email confirmations

Marketing

  • get_ads(context_keys) - Promotional content
  • list_recommendations(user_id, product_ids) - Product suggestions

Configuration

Environment Variables

Override microservice endpoints:

export PRODUCT_CATALOG_SERVICE="localhost:3550"
export CART_SERVICE="localhost:7070"
export RECOMMENDATION_SERVICE="localhost:8080"
export SHIPPING_SERVICE="localhost:50052"
export CURRENCY_SERVICE="localhost:7000"
export PAYMENT_SERVICE="localhost:50051"
export EMAIL_SERVICE="localhost:5000"
export CHECKOUT_SERVICE="localhost:5050"
export AD_SERVICE="localhost:9555"

Development

Local Development

# 1. Clone the repository
git clone https://github.com/arjunprabhulal/ai-boutique-assit-mcp.git
cd ai-boutique-assit-mcp

# 2. Install dependencies
pip install -r requirements.txt

# 3. Start MCP server
python -m ai_boutique_assit_mcp.mcp_server --port 8081

# 4. Test with ADK
adk run ai_boutique_assit_mcp

Build and Publish

# Build package
python -m build

# Publish to PyPI
python -m twine upload dist/*

Requirements

  • Python: 3.9 or higher
  • Google ADK: For MCP integration
  • gRPC: For microservice communication
  • Target microservices: Compatible gRPC services

Use Cases

  • AI Agents: Connect any LLM to e-commerce microservices
  • API Gateway: Unified access to distributed services
  • Testing: Mock or test e-commerce workflows
  • Integration: Standard protocol for microservice access
  • Multi-platform: Use from Python, Node.js, any MCP client

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Repository: https://github.com/arjunprabhulal/ai-boutique-assit-mcp

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a Pull Request

License

MIT License - see LICENSE file for details.

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

ai_boutique_assit_mcp-1.0.2.tar.gz (20.8 kB view details)

Uploaded Source

Built Distribution

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

ai_boutique_assit_mcp-1.0.2-py3-none-any.whl (19.9 kB view details)

Uploaded Python 3

File details

Details for the file ai_boutique_assit_mcp-1.0.2.tar.gz.

File metadata

  • Download URL: ai_boutique_assit_mcp-1.0.2.tar.gz
  • Upload date:
  • Size: 20.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.11

File hashes

Hashes for ai_boutique_assit_mcp-1.0.2.tar.gz
Algorithm Hash digest
SHA256 dd4e0b563e5c6dd9759f47897d10d203aff62de4ab5bb61c2bb1594836345d46
MD5 3374b8a2391614a1bac853fbd1579b23
BLAKE2b-256 6936c9956e5322b5181fdacc7e954736e8dfb9f024cb1e967fcc62c064b70a73

See more details on using hashes here.

File details

Details for the file ai_boutique_assit_mcp-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for ai_boutique_assit_mcp-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6afe2bb4e7e186f7be09f859a7ddbe50332ef9a74eb04767ba2601c44c0e7f48
MD5 f43c884e69ed0f1a27c656bbbbe3a74d
BLAKE2b-256 9719a370f76b2080ef470093d4c6e916a23e9a98b66c4b70c1f67950f5da6029

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