Skip to main content
Glama
francisco-perez-sorrosal

wasmer-sandbox-mcp

run_python

Execute Python code inside an isolated sandbox and get back stdout, stderr, and exit code. Use it to run untrusted snippets or experiments without affecting the host machine.

Instructions

Run Python code inside an isolated Wasmer sandbox and get back its output.

Use it to execute code you do not want touching this machine: untrusted snippets, experiments, quick calculations, anything with side effects you would rather contain. code is passed to python -c, so print what you want to see. Set network=true only when the code must reach the internet — that routes to a second sandbox with the host's network and its own separate state. Returns exit_code, stdout, stderr, reason and duration_ms; a non-zero exit_code is a normal result, not an error.

The sandbox is long-lived: files written and packages installed by earlier calls are still there, and anything this code writes stays for the next one. Call reset_sandbox when you want a clean slate.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes
stdinNo
networkNo
timeout_sNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and does it thoroughly. It discloses the long-lived sandbox, persistence of files and packages, the separate network sandbox state, the return schema, and the important fact that a non-zero exit_code is a normal result rather than an error.

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 organized into focused paragraphs: purpose, usage context, network behavior, output semantics, and persistence. Every sentence adds operational value and the most important scoping statement is front-loaded. Despite its length, no content is redundant.

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?

The description is highly complete for a stateful sandbox tool: it explains execution, safety, network mode, return values, persistence, and reset path. The main gap is the absence of any guidance on stdin and timeout_s behavior, which are the two underspecified parameters in an otherwise excellent descrption.

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 0%, so the description must compensate. It adds real meaning for code (passed to python -c) and network (routes to a separate sandbox with host network), but it does not explain stdin or timeout_s. Those parameters are still largely inferable from their names, defaults, and types, but the description could have been even clearer.

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?

The description clearly states the verb (execute), resource (Python code in an isolated Wasmer sandbox) and outcome (get back its output). It also differentiates from siblings by naming Python-specific execution and describing safety isolation, so an agent can distinguish it from run_command or sandbox file operations.

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?

It explicitly says when to use the tool: for untrusted snippets, experiments, quick calculations, and anything with side effects you want contained. It gives conditional guidance for network=true and mentions reset_sandbox for a clean slate, but it does not explicitly contrast with siblings like run_command or list_sandbox_dir, so no exclusions are stated.

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

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/francisco-perez-sorrosal/wasmer-sandbox-mcp'

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