Registry / aws / awslabs-mysql-mcp-server

awslabs-mysql-mcp-server

JSON →
library1.0.21pypypiunverified

The AWS Labs MySQL Model Context Protocol (MCP) server enables AI agents and LLM applications to interact with MySQL databases, converting natural language questions into MySQL-compatible SQL queries. It's an active project by AWS Labs, with frequent updates, and currently at version 1.0.17. It integrates with various MCP-compatible AI clients/IDEs like Kiro, Cursor, and VS Code, extending their capabilities to manage and query MySQL databases securely.

pip install awslabs.mysql-mcp-server
INSTALL
IMPORT
SIG · AWSLABS-MYSQL-MCP-
A
awslabs-mysql-mcp-server
awspythonv1.0.21
Install
9.6s avg
Import
Disk
127MB
Pass rate
8/ 10
Env Coverage8 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.0.21 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
glibc
py 3.10
✓ —
✓ 11.43s
py 3.11
✓ —
✓ 10.18s
py 3.12
✓ —
✓ 8.53s
py 3.13
✓ —
✓ 8.28s
py 3.9
✕ build_error
✕ build_error
127MB installed
● package 127MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

awslabs.mysql-mcp-server
This library is primarily run as a server executable, not typically imported directly into Python applications by end-users. MCP clients (e.g., AI IDEs) invoke it.
The interaction is typically via an MCP client executing the server, not direct Python imports.

The AWS Labs MySQL MCP Server is designed to be executed as a server, which MCP-compatible AI clients connect to. The `uvx` command, as shown above, is the recommended way to run it, optionally specifying connection details for either RDS Data API or direct MySQL. Prior to running, ensure AWS credentials are configured (e.g., via `AWS_PROFILE` environment variable or `aws configure`), and your database credentials are securely stored in AWS Secrets Manager.

# The awslabs.mysql-mcp-server is intended to be run as an executable, often managed by an MCP client or 'uvx'. # This command starts the server, which an MCP client can then connect to. # Ensure your AWS credentials (e.g., via AWS_PROFILE) are configured and Secrets Manager # contains your MySQL credentials. # Example for RDS Data API connection (replace with your actual ARN and secret name): # export AWS_PROFILE="your-aws-profile" # export AWS_REGION="your-aws-region" # uvx awslabs.mysql-mcp-server@latest \ # --resource_arn "arn:aws:rds:your-aws-region:123456789012:cluster:your-db-cluster" \ # --secret_arn "arn:aws:secretsmanager:your-aws-region:123456789012:secret:your-db-credentials-XXXXXX" # Example for Direct MySQL connection (replace with your actual host, port, user, and secret name): # export AWS_PROFILE="your-aws-profile" # export AWS_REGION="your-aws-region" # uvx awslabs.mysql-mcp-server@latest \ # --hostname "your-mysql-host.com" \ # --port 3306 \ # --database "your_database_name" \ # --secret_arn "arn:aws:secretsmanager:your-aws-region:123456789012:secret:your-db-credentials-XXXXXX"
mysql-mcp-server --version
Debug
Known issues
breakingServer Sent Events (SSE) support was removed from all MCP servers in their latest major versions, effective May 26th, 2025. This change aligns with the Model Context Protocol specification. Streamable HTTP is planned as a replacement for improved transport capabilities.
fix
Clients should update to use new transport mechanisms as they become available. Review MCP client documentation for compatibility with post-SSE versions.
affects: >=1.0.0 (from May 26, 2025)
gotchaPotential for SQL injection if proper security practices are not followed. Although the MySQL MCP server includes a `mutable_sql_detector.py` for client-side checks, it is crucial to also enforce least-privilege access via server-side IAM/RBAC.
fix
Always configure the underlying MySQL database user with minimal necessary permissions (e.g., `SELECT` only if read-only operations are intended). Regularly review database access policies and use the latest MCP server version which includes enhanced client-side checks.
affects: All versions
gotchaThe `awslabs.core-mcp-server` is deprecated. If your setup used this for proxying, you must now configure individual MCP servers (like `awslabs.mysql-mcp-server`) directly in your client application.
fix
Refer to the MCP client's documentation (e.g., Kiro, Cursor, VS Code) on how to directly configure `awslabs.mysql-mcp-server` without relying on the deprecated core server.
affects: All versions (migration from `awslabs.core-mcp-server`)
Upgrade
Version history
1.0.21latest on PyPI · released May 28, 2026
Audit
Dependencies
pythonrequiredRequires Python 3.10 or newer.
uvoptionalRecommended for installation and running MCP servers.
Aurora MySQL ClusterrequiredTarget database for natural language queries.
AWS Secrets ManagerrequiredRequired for storing database credentials.
AWS RDS Data APIoptionalRequired if using RDS Data API connection method.
DockeroptionalRecommended for running the MCP server locally in a container.
Agent activity
21 hits · last 30 days
node
18
OpenAI (training)
1
Resources
awslabs-mysql-mcp-server — pip install awslabs-mysql-mcp-server · libregistry