npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

crimson-mysql-mcp

v1.3.3

Published

A Model Context Protocol (MCP) server that provides MySQL database connectivity and tools.

Readme

MySQL MCP Server

A Model Context Protocol (MCP) server that provides MySQL database connectivity and tools.

Installation

npm install
npm run build

Usage

Configuration

The server can be configured using either environment variables or command-line arguments. Environment variables take precedence over command-line arguments.

Environment Variables

  • MYSQL_HOST: MySQL host (default: localhost)
  • MYSQL_PORT: MySQL port (default: 3306)
  • MYSQL_USER: MySQL user (default: root)
  • MYSQL_PASSWORD: MySQL password (default: empty)
  • MYSQL_DATABASE: MySQL database (default: test)

Command-Line Arguments

  • -h, --host: MySQL host (default: localhost)
  • -p, --port: MySQL port (default: 3306)
  • -u, --user: MySQL user (default: root)
  • -P, --password: MySQL password (default: empty)
  • -d, --database: MySQL database (default: test)

Examples

Basic usage with default settings:

crimson-mysql-mcp

Specify custom host and database:

crimson-mysql-mcp --host db.example.com --database myapp

Using short flags:

crimson-mysql-mcp -h 192.168.1.100 -u myuser -P mypass -d production

Claude Desktop Configuration

Using environment variables (recommended):

{
  "mcpServers": {
    "mysql": {
      "command": "npx",
      "args": [
        "-y",
        "[email protected]"
      ],
      "env": {
        "MYSQL_HOST": "your-mysql-host",
        "MYSQL_PORT": "3306",
        "MYSQL_USER": "your-username",
        "MYSQL_PASSWORD": "your-password",
        "MYSQL_DATABASE": "your-database"
      }
    }
  }
}

For local development:

{
  "mcpServers": {
    "mysql": {
      "command": "node",
      "args": [
        "/path/to/your/crimson-mysql-mcp/build/index.js"
      ],
      "env": {
        "MYSQL_HOST": "localhost",
        "MYSQL_USER": "root",
        "MYSQL_DATABASE": "test"
      }
    }
  }
}

Available Tools

  • get-schema: Get the schema/structure of a MySQL table
    • Parameters: schemaName (string) - The name of the table to describe

Development

# Install dependencies
npm install

# Run in development mode
npm run server:dev

# Build the project
npm run build

# Watch and rebuild on changes
npm run server:build:watch

# Run with MCP Inspector (for debugging)
npm run server:inspect

Publishing to npm

To make this package available via npx:

  1. Update the package.json with your npm account details
  2. Run:
    npm publish

License

ISC