Enterprise Data MCP Server
MCP server providing natural-language tools for managing and querying an employee database, including user CRUD, search, and statistics.
README
Enterprise Data Agent šļø
A natural-language interface to an enterprise employee database, powered by Groq LLM tool-calling and a local SQLite database, with a Streamlit frontend and a Model Context Protocol (MCP) server backend.
Architecture
flowchart TD
%% Styling
classDef client fill:#2d3748,stroke:#94a3b8,stroke-width:1px,color:#f8fafc,rx:10px
classDef core fill:#0f172a,stroke:#3b82f6,stroke-width:2px,color:#eff6ff,rx:6px
classDef db fill:#064e3b,stroke:#10b981,stroke-width:2px,color:#ecfdf5,rx:6px
classDef ai fill:#312e81,stroke:#8b5cf6,stroke-width:2px,color:#eef2ff,rx:6px
%% Nodes
User(["š¤ User Browser"]):::client
ExtAI(["š¤ MCP Client (Claude, Cursor)"]):::client
App["ā” Streamlit App"]:::core
Server["š MCP Server"]:::core
DBLayer["āļø Shared DB Layer"]:::core
Groq{"š§ Groq LLM"}:::ai
SQLite[("š¾ SQLite Database")]:::db
%% Connections
User <-->|"Chat Interface"| App
App <-->|"Prompts & Tools"| Groq
App -->|"Execute Tools"| DBLayer
ExtAI <-->|"MCP / stdio"| Server
Server -->|"Execute Tools"| DBLayer
DBLayer <-->|"SQL Operations"| SQLite
Quick Start
1. Prerequisites
- Python 3.11+
- A Groq API key
2. Clone & Set Up
git clone <your-repo-url>
cd mcp_project
# Create and activate a virtual environment
python -m venv venv
venv\Scripts\activate # Windows
# source venv/bin/activate # macOS/Linux
# Install dependencies
pip install -r requirements.txt
3. Configure Environment
Create a .env file in the project root (F:\PROJECTS\MCP\.env):
GROQ_API_KEY=gsk_your_key_here
GROQ_MODEL=llama-3.3-70b-versatile # optional, this is the default
4. Initialize the Database
# From the project root (F:\PROJECTS\MCP\)
sqlite3 enterprise_data.db < schema.sql
5. Run the App
# From F:\PROJECTS\MCP\
streamlit run mcp_project/app.py
Open http://localhost:8501 in your browser.
Available Tools
The LLM can call these tools automatically based on your query:
| Tool | Description |
|---|---|
get_active_users |
List all active users and their roles |
add_user |
Add a new user (name + role) |
deactivate_user |
Deactivate an active user by name |
get_user_stats |
Get total, active, and inactive counts |
search_users |
Search users by name fragment |
Example Queries
- "Who are our active users?"
- "Add Jane Doe as a Manager"
- "How many users do we have in total?"
- "Search for users named Alice"
- "Deactivate Bob Jones"
- "Show me user statistics"
Running the MCP Server (Standalone)
server.py exposes the same tools via the Model Context Protocol. It supports both local stdio connections and an HTTP-based sse Transport!
It now exposes:
- Tools: DB query and update operations
- Resources: Exposes
schema.sqlover MCP - Prompts: Provides pre-configured prompts like
hr-assistant
To run locally for AI desktop apps (like Claude Desktop / Cursor):
python mcp_project/server.py --transport stdio
To run as an HTTP SSE server on port 8000:
python mcp_project/server.py --transport sse --port 8000
Project Structure
F:\PROJECTS\MCP\
āāā .env # ā API key (never commit this!)
āāā .gitignore
āāā requirements.txt
āāā schema.sql # DB schema ā use to recreate the database
āāā enterprise_data.db # SQLite database (gitignored)
āāā mcp_project\
āāā app.py # Streamlit frontend
āāā server.py # MCP stdio server
āāā db.py # Shared database access layer
Security Notes
- Never commit your
.envfile. The.gitignoreexcludes it. - Never commit
enterprise_data.db. Useschema.sqlto recreate it. - Rotate your Groq API key at console.groq.com if it has ever been exposed.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
Neon Database
MCP server for interacting with Neon Management API and databases
E2B
Using MCP to run code via e2b.
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.