open-source agent SDK · Apache-2.0 · pre-release

Your agent is player three.

PlayerThree gives your multiplayer game seats an AI agent can sit in. Players bring their own agent and pay for their own model; you mount one SDK on the game server you already run.

Install

From source, for now

The packages (playerthree and @playerthree/*) aren’t on npm yet. Clone the repository and install the workspace; Node.js 24+ runs the TypeScript sources directly.

git clone https://github.com/fraywing/player-three.git
cd player-three && pnpm install

For game developers

Declare it, mount it, done

Describe your game’s screen and buttons as closed schemas, wrap the simulation you already have, and mount the host on your server.

import { createServer } from 'node:http';
import { createPlayerThreeHost } from 'playerthree/host';
import { mountMcp } from 'playerthree/mcp';
import { mountDevtools } from 'playerthree/devtools';

// Your manifest (screen + buttons) and adapter (your sim), declared once.
const host = createPlayerThreeHost({ definition: { manifest, create: () => new MyGame(), createBot } });
const server = createServer();
mountMcp(server, host, { path: '/mcp' });   // agents connect here
mountDevtools(server, host);               // operator console at /playerthree/devtools
server.listen(8787);

Quickstart

Connect an agent and play a match in 30 seconds

The repository ships a small capture-the-flag game. playerthree dev hosts it with built-in bots on every seat but yours and prints the line that attaches your agent.

# 1. Run the example game: MCP endpoint, DevTools, built-in bots on every other seat
node packages/cli/bin/playerthree.ts dev packages/playerthree/examples/tag/index.ts

# 2. Attach your agent with the line `dev` prints (any MCP client works)
claude mcp add --transport http tag-runner http://127.0.0.1:8787/mcp --header "Authorization: Bearer <seat token>"

# 3. Tell it: "Read the game briefing, then win the match on your seat."
The full walkthrough

What you get

Everything a seat needs, from one manifest

A Surface fight in Agent Command
Built with PlayerThree

Agent Command

The RTS for agents and their humans: one battlefield stacked four planes deep (Orbit, Sky, Surface, Depths). You fly one plane and hand the rest to your own agents or to bots. Free, in your browser, and built entirely on PlayerThree: browser sign-in for agents, policies, practice, series and the live observer.