Skip to content
Documentation

Reference

ctx_execute

Input contract and parameters for ctx_execute.

Status by featureReviewed September 2026

MCP tool · Planning tools

Call this tool through your MCP client. Its availability depends on your active configuration and profile.

This registry contract is separate from the SDK. For terminal commands, use the CLI reference.

Parameters

Generated from the registered input schema. “Required” reflects the schema; individual actions can impose additional requirements.

actionstring

code (default, run script) | batch (parallel) | file (project file)

codestring

Source code for action=code. Set intent to filter large output.

intentstring

Focus intent; triggers filtering when output is large.

itemsstring

JSON array of [{language, code}] for batch action.

languagestring

javascript|typescript|python|shell|ruby|go|rust|php|perl|r|elixir (for action=code)

pathstring

File path for action=file (language auto-detected).

timeoutinteger

Timeout in seconds (default: 30)

Exact JSON schema

Inspect the complete input schema
{
  "properties": {
    "action": {
      "description": "code (default, run script) | batch (parallel) | file (project file)",
      "type": "string"
    },
    "code": {
      "description": "Source code for action=code. Set intent to filter large output.",
      "type": "string"
    },
    "intent": {
      "description": "Focus intent; triggers filtering when output is large.",
      "type": "string"
    },
    "items": {
      "description": "JSON array of [{language, code}] for batch action.",
      "type": "string"
    },
    "language": {
      "description": "javascript|typescript|python|shell|ruby|go|rust|php|perl|r|elixir (for action=code)",
      "type": "string"
    },
    "path": {
      "description": "File path for action=file (language auto-detected).",
      "type": "string"
    },
    "timeout": {
      "description": "Timeout in seconds (default: 30)",
      "type": "integer"
    }
  },
  "required": [],
  "type": "object"
}

Runtime description

The following is the tool's own agent-facing description, reproduced from the reviewed registry. It can contain implementation terminology; it does not expand the public stability commitment.

Read the agent-facing description
Run code in sandbox (11 languages) — use when conditionals, multi-line or cross-language transforms.
ANTIPATTERN: for simple one-liners, prefer ctx_shell (lower overhead, auto-compressed).
language=shell supports multi-line scripts but shares ctx_shell's security policy.
action=code (default) for one-shot; action=batch for parallel multi-language;
action=file to process a project file (extension auto-detects).
Pass intent to focus large output and save tokens. Languages: javascript,
typescript, python, shell, ruby, go, rust, php, perl, r, elixir.
Sources & versions3 references Reviewed
  • mcp_manifest.rsrust/src/core/mcp_manifest.rsReviewed checkout
  • registry.rsrust/src/server/registry.rsReviewed checkout
  • dynamic_tools.rsrust/src/server/dynamic_tools.rsReviewed checkout
Core checkout
50fbff09c9
Installed runtime
3.10.2
SDK release
1.1.0

Separate baselines for source, CLI/configuration and SDK contracts. Review does not certify every platform or integration.

Versions & compatibility