The automatic schema discovery is what makes the single `query` tool workable — the model can see column names and types before writing SQL rather than guessing. And read-only is enforced twice, in validation and in the transaction, so the guarantee does not depend on the model behaving. Small surface, clear promise.
A deliberately narrow MySQL server. It gives a model two things — the schema of every table, and one tool for running SELECT statements — and enforces read-only at two levels: the SQL is validated to allow only SELECT, and every query runs inside a READ ONLY transaction. There is no path to INSERT, UPDATE, DELETE, CREATE, ALTER or DROP.
- A SQL query executed against the connected database, inside a READ ONLY transaction — `query`
- JSON schema information for each table, discovered automatically from database metadata, with column names and data types, exposed as resources rather than requiring a call
- A hard boundary: SQL validation permits SELECT only, and no data-modification or schema-modification statement can pass
- Communication over JSON-RPC on stdio, which is what a local client expects
Node v18 or newer. The connection string is a command-line argument: `npx -y @davewind/mysql-mcp-server mysql://user:password@localhost:port/database`, so the credential lives in your client's config file — give it a database user with read permission only, and the enforcement is then belt and braces. It can also be installed globally with `npm install @davewind/mysql-mcp-server -g`.
One command plus a key — npm install @davewind/mysql-mcp-server -g, then supply credentials
