Use AgentsKit from Codex, Claude Code, and Cursor
Expose one safe AgentsKit MCP server to the coding agent you already use, with verified configuration for each host.
You should not need a separate interface to use an AgentsKit tool or agent while
coding. @agentskit/mcp exposes the same server over STDIO to Codex, Claude Code,
Cursor, and other MCP hosts. The host configuration changes; the AgentsKit
command does not.
The verified default exposes fetch and search. It does not enable shell,
filesystem, SQLite, or a model provider, and it needs no credential to start.
#Codex
Add the server with the CLI:
codex mcp add agentskit -- npx -y @agentskit/mcp@0.3.3 --tools fetch,search
codex mcp listOr commit a project-scoped .codex/config.toml in a trusted project:
[mcp_servers.agentskit]
command = "npx"
args = ["-y", "@agentskit/mcp@0.3.3", "--tools", "fetch,search"]
default_tools_approval_mode = "prompt"Codex CLI, the IDE extension, and the desktop app share this configuration.
Use /mcp to inspect the connected server.
#Claude Code
Create a project-scoped server:
claude mcp add --scope project --transport stdio agentskit -- npx -y @agentskit/mcp@0.3.3 --tools fetch,search
claude mcp listThe equivalent .mcp.json is:
{
"mcpServers": {
"agentskit": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@agentskit/mcp@0.3.3", "--tools", "fetch,search"]
}
}
}Claude Code asks for approval before using a project-scoped server. Review the
command, approve it, and use /mcp to check its status.
#Cursor
Create .cursor/mcp.json:
{
"mcpServers": {
"agentskit": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@agentskit/mcp@0.3.3", "--tools", "fetch,search"]
}
}
}Restart or reload Cursor, then inspect the MCP settings to confirm that the server and its tools are available.
#Expose a complete Registry agent
The same bridge can publish a bounded Registry agent as one MCP tool. Extend the server arguments rather than changing host-specific code:
OPENROUTER_API_KEY=your-key \
npx -y @agentskit/mcp@0.3.3 \
--tools fetch,search \
--agents code-review \
--provider openrouter \
--model openrouter/free \
--max-steps 8Keep provider credentials in environment variables. Do not put --api-key in a
committed MCP configuration because command arguments can be visible to other
local processes.
#Verify the path
The repository proof first launches the built CLI over real child-process STDIO
and verifies that --tools fetch,search exposes fetch_url and web_search.
The package test also initializes an in-memory client, lists a bounded echo tool,
calls it, and closes both ends:
pnpm --filter @agentskit/mcp... build
node packages/mcp/fixtures/run-coding-agent-hosts.mjs
pnpm --filter @agentskit/mcp exec vitest run tests/coding-agent-hosts.test.tsBoth proofs are offline and credential-free. Their sources are under
packages/mcp/fixtures/.
#Security boundary
--allow-shellis absent, so shell execution stays disabled.- Filesystem access is absent until you pass both
filesystemand--fs-root. - Provider calls are absent until you select an agent, provider, model, and key.
- Host approval remains enabled; the recipe does not bypass Codex or Claude trust prompts.
#Sources
- Codex MCP configuration
- Claude Code MCP configuration
- Cursor MCP configuration
- MCP architecture
- AgentsKit MCP package
#See also
Explore nearby
- PeerRecipes
Copy-paste solutions grouped by theme. Every recipe end-to-end, runs as written.
- PeerCustom adapter
Wrap any LLM API as an AgentsKit adapter. Plug-and-play with the rest of the kit in 30 lines.
- PeerAdapter contract tests
Verify any adapter against the ADR 0001 invariants A1βA10 with the shared test harness.