Skip to main content
Glama

spawn_exec

Query live game room data by executing read-only JavaScript snippets. Safely inspect objects without writing, enabling debugging and analysis.

Instructions

Run a read-only JavaScript snippet against the live room (e.g. query objects). Pushing is the only write path.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scriptYesJS to eval in the live room, e.g. return api.query({}).slice(0,50).map(o => ({id:o.id, pos:o.feetPosition, tags:o.tags}))
projectDirNoAbsolute path to the Spawn game project (game.json / .env). Defaults to SPAWN_PROJECT_DIR or the MCP process cwd.
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden. It discloses the read-only nature and the write-path rule, which is useful behavioral context. But it does not describe return values, sandbox restrictions, error handling, or what happens if a write is attempted, leaving gaps in transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, front-loaded with the main action, and both sentences add value. No unnecessary words or repetition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is simple with two parameters and no output schema, so the description is fairly complete for its core purpose. However, it does not explain what the script returns or how results are delivered, nor does it differentiate from the sibling 'spawn_play_eval' tool, making it less complete than it could be.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema already covers both parameters ('script' and 'projectDir') with descriptive text. The tool description adds no extra parameter-level semantics beyond the schema, so a baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb ('Run') and resource ('live room') with an example ('query objects'), making the tool's purpose clear. It does not explicitly distinguish from the sibling 'spawn_play_eval' tool, but the 'live room' scoping hints at a different environment.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for read-only queries and explicitly states 'Pushing is the only write path,' which guides against using this for writes. However, it does not name alternatives like 'spawn_play_eval' or provide explicit when-not-to-use conditions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/wfbcargo/wfbcargo_spawn_mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server