mcp-mysql-server
If you are the rightful owner of mcp-mysql-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
A Model Context Protocol server that provides MySQL database operations, enabling AI models to interact with MySQL databases through a standardized interface.
The @f4ww4z/mcp-mysql-server is a Model Context Protocol (MCP) server designed to facilitate seamless interaction between AI models and MySQL databases. It provides a standardized interface for executing database operations such as connecting to a database, executing queries, and managing database tables. The server supports secure connection handling, prepared statements, and comprehensive error handling, making it a robust solution for database operations. It is implemented in TypeScript and offers automatic connection management to ensure efficient resource utilization. The server can be installed via Smithery or manually using npx, and it requires specific environment variables for configuration. It also supports running evaluations using the mcp-eval package, which allows for testing without the need for rebuilding between tests.
Features
- Secure connection handling with automatic cleanup
- Prepared statement support for query parameters
- Comprehensive error handling and validation
- TypeScript support
- Automatic connection management
Tools
connect_db
Use the provided credentials to establish a connection to the MySQL database
query
Execute SELECT query, support precompiled statement parameters
execute
Execute INSERT, UPDATE, or DELETE queries, and support precompiled statement parameters
list_tables
List all tables in the connection database
describe_table
Get the structure information of a specific table