go-mcp-mysql

go-mcp-mysql

29

This project is a simple, ready-to-use MCP server designed to automate interactions with MySQL databases. It supports CRUD operations, read-only mode, and query plan verification while being easily configurable through command line arguments or DSNs.

Overview

  • Zero burden, ready-to-use Model Context Protocol (MCP) server for MySQL interaction and automation.
  • Provides CRUD operations and a read-only mode.
  • Can perform query plan checks with optional flags.
  • Work in progress, not recommended for production use.

Installation

  • Download the latest release or build from source with Go.

Usage

  • Use command line arguments or DSN for configuration.
  • Optional flags for read-only mode and query plan checks.

Tools

Schema Tools

  • list_database: List all databases.
  • list_table: List tables by name.
  • create_table: Create a new table.
  • alter_table: Alter a table, no drops allowed.
  • desc_table: Describe table structure.

Data Tools

  • read_query: Execute read-only queries.
  • write_query: Execute write queries.
  • update_query: Execute update queries.
  • delete_query: Execute delete queries.