Skip to main content
Glama
JacobW2000

sqlite-mcp-server

by JacobW2000

Employee Database MCP Server

An MCP (Model Context Protocol) server built with FastMCP and SQLite that enables AI clients (such as Claude Desktop and Cursor) to query, analyze, and update structured employee records using natural language.


πŸ—οΈ Architecture

flowchart LR
    A[Claude Desktop / LLM Client] -->|MCP Protocol via stdio| B[server.py / FastMCP]
    B -->|Prepared Queries| C[database.py]
    C -->|SQL Operations| D[(SQLite DB)]

Related MCP server: SQLite MCP Server

✨ Features & Exposed MCP Tools

The server exposes parameterized, injection-safe database functions directly to LLM clients:

Category

MCP Tool Name

Description

Lookup & Search

get_employee_by_id, search_employees_by_name, list_employees

Fetch individual records or query by name/pattern.

Data Operations

add_employee, update_employee_salary, remove_employee

Perform CRUD mutations with input validation.

Analytics & Metrics

get_highest_paid_employee, calculate_average_salary, get_company_stats

Aggregate salaries and generate company-wide statistics.

Department Info

list_departments, count_employees_by_department

Group and summarize workforce distribution.


πŸ› οΈ Tech Stack

  • Language: Python 3.10+

  • Database: SQLite

  • Protocol: Model Context Protocol (MCP / FastMCP)

  • Testing: pytest (11 unit tests covering database transactions and queries)


πŸš€ Quickstart & Setup

1. Installation

Clone the repository and install dependencies:

git clone [https://github.com/JacobW2000/sqlite-mcp-server.git](https://github.com/JacobW2000/sqlite-mcp-server.git)
cd sqlite-mcp-server
python -m venv venv

# On Windows:
.\venv\Scripts\activate

# On macOS/Linux:
# source venv/bin/activate

pip install -r requirements.txt

2. Integration with Claude Desktop

Add the server configuration to your claude_desktop_config.json:

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "employee-database": {
      "command": "python",
      "args": [
        "C:/path/to/sqlite-mcp-server/server.py"
      ]
    }
  }
}

πŸ§ͺ Testing

This project includes 11 automated pytest tests covering database operations, transaction safety, and employee queries:

python -m pytest tests/test_database.py

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    C
    maintenance
    Provides database access capabilities to Claude with support for both SQLite and SQL Server databases. It enables users to manage schemas, execute SQL queries, and export results through natural language interaction.
    676 npm
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables natural language interaction with local SQLite databases through Claude Desktop, translating plain English queries into SQL for data analysis and exploration.
    3
    MIT
  • A
    license
    Not graded
    quality
    C
    maintenance
    Enables Claude to query and manage databases (SQLite, SQL Server, PostgreSQL, MySQL) through natural language, supporting read/write operations and schema management.
    676 npm
    MIT
  • F
    license
    Not graded
    quality
    C
    maintenance
    Enables Claude Desktop to securely query a SQLite HR database, providing tools to check leave balances and list pending approvals through natural language.
    -