The master skill in PlanetScale's official pack: runs a full read-only best-practices assessment of a database or org, then produces one evidence-backed report.
PlanetScale CLI AutomationSkill
Summary
How to drive the PlanetScale CLI non-interactively: --format json everywhere, auth check before anything else, pscale sql instead of pscale shell, correct flag placement.
Features
- Bootstrap with `pscale agent-guide` and `pscale auth check`, both --format json
- --format json on every command so output is parseable, never a table
- --org belongs on the resource subcommand, not on root pscale
- Positional arguments before flags; --force where a prompt would block
- `pscale sql` for non-interactive queries — never `pscale shell`
- Separates the CLI's AGENTS.md from your project's, and forbids editing the latter unasked
Install This Skill
Add this skill to your favorite AI agent in a few steps.
Skill Content
Usage Instructions
Learn how to use this skill with different AI agents.
Description
pscale is built for a human at a terminal, and an agent that treats it that way hangs on an interactive prompt or parses a table that was never meant to be parsed. This official PlanetScale skill is the conventions layer that stops that happening. It covers the CLI only — the operational workflows live in the pack's other skills.
Bootstrap, then assume nothing
Two commands come first, every time: pscale agent-guide --format json for the CLI's own machine-readable conventions, and pscale auth check --format json to confirm authentication. When auth check comes back "status": "action_required", the JSON carries issues and next_steps to follow — and login may need a human to approve in a browser, which the skill flags rather than letting the agent stall.
The conventions that actually bite
- `--format json` on everything. Table output is for people.
- `--org <org>` goes on the resource subcommand (
database,branch,sql,api), not on rootpscale. This is the flag placement people get wrong first. - Positional arguments before flags:
pscale sql mydb main --org bb .... - `pscale sql`, never `pscale shell` — the latter is interactive and will hang an unattended run.
- `--force` per command where a confirmation prompt would otherwise appear.
Two AGENTS.md files, and they are not the same
A distinction worth the space it takes: the CLI's own AGENTS.md (shipped with pscale, or pscale agent-guide) tells an agent how to call the CLI. Your application repository's AGENTS.md tells it which org, database, branch, engine, production branch, MCP scope and approval rules apply. The skill is explicit that the project file is not the agent's to edit without operator approval.
Run this before the other PlanetScale skills whenever the agent is driving pscale directly. Part of PlanetScale's official skill pack; works with any agent that reads SKILL.md.
Related Skills
Build crash-safe AI agents on AgentKit and step.ai — durable tool calls, human-in-the-loop approval, realtime progress, and when not to reach for an agent loop at all.
Inngest's durable-execution playbook as an agent skill — steps and memoisation, event and cron triggers, idempotency, cancellation, retries and non-retriable errors.
Temporal's official skill for building durable workflows — SDK patterns across seven languages, plus the determinism rules that decide whether a workflow survives a replay.