Skip to main content
Glama
E-commerce MCP Server

E-commerce MCP Server

E-commerce Chatbot with MCP Server (Model Context Protocol)

This project refactors your existing LangChain + FAISS vector database e-commerce chatbot to use MCP (Model Context Protocol) server for real-time product data access.

Key Changes

Removed:

  • FAISS vector database and embeddings

  • Static JSON file loading

  • Vector similarity search

Added:

  • MCP Server for MongoDB integration

  • Real-time product queries

  • Structured database operations

  • MongoDB text search indexing

Related MCP server: BigGo MCP Server

Features

  • Real-time Data: Always up-to-date product information

  • Structured Queries: Price range, category filtering

  • Product Recommendations: Based on category and price similarity

  • Text Input: Supports text queries

  • Session Management: Maintains conversation context

  • Coreference Resolution: Handles pronouns and references

Setup

  1. Install dependencies:

pip install -r requirements.txt
  1. Set up environment variables in .env

  2. Start MongoDB:

docker-compose up mongodb -d
  1. Run the application:

uvicorn main:app --reload

API Endpoints

  • POST /api/v1/chat/ - Text-based chat

Benefits of MCP Integration

  1. Real-time Inventory: Always current stock levels

  2. Complex Queries: Price ranges, category filters

  3. Better Performance: Optimized database queries

  4. Scalability: Direct MongoDB connection

  5. Flexibility: Easy to extend with new query types

The MCP server provides a clean abstraction layer between your LLM and database, enabling more sophisticated product queries while maintaining the conversational interface your users expect.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      B
      maintenance
      A Model Context Protocol server that provides access to MongoDB databases. This server enables LLMs to inspect collection schemas and execute read-only queries.
      8
      1,425 npm
      283
      MIT
    • A
      license
      C
      quality
      D
      maintenance
      A Model Context Protocol server enabling product searches across e-commerce platforms, price history tracking, and product specification-based searches using natural language prompts.
      2
      142 PyPI
      19
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol server that enables LLMs to interact directly with MongoDB databases, allowing users to query collections, inspect schemas, and manage data through natural language.
      1
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol server that enables LLMs to interact directly with MongoDB databases, allowing users to query collections, inspect schemas, and manage data through natural language.
      MIT