Healthcare MCP Server
Provides tools for querying and analyzing patient records stored in a SQLite database, including schema retrieval, SELECT queries, patient risk summaries, and readmission risk summaries.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Healthcare MCP Server
A custom MCP (Model Context Protocol) server that lets an AI agent (Claude Desktop, or any MCP client) query a small patient-records SQLite database.
Project structure
healthcare-mcp-server/
├── server.py # MCP server - registers all tools, runs Streamable HTTP on port 8000
├── db.py # SQLite connection + CREATE TABLE statements
├── seed_data.py # Populates patients.db with sample data
├── requirements.txt
├── tools/
│ ├── schema.py # get_schema tool
│ ├── query.py # query_database tool (SELECT-only, guarded)
│ ├── risk.py # get_patient_risk_summary tool
│ └── readmission.py # get_readmission_risk_summary tool
└── patients.db # created after running db.py + seed_data.pyRelated MCP server: MCP SQLite Server (Read-Only)
Tools exposed
Tool | What it does |
| Returns all table/column names so the agent can write correct SQL before it queries anything. |
| Runs an agent-generated SQL |
| Joins visits + labs + medications for one patient and produces a risk score/level with reasons. |
| Looks at visit frequency/spacing and diagnosis to estimate readmission risk. |
Setup
cd healthcare-mcp-server
pip install -r requirements.txt
# 1. Create the tables
python db.py
# 2. Populate sample data (safe to re-run)
python seed_data.py
# 3. Start the MCP server (Streamable HTTP on port 8000)
python server.pyThe server will be reachable at http://localhost:8000/mcp.
Connecting it to Claude Desktop
Open Claude Desktop → Settings → Developer → Edit Config.
Add an entry under
mcpServerspointing at your running server:
{
"mcpServers": {
"my-healthcare-server": {
"url": "http://localhost:8000/mcp"
}
}
}Save, fully quit and reopen Claude Desktop.
Click the + icon → your server should now be listed under connectors. Enable it, and Claude will be able to call the four tools above.
Example prompts to try
"Can you get me any 5 patient details?"
"What is the risk profile of the patient James Walker?"
"How many times has James Walker visited the hospital, and which doctors has he consulted?"
The last question needs a JOIN across visits and can't be answered without
the agent first calling get_schema to understand the table structure -
that's the point of exposing schema as its own tool.
Safety note
query_database only allows SELECT statements and blocks a short list of
destructive keywords (insert, update, delete, drop, alter,
attach). This is a minimal example guardrail, not a production-grade
solution - a real deployment would need parameterized queries, per-table
allow-lists, row limits, timeouts, and audit logging on top of this.
This server cannot be deployed
Maintenance
Related MCP Connectors
- dataOAuthco.thinair
PostgreSQL, MySQL, and SQL Server in one session. 26 read-only MCP tools for AI agents.
Astra DB tools for agents: schema, find, vector search, guarded writes, and interactive views.
- OleanderOAuthdev.oleander
The all-in-one data stack for agents. Upload files, run SQL, evolve tables, and render charts.
Query and update Teable records, manage tables, and access the Teable API with AI agents.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceExposes a SQLite database to AI assistants with structured, read-safe access. Includes five tools for schema exploration, querying, and sampling data.-
- FlicenseAqualityCmaintenanceEnables AI agents to safely inspect and query a SQLite database through read-only MCP tools for listing tables, describing schemas, and running paginated SELECT queries.3-
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to safely query and explore SQLite databases through read-only, guard-protected tools that block writes, sensitive table access, and runaway queries.1MIT
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to safely explore and query databases across SQLite, PostgreSQL, MySQL, and MSSQL, with schema introspection, natural language queries, and data profiling.20 PyPIMIT