Any MCP client
Connect it by hand
Not in the list? Any MCP-compatible client works. There are only two shapes to know, and the CLI will print both, filled in for your machine, if you run npx @phaserjs/game-agent manual.
The agent runs on credits
Building gives you your own cloud sandbox, where your projects and the Phaser Agentic Engine live. Time on it is billed per minute, and generating images and audio costs credits too. A fully featured game typically costs around 500 credits to build.
You need credits on your Phaser account before you can build.
Which key does my client use?
You add one server named phaser-game-agent. Only the container key differs by client:
- mcpServers
Cursor, Windsurf, most VS Code AI forks, Claude (JSON) - servers
native VS Code, Copilot (JSON) - mcp_servers
Codex (TOML)
Your access token
A token and a positive credit balance are required to perform any operation on the MCP server.
Checking your account…
Shape A · Native remote HTTP
For clients that speak remote MCP
If your client offers a “remote / HTTP MCP server” option, use this. No bridge, no local process: it sends your token as a Bearer header. Swap mcpServers for servers if that’s your client’s key.
{
"mcpServers": {
"phaser-game-agent": {
"type": "http",
"url": "https://mcp.phaser.io/agent/mcp",
"headers": { "Authorization": "Bearer pga_YOUR_TOKEN" }
}
}
}
Shape B · stdio bridge
Works with every client
For clients that launch a local command and speak MCP over stdio. This runs the bundled bridge.mjs, which proxies to the hosted server and carries your token in an env var. The node and bridge.mjs paths are machine-specific, so run npx @phaserjs/game-agent manual to get the real ones.
{
"mcpServers": {
"phaser-game-agent": {
"command": "/absolute/path/to/node",
"args": ["/absolute/path/to/bridge.mjs"],
"env": {
"PHASER_AGENT_MCP_URL": "https://mcp.phaser.io/agent/mcp",
"PHASER_GAME_AGENT_TOKEN": "pga_YOUR_TOKEN"
}
}
}
}
TOML clients (Codex-style) use the same data as a table:
[mcp_servers.phaser-game-agent]
command = "/absolute/path/to/node"
args = ["/absolute/path/to/bridge.mjs"]
[mcp_servers.phaser-game-agent.env]
PHASER_AGENT_MCP_URL = "https://mcp.phaser.io/agent/mcp"
PHASER_GAME_AGENT_TOKEN = "pga_YOUR_TOKEN"
Then restart & verify
Restart your client (MCP servers are read at startup) and ask its agent:
Got a client working that we don’t list? We’d love to add it as a first-class target, so tell us at the phaser-game-agent repo.
What you can ask it
You describe what you want in plain language and your agent calls the tools for you. Tap a prompt to copy it.
Account and games
Build a game
Tweak and polish
Build your first game
Three prompts, start to finish. Paste them into your agent’s chat.
Prove the connection
It greets you by name and reports your credit balance, which tells you the tool loaded and your token works.
Check my Phaser Game Agent accountDescribe a game
Your agent reads the built-in guide, opens a cloud project, reuses known-good blocks, writes the code, type-checks it and publishes a preview. You get a public
playUrlwhen it finishes.Use the Phaser Game Agent: open a project and build me a Breakout clone, then preview it.Play it and ask for changes
Open the play URL in your browser, then keep talking. Your sandbox pauses automatically after every operation, so you pay for the work it does and not for the time you spend playing or thinking.
Make the paddle wider and add a particle burst when a brick breaks.Add a high-score table that survives a refresh.How many plays has my game had?
After the build
Finished games land in your library at /agent/games, with versions and play analytics. From there you can:
Play it
Runs in the browser. Players need no download and no account.
Share it
Every game gets a public link you can send to anyone.
Export it
Download a standalone build for Web, Windows, macOS or Linux.
Embed it
Drop it into your own site with an iframe.