Skip to main content
Glama
ossmalaysia

codex-local-mcp

by ossmalaysia

Run a task with the local Codex CLI

codex_run

Delegate a coding task to a local CLI agent that writes and runs code, installs packages, and calls APIs in an isolated workspace, then returns the output and any created files.

Instructions

Hand a natural-language task to the local Codex CLI coding agent. Codex can write and run code, install packages and call APIs inside an isolated workspace folder, then this returns its output plus any files it created. Blocking: it does not return until Codex finishes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelNoOverride the Codex model for this run.
promptYesThe task for Codex, written as you would to a developer.
workspaceNoRelative workspace folder name under the workspace root. Reuse the same name to continue working on the same files. Defaults to a new timestamped folder.
timeout_secNoSeconds before Codex is killed. Default 300.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It does this well by stating execution capabilities, workspace isolation, return contents, and blocking behavior ('it does not return until Codex finishes'). It does not mention potential error conditions or broader side effects, but it covers the most important operational consequences for an agent deciding to call the tool.

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 three sentences, front-loads the core purpose, and includes only essential behavioral details. Every sentence contributes: purpose, capability/return, and blocking behavior. There is no redundant wording or 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?

Given no output schema, the description appropriately explains return values ('returns its output plus any files it created') and the blocking nature of the call. It omits error-handling details or security caveats, but for a task-execution tool the core needs are covered. Sibling differentiation is implicitly handled through capability emphasis.

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 description coverage is 100%, and all four parameters have clear descriptions in the schema itself. The description adds context about the isolated workspace and the blocking execution model, which indirectly relates to the workspace and timeout parameters, but it does not add new parameter-specific meaning beyond the schema. This matches the baseline 3 for high schema coverage.

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 identifies a specific verb and resource: 'Hand a natural-language task to the local Codex CLI coding agent.' It further distinguishes the tool from siblings by enumerating capabilities (write/run code, install packages, call APIs) and stating it returns output plus created files. This makes the tool's identity unambiguous relative to codex_read_artifact and codex_generate_image.

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?

The description gives clear context for when to use the tool: when you need a coding agent to execute a natural-language task in an isolated workspace. It does not explicitly name alternatives or state when not to use it, so it falls short of a 5. The implied usage context is strong enough to guide an agent without being misleading.

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