OpenAI Codex Setup
Omnodex traces OpenAI Codex in the Codex mode of ChatGPT Desktop, the Codex CLI, and the Codex IDE extension.
What gets installed
Section titled “What gets installed”There are two independent parts. You can use either one, and the full setup uses both.
| Part | What it does | How you install it |
|---|---|---|
| Hooks | Record Codex session lifecycle and the tool calls Codex runs locally, such as shell commands and file edits | omnodex install codex in each project |
| Omnodex plugin | Registers the Omnodex MCP server, routes the upstream MCP servers you choose, and adds the omnodex_status, omnodex_connect, and omnodex_connection_status tools | Install once per host from a local marketplace |
omnodex install codex installs hooks only. The plugin installs the MCP connection; it does not install hooks or the Omnodex runtime. You can also register the MCP server manually if you prefer.
For the full setup: install the runtime, install the plugin, install hooks in your project, then optionally connect to the hosted dashboard. Plugin downloads are public, including for Free users.
Choose where Codex runs
Section titled “Choose where Codex runs”Codex reads its configuration from the Codex home on the host where it runs. Desktop, CLI, and IDE share configuration only when they run on the same host.
| Where Codex runs | Codex config | Omnodex home | Path style |
|---|---|---|---|
| Native Windows (ChatGPT Desktop, or the CLI in PowerShell) | C:\Users\<you>\.codex\config.toml | C:\Users\<you>\.omnodex\ | Backslashes |
| WSL | /home/<you>/.codex/config.toml | /home/<you>/.omnodex/ | Forward slashes |
| macOS | /Users/<you>/.codex/config.toml | /Users/<you>/.omnodex/ | Forward slashes |
| Linux | /home/<you>/.codex/config.toml | /home/<you>/.omnodex/ | Forward slashes |
ChatGPT Desktop on Windows runs Codex natively; WSL is not required. If you also run the Codex CLI inside WSL, that is a second host with its own configuration and its own Omnodex data. Set up each host you use. Windows and WSL covers running both.
An npm install in WSL does not cover native Windows Codex. Install with npm in PowerShell as well if you use ChatGPT Desktop or the CLI on Windows. Run updates on both hosts, using each host’s shell and Node.js installation.
Never mix path styles: do not put C:\... paths in WSL configuration, or /mnt/c/... or ~ in configuration used by native Windows.
Before you start
Section titled “Before you start”On the host where Codex runs:
- Install Omnodex on this host: from npm, or from source including the
omnodex-config.jsonstep for hooks. - Confirm Node.js 24+ is available. The plugin starts with
node; if your desktop app cannot find it, use the absolute path printed below in the unpacked plugin’s.mcp.jsoncommandfield before installing it.
where.exe nodenode --versionwhich nodenode --versionOn macOS, Homebrew installs Node under /opt/homebrew/bin on Apple Silicon and /usr/local/bin on Intel. Use the path which node prints.
Install the Omnodex plugin
Section titled “Install the Omnodex plugin”The plugin’s Node.js launcher works on native Windows, macOS, and Linux. A personal marketplace makes the downloaded plugin available in the app’s Plugins directory. You do not need to add a separate MCP server entry.
The app steps below apply to the host running ChatGPT Desktop. For a CLI-only host without the desktop plugin browser, such as WSL, use the manual MCP alternative on that host. Installing the plugin in the Windows app does not install it inside WSL.
-
Configure the proxy.
Create
omnodex-proxy.jsonin your Omnodex home. Its location isC:\Users\<you>\.omnodex\on native Windows or~/.omnodex/on macOS, Linux, and WSL.The plugin finds the npm install on its own:
{"version": 1,"redact_parameters": false,"upstream_servers": []}Add
proxy_binto point the plugin at your build’s proxy:C:\Users\<you>\.omnodex\omnodex-proxy.json:{"version": 1,"redact_parameters": false,"proxy_bin": "C:\\path\\to\\omnodex\\packages\\mcp-proxy\\dist\\bin\\omnodex-mcp-proxy.js","upstream_servers": []}~/.omnodex/omnodex-proxy.json:{"version": 1,"redact_parameters": false,"proxy_bin": "/path/to/omnodex/packages/mcp-proxy/dist/bin/omnodex-mcp-proxy.js","upstream_servers": []}An empty
upstream_serverslist is enough to use Omnodex’s status and dashboard connection tools. To record other MCP servers at the proxy layer, add them using the proxy configuration reference. Keep any existing upstream entries when addingproxy_bin. -
Download and unpack the plugin.
Download
omnodex-codex.zipand extract its contents into~/.codex/plugins/omnodex-codex/(C:\Users\<you>\.codex\plugins\omnodex-codex\on Windows).The archive contains files at its root:
.codex-plugin/plugin.json,.mcp.json, andbin/launch-proxy.jsshould be directly inside that folder, without an extra nested folder. If your archive tool hides files beginning with a dot, make sure it still extracts them. -
Add it to a personal marketplace.
Create
~/.agents/plugins/marketplace.json(C:\Users\<you>\.agents\plugins\marketplace.jsonon Windows), creating the parent folders if needed:{"name": "omnodex-local","interface": { "displayName": "Omnodex local" },"plugins": [{"name": "omnodex-codex","source": { "source": "local", "path": "./.codex/plugins/omnodex-codex" },"policy": { "installation": "AVAILABLE", "authentication": "ON_INSTALL" },"category": "Productivity"}]}The
source.pathis relative to your home directory, the personal marketplace root, rather than to.agents/plugins/. The forward slashes in this relative path work on Windows too.If you already have a personal marketplace, keep its name and other plugins, and append only the
omnodex-codexentry to itspluginsarray. You can keep an existing marketplace name such aslocal-testing; it does not need to be namedomnodex-local. -
Install in the app.
Fully quit and reopen ChatGPT Desktop. Open Plugins, select your personal marketplace (Omnodex local in the example), open Omnodex, and install it. Confirm it is enabled, then start a new Codex conversation.
Ask Codex to call
omnodex_status. In the CLI,/mcpalso shows the server connection. A plugin installed and enabled on this host can be used by local Codex CLI and IDE sessions using the same Codex home.
This is the local marketplace workflow described in OpenAI’s plugin documentation. It does not require Omnodex to be listed in OpenAI’s public directory or a login to download the archive.
Alternative: register the Omnodex MCP server manually
This is an alternative to plugin installation. Skip this section if you installed the plugin. You can use the same proxy configuration from above; proxy_bin is used by the plugin launcher, while a manual entry names the proxy script directly.
The entry runs the proxy script with Node.js, including on Windows, where node cannot run npm’s .cmd wrapper. The script is:
<global node_modules>/omnodex/bin/omnodex-mcp-proxy.js, where npm root -g prints the global node_modules folder. Run it on the same host as Codex. On Windows it is usually C:\Users\<you>\AppData\Roaming\npm\node_modules\omnodex\bin\omnodex-mcp-proxy.js.
<repo>/packages/mcp-proxy/dist/bin/omnodex-mcp-proxy.js in your clone.
-
Create the proxy configuration.
List the upstream MCP servers to route in
omnodex-proxy.jsonin your Omnodex home. The file may list none, in which case the proxy serves only its built-inomnodex_*tools:C:\Users\<you>\.omnodex\omnodex-proxy.json:{"version": 1,"redact_parameters": false,"upstream_servers": [{"name": "filesystem","transport": "stdio","command": "C:\\Program Files\\nodejs\\npx.cmd","args": ["-y", "@modelcontextprotocol/server-filesystem", "C:\\Users\\<you>\\Documents\\project"]}]}Use the
npx.cmdpath thatwhere.exe npxprints.~/.omnodex/omnodex-proxy.json:{"version": 1,"redact_parameters": false,"upstream_servers": [{"name": "filesystem","transport": "stdio","command": "npx","args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/<you>/project"]}]}Replace the example with the MCP servers you want Omnodex to see. Put secrets in environment variables and reference them as
${VAR}in an upstream’senv, never as literal values. See Configuration. -
Add the server in ChatGPT Desktop.
Open Settings > MCP servers > Add server, choose STDIO, and enter:
Field Value Name omnodexCommand Absolute path to Node.js Arguments The proxy script above, --config, and the path to youromnodex-proxy.jsonUse absolute paths in the path style of the host. Save, then restart Codex.
-
Or add it from the CLI or a config file.
codex mcp addwrites the same entry to the host’sconfig.toml, so the Desktop app, CLI, and IDE extension on that host all see it.These fill in the Node.js and proxy paths for you:
Terminal window codex mcp add omnodex -- (Get-Command node).Source "$(npm root -g)\omnodex\bin\omnodex-mcp-proxy.js" --config "$env:USERPROFILE\.omnodex\omnodex-proxy.json"codex mcp listTerminal window codex mcp add omnodex -- "$(command -v node)" "$(npm root -g)/omnodex/bin/omnodex-mcp-proxy.js" --config "$HOME/.omnodex/omnodex-proxy.json"codex mcp listTerminal window codex mcp add omnodex -- "C:\Program Files\nodejs\node.exe" "C:\path\to\omnodex\packages\mcp-proxy\dist\bin\omnodex-mcp-proxy.js" --config "C:\Users\<you>\.omnodex\omnodex-proxy.json"codex mcp listTerminal window codex mcp add omnodex -- /absolute/path/to/node /path/to/omnodex/packages/mcp-proxy/dist/bin/omnodex-mcp-proxy.js --config /home/<you>/.omnodex/omnodex-proxy.jsoncodex mcp listThe same entry in
config.toml, with the proxy script from above. On Windows, TOML literal strings (single quotes) keep backslashes as they are:[mcp_servers.omnodex]command = 'C:\Program Files\nodejs\node.exe'args = ['C:\path\to\omnodex-mcp-proxy.js','--config','C:\Users\<you>\.omnodex\omnodex-proxy.json',][mcp_servers.omnodex]command = "/absolute/path/to/node"args = ["/path/to/omnodex-mcp-proxy.js","--config","/home/<you>/.omnodex/omnodex-proxy.json",]To remove it:
codex mcp remove omnodex. -
Verify.
Start a new conversation, enter
/mcp, and confirmomnodexis connected. Ask Codex to callomnodex_status, then to call one of the routed tools. Routed tools appear as<server>__<tool>, for examplefilesystem__list_allowed_directories.Start a new conversation after changing MCP servers. Existing conversations keep the tool list they started with.
Install the hooks
Section titled “Install the hooks”-
Install into the project.
From the project directory, in the shell of the host where Codex runs:
Terminal window omnodex install codexThis writes Omnodex entries to
<project>/.codex/hooks.json. Hooks are enabled by default in Codex; there is no feature flag to set. If hooks do not run at all, check that yourconfig.tomldoes not containhooks = falseunder[features].When it finishes, the command offers to connect this host to the hosted dashboard. Press Ctrl+C to skip; the hooks are already installed.
-
Trust the hooks in Codex.
Codex does not run new project hooks until you trust them. When Codex prompts you to review the hooks for the project, approve the Omnodex entries.
Codex may report that it clamps the
SessionEndhook timeout to 3 seconds. That is expected; the hook finishes well within it. -
Verify.
Start a new conversation in the project and have Codex run a shell command. A session file for it appears under
event-log/sessions/in your Omnodex home.
What gets traced
Section titled “What gets traced”| Activity | Recorded by | Notes |
|---|---|---|
| Session start and end | Hooks | |
| Thread names | Hooks | session.renamed when Codex names the thread or you rename it, read from Codex’s session index |
| Shell commands | Hooks | tool.invoked and tool.completed with timing and status |
File edits (apply_patch) | Hooks | Recorded as tool calls, not yet as file.written events |
| MCP tool calls routed through Omnodex | Omnodex MCP server | Parameters (unless redacted), timing, status, and response size |
| MCP server sessions | Omnodex MCP server | See the note below about session end |
| Hosted tools such as web search | Not visible | These run on OpenAI’s side, outside local hooks |
Hooks and the MCP server record different layers. A call routed through Omnodex can appear once from each. Use redact_parameters in omnodex-proxy.json to keep parameter values out of the log for any upstream.
When ChatGPT Desktop quits, it may stop the Omnodex MCP server without closing its connection, so the proxy session can be missing its end event. Tool call records are not affected.
Connect to the hosted dashboard
Section titled “Connect to the hosted dashboard”On each host, run:
omnodex connectThis starts a device code flow: the CLI shows a short code and a URL. Open the URL, sign in or create an account, and enter the code. The API token and sync passphrase are stored in stream-config.json in that host’s Omnodex home. The passphrase is transferred end-to-end encrypted.
You can also connect from inside Codex by asking it to call omnodex_connect from the Omnodex MCP server.
If a stream is disconnected or revoked in the dashboard, run omnodex connect again.
View results
Section titled “View results”omnodex dashboardCodex events carry interceptor: "codex-hook" (hooks) or interceptor: "mcp-proxy" (MCP server), so you can tell the sources apart in the dashboard.
Updating
Section titled “Updating”-
Update your Omnodex runtime on each host where Codex runs: PowerShell for ChatGPT Desktop and the CLI on native Windows, a WSL terminal for the CLI in WSL.
Run
omnodex update. The plugin launcher and hook launchers use the installed package; no build is needed.Run
omnodex updatefrom your clone to pull and rebuild. If your build stays in the same location,proxy_binand hook handler paths do not need to change.See Updating. Neither method downloads a new plugin archive.
-
Update the plugin only when its package changes.
Compare
.codex-plugin/plugin.jsonin your plugin folder with the Codex version in the release manifest. A runtime update alone does not require a plugin reinstall.For a new plugin release, uninstall Omnodex from your personal marketplace in the app, replace the contents of
~/.codex/plugins/omnodex-codex/with the latest ZIP, then restart the app and install it again from the same marketplace. Keep your marketplace entry and proxy configuration.Codex can load an installed copy from its plugin cache, so replacing the source folder alone may leave the old installed files in use. Reinstalling refreshes that copy. If you use manual MCP registration, skip this step.
-
Restart Codex. Fully quit and reopen ChatGPT Desktop, or start a new CLI session. Then start a new conversation: existing conversations keep the tool list they started with.
-
Verify. Ask Codex to call
omnodex_statusandomnodex_connection_status. Run a shell command in a project with hooks installed, then check the local dashboard, or the hosted dashboard if connected. In the CLI,/mcpalso confirms the server connection.
For a marketplace tracked through codex plugin marketplace add, codex plugin marketplace upgrade <marketplace-name> refreshes that marketplace source. It does not download Omnodex’s public ZIP into a manually maintained local plugin folder. Use the steps above for the personal marketplace setup on this page.
Troubleshooting
Section titled “Troubleshooting”omnodex does not show as connected in /mcp:
- Run the command from the server entry yourself in the host’s shell. It should start and wait for input; press Ctrl+C to stop it. If it exits with a config error, fix
omnodex-proxy.json. - Check that every path in the entry is absolute and uses the host’s path style.
- Restart Codex after any change to MCP servers.
No hook events:
- Run
omnodex statusin the project to confirm the hooks are installed. - Confirm you trusted the hooks in Codex for this project.
- Check
launcher.login your Omnodex home.Could not locate codex hook shimmeans the launcher could not find Omnodex: for a source install,omnodex-config.jsonis missing or has the wrongcodexpath; for an npm install,omnodexis not on thePATHCodex runs hooks with. - The conversation must be in the project where you installed the hooks.
ChatGPT on the web: web sessions, including Codex on the web, do not use the Codex configuration on your machine, so local hooks and the Omnodex MCP server do not see them.
Plugin missing from the directory: check that marketplace.json is valid JSON and that its source.path points to the unpacked plugin folder. Fully restart the app after creating the marketplace.
Plugin installed but the server does not start: the current plugin uses a Node.js launcher on Windows and Unix. Check that Node.js 24+ is available to the app. For source installs, check proxy_bin; for npm installs, confirm the package includes omnodex-mcp-proxy and was installed on the same host as Codex. If the desktop app cannot locate your npm prefix, set proxy_bin to the full JavaScript path from the manual setup above. Fatal launcher errors are written to launcher-codex.log in your Omnodex home. If your old plugin references launch-proxy.sh, replace it with the latest download.
Next steps
Section titled “Next steps”- Plugins - Public downloads for every supported surface
- Windows and WSL - Running Codex and other agents on both
- Running Detection - Risk detection works the same across all interceptors
- Events and Traces - The event model