- Node.js 20+ (the CLI is zero-dependency — Node built-ins only).
- One or more supported coding agents installed (see Connecting your editor).
- A Phaser account with agent access — i.e. a subscription or credits. You'll sign in during setup; if you have no access yet the CLI will tell you and point you at the buy-credits page.
The fastest path is the interactive one-shot. It detects your editors, lets you pick, signs you in, and writes the config for each:
npx @phaserjs/game-agentWhat happens:
- Detect — it finds the coding-agent CLIs/editors you have installed.
- Pick — choose which to configure (or
all). - Sign in — your browser opens to authorize; the token is stored locally at
~/.config/phaser-game-agent/config.json. (No browser? Uselogin --token <t>— see the CLI reference.) - Configure — it writes the MCP server entry into each editor's config file.
Install it globally if you use a bridge-based editor (Codex, Cursor, Gemini CLI, Antigravity, Qoder, Windsurf). Those store an absolute path to the bundled
bridge.mjs; a global install keeps that path stable:npm install -g @phaserjs/game-agentClaude Code and VS Code talk to the server directly (no bridge), so they don't need this — but a global install never hurts.
MCP servers are read at startup. Restart the editor/CLI you just configured or it won't see the new server.
Ask your agent:
"Check my Phaser Game Agent account"
It should greet you by name and report your credit balance. That single call proves the whole
chain works — the tool loaded, your token is valid, and the server answered. (Under the hood
that's the phaser_game_agent_hello tool.)
If nothing happens, see Troubleshooting.
Once the account check works, just describe what you want:
"use the Phaser Game Agent — open a project and build me a Breakout clone, then preview it."
Your agent will call phaser_game_agent_guide first to learn the workflow, then open a project,
build, and hand you a preview URL. The game lives in your Phaser account library with versions and
play analytics, exactly as if it were built on the website.
Run phaser-game-agent again any time. When you're already signed in it shows who you're logged
in as and gives you a menu to:
- Configure / update your coding agents (including a "Configure a CLI not on this list" option for anything we don't list yet)
- Refresh your token across everything you've already configured
- Show credits balance and transactions, with a buy-more link
- Log out
See the CLI reference for the non-interactive commands.