Connect to MySQL and run read-only queries to inspect table data.

Apache-2.0Auto-check: notesDatabases

Install Mysql Query

skills CLI
$ npx skills add hashgraph-online/awesome-codex-plugins --skill mysql-query -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install hashgraph-online/awesome-codex-plugins mysql-query --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/hashgraph-online/awesome-codex-plugins.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/Colin4k1024/tsp/skills/mysql-query .claude/skills/mysql-query && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
mysql-query
GitHub stars
1.3k
Token cost
~799 tokens
SKILL.md length
152 words
Files
4 (incl. scripts)
Skills in repo
714
Repo updated
First seen
Licence
Apache-2.0

At a glance

Connect to MySQL and run read-only queries to inspect table data.

  • Works in 4 steps: 先确认 SQL 是只读语句,并按需补 LIMIT。 → 优先使用当前 skill 的脚本执行,除非用户明确要求别的方式。 → 若连接信息不完整或只读边界不清晰,先停在 待确认项,不要私自补全。 → …
  • The user wants to query MySQL
  • SKILL.md covers 何时使用, 连接信息:必须由用户提供, 执行合同 and 执行查询, plus 3 more sections
  • Runs Python scripts from its folder; calls python3 and pip3

What it does

Mysql Query is an agent skill from hashgraph-online/awesome-codex-plugins. Connect to MySQL and run read-only queries to inspect table data. Use when the user wants to query MySQL, show tables, view table contents, check schema, or run read-only SQL. Connection info must be provided by the user; do not read from environment or application config.

Its SKILL.md is about 800 tokens, which your agent loads only when the skill is triggered. The skill folder holds 5 other files, including scripts (for example `agents/openai.yaml` and `scripts/query.py`).

It sits in Databases, covering SQL. It works with MySQL and SQL. The repository describes itself as: A curated list of awesome OpenAI Codex / ChatGPT plugins, skills, and resources. The 1 Codex Marketplace. See live plugins at: https://hol.org/plugins/best-codex-plugins. The licence is Apache-2.0.

When your agent uses it

  • The user wants to query MySQL
  • View table contents
  • Run read-only SQL

Example prompts

  • “/mysql-query”

Requirements

  • Python 3

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. 先确认 SQL 是只读语句,并按需补 LIMIT。
  2. 优先使用当前 skill 的脚本执行,除非用户明确要求别的方式。
  3. 若连接信息不完整或只读边界不清晰,先停在 待确认项,不要私自补全。
  4. 不把密码写入仓库、脚本文件或长期日志。

What it can do on your machine

Read from SKILL.md and the folder at commit 9e7b281. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 2 files in scripts/ (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python3
    • pip3

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use pip3, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Mysql Query loads about 799 tokens when it runs. Until then it costs about 71 tokens; SKILL.md has 152 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~71
When it runs · the whole SKILL.md, loaded when a task matches
~799

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NoteMentions a .env fileSKILL.md:15
    plication.yml`、`application-*.yml`、环境变量、`.env` 等读取 MySQL 连接信息。

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from hashgraph-online/awesome-codex-plugins at commit 9e7b281, republished under its Apache-2.0 licence (© hashgraph-online). 152 words, ~799 tokens.

Download SKILL.mdSave it as .claude/skills/mysql-query/SKILL.md (or your agent's skills folder). This skill also uses 3 other files; get the full folder from GitHub.
name
mysql-query
description
Connect to MySQL and run read-only queries to inspect table data. Use when the user wants to query MySQL, show tables, view table contents, check schema, or run read-only SQL. Connection info must be provided by the user; do not read from environment or application config.

MySQL 连接与查询

何时使用

  • 用户要求查询 MySQL、查询数据库里一共有哪些表、查看某张表数据、统计条数、检查表结构
  • 必须由用户提供连接信息(host、port、user、password、database),不得从环境变量或 application.yml 读取

连接信息:必须由用户提供

  • 禁止从 application.yml、application-*.yml、环境变量、.env 等读取 MySQL 连接信息。
  • 调用脚本或写代码时,必须使用用户本次提供的:host、port、user、password、database。
  • 若用户未提供完整连接信息,应提示用户补全后再执行。

执行合同

适用前提
  • 任务目标是只读查询、验数、查结构或排障取数,而不是写库或迁移。
  • 用户已经在本次对话中提供了完整连接信息;若未提供完整信息,本 skill 只能停在待补充状态。
任务变量
  • host、port、user、password、database:全部必须来自用户当次提供。
  • sql:本次准备执行的只读 SQL。
  • <skill_dir>:当前安装环境中的 mysql-query 技能目录,用于定位脚本。
变量来源
  • 所有连接变量只能来自用户消息、当前任务单或上游 /handoff 中明确给出的数据库连接信息。
  • 不允许从仓库配置、环境变量、历史默认值或示例命令中推断真实密码。
  • <skill_dir> 为当前 skill 安装目录,由运行环境解析,不需要用户提供。
  • 若 SQL 语义不明确,应先把查询目标写清楚再执行,避免误查大表。
执行入口
  1. 先确认 SQL 是只读语句,并按需补 LIMIT。
  2. 优先使用当前 skill 的脚本执行,除非用户明确要求别的方式。
  3. 若连接信息不完整或只读边界不清晰,先停在 待确认项,不要私自补全。
  4. 不把密码写入仓库、脚本文件或长期日志。
输出回落
  • 查询结果应按当前任务目标回落到 /team-execute、/team-review 或 /handoff 的证据区,而不是只停留在终端输出。
  • 若查询用于发布验证或数据核对,需在 /team-release 或 /team-review 中注明表、条件、时间点和结论。
  • 用户提供的连接信息只在本次任务内使用,不进入文档存档。

执行查询

使用脚本(推荐)

使用 python3,依赖:pip3 install pymysql。路径示例:<skill_dir>/scripts/query.py,其中 <skill_dir> 为当前安装环境里的 mysql-query 技能目录。

参数(均由用户提供):

  • --host:MySQL 主机(必填)
  • --port:端口(可选,默认 3306)
  • --user:用户名(必填)
  • --password:密码(必填)
  • --database:数据库名(必填)
  • --sql:SELECT 语句(必填,或通过 stdin 传入)
bash
# 用户提供连接信息后,按下列方式调用
python3 <skill_dir>/scripts/query.py \
  --host 127.0.0.1 \
  --port 3306 \
  --user myuser \
  --password '用户提供的密码' \
  --database mydb \
  --sql "SELECT * FROM users LIMIT 10"

# 从标准输入传 SQL
echo "SELECT id, name FROM products LIMIT 5" | python3 <skill_dir>/scripts/query.py \
  --host 127.0.0.1 --port 3306 --user myuser --password 'xxx' --database mydb

脚本会:

  • 只执行 read-only 类型的 SQL 语句(非 read-only 会报错退出)
  • 将结果以表格形式打印到 stdout
内联代码时

若在项目内写一次性脚本,连接参数也必须来自用户当次提供的变量或输入,不要从 application.yml 或 os.environ 读取。

python
import pymysql

# 使用用户提供的变量(例如从 API 入参、用户输入传入)
host = user_provided_host
port = user_provided_port
user = user_provided_user
password = user_provided_password
database = user_provided_database

conn = pymysql.connect(host=host, port=port, user=user, password=password, database=database, charset="utf8mb4")
# ...

安全与约定

  • 默认只做只读:未明确要求时不执行写操作或 DDL。
  • LIMIT:对未知大表查询时建议加 LIMIT。
  • 敏感信息:不把用户提供的密码写进仓库或日志;仅在当次请求中使用。

常见场景

用户需求做法
看某张表前 N 条SELECT * FROM table_name LIMIT 20
查表结构DESCRIBE table_name 或 SHOW CREATE TABLE table_name
统计行数SELECT COUNT(*) FROM table_name
按条件查用 WHERE,必要时加 LIMIT

Overview

连接 MySQL 执行只读查询,支持查看表列表、表结构、表数据和聚合统计。连接信息(host/port/user/password/database)必须由用户在本次对话中提供,禁止从配置文件或环境变量读取。

本 skill 只执行只读 SQL,不执行 INSERT / UPDATE / DELETE 等写操作。

© hashgraph-online, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 3 other files (scripts) in plugins/Colin4k1024/tsp/skills/mysql-query of hashgraph-online/awesome-codex-plugins.

  • SKILL.md
  • agents/openai.yaml
  • scripts/query.py
  • scripts/requirements.txt

Open the folder on GitHubat commit 9e7b281

Compare with similar skills

Mysql Query next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Mysql Query compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Mysql Query this skillhashgraph-online/awesome-codex-plugins1.3k—~799Automated safety check: NotesApache-2.0
SQL Database Support for pRESTprest/prest4.6k—~1.6kAutomated safety check: PassMIT
Chdb SQLvemetric/vemetric3951 repos~1.2kAutomated safety check: PassApache-2.0
Sql2erystemsrx/sql_to_ER188—~1.1kAutomated safety check: PassAGPL-3.0
Squixeduardofuncao/squix273—~784Automated safety check: PassMIT
Golang Databaseunxed/f42412 repos~2.9kAutomated safety check: PassMIT

Similar skills

  • Guides classifying, gap-analyzing and scaffolding support for a new SQL database in pREST, from Postgres-compatible variants to entirely new dialects.

    4.6k GitHub stars~1.6k tokensUpdated today
    DatabasesAuto-check passed
  • Chdb SQL

    vemetric/vemetric

    A skill your agent uses when the user wants to run SQL — especially analytical SQL — on local files (parquet/csv/json), URLs, S3 paths, or remote databases (Postgres, MySQL, MongoDB, ClickHouse…

    395 GitHub starsUsed in 1 repo~1.2k tokens
    DatabasesAuto-check passed
  • Sql2er

    ystemsrx/sql_to_ER

    A skill your agent uses when the user wants a Chen-model ER diagram from SQL CREATE TABLE statements or DBML, wants to rearrange or clean up an existing sql2er state, wants a skeleton-only overview…

    188 GitHub stars~1.1k tokensUpdated 8 days ago
    DatabasesAuto-check passed
  • Squix

    eduardofuncao/squix

    Run SQL queries across databases (Postgres, MySQL, SQLite, etc.) via the squix CLI.

    273 GitHub stars~784 tokensUpdated 16 days ago
    DatabasesAuto-check passed
  • Comprehensive guide for Go database access — parameterized queries, struct scanning, NULLable columns, transactions, isolation levels, SELECT FOR UPDATE, connection pool, batch processing, context…

    241 GitHub starsUsed in 2 repos~2.9k tokens
    DatabasesAuto-check passed
  • Database Migrations SQL Migrations

    rmyndharis/antigravity-skills

    SQL database migrations with zero-downtime strategies for PostgreSQL, MySQL, SQL Server

    1.7k GitHub starsUsed in 3 repos~577 tokens
    DatabasesAuto-check: notes

More from hashgraph-online/awesome-codex-plugins

All 714 skills in this repo
  • Anime Reaction Gif

    hashgraph-online/awesome-codex-plugins

    Create original anime-style reaction stickers as looping GIFs and MP4 previews, using generated character pose sheets and timed key poses.

    1.3k GitHub stars~922 tokensUpdated today
    Auto-check passed
  • Calibredb

    hashgraph-online/awesome-codex-plugins

    Manage and query Calibre libraries with the calibredb CLI (local paths or Calibre Content server URLs).

    1.3k GitHub stars~1k tokensUpdated today
    Auto-check passed
  • Rust API Test Harness

    hashgraph-online/awesome-codex-plugins

    A skill your agent uses when adding, changing, testing, or debugging Rust HTTP APIs and services, especially when Codex needs black-box integration tests, random-port app startup, real database test…

    1.3k GitHub stars~1.7k tokensUpdated today
    Auto-check passed
  • Art

    hashgraph-online/awesome-codex-plugins

    Make a studio's game look like something at build time — a cover from a real frame of the game (free), painted covers, backdrops, textures and character plates from image models through the…

    1.3k GitHub stars~2.4k tokensUpdated today
    Auto-check passed
  • Calle

    hashgraph-online/awesome-codex-plugins

    Use CALL-E from Codex through the calle CLI. An agent skill from hashgraph-online/awesome-codex-plugins.

    1.3k GitHub stars~2.9k tokensUpdated today
    Auto-check passed
  • Game Balance Economy

    hashgraph-online/awesome-codex-plugins

    Balance game difficulty, resources, rewards, probability, progression, economies, and dominant strategies.

    1.3k GitHub stars~618 tokensUpdated today
    Auto-check passed

Works with

Categories

Questions about Mysql Query

What does Mysql Query do?

Connect to MySQL and run read-only queries to inspect table data. Mysql Query is an agent skill from hashgraph-online/awesome-codex-plugins. Connect to MySQL and run read-only queries to inspect table data.

When should I use Mysql Query?

Mysql Query fits situations like: the user wants to query MySQL; view table contents; run read-only SQL.

How do I install Mysql Query in Claude Code?

Run `npx skills add hashgraph-online/awesome-codex-plugins --skill mysql-query -a claude-code`. Or copy the skill folder (plugins/Colin4k1024/tsp/skills/mysql-query in hashgraph-online/awesome-codex-plugins) into .claude/skills/mysql-query in your project. Claude Code loads it when a task matches its description.

How do I install Mysql Query in Codex?

Run `npx skills add hashgraph-online/awesome-codex-plugins --skill mysql-query -a codex`. Or copy the skill folder (plugins/Colin4k1024/tsp/skills/mysql-query in hashgraph-online/awesome-codex-plugins) into .agents/skills/mysql-query in your project. Codex loads it when a task matches its description.

Can I use Mysql Query in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add hashgraph-online/awesome-codex-plugins --skill mysql-query -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/mysql-query, .gemini/skills/mysql-query, .github/skills/mysql-query and .opencode/skills/mysql-query in your project.

What does Mysql Query need to run?

Going by SKILL.md and its folder, Mysql Query needs Python for the scripts in its folder and the command-line tools its instructions call (python3 and pip3). Our summary lists: Python 3.

Does Mysql Query access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Mysql Query safe to install?

Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Mysql Query use?

Mysql Query is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Mysql Query use?

About 799 tokens (SKILL.md is roughly 3.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Mysql Query?

Skills that share tags, products or a category with Mysql Query: SQL Database Support for pREST (prest/prest, 4.6k stars), Chdb SQL (vemetric/vemetric, 395 stars), Sql2er (ystemsrx/sql_to_ER, 188 stars) and Squix (eduardofuncao/squix, 273 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Mysql Query?

hashgraph-online (a GitHub organization) maintains it in hashgraph-online/awesome-codex-plugins, which has 1,255 GitHub stars. The repository holds 714 skills in this directory. The repository was last updated on October 9, 2026.

Source: hashgraph-online/awesome-codex-plugins on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.