mysql-mcp
2
The MySQL MCP Server project is an implementation of the Model Context Protocol to interact with MySQL databases. It provides tools for executing specific SQL queries and retrieving information about database tables.
MySQL MCP Server
This project implements an MCP (Model Context Protocol) server for working with MySQL databases. It supports various functionalities such as executing SQL queries and retrieving table structures and lists through specified MCP tools and resources.
Environment Variables
MYSQL_HOST
: MySQL server hostMYSQL_PORT
: MySQL server portMYSQL_USER
: MySQL usernameMYSQL_PASS
: MySQL passwordMYSQL_DB
: MySQL database name
Available MCP Tools
query
: execute SQL queries (only SELECT, SHOW, EXPLAIN, DESCRIBE)table-schema
: get table structurelist-tables
: get list of all tables in the database
Available MCP Resources
table://{name}
: get data from the specified table (up to 100 rows)