MCP.so
ログイン

MySQL MCP Server

@ganganbiz1

基本情報

カテゴリ

データベース

トランスポート

stdio

作者

ganganbiz1

MySQL MCP Server について

概要はまだありません

MySQL MCP Server の設定

以下の設定を使って、このサーバーを MCP 対応クライアントに追加してください。

{
  "mcpServers": {
    "mysql-mcp-server-ganganbiz1": {
      "command": "docker",
      "args": [
        "build",
        "-t",
        "mysql-mcp-server",
        "."
      ]
    }
  }
}

MySQL MCP Server のツール

ツール一覧はまだありません

この掲載には表示できるツール一覧がまだありません。サーバーにツールがないという意味ではありません。対応機能はプロジェクトのドキュメントをご確認ください。

ツールは README から自動的に抽出されます。メンテナーは ## Tools という見出しの下に記載することで、このタブに反映できます。

概要

What is MySQL MCP Server?

A MySQL Model Context Protocol (MCP) server implemented with FastMCP 2.0 and Python. It enables AI assistants and MCP clients to execute SQL queries, retrieve database schema information, and explore MySQL databases via standardized MCP tools.

How to use MySQL MCP Server?

Deploy using Docker (recommended) or run locally with Poetry. Set environment variables (MYSQL_HOST, MYSQL_PORT, MYSQL_USER, MYSQL_PASSWORD, MYSQL_DATABASE) to connect to a MySQL instance. For Cursor integration, add the provided configuration to ~/.cursor/mcp.json. The server exposes five MCP tools: execute_query, execute_update, get_tables, get_table_schema, and describe_database.

Key features of MySQL MCP Server

  • Execute SQL queries and return results via MCP
  • Get schema information for tables and entire database
  • Fully containerized with Docker and docker-compose
  • Packaged with Poetry for dependency management
  • Provides five ready-to-use MCP tools

Use cases of MySQL MCP Server

  • AI assistants querying MySQL databases in real time
  • Dynamic schema exploration for database documentation
  • Automating data retrieval and updates via MCP clients
  • Integrating MySQL with Cursor or other MCP-supporting IDEs

よくある質問

1

What are the prerequisites for running MySQL MCP Server?

Docker and docker-compose are required for containerized deployment. For local development, you need Python 3.13+ and Poetry.

2

How do I connect the server to my MySQL database?

Set the environment variables `MYSQL_HOST`, `MYSQL_PORT`, `MYSQL_USER`, `MYSQL_PASSWORD`, and `MYSQL_DATABASE` before starting the container. The Docker run command passes these variables from the host environment.

3

What MCP tools does the server provide?

Five tools: `execute_query` (read-only SQL), `execute_update` (INSERT/UPDATE), `get_tables`, `get_table_schema`, and `describe_database` (comprehensive structure).

4

How do I integrate MySQL MCP Server with Cursor?

Add the provided JSON block to `~/.cursor/mcp.json`, specifying the Docker command and environment variables. The server will then be available as an MCP tool within Cursor.

5

Can I develop or run the server locally without Docker?

Yes, the project is packaged with Poetry for local development. The README lists Poetry as a prerequisite for non-Docker usage, though no explicit local run command is given.

コメント

「データベース」の他のコンテンツ