One brain, many arms — spawn multiple specialized Codex agents as MCP servers
接入配置
选择客户端,复制配置,再按项目文档补齐环境变量。
claude mcp add codex-octopus --env CODEX_API_KEY='<CODEX_API_KEY>' -- npx -y codex-octopus~/.codex/config.toml
[mcp_servers.codex-octopus]
command = "npx"
args = ["-y", "codex-octopus"]
env = { CODEX_API_KEY = "<CODEX_API_KEY>" }
# codex mcp add codex-octopus --env CODEX_API_KEY='<CODEX_API_KEY>' -- npx -y codex-octopus~/.cursor/mcp.json
{
"mcpServers": {
"codex-octopus": {
"command": "npx",
"args": [
"-y",
"codex-octopus"
],
"env": {
"CODEX_API_KEY": "<CODEX_API_KEY>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"codex-octopus": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"codex-octopus"
],
"env": {
"CODEX_API_KEY": "<CODEX_API_KEY>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"codex-octopus": {
"command": "npx",
"args": [
"-y",
"codex-octopus"
],
"env": {
"CODEX_API_KEY": "<CODEX_API_KEY>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"codex-octopus": {
"command": "npx",
"args": [
"-y",
"codex-octopus"
],
"env": {
"CODEX_API_KEY": "<CODEX_API_KEY>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"codex-octopus": {
"command": "npx",
"args": [
"-y",
"codex-octopus"
],
"env": {
"CODEX_API_KEY": "<CODEX_API_KEY>"
}
}
}
}需要的环境变量
CODEX_API_KEY
把占位值换成你自己的密钥;不要把密钥提交到代码仓库。