Codex As Mcp MCP Server

codex-as-mcp is a small Model Context Protocol (MCP) server that lets MCP clients (Claude Code, Cursor, etc.) delegate work to the Codex CLI.

Local serverstdio

What is the Codex As Mcp Server?

Codex As Mcp is an MCP project maintained in the kky42/codex-as-mcp repository. The maintainer describes its purpose as “codex-as-mcp is a small Model Context Protocol (MCP) server that lets MCP clients (Claude Code, Cursor, etc.) delegate work to the Codex CLI”. Read the project documentation for the complete scope.

Local setup

The project provides a local client configuration using uvx. Follow the repository’s build and installation steps before copying it, and replace example paths with the paths on your own computer.

Configuration values

The example declares PROVIDER_API_KEY. Secret-looking values have been replaced with placeholders. Required and optional labels are shown only when the documentation states them.

Source

Project documentation · Repository · Discovery listing. This profile records the public documentation checked on 2026-10-08.

Recorded tools

Check the linked publisher documentation and your connected client's tool list. Names and availability can vary with the server version and account permissions.

ToolWhat it does
spawn_agentprompt: str) – Spawns an autonomous Codex subagent using the server's working directory and returns the agent's final message.
spawn_agents_parallelagents: list[dict]) – Spawns multiple Codex subagents in parallel; each item must include a prompt key and results include either an output or an error per…

How to install the Codex As Mcp Server

{
  "mcpServers": {
    "codex-subagent": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "codex-as-mcp@latest"
      ],
      "env": {
        "PROVIDER_API_KEY": "YOUR_PROVIDER_API_KEY"
      }
    }
  }
}

From the project documentation. Replace placeholders and example paths before connecting.

Configuration

VariableDescriptionRequired
PROVIDER_API_KEYDeclared in the maintainer’s client configuration.Check documentation