Skip to content

MySQL Reporter

Lets an agent query a MySQL database read-only and turn results into formatted reports.

Repository
xerrors/Yuxi
Stars
7,576
Licence
MIT
Files
5 files

What it does

Once installed, the agent can connect to a MySQL database through small Python scripts, list tables, inspect table structures, and run read-only SELECT-style queries to build a report with tables, key figures and conclusions. The scripts check that queries are read-only and that table names are safe, and the skill tells the agent not to reveal passwords or the raw SQL it ran. If database settings are missing, the agent is instructed to ask you to add them in your sandbox environment variables rather than guessing.

Great for

  • Analysts who want quick sales, user or business metric reports from a MySQL database by asking in plain language
  • Teams with a read-only reporting replica that want an agent to summarise results
  • Operators who already maintain a description of their database to help the agent interpret tables

Skip it if

  • Anyone who needs the agent to change data, since the skill is designed for read-only queries and should not be pointed at production write access
  • Use with a database holding sensitive personal data without reviewing permissions first, because the agent will read whatever the configured account can read

Try asking

  • “Generate a weekly sales report from the orders table with totals and week-over-week change”
  • “List the tables in our analytics database and explain what each one likely contains”
  • “Show the structure of the users table and summarise signup trends for last month”
Step-by-step guide: how to use MySQL ReporterInstall, first run, examples, tips and FAQs

Install in 3 steps

  1. 1

    Download the skill

    The ZIP contains the 5 original files, the MIT licence and an attribution note.

    mysql-reporter.zip
  2. 2

    Add it to your agent

    Claude Code (all projects)

    mkdir -p ~/.claude/skills && unzip mysql-reporter.zip -d ~/.claude/skills/

    Claude Code / Agent SDK (this project only)

    mkdir -p .claude/skills && unzip mysql-reporter.zip -d .claude/skills/

    Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.

  3. 3

    Ask for the task

    No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.

Get better results

  • Use a read-only database account so the agent cannot change data even if a query slips through the checks.
  • Set MYSQL_DATABASE_DESCRIPTION to explain business terms so the agent interprets tables correctly.
  • Ask for a specific time range and metric to keep queries efficient and avoid full table scans.

What's inside

  • scripts/_mysql_common.py
  • scripts/describe_table.py
  • scripts/list_tables.py
  • scripts/query.py
  • SKILL.md

Redistributed unmodified from xerrors/Yuxi under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.