Preface¶
In WordPress plugin, theme, or Blueprint related tasks, you often need to “get a runnable site up first” before validating changes. Locally, you can install a full stack, or use WordPress Playground: running WordPress via WebAssembly in the browser or CLI, with SQLite under the hood, and instances can be discarded at any time. Playground capabilities are extensive—local @wp-playground/cli, playground.wordpress.net share links, snapshots, mounting local code, version switching, Xdebug, etc.—but if an AI assistant picks paths based on impressions, it can easily mix up Blueprint authoring with runtime execution, or misidentify requirements regarding “browser-only” vs. “local disk access.”
The following introduces wp-playground from the official WordPress Agent Skills repository: it is not an encyclopedia of Playground, but rather a layer of routing wrappers. It first determines which workflow you need, then loads only the corresponding reference or sister skill, avoiding redundancy and mis-routing.
What This Is¶
wp-playground comes from WordPress/agent-skills, maintained in alignment with the WordPress ecosystem. The skill describes itself as a thin routing wrapper: when user intent is ambiguous, or tasks span multiple Playground capabilities, it routes according to a fixed procedure instead of piling Blueprint schemas and CLI details into a single document.
The division of labor with the blueprint skill is clear: for writing, reviewing, schemas, steps, resources, bundles, etc. of Blueprint JSON, the blueprint skill should be used directly; wp-playground is responsible for routing and guidance regarding Playground workflows such as runtime, CLI, debugging, and share links.
Official directory location: skills/wp-playground.
Compatibility (Skill Metadata):
- WordPress 7.0+, PHP 7.4.0+
- Playground CLI requires Node.js 20.18+; WordPress runs in WebAssembly, database is SQLite
Core Features¶
The following capabilities are derived from the skill description and routing table, categorized by workflow.
Intent Recognition and Routing¶
The Agent selects subsequent documents based on user intent, and in principle loads only the reference relevant to the current task at a time; if the request contains multiple independent parts, more than one may be loaded.
- Determine the category: Blueprint authoring/review, local CLI, browser-only/share links, Xdebug or stuck CLI, or mixed requests.
- Route to the corresponding source below; for mixed tasks, hand the Blueprint part to
blueprint, then return to wp-playground to handle runtime, CLI, debugging, or sharing. - Do not duplicate Blueprint schema details within wp-playground.
| Intent | Destination |
|---|---|
| Blueprint JSON, schema, steps, resources, bundles or Blueprint review | Use the blueprint skill |
Local CLI: @wp-playground/cli server, run-blueprint, build-snapshot, mounting, version switching, local verification |
references/cli.md |
| Xdebug or stuck CLI | references/debugging.md |
| Browser-only: Query API, Blueprint URLs, share links, browser limitations; existing site operations via WebMCP, Playground MCP, Sites API | references/website.md (load only the corresponding reference based on the chosen connection method; when no connection method is specified, prioritize available WebMCP tools for supported browser operations) |
The skill description also mentions: WebMCP site tools, snapshots, mounts, version switching, Xdebug, as well as playground.wordpress.net share links and browser previews, are all expanded in the references pointed to by the above routing.
Information the Agent Needs to Clarify Beforehand¶
- Workflow type: Blueprint authoring, local CLI, website/share links, snapshots, or debugging.
- If mounting or packaging local code is needed: project or bundle path.
- If version-sensitive: target WordPress / PHP version.
- Local services: port preference.
- Whether browser sharing is mandatory, or whether access to the local file system is mandatory.
Validation and Common Failure Modes¶
Validation:
- Blueprint content: Against the published schema, and follow the verification of the
blueprintskill. - Local CLI: Confirm the mounted plugin/theme or Blueprint side effects within the Playground instance.
- Share links: Open the generated URL, confirm the landing page and expected resource loading.
Failure Modes (Skill explicitly requires correcting routing):
- Blueprint-related work mistakenly entering wp-playground → Switch to the blueprint skill.
- Browser-only workflow but needing local file system → Switch to CLI (
references/cli.md);playground.wordpress.netcannot read local paths. - Local CLI workflow but wanting a shareable browser link → Check
references/website.md; local server URLs are not portable share links. - Debugging being vaguely handled as a “secondary jump” → Read
references/debugging.mddirectly.
Upgrade Path: If the task requires PHP extensions, native databases, persistence, or near-production facilities, and Playground cannot meet them, the skill suggests switching to a full WordPress stack, such as wp-env, Docker, or the project’s own environment.
Installation and Activation¶
The fastest way uses the npx skills recommended by the official repository (consistent with the agent-skills README).
To install only wp-playground:
npx skills add WordPress/agent-skills --skill wp-playground
To view all skills in the repository:
npx skills add WordPress/agent-skills --list
To install multiple skills at once (example includes wp-playground):
npx skills add WordPress/agent-skills --skill wp-plugin-development wp-abilities-api wp-playground
Scope: By default, it asks whether to install to the project (e.g., .cursor/skills/, .claude/skills/), which can be committed to version control for team sharing. For global installation, add -g / --global, e.g.:
npx skills add WordPress/agent-skills --skill wp-playground --global
Cursor Global: After cloning and building agent-skills, you can use the official script to install to ~/.cursor/skills/:
node shared/scripts/skillpack-install.mjs --targets=cursor-global
(For full clone, build, and steps to install to Codex / VS Code / Claude / Cursor paths, see the Quick Start in WordPress/agent-skills.)
Before local CLI related operations, the skill requires confirming Node.js 20.18+ and the availability of npm / npx.
Typical Usage (Agent-side Process)¶
wp-playground does not replace you writing Playground commands by hand, but prescribes that the Agent routes first, then reads deep docs. A reproducible collaboration method is as follows.
- Describe the goal to the assistant (e.g., “Get a local site up with a Blueprint and mount the current plugin,” “Generate a playground.wordpress.net share link,” “CLI is stuck and needs Xdebug”).
- The assistant loads wp-playground and categorizes the intent according to the Procedure.
- If Blueprint JSON is involved → Switch or parallelly use the blueprint skill.
- If for local execution → Use
@wp-playground/cliaccording toreferences/cli.md(e.g., server,run-blueprint,build-snapshot, etc., depending on the reference). - If purely browser-based → Configure Query API / Blueprint URL according to
references/website.md; when sharing is needed, verify the URL opens and resources load correctly. - If for debugging → Follow
references/debugging.mddirectly (Xdebug, runtime logs, worker flags, etc.).
Example of a mixed request: Let blueprint complete JSON authoring and schema validation first, then return to wp-playground to guide local run-blueprint or browser sharing, avoiding mixing two sets of authoritative instructions in the same conversation turn.
Scenarios and Notes¶
Who is it for
- Developers using Cursor, Claude Code, Codex, Copilot, etc. that support Agent Skills, who frequently spin up temporary Playground environments in WordPress tasks.
- Teams that have installed WordPress/agent-skills and want Playground-related questions to not have the AI guess the workflow incorrectly.
Constraints (Guardrails)
- Playground instances are disposable, based on SQLite; do not point to production data.
- Browser-only Playground cannot read local file system paths; use public URLs, hosted ZIP bundles, or inline Blueprint JSON, or switch to local CLI mounting.
- The single source of truth for Blueprint remains in the blueprint skill; do not copy schema examples in wp-playground.
According to official WordPress documentation: these skills are generated from documentation and Gutenberg/WordPress materials, then reviewed by contributors, are v1, and will continue to iterate; see the repository’s docs/ai-authorship.md for details.
Closing¶
The value of wp-playground lies in collapsing the multiple entry points of Playground into an executable routing: Blueprints go to blueprint, CLI / browser / debugging each read the corresponding reference, and it specifies validation and correction methods upon failure. If you are already using Agents for WordPress development, install it along with blueprint, wp-env, etc., to reduce the trial and error of the “spinning up an environment” step.
Official Skill Directory: https://github.com/WordPress/agent-skills/tree/trunk/skills/wp-playground