- Home
- MCP servers
- Northwind FastAPI
Northwind FastAPI
- python
0
GitHub Stars
python
Language
7 months ago
First Indexed
3 months ago
Catalog Refreshed
Documentation & install
Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.
You run a Python-based MCP server that exposes data from the Northwind database via a REST API and a Model Context Protocol (MCP) endpoint. This setup lets Large Language Models discover your data schema and execute API calls to retrieve information in natural language workflows.
How to use
You connect an MCP client to the MCP endpoint to let the model query the API. The REST API at /api/v1 provides data like products, while the MCP endpoint at /mcp enables the model to discover available data and interact with your API programmatically. Use the MCP client to explore the schema, request lists of resources, and perform typical CRUD-like queries through natural-language prompts.
Practical usage patterns include asking for a list of products, filtering by category or price, or requesting summaries of inventory. The MCP bridge translates your natural-language request into the appropriate REST calls under the covers, returning structured data that you can render or further process.
How to install
Prerequisites: you need Python 3.10 or newer and a virtual environment tool.
# Step 1: Set up Python environment
python -m venv venv
# Step 2: Activate the virtual environment
# Windows
venv\Scripts\activate
# macOS/Linux
source venv/bin/activate
# Step 3: Install dependencies
pip install -r requirements.txt
How to run
uvicorn src.main:app --reload
Accessing the API and MCP endpoint
Once running, you can explore the REST API and MCP endpoint locally at the following paths:
REST API: http://localhost:8000/api/v1/products
MCP endpoint: http://localhost:8000/mcp
Available tools
list_products
Fetches all products from the Northwind dataset through the REST API at /api/v1/products.
mcp_discovery
Interacts with the MCP endpoint at /mcp to discover data schemas and available API actions for LLMs.