
Free deckbuilding 4X space game you play against your AI in the browser. No sign-in, no API key.
Maintain this server? Claim it
Call this server's tools from your browser. Nothing to install.
Requests go through mcptry because browsers can't call most MCP servers directly. Header values are sent to the server for that request only and are never stored or logged.
Tool list from our last check. Connect live to refresh it.
Do one action on your turn, given as one of the objects from legal_actions. Returns ok, error (why not, if it failed), log (what happened), turn and game_over, and hand_changed when cards left or joined your hand other than by being played. The player sees each move on their map, so it needs no explaining. {"type": "next_phase"} ends the fleet phase (locking ship orders and fleet cards) or the deploy phase (locking card plays); {"type": "end_turn"} (from the buy phase) hands the turn to the player: then call wait_for_turn at once (don't end your reply: the game only comes back to you through wait_for_turn). To send a ship somewhere it can't reach this turn, use {"type": "move", "fleet": id, "x": x, "y": y, "toward": true}: it goes as far along the way as it can (around the black hole and systems), as its move for the turn. Add "keep": 1 to stop next to a system (to settle or raze it next turn), or "keep": 2 for a Carrier to strike from. A ship's move can be split over several move orders in a turn (its move_tiles_left says what's left); entering a rival's zone of control ends it. Under fog of war (The Divide) a move is also walked tile by tile. It stops short, keeping the rest of its move, when a gap, system or ship you hadn't seen is in its way, or a rival ship comes into sight within its attack range; entering a rival's zone of control ends its move. The log line says where it ended up, why it stopped, and the tiles of its move left; look again (get_state or legal_actions) before the next order. An attack, bombard or raze with x, y that stops short on the way makes no attack: its error says where the ship stopped and why.
The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them.
One action object from legal_actions, unchanged (a move with x, y set to one of its tiles).
This tool isn't marked read-only, so it may change something on the server or in an account you connected.
Pick your client. Values in capitals, like YOUR_TOKEN, are yours to fill in.
Run in a terminal
claude mcp add --transport http peace-in-space-game https://peaceinspace.app/mcp
Do one action on your turn, given as one of the objects from legal_actions. Returns ok, error (why not, if it failed), log (what happened), turn and game_over, and hand_changed when cards left or joined your hand other than by being played. The player sees each move on their map, so it needs no explaining. {"type": "next_phase"} ends the fleet phase (locking ship orders and fleet cards) or the deploy phase (locking card plays); {"type": "end_turn"} (from the buy phase) hands the turn to the player: then call wait_for_turn at once (don't end your reply: the game only comes back to you through wait_for_turn). To send a ship somewhere it can't reach this turn, use {"type": "move", "fleet": id, "x": x, "y": y, "toward": true}: it goes as far along the way as it can (around the black hole and systems), as its move for the turn. Add "keep": 1 to stop next to a system (to settle or raze it next turn), or "keep": 2 for a Carrier to strike from. A ship's move can be split over several move orders in a turn (its move_tiles_left says what's left); entering a rival's zone of control ends it. Under fog of war (The Divide) a move is also walked tile by tile. It stops short, keeping the rest of its move, when a gap, system or ship you hadn't seen is in its way, or a rival ship comes into sight within its attack range; entering a rival's zone of control ends its move. The log line says where it ended up, why it stopped, and the tiles of its move left; look again (get_state or legal_actions) before the next order. An attack, bombard or raze with x, y that stops short on the way makes no attack: its error says where the ship stopped and why.
| Argument | Type | Description |
|---|---|---|
| code* | string | The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them. |
| action* | object | One action object from legal_actions, unchanged (a move with x, y set to one of its tiles). |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"action",
"code"
],
"properties": {
"code": {
"type": "string",
"description": "The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them."
},
"action": {
"type": "object",
"description": "One action object from legal_actions, unchanged (a move with x, y set to one of its tiles).",
"propertyNames": {
"type": "string"
},
"additionalProperties": {}
}
}
}Reference text (Markdown): "rules" (how a turn goes, combat, winning), "production" (every ship and building, with costs and stats) or "techs" (the tech tree by tier, with costs). Prices for what you can buy right now are in legal_actions.
| Argument | Type | Description |
|---|---|---|
| code* | string | The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them. |
| topic* | string | rules: how a turn goes, combat, winning. production: every ship and building. techs: the tech tree. |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"topic",
"code"
],
"properties": {
"code": {
"type": "string",
"description": "The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them."
},
"topic": {
"enum": [
"rules",
"production",
"techs"
],
"type": "string",
"description": "rules: how a turn goes, combat, winning. production: every ship and building. techs: the tech tree."
}
}
}What your empire can see right now: turn, your_turn, your empire (phase, pools, hand with each fleet/tactic card's rules text, techs), your ships' AP, the enemy, every planet and fleet on the map, the board's size, and the log of what you saw happen since your last turn ended. Fields that would be empty, false or 0 are left out. The black hole's tiles (no piece enters them) come with the game's first board only: board=true sends them again (The Divide's gaps, which grow as you chart the board, come every time). Tiles are (x, y) hexes, odd rows shifted half a tile right. Rival details are hidden outside your systems' and fleets' view: a rival ship's type is "unknown" until it has been in view, and a rival ship or system out of view has in_view: false. What's out of view is unknown, not absent. On The Divide (board.fog_of_war) you know only what you've seen: you start with what your homeworld and first ship see, and whatever your ships and systems see is charted for good, gaps too (board.gaps: no piece enters one); planets lists only those systems (one out of sight with in_view: false, holder_last_seen and last_seen_turn), fleets lists rival ships only while in sight, and enemy.homeworld is -1 until you've found it. Both halves hold the same systems: board.your_half says how many colony and outpost sites yours has and how many you've found, so while some are still unfound, a ship sent over your own half finds you room to expand. Your ships there carry move_tiles_left of move_tiles: a turn's move can be spent over several moves. crates lists the supply crates you know of (x, y, resource, amount): a ship that moves onto or through one takes it, +2 of that resource to your pool. Distances are counted for you: each rival ship has nearest_mine (your closest ship or system, in tiles) and, if armed, threatens_fleets / threatens_planets (what of yours it could reach and hit next turn, as the crow flies); each armed ship of yours has in_range_fleets / in_range_planets (what it can hit from where it stands). On Derelict Shipyard, fleets with neutral: true are guards that belong to nobody (guards: the system they hold, which shows guarded: true): they strike any ship that ends its owner's turn near that system, and it can't be settled until they're destroyed. A "notice" says when the player started a new game or their game reloaded its save (and which of your actions that undid). Works on the player's turn too. brief: true answers with the same board as short lines of text: pools, hand, systems, every ship with its HP, AP and what it can hit or threatens, and the log.
| Argument | Type | Description |
|---|---|---|
| code* | string | The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them. |
| board | boolean | Include the board's size and black hole tiles (sent with the first board only). |
| brief | boolean | Answer with your board as short lines of text instead of JSON: your pools, hand, systems, every ship with its HP, AP and what it can hit or threatens, and the log. Far fewer tokens. |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"code"
],
"properties": {
"code": {
"type": "string",
"description": "The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them."
},
"board": {
"type": "boolean",
"default": false,
"description": "Include the board's size and black hole tiles (sent with the first board only)."
},
"brief": {
"type": "boolean",
"default": false,
"description": "Answer with your board as short lines of text instead of JSON: your pools, hand, systems, every ship with its HP, AP and what it can hit or threatens, and the log. Far fewer tokens."
}
}
}Every action available on your turn, each a JSON object to pass to act unchanged (types: choose_job, play, tactic, sensor_sweep, spy, overload, feed, buy, scrap, move, attack, bombard, raze, settle, undo, next_phase, end_turn; only the current phase's). A few entries need one value added: a move lists the `tiles` the ship can reach (send {"type": "move", "fleet": id, "x": x, "y": y} with one of them; with tiles_as_known: true, under fog of war, they're the tiles as you know them: space you can't see counts as open, so the move may stop short); a fleet card or scrap that fits several ships lists them in `fleets` (send it with "fleet": one of them); a Sensor Sweep (sensor_sweep, one per Sensor Outpost ready) needs x, y: any tile. Buys carry their name and cost (get_reference has what they do); a ship's buy lists the `tiles` it can launch on: add x, y to pick one, or leave them out for the first free one. When a tech is missing for want of research, you.next_tier says what the next costs. An attack, bombard or raze with x, y moves the piece there first and then acts, as the ship's one turn (its AP). With `fleet`, only that ship's orders.
| Argument | Type | Description |
|---|---|---|
| code* | string | The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them. |
| fleet | integer | Only this ship's orders. -1 for every action. |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"code"
],
"properties": {
"code": {
"type": "string",
"description": "The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them."
},
"fleet": {
"type": "integer",
"default": -1,
"maximum": 9007199254740991,
"minimum": -9007199254740991,
"description": "Only this ship's orders. -1 for every action."
}
}
}Start a new game. Call this first whenever the player wants to play and their message names no code or link: don't ask them for one. Returns a fresh code and the link for them to open in their own browser: give them the link, then call wait_for_turn in the same reply, which holds until they open it. Only if they say they already have a game open, ask for its code instead. Leave map out (the default map) unless the player asks for a particular one; if they do, pass it, and the game they open starts on it.
| Argument | Type | Description |
|---|---|---|
| map | string | The map to play on, by id. Leave it out unless the player asks for a particular map. black_hole (Black Hole, the default: A black hole fills the middle; the two sides meet through a lane above it and one below, a bonus world in each.); derelict_shipyard (Derelict Shipyard: Open space, and one red star in the very middle with an Orbital Shipyard built in, for whoever clears the neutral warships that guard it.); twin_giants (Twin Giants: Two dying giant stars, mirrored, leave three lanes: a bonus world in the top and bottom ones, one colony site in the middle one.); the_divide (The Divide: Gaps break up the middle of the board. You know only what you see: the rest, the rival's homeworld too, is fog until you've seen it. Systems and gaps are placed afresh each game.). |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"properties": {
"map": {
"enum": [
"black_hole",
"derelict_shipyard",
"twin_giants",
"the_divide"
],
"type": "string",
"default": "black_hole",
"description": "The map to play on, by id. Leave it out unless the player asks for a particular map. black_hole (Black Hole, the default: A black hole fills the middle; the two sides meet through a lane above it and one below, a bonus world in each.); derelict_shipyard (Derelict Shipyard: Open space, and one red star in the very middle with an Orbital Shipyard built in, for whoever clears the neutral warships that guard it.); twin_giants (Twin Giants: Two dying giant stars, mirrored, leave three lanes: a bonus world in the top and bottom ones, one colony site in the middle one.); the_divide (The Divide: Gaps break up the middle of the board. You know only what you see: the rest, the rival's homeworld too, is fog until you've seen it. Systems and gaps are placed afresh each game.)."
}
}
}How an attack by your piece `fleet` would go, against the enemy piece `target` or the enemy system `planet` (give one): from where it stands, or from tile x, y it would move to first (as an attack with x, y from legal_actions does). Changes nothing.
| Argument | Type | Description |
|---|---|---|
| x | integer | Preview from this tile, as if moved there first. -1: from where it stands. |
| y | integer | The tile's row, with x. |
| code* | string | The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them. |
| fleet* | integer | The attacking ship (one of yours). |
| planet | integer | An enemy system to attack. Give target or planet. |
| target | integer | An enemy ship to attack. Give target or planet. |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"fleet",
"code"
],
"properties": {
"x": {
"type": "integer",
"default": -1,
"maximum": 9007199254740991,
"minimum": -9007199254740991,
"description": "Preview from this tile, as if moved there first. -1: from where it stands."
},
"y": {
"type": "integer",
"default": -1,
"maximum": 9007199254740991,
"minimum": -9007199254740991,
"description": "The tile's row, with x."
},
"code": {
"type": "string",
"description": "The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them."
},
"fleet": {
"type": "integer",
"maximum": 9007199254740991,
"minimum": -9007199254740991,
"description": "The attacking ship (one of yours)."
},
"planet": {
"type": "integer",
"default": -1,
"maximum": 9007199254740991,
"minimum": -9007199254740991,
"description": "An enemy system to attack. Give target or planet."
},
"target": {
"type": "integer",
"default": -1,
"maximum": 9007199254740991,
"minimum": -9007199254740991,
"description": "An enemy ship to attack. Give target or planet."
}
}
}Keep your plan for this game on the server, where it outlasts your context: each turn's first board (wait_for_turn, get_state) starts with it as your_plan, with the turn you wrote it; later boards that turn just say it's unchanged. Send the whole plan each time: it replaces the last one. Keep to what the board can't tell you: your intent, lessons and triggers. Don't copy the board into it (ship ids, HP, positions): it comes every turn, and a copy is stale within a turn or two. Short and concrete works best, about 10 lines, for example: WIN PATH: how you actually win: whose homeworld falls, how and roughly when. NEXT 3 TURNS (to turn N): what you'll settle, build, research and move. BY TURN N+5 / N+10: where your empire and fleets should be. ENEMY: how they play and where their pushes come from (not a list of their ships). LESSONS: what this game has taught you (what one ship can do to a colony, which ship beats which). DON'T: the mistakes this plan guards against (chasing kills deep into their side, feeding ships in one at a time). REVISE IF: the triggers that mean the plan no longer holds (losing a system, losing 2+ warships, enemy ships within 4 tiles of a colony). Write one on your first turn. Then at the start of each turn, check its REVISE IF triggers against the board and your_plan.since_written (the systems and ships you've lost or gained since you wrote it): rewrite it when one has fired, a step is done or the board changes your mind, and leave it be when it still holds (turns_ago says how long it has stood). The player and their game don't see it. Changes nothing in the game.
| Argument | Type | Description |
|---|---|---|
| code* | string | The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them. |
| plan* | string | Your whole plan, as text (up to 3000 characters). It replaces the one kept before; an empty string drops it. |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"plan",
"code"
],
"properties": {
"code": {
"type": "string",
"description": "The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them."
},
"plan": {
"type": "string",
"maxLength": 3000,
"description": "Your whole plan, as text (up to 3000 characters). It replaces the one kept before; an empty string drops it."
}
}
}Wait until it's your turn, then return the board (as get_state). Your first call starts the player's game and gives you your empire; if they haven't opened it yet, it waits for them to, answering {"your_turn": false, "game_open": false} when its hold runs out: call it again. Holds up to 50 seconds; if your turn hasn't started by then it returns {"your_turn": false} with how long the player has been on their turn and usually takes: call it again right away (no need to pause, and don't end your reply to wait for the player: their turn ends when this returns). While the player's game tab is hidden (it pauses the game) it waits the same way, with tab_hidden: true, and returns once they're back. It's safe to call repeatedly and can run as a long-running or background call. The player would rather not have a commentary on your turn. Your turn's board starts with your_plan: the plan you kept with set_plan, the turn you wrote it, turns_ago and since_written, the systems and ships you've lost or gained since (null if none). With brief: true, your turn's board comes as short lines of text instead of JSON (far fewer tokens).
| Argument | Type | Description |
|---|---|---|
| code* | string | The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them. |
| brief | boolean | Answer with your board as short lines of text instead of JSON: your pools, hand, systems, every ship with its HP, AP and what it can hit or threatens, and the log. Far fewer tokens. |
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"required": [
"code"
],
"properties": {
"code": {
"type": "string",
"description": "The game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them."
},
"brief": {
"type": "boolean",
"default": false,
"description": "Answer with your board as short lines of text instead of JSON: your pools, hand, systems, every ship with its HP, AP and what it can hit or threatens, and the log. Far fewer tokens."
}
}
}We read every tool's name, description and inputs the way the model will, looking for instructions hidden from you. A clean result means no warning signs, not a guarantee. Scanned Dec 4, 2026.