Northwind FastAPI MCP Example
Uses FastAPI to create an MCP server that exposes the Northwind database through both a REST API and an MCP endpoint, allowing queries for product data and other Northwind dataset information.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Northwind FastAPI MCP Examplelist all products in the Northwind database"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
🚀 Northwind FastAPI MCP Example
This project demonstrates how to use fastapi-mcp to create a Model Context Protocol (MCP) server that allows Large Language Models (LLMs) to connect and interact with a REST API.
📋 Overview
The Northwind API is a simple example that shows how to expose data from the classic Northwind database through both a traditional REST API and an MCP endpoint, making it accessible for LLMs to query and understand.
Related MCP server: SQL Server MCP
🏁 Getting Started
Prerequisites
Python 3.10+ 🐍
Virtual environment tool 🔧
Installation
Clone the repository and install dependencies:
git clone https://github.com/RobertoRuben/mcp-northwind-fastapi-example.git cd mcp-northwind-fastapi-example python -m venv venv venv\Scripts\activate # On Windows pip install -r requirements.txtRun the application:
uvicorn src.main:app --reloadAccess the API documentation at
http://localhost:8000/api/v1/docs📝
🔌 Available Endpoints
REST API Endpoints
GET /api/v1/products: List all products 📦
MCP Endpoint
http://localhost:8000/mcp: Model Context Protocol endpoint for LLM connections 🤖
🔗 Connecting an LLM to the API
This example demonstrates how fastapi-mcp creates a bridge between your REST API and Large Language Models:
Traditional REST endpoints serve structured data at
/api/v1/products*📊The MCP endpoint at
/mcpallows LLMs to discover and interact with your API programmatically 🧠LLMs can understand your data schema and execute appropriate API calls automatically. ✨
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-qualityCmaintenanceA Model Context Protocol server that allows Large Language Models like Claude to execute SQL queries, explore database schemas, and maintain persistent connections to SQL Server databases.Last updated
- AlicenseBqualityCmaintenanceA Model Context Protocol server that enables AI assistants (Cursor, Windsurf, Claude Code) to interact with Microsoft SQL Server databases by providing connectivity through environment-configurable connections.Last updated85598MIT
- Alicense-qualityDmaintenanceAn MCP (Model Context Protocol) server that exposes natural language to SQL functionality, allowing any MCP-compatible client to convert plain English questions into SQL queries for database interaction using AI.Last updated3MIT
- AlicenseAqualityDmaintenanceA Model Context Protocol server that enables LLMs like Claude to interact with Microsoft SQL Server databases through natural language, supporting queries, data manipulation, and table management.Last updated83,172MIT
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
MCP (Model Context Protocol) server for Appwrite
GibsonAI MCP server: manage your databases with natural language
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/RobertoRuben/mcp-northwind-fastapi-example'
If you have feedback or need assistance with the MCP directory API, please join our Discord server