Skip to content

Read-only MySQL query skill for multiple configured databases, with description-based auto-selection and write blocking.

CCM score
67 of 100
skills.sh installs
426
GitHub stars
462
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers listing databases, browsing tables and schemas, and running SELECT-style queries with optional row limits
  • Includes scripts/query.py with flags --list, --tables, --schema, --query, and --limit across named connections
  • Enforces a read-only session, single-statement validation, a 30-second timeout, and a 10,000-row cap per query
  • Designed for analysts who need to query several MySQL databases where write access must be blocked

Install

$ npx -y skills add sanjay3290/ai-skills --skill mysql -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

MySQL Read-Only Query Skill

Execute safe, read-only queries against configured MySQL databases.

Requirements

  • Python 3.8+
  • mysql-connector-python: pip install -r requirements.txt

Setup

Create connections.json in the skill directory or ~/.config/claude/mysql-connections.json.

Security: Set file permissions to 600 since it contains credentials:

chmod 600 connections.json
{
  "databases": [
    {
      "name": "production",
      "description": "Main app database - users, orders, transactions",
      "host": "db.example.com",
      "port": 3306,
      "database": "app_prod",
      "user": "readonly_user",
      "password": "your-password",
      "ssl_disabled": false
    }
  ]
}

Config Fields

Details

Repository
github.com/sanjay3290/ai-skills
Categories
Databases, Data Science & Analytics
License
Apache-2.0
First seen
Jun 3, 2026

Questions

What does the mysql skill do?

The mysql skill runs read-only SQL queries against one or more MySQL databases. It can list tables, show schemas, and run SELECT queries with a row limit. It blocks write operations such as INSERT, UPDATE, DELETE and DROP for safety.

How do I install the mysql skill?

Run npx -y skills add sanjay3290/ai-skills --skill mysql -y in your project. Afterward, the agent can query your configured MySQL databases through this skill.

What does the mysql skill need before it works?

It needs Python 3.8 or newer and the mysql-connector-python package, installed from requirements.txt. You also create a connections.json file with each database's host, database name, user and password, and set its permissions to 600.

Which database skills lead the Databases category?

The mysql skill sits in the Databases category alongside Prisma and Supabase Postgres skills, which lead that category on Claude Marketplaces. This skill is set apart by its focus on read-only MySQL access across several connections.

How does the mysql skill pick which database to query?

Each database entry has a description of the data it holds, and the skill matches the user's request to those descriptions. If the match is unclear, it lists the configured databases and asks which one to use.

More from sanjay3290/ai-skills

All 20

Similar to Mysql

More Databases