← Back to Plugins
MCP Server MCP

io.github.andezdev/tokenlite-mysql-mcp

github By github 👁 1 views ▲ 0 votes

A secure, efficient, and intelligent MySQL server for the Model Context Protocol

Homepage Verified source GitHub

Install

npx -y @andezdev/[email protected]

Configuration Example

{
  "remotes": [],
  "packages": [
    {
      "registryType": "npm",
      "identifier": "@andezdev/tokenlite-mysql-mcp",
      "version": "4.1.0",
      "transport": {
        "type": "stdio"
      },
      "environmentVariables": [
        {
          "description": "MySQL Host address (defaults to localhost)",
          "format": "string",
          "name": "DB_HOST"
        },
        {
          "description": "MySQL Port (defaults to 3306)",
          "format": "string",
          "name": "DB_PORT"
        },
        {
          "description": "MySQL Username (defaults to root)",
          "format": "string",
          "name": "DB_USER"
        },
        {
          "description": "MySQL Password (defaults to empty string)",
          "format": "string",
          "isSecret": true,
          "name": "DB_PASSWORD"
        },
        {
          "description": "MySQL Database name",
          "isRequired": true,
          "format": "string",
          "name": "DB_NAME"
        },
        {
          "description": "EXPLAIN guardrail: max estimated rows for unindexed full table scans before blocking (defaults to 1000). MCP_SAFE_QUERY_MAX_ROWS is a deprecated alias.",
          "format": "string",
          "name": "MCP_EXPLAIN_MAX_SCAN_ROWS"
        },
        {
          "description": "Max rows returned per SELECT; injected as LIMIT at the AST level (defaults to 500)",
          "format": "string",
          "name": "MCP_QUERY_ROW_LIMIT"
        },
        {
          "description": "Deprecated alias for MCP_EXPLAIN_MAX_SCAN_ROWS",
          "format": "string",
          "name": "MCP_SAFE_QUERY_MAX_ROWS"
        },
        {
          "description": "Enable or disable the EXPLAIN guardrail (defaults to true)",
          "format": "string",
          "name": "MCP_SAFE_QUERY_ENABLE_BLOCKING"
        },
        {
          "description": "Absolute path to your custom metadata.json dictionary",
          "format": "string",
          "name": "MCP_METADATA_PATH"
        },
        {
          "description": "Absolute path to your custom templates.json pre-approved queries",
          "format": "string",
          "name": "MCP_TEMPLATES_PATH"
        },
        {
          "description": "Prefix for tool names, e.g., to run multiple instances (defaults to DB_NAME, e.g. mydb_). Only set to override.",
          "format": "string",
          "name": "TOOL_PREFIX"
        },
        {
          "description": "Max tool invocations per minute, sliding window (defaults to 60). Set to 0 to disable.",
          "format": "string",
          "name": "MCP_RATE_LIMIT_RPM"
        },
        {
          "description": "Max execution time for a query in milliseconds to protect against DoS (defaults to 15000)",
          "format": "string",
          "name": "MYSQL_QUERY_TIMEOUT"
        },
        {
          "description": "Max concurrent pool connections (defaults to 10)",
          "format": "string",
          "name": "MYSQL_CONNECTION_LIMIT"
        },
        {
          "description": "Max time to wait for a connection socket to establish in milliseconds (defaults to 10000)",
          "format": "string",
          "name": "MYSQL_CONNECT_TIMEOUT"
        },
        {
          "description": "Max retries on transient connection errors (defaults to 3)",
          "format": "string",
          "name": "MYSQL_RETRY_ATTEMPTS"
        },
        {
          "description": "Base delay in milliseconds for exponential backoff between retries (defaults to 1000)",
          "format": "string",
          "name": "MYSQL_RETRY_DELAY_MS"
        },
        {
          "description": "Max queued requests when all pool connections are busy to prevent memory leak (defaults to 50)",
          "format": "string",
          "name": "MYSQL_QUEUE_LIMIT"
        },
        {
          "description": "Time-to-live in seconds for cached DDL statements (defaults to 60)",
          "format": "string",
          "name": "MCP_DDL_CACHE_TTL"
        },
        {
          "description": "Minimum severity level for MCP log notifications (defaults to info). Levels: debug, info, notice, warning, error, critical, alert, emergency",
          "format": "string",
          "name": "MCP_LOG_LEVEL"
        },
        {
          "description": "Enable INSERT and REPLACE queries (defaults to false)",
          "format": "string",
          "name": "ALLOW_INSERT_OPERATION"
        },
        {
          "description": "Enable UPDATE queries (defaults to false)",
          "format": "string",
          "name": "ALLOW_UPDATE_OPERATION"
        },
        {
          "description": "Enable DELETE and TRUNCATE queries (defaults to false)",
          "format": "string",
          "name": "ALLOW_DELETE_OPERATION"
        },
        {
          "description": "Enable Data Definition Language queries like CREATE, ALTER, DROP, RENAME (defaults to false)",
          "format": "string",
          "name": "ALLOW_DDL_OPERATION"
        },
        {
          "description": "Enable TLS for the MySQL connection (defaults to false)",
          "format": "string",
          "name": "DB_SSL"
        },
        {
          "description": "Reject self-signed or untrusted TLS certificates when DB_SSL is true (defaults to true)",
          "format": "string",
          "name": "DB_SSL_REJECT_UNAUTHORIZED"
        }
      ]
    }
  ]
}
mcp model-context-protocol npm

Comments

Sign in to leave a comment

Loading comments...