★ 1682 JavaScript MIT http 更新 10小时前

Mysql

A Model Context Protocol server that provides read-only access to MySQL databases. This server enables LLMs to inspect database schemas and execute read-only queries.

安装配置

npx @benborla29/mcp-server-mysql
MYSQL_HOST=127.0.0.1
   MYSQL_PORT=3306
   MYSQL_USER=mcp_test
   MYSQL_PASS=mcp_test_password
   MYSQL_DB=mcp_test

README 摘要

# MCP Server for MySQL - Claude Code Edition > **🚀 This is a modified version optimized for Claude Code with SSH tunnel support** > **Original Author:** [@benborla29](https://github.com/benborla) > **Original Repository:** [https://github.com/benborla/mcp-server-mysql](https://github.com/benborla/mcp-server-mysql) > **License:** MIT ## MCP Server for MySQL based on NodeJS [![Trust Score](https://archestra.ai/mcp-catalog/api/badge/quality/benborla/mcp-server-mysql)](https://archestra.ai/mcp-catalog/benborla__mcp-server-mysql) ### Key Features of This Fork - ✅ **Claude Code Integration** - Optimized for use with Anthropic's Claude Code CLI - ✅ **SSH Tunnel Support** - Built-in support for SSH tunnels to remote databases - ✅ **Auto-start/stop Hooks** - Automatic tunnel management with Claude start/stop - ✅ **DDL Operations** - Added `MYSQL_DISABLE_READ_ONLY_TRANSACTIONS` for CREATE TABLE support - ✅ **Multi-Project Setup** - Easy configuration for multiple projects with different databases ### Quick Start for Claude Code Users 1. **Read the Setup Guide**: See [PROJECT_SETUP_GUIDE.md](PROJECT_SETUP_GUIDE.md) for detailed instructions 2. **Configure SSH Tunnels**: Set up automatic SSH tunnels for remote databases 3. **Use with Claude**: Integrated MCP server works seamlessly with Claude Code A Model Context Protocol server that provides access to MySQL databases through SSH tunnels. This server enables Claude and other LLMs to inspect database schemas and execute SQL queries securely. ## Table of Contents - [Requirements](#requirements) - [Installation](#installation) - [Smithery](#using-smithery) - [Clone to Local Repository](#running-from-local-repository) - [Remote mode](#run-in-remote-mode) - [Components](#components) - [Configuration](#configuration) - [Environment Variables](#environment-variables) - [Multi-DB Mode](#multi-db-mode) - [Schema-Specific Permissions](#schema-specific-permissions) - [Testing](#testing) - [Troubleshooting](#troubleshooting) - [Contributing](#contributing) - [License](#license) ## Requirements - Node.js v20 or higher - MySQL 5.7 or higher (MySQL 8.0+ recommended) - MySQL user with appropriate permissions for the operations you need - For write operations: MySQL user with INSERT, UPDATE, and/or DELETE privileges ## Installation ### Using Smithery There are several ways to install and configure the MCP server but the most common would be checking this website [https://smithery.ai/server/@benborla29/mcp-server-mysql](https://smithery.ai/server/@benborla29/mcp-server-mysql) ### Cursor For Cursor IDE, you can install this MCP server with the following command in your project: 1. Visit [https://smithery.ai/server/@benborla29/mcp-server-mysql](https://smithery.ai/server/@benborla29/mcp-server-mysql) 2. Follow the instruction for Cursor MCP Get provides a centralized registry of MCP servers and simplifies the installation process. ### Codex CLI Codex CLI installation is similar to Claude Code below ```bash codex mcp add mcp_server_mysql \ --env MYSQL_HOST="127.0.0.1" \ --env MYSQL_PORT="3306" \ --env MYSQL_USER="root" \ --env MYSQL_PASS="your_password" \ --env MYSQL_DB="your_database" \ --env ALLOW_INSERT_OPERATION="false" \ --env ALLOW_UPDATE_OPERATION="false" \ --env ALLOW_DELETE_OPERATION="false" \ -- npx -y @benborla29/mcp-server-mysql ``` ### Claude Code #### Option 1: Import from Claude Desktop (Recommended if already configured) If you already have...

相关 MCP

Go Sdk

The official Go SDK for Model Context Protocol servers and clients. Maintained in collaboration with Google.

★ 4563 Go http 待补充
mcp Go http

Csharp Sdk

The official C# SDK for Model Context Protocol servers and clients. Maintained in collaboration with Microsoft.

★ 4275 C# http 待补充
mcp C# http

Core

A framework helps you quickly build AI Native IDE products. MCP Client, supports Model Context Protocol (MCP) tools via...

★ 3628 TypeScript http 待补充
mcp TypeScript http

Markdownify

A Model Context Protocol server for converting almost anything to Markdown

★ 2687 TypeScript http 待补充
mcp TypeScript http

Brightdata

A powerful Model Context Protocol (MCP) server that provides an all-in-one solution for public web access.

★ 2371 JavaScript sse 有配置
mcp sse JavaScript