mcp-readonly-db
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| MCP_DB_PATH | No | The SQLite file to expose. Relative paths depend on where the app was launched from, so use absolute paths in the Claude config. | ./data/shop.db |
| MCP_MAX_ROWS | No | Most rows any single answer may contain. Maximum is 1000. | 200 |
| MCP_AUDIT_LOG | No | Where every request is recorded. | ./logs/audit.log |
| MCP_QUERY_TIMEOUT_MS | No | A query running longer than this is stopped. | 5000 |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| list_tablesA | List every table and view in the database with its row count. Start here. |
| describe_tableB | Show a table's columns (name, type, nullability, primary key), foreign keys and row count. |
| sample_rowsA | Return the first few rows of a table so you can see what the data looks like. |
| run_queryA | Run ONE read-only SQLite SELECT statement (WITH ... SELECT is fine). Writes, PRAGMA, ATTACH, comments and multiple statements are rejected. Use ? placeholders with the params array instead of pasting values into SQL. Results are capped at a row limit and queries are time-limited. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 4 tools
Each tool occupies a clear niche in a database exploration workflow: list_tables for discovery, describe_table for schema, sample_rows for quick previews, and run_query for ad-hoc SQL. sample_rows could technically be done via run_query, but the descriptions make the intended progression unambiguous and the guardrails differ.
All four tools follow a consistent snake_case verb_noun pattern (list_tables, describe_table, sample_rows, run_query). No mixed conventions or vague names.
Four tools is well-scoped for a read-only database explorer: enough to cover discovery, schema inspection, previewing, and querying without redundancy. Every tool earns its place.
The surface covers the full read-only lifecycle from table discovery through querying, with no dead ends for the stated purpose. Minor gaps like listing indexes/views separately or EXPLAIN support exist but agents can work around them via run_query or describe_table.