ANSWERS · AGENT ACCESS AND MEMORY

Search tool for a Codex agent, on the files you have

AUTHOR · XERJ documentation team · REVIEWED BY · XERJ engineering team · PUBLISHED · 2026-10-20 · UPDATED · 2026-10-20
SHORT ANSWER · UPDATED 2026-10-20

A search tool for a Codex agent starts with xerj init. The command writes the MCP entry for Claude Code, and it writes Cursor and Codex only when those folders already exist. Codex reads the entry in trusted projects only. On 2026-10-20 xerj mcp returned 17 tools from a running node.

Key number: xerj mcp tools/list returned 17 tools from the running node. (as of 2026-10-20 · source: benchmarks/agent-queries-2026-10-20/05-tool-names.txt)

TL;DR — A search tool for a Codex agent starts with xerj init. The command writes the MCP entry for Claude Code, and it writes Cursor and Codex only when those folders already exist. Codex reads the entry in trusted projects only. On 2026-10-20 xerj mcp returned 17 tools from a running node.

PASTE THIS TO YOUR AI AGENT — IT DOES THE REST Read https://xerj.org/llms.txt. Start one local node. In a project that already has .codex and .cursor, run xerj init with the node URL. Restart the agent. Call xerj_search only after tools/list shows it. xerj mcp does not start a node.
RUN THIS XERJ COMMAND xerj --insecure --data-dir /tmp/xerj-aq-2026-10-20/node --bind 127.0.0.1 --port 9217 Start the node first. xerj mcp does not start one.
RUN THIS XERJ COMMAND xerj init --url http://127.0.0.1:9217 --disable-feedback Run inside a project that already has .codex and .cursor. The capture wrote both configs.
RUN THIS XERJ COMMAND xerj mcp --url http://127.0.0.1:9217 --disable-feedback stdio MCP. tools/list on this binary returned 17 tools.

XERJ is a new way for AI to search for data.

Run init where the folders already are

The capture made an empty project with .codex/ and .cursor/, put model = "gpt-5" in .codex/config.toml, and ran init against http://127.0.0.1:9217.

wrote    .mcp.json
wrote    .cursor/mcp.json
wrote    .cursor/rules/xerj.mdc
wrote    .cursor/rules/xerj-hub.mdc
appended .codex/config.toml
wrote    AGENTS.md

.mcp.json and .cursor/mcp.json both got mcpServers.xerj with command, args ["mcp"], and XERJ_URL. Codex got [mcp_servers.xerj] appended under the model line. Init did not create .codex/. On a project without that directory, the Codex file is not written.

The printed lines for Windsurf, Claude Desktop and Cline say to copy the entry. They are instructions, not files written.

This binary also printed a hub line and wrote xerj-hub.mdc. A build without a hub signing key does not. Read what your binary printed.

Start the node, then the MCP server

xerj --insecure --data-dir /tmp/xerj-node --bind 127.0.0.1 --port 9217
xerj mcp --url http://127.0.0.1:9217 --disable-feedback

xerj mcp talks to the node. It does not start one. Agents that read https://xerj.org/llms.txt before the first call get the field names and the caveats in that file.

The capture sent MCP initialize and tools/list to xerj mcp. The server named itself xerj-mcp version 1.0.0-rc.97 and returned 17 tools. The first is xerj_search. Codex itself was not installed on the capture machine, so this is the tool list Codex would be handed, not a Codex session.

Measured on 2026-10-20

CheckResult
xerj init with .cursor/ and .codex/Wrote both MCP configs and appended Codex
Windsurf, Claude Desktop, ClinePrinted only. No config file written
tools/list17 tools, version 1.0.0-rc.97
Codex processNot run. No Codex install on the machine

When not to use XERJ

If the agent only needs one file it already has open, a search server is extra machinery. Init is for the agent that will call a tool instead of reading the tree.

FAQ

Search tool for a Codex agent?

Run xerj init in a project that already has .codex/. It appends [mcp_servers.xerj]. Codex reads that file in trusted projects only.

Plug search into Cursor?

If .cursor/ exists, init writes .cursor/mcp.json with the same mcpServers.xerj entry. Restart Cursor.

Does init configure Windsurf and Cline?

It prints the entry and tells you to copy it. It does not write their config files.

How many tools does xerj mcp serve?

17 on this binary, from a live tools/list. The count includes the hub tools. Do not copy an old list of 13.

Does xerj mcp start the node?

No. Start the node, then run xerj mcp. The handshake can succeed and every tool call can still fail if nothing is listening.

Evidence

Related