Skip to main content
Glama

runtime_sandboxes_interpreter_contexts

Destructive

List, create, restart, interrupt or remove a sandbox's interpreter contexts, each an isolated interpreter with its own variables. restart clears a context's variables; interrupt stops the running cell and keeps them.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
envNoEnvironment variables for the context's process.
actionYes
contextNoA context's id; each language's name is its default context, started on first use.
languageNopython by default. R, Java and Go are installed on first use (tens of seconds, once) when the image lacks them.
idempotencyKeyNoOptional: left out, one is made and returned as idempotencyKey. Send it back only to retry this exact call after a temporary error.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior4/5

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

Annotations declare destructiveHint=true and readOnlyHint=false, and the description usefully goes beyond them by specifying exactly what restart destroys (variables) versus interrupt (keeps them). This is real behavioral context beyond the safety flags, though it doesn't cover permissions or the isolation model in more depth.

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?

Two sentences, dense and front-loaded: the operation list leads, followed by the resource definition, then the restart/interrupt clarifications. No filler.

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?

For a six-parameter destructive multi-action tool with no output schema, the description conveys the key lifecycle semantics an agent needs before invoking it. It omits return-value expectations and per-action parameter requirements, but the absence of an output schema and the strong action semantics keep it largely complete.

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?

The description adds meaning for the 'action' parameter's variants, explaining restarts/interrupts in terms of variable lifecycle, which the enum alone does not convey. Schema coverage is 67% and parameters like env, context, and idempotencyKey are documented in-schema, so the description mostly complements rather than compensates.

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 names a specific resource ('a sandbox's interpreter contexts') and enumerates the exact operations (list, create, restart, interrupt, remove), matching the action enum. It also distinguishes the resource from siblings like runtime_sandboxes_interpreter_run by defining a context as 'an isolated interpreter with its own variables.'

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 two semantic clauses tell the agent what restart and interrupt do, which implicitly guides action choice, but there is no explicit when-to-use guidance versus siblings such as interpreter_run, nor does it state which action requires which parameter (e.g., create needing language/context).

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.