Skip to main content
Glama
okenjioxx

Roblox Executor MCP Server

by okenjioxx

Execute code and wait for the result

execute-and-wait
Destructive

Run Luau in a live Roblox client and wait for the structured result: success, returned value, printed output, and any error. Use for debugging or inspecting function returns in one call.

Instructions

Run Luau in the active Roblox client and WAIT for what happened, returning a structured result: { ok, returnValue, output, error? }. Unlike the fire-and-forget 'execute' tool, this reports success/failure, any error message, the FIRST value your code returns (encoded so Instances/Vector3/etc. survive), and the print()/warn() output it emitted. Output capture connects game:GetService("LogService").MessageOut to a buffer for the duration of the run, then disconnects — so it sees logs even when an executor routes print() to the Roblox console rather than swapping the global. The code is COMPILED FIRST via loadstring (a syntax error is reported as { ok = false, error } and nothing runs), then executed under pcall; a runtime error is reported in error, never as a tool failure. Use this for quick experiments, debugging, or calling a function and inspecting what it gives back in one round trip. Signature: { code: string, client: string?, agent: string?, threadContext: number?, timeoutMs: number? }. Phase: act; cost=medium; idempotency=contextual-write. Requires: active-client, explicit-mutation-approval, validated-source. Produces: operation-receipt. Verify with: assert-state. Safety: MUTATING; executes caller-selected behavior in the live client. On failure: inspect tool-schema for exact fields, defaults, constraints, and an invocation example.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesThe Luau code to run. It may 'return' a value (the FIRST return comes back in `returnValue`, encoded) and may print()/warn() (captured into `output`). Do not JSON-encode anything yourself.
agentNoOptional. A stable label for WHICH agent is calling when several share this MCP session (e.g. 'researcher'). Gives that agent its own fair scheduling lane, its own persistent VM on each game, and its own queue budget, so co-tenant agents don't starve or clobber each other.
clientNoOptional. Run on a specific connected client — its clientId OR username — for THIS call only, overriding your session's select-client binding without changing it. Lets multiple agents drive different games at the same time; omit to use your session's selected client.
timeoutMsNoOptional per-call deadline in milliseconds; omit it to use the tool or server default.
threadContextNoOptional Roblox thread identity for this call; omit it to use the server default.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0-spies.2

TDQS

A4.6/5.0
Behavior5/5

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

Goes well beyond the annotations (destructive/idempotent hints): it discloses the output-capture mechanism (LogService.MessageOut buffered then disconnected), compile-first via loadstring with syntax errors returned as { ok=false, error }, execution under pcall, and the crucial contract that runtime errors are reported in `error` and never as a tool failure. That is exactly the behavioral context annotations cannot carry.

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

Conciseness4/5

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

Front-loads the core behavior and error contract efficiently, with each sentence doing work (capture mechanism, compile-then-pcall, sibling distinction). It is dense and slightly long, and the trailing 'Phase/cost/Requires/Produces/Verify' metadata block plus the pointer to tool-schema is boilerplate padding.

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

Completeness5/5

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

For a mutating execution tool with no output schema, the description fully specifies the return object ({ ok, returnValue, output, error? }), the error semantics, the safety posture, and required preconditions (active-client, explicit-mutation-approval). Nothing an agent needs to call it correctly is missing.

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?

Schema coverage is 100% and the per-parameter descriptions (especially agent and client) are already rich, so the baseline is 3. The description's 'Signature: { code, client, agent, threadContext, timeoutMs }' restates parameter names without adding meaning beyond the schema, so it does not exceed the baseline.

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

Purpose5/5

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

States a specific verb and resource ('Run Luau in the active Roblox client') plus the key scope distinction ('WAIT for what happened') and the exact return shape. It explicitly names the sibling it is not ('fire-and-forget execute'), so an agent can differentiate without opening either schema.

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

Usage Guidelines5/5

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

Names the alternative ('execute') and the condition that selects this one (fire-and-forget vs. reporting result). Adds concrete scenarios: 'quick experiments, debugging, or calling a function and inspecting what it gives back in one round trip.' Nothing left to inference.

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

Deploy Server

Other Tools