mcpbeat Sign in

Planetscale Pscale CLI Automation Agent Skill

>- Use the PlanetScale CLI (pscale) from automated agents with --format json, auth check, pscale sql, and per-command --force. Run before other PlanetScale skills when driving pscale directly. Use when the user asks to automate pscale, run CLI commands headless, or verify pscale auth from an agent.

877 tokens
context cost
the whole folder, loaded on every use
1
files
instructions only
0
copies elsewhere
how many repositories repackaged it
103
stars on the repo
on the repository, not the skill itself

Install

one command, takes just this skill from the repository
npx skills add https://github.com/planetscale/skills --skill planetscale-pscale-cli-automation

The instruction itself

9 sections, as written by the author

PlanetScale CLI automation

Purpose

Teach agents how to invoke pscale non-interactively. This skill covers **CLI

conventions only**. Operational workflows (inventory, safety review, schema

recommendations) use the other skills in this repo — start with

../00-safe-orchestrator/SKILL.md for a full assessment.

Two AGENTS.md files (do not confuse them)

| Document | Where | Purpose |

|----------|-------|---------|

| CLI agent guide | Shipped with pscale (AGENTS.md in the CLI repo, or pscale agent-guide) | How to call pscale: auth, --format json, flag placement, pscale sql |

| Project agent guide | Your application repository's AGENTS.md | Which org, database, branch, engine, prod branch, MCP scope, approval rules |

Do not edit project AGENTS.md without operator approval (see

../09-mcp-agent-operating-model/SKILL.md).

Bootstrap (always start here)

pscale agent-guide --format json
pscale auth check --format json

If auth check returns "status": "action_required", follow issues and

next_steps in the JSON. For login, the human may need to approve in the

browser; use pscale auth login --format json.

Conventions

  • Always pass --format json for automation.
  • Put --org <org> on resource subcommands (database, branch, sql,

api, …) — not on root pscale.

  • Put positional arguments before flags (pscale sql mydb main --org bb …).
  • Use pscale sql, not pscale shell (shell requires a TTY).
  • Default SQL role is reader; pass --role admin (or writer/readwriter) for

writes. Match pscale shell semantics for --role and --replica.

  • --force is per subcommand only (e.g. database delete … --force, `pscale

sql … --force). There is no global --force or PSCALE_FORCE`.

  • --format json alone never skips confirmations — add --force on the

destructive subcommand after explicit user approval.

Typical workflow

pscale auth check --format json
pscale org list --format json
pscale database list --org <org> --format json
pscale branch list <database> --org <org> --format json
pscale sql <database> <branch> --org <org> --format json --query "SELECT 1"

MySQL uses @primary by default (same as pscale shell); pass --keyspace only

for multi-keyspace databases.

MCP vs CLI

  • MCP clients — use the hosted PlanetScale MCP server (see `pscale agent-guide

--format json` for the current URL).

  • Shell scripts and coding agents — use pscale with --format json as above.

When this skill is not enough

Install the full PlanetScale skills pack (if not already):

git clone https://github.com/planetscale/skills.git && cd skills && script/setup
# or: npx skills add planetscale/skills -g -y

Then run sub-skills or ../00-safe-orchestrator/SKILL.md for database operations

beyond basic CLI invocation.

Current conventions source of truth

Prefer live output over memorized flag syntax:

pscale agent-guide --format json

The embedded guide field contains the full CLI agent guide shipped with your

pscale binary.

Other skills for the same job

different authors, same section of the catalogue
Hook Development
by anthropics
vendor ×2

This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.

16k tokens scripts
Hook Development
by anthropics
vendor ×2

This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.

16k tokens scripts
Copilot SDK
by christophacham
×2

Build agentic applications with GitHub Copilot SDK. Use when embedding AI agents in apps, creating custom tools, implementing streaming responses, managing sessions, connecting to MCP servers, or creating custom agents. Triggers on Copilot SDK, GitHub SDK, agentic app, embed Copilot, programmable agent, MCP server, custom agent.

6k tokens
Cass
by Dicklesworthstone
×2

Coding Agent Session Search - unified CLI/TUI to index and search local coding agent history from Claude Code, Codex, Gemini, Cursor, Aider, ChatGPT, Pi-Agent, Factory, and more. Purpose-built for AI agent consumption with robot mode.

6k tokens
Dcg
by Dicklesworthstone
×2

Destructive Command Guard - High-performance Rust hook for Claude Code that blocks dangerous commands before execution. SIMD-accelerated, modular pack system, whitelist-first architecture. Essential safety layer for agent workflows.

4k tokens
Makepad Skills
by ComeOnOliver
×2

Makepad UI development skills for Rust apps: setup, patterns, shaders, packaging, and troubleshooting.

2k tokens
Varlock Claude Skill
by ComeOnOliver
×2

Secure environment variable management ensuring secrets are never exposed in Claude sessions, terminals, logs, or git commits

3k tokens
Create Agentsmd
by github
vendor ×1

Prompt for generating an AGENTS.md file for a repository

2k tokens

How to use it

Copy the folder

Take planetscale/planetscale-pscale-cli-automation from the repository into ~/.claude/skills for personal use, or into .claude/skills inside a project.

Check the name does not clash

The agent identifies a skill by the name field in its header. Two skills with the same name cannot sit side by side — one of them will be ignored.

Install what it needs

The instructions reference npx. Without those the skill loads but fails at the first command.