Skip to main content
Glama

code run

code_run
Read-only

Run Python 3.13 (numpy, pandas), JavaScript (Node 24) or bash in a fresh isolated container with no Internet access, and get stdout, stderr and the exit code. For calculations, data wrangling, parsing and testing snippets. $0.005 for a 10 s limit, $0.01 up to 30 s, $0.02 up to 60 s. Costs $0.02 USDC per call (x402).

Input Schema

NameRequiredDescriptionDefault
codeYesProgram source
stdinNoOptional input piped to the program
languageNopython (default), javascript or bash
timeout_sNo1-60, default 10

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior5/5

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

Goes well beyond the readOnlyHint/openWorldHint annotations: it discloses sandbox isolation ('fresh isolated container'), a hard capability limit ('no Internet access'), the return channels (stdout, stderr, exit code), and the cost/payment model (timeout-tiered pricing plus an x402 USDC charge). These are exactly the operational facts an agent needs before invoking a code-execution primitive.

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 purpose, then use cases, then pricing in three tight sentences with little waste. The pricing tail is slightly muddled, however: '$0.02 up to 60 s' and 'Costs $0.02 USDC per call' can be read as two different charges, which invites confusion rather than clarity.

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

Completeness4/5

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

With no output schema, the description correctly enumerates the returns (stdout, stderr, exit code), and all four parameters are documented in the schema. Minor gaps remain, such as whether any filesystem state persists between calls or concurrency limits, but nothing critical for correct invocation is missing.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds real meaning: runtime versions and bundled libraries for language, and cost-per-tier for timeout_s that the schema's '1-60, default 10' does not convey. stdin is not elaborated on, so it is not a full 5.

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?

Names a concrete verb (Run) and resource (Python 3.13/JavaScript Node 24/bash in a fresh isolated container) with unusual specificity about runtimes and libraries, so an agent knows exactly what executes. It does not explicitly differentiate itself from near-neighbors like data_run, calc, or devtools, which keeps it short of a 5.

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

Usage Guidelines4/5

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

States the intended use cases ('calculations, data wrangling, parsing and testing snippets'), giving clear context for when this tool fits. There are no explicit exclusions or pointers to sibling alternatives for adjacent tasks (e.g., simple math via calc), so it stops short of a 5.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources