Google Antigravity Setup
Omnodex traces Google Antigravity in the Desktop App, the agy CLI, and the standalone Antigravity IDE.
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 session start and end, and every tool call the agent makes | omnodex install antigravity in each project |
| Omnodex MCP server | Routes the MCP servers you choose through the Omnodex proxy, records each call at the MCP protocol layer, and adds the omnodex_status, omnodex_connect, and omnodex_connection_status tools | An omnodex entry in Antigravity’s mcp_config.json |
Only MCP servers listed in the Omnodex proxy configuration are recorded by the MCP server. Servers you leave in Antigravity’s own mcp_config.json keep working, but Omnodex sees their calls only through hooks.
Choose where Antigravity runs
Section titled “Choose where Antigravity runs”The Antigravity surfaces read their MCP configuration from different files. A project’s .agents/ folder is shared by all of them.
| File | Desktop App and IDE | agy CLI |
|---|---|---|
| MCP servers, all projects | ~/.gemini/config/mcp_config.json | ~/.gemini/antigravity-cli/mcp_config.json |
| MCP servers, one project | <project>/.agents/mcp_config.json | <project>/.agents/mcp_config.json |
| Hooks, one project | <project>/.agents/hooks.json | <project>/.agents/hooks.json |
| Hooks, all projects | ~/.gemini/config/hooks.json | ~/.gemini/config/hooks.json |
On macOS and Linux every surface shares one home directory, so one setup covers all of them.
On Windows, the Desktop App is a native Windows program and uses C:\Users\<you>\.gemini\ and C:\Users\<you>\.omnodex\. The agy CLI inside WSL is a separate host with its own /home/<you>/.gemini/ and /home/<you>/.omnodex/. Set up each host you use, with that host’s path style, and never put C:\... paths in WSL configuration or /mnt/c/... paths in Windows configuration. Windows and WSL covers running both.
Before you start
Section titled “Before you start”On the host where Antigravity runs:
- Install Omnodex from source, including the
omnodex-config.jsonstep for hooks. - Find the absolute path of Node.js. The Desktop App may not see the same
PATHas your terminal, so the MCP server entry below uses an absolute path.
where.exe nodewhere.exe npxwhich nodewhich npx- Note the full path of the Omnodex proxy in your build:
<repo>/packages/mcp-proxy/dist/bin/omnodex-mcp-proxy.js.
Register the Omnodex MCP server
Section titled “Register the Omnodex MCP server”The steps below use the Desktop App’s global file, ~/.gemini/config/mcp_config.json. For the agy CLI, make the same change in ~/.gemini/antigravity-cli/mcp_config.json. To limit Omnodex to one project, use <project>/.agents/mcp_config.json instead.
-
Create the proxy configuration.
The proxy starts the MCP servers you want Omnodex to see and forwards every call to them. Create
omnodex-proxy.jsonin your Omnodex home: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 npxprinted. Backslashes are doubled in JSON.~/.omnodex/omnodex-proxy.json:{"version": 1,"redact_parameters": false,"upstream_servers": [{"name": "filesystem","transport": "stdio","command": "/usr/local/bin/npx","args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/<you>/project"]}]}Use the
npxpath thatwhich npxprinted.The filesystem server is a good first upstream because its calls are easy to recognize. Replace it with the MCP servers you want Omnodex to see. Only
stdioupstreams are supported. Put secrets in environment variables and reference them as${VAR}in an upstream’senv, never as literal values. See Configuration.Check that the proxy starts before you point Antigravity at it. It waits for input; press Ctrl+C to stop it:
Terminal window node /path/to/omnodex/packages/mcp-proxy/dist/bin/omnodex-mcp-proxy.js --config ~/.omnodex/omnodex-proxy.json -
Look at your current
mcp_config.json.If the file does not exist yet, create it with an empty
{ "mcpServers": {} }. If you already use MCP servers in Antigravity, it looks something like this, with one entry per server undermcpServers:{"mcpServers": {"issue-tracker": {"serverUrl": "https://mcp.example.com/mcp"},"github": {"command": "npx","args": ["-y", "@modelcontextprotocol/server-github"],"env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "..." }}}}Remote servers use
serverUrl. Local servers usecommandandargs. -
Add
omnodexnext to the existing entries.Add an
omnodexkey insidemcpServers. Keep every other entry as it is.C:\Users\<you>\.gemini\config\mcp_config.json:{"mcpServers": {"issue-tracker": {"serverUrl": "https://mcp.example.com/mcp"},"github": {"command": "npx","args": ["-y", "@modelcontextprotocol/server-github"],"env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "..." }},"omnodex": {"command": "C:\\Program Files\\nodejs\\node.exe","args": ["C:\\path\\to\\omnodex\\packages\\mcp-proxy\\dist\\bin\\omnodex-mcp-proxy.js","--config","C:\\Users\\<you>\\.omnodex\\omnodex-proxy.json"]}}}~/.gemini/config/mcp_config.json(or~/.gemini/antigravity-cli/mcp_config.jsonforagy):{"mcpServers": {"issue-tracker": {"serverUrl": "https://mcp.example.com/mcp"},"github": {"command": "npx","args": ["-y", "@modelcontextprotocol/server-github"],"env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "..." }},"omnodex": {"command": "/usr/local/bin/node","args": ["/Users/<you>/src/omnodex/packages/mcp-proxy/dist/bin/omnodex-mcp-proxy.js","--config","/Users/<you>/.omnodex/omnodex-proxy.json"]}}}JSON does not expand
~, so write the full home path.Field Value commandThe absolute Node.js path from Before you start args[0]The absolute path to omnodex-mcp-proxy.jsin your buildargs[1],args[2]--configand the absolute path to youromnodex-proxy.jsonAlways pass
--config. Antigravity does not setOMNODEX_HOMEwhen it starts the server.To have Omnodex record one of the servers you already had, such as
githubabove, move it: add it toupstream_serversinomnodex-proxy.json(with"transport": "stdio"and absolute paths), then delete its entry frommcp_config.json. If a server is in both files, the agent gets two copies of its tools, and only the copy namedgithub__<tool>is recorded by the proxy. -
(Windows Desktop App) Create the tool cache folder.
The Desktop App caches each MCP server’s tool list under
~/.gemini/antigravity/mcp/<server>/. If that folder is missing, the tools can stay disabled in settings:Terminal window New-Item -ItemType Directory -Force -Path "$env:USERPROFILE\.gemini\antigravity\mcp\omnodex" -
Restart Antigravity and approve the server.
Fully quit and reopen the Desktop App, or start a new
agysession. Antigravity asks you to approve a new MCP server the first time it connects. -
Verify.
- Desktop App: open Settings > MCP Servers, confirm
omnodexis connected, and enable its tools. agy: enter/mcpand confirmomnodexis listed without errors.
Ask the agent to call
omnodex_status. It returns the proxy version and your upstream servers. Then ask it to use a routed tool. Routed tools appear as<server>__<tool>, for examplefilesystem__list_allowed_directories. - Desktop App: open Settings > MCP Servers, confirm
Alternative: omnodex install antigravity --mcp
Section titled “Alternative: omnodex install antigravity --mcp”omnodex install antigravity --mcp writes the omnodex entry to <project>/.agents/mcp_config.json for you, merging with any servers already there. The entry it writes runs the launcher from the Omnodex Antigravity plugin, so it has two extra requirements:
- The plugin must be unpacked first, in
~/.gemini/config/plugins/omnodex-antigravity/(Desktop App) or installed withagy plugin install <unzipped folder>(CLI). The command stops with a warning if it cannot find the plugin. omnodex-proxy.jsonmust includeproxy_bin, the absolute path toomnodex-mcp-proxy.js, so the launcher can find your build.
If you do not need the plugin for anything else, the manual entry above has fewer moving parts.
Install the hooks
Section titled “Install the hooks”-
Install into the project.
From the project directory, in the shell of the host where Antigravity runs:
Terminal window omnodex install antigravityRun from PowerShell, not WSL, so the hook commands use Windows paths:
Terminal window node C:\path\to\omnodex\packages\cli\dist\index.js install antigravity "C:\path\to\your\project"This writes an
omnodexentry to<project>/.agents/hooks.jsonfor five events:- PreInvocation and PostInvocation: session start and end
- PreToolUse and PostToolUse: every tool call, with timing and status
- Stop: the agent loop ending
The hooks observe only. They never block a tool call.
When it finishes, the command offers to connect this host to the hosted dashboard. Press Ctrl+C to skip; the hooks are already installed.
-
Verify.
Terminal window omnodex statusThen start a session in the project and have the agent run a command. A session file for it appears under
event-log/sessions/in your Omnodex home.
Trust and approval
Section titled “Trust and approval”Hooks in .agents/hooks.json and ~/.gemini/config/hooks.json load automatically. There is no separate approval step.
Antigravity asks you to approve each MCP server on its first connection and remembers the answer.
The CLI’s --sandbox flag changes which tools the agent can use. It does not affect hooks.
What gets traced
Section titled “What gets traced”| Activity | Recorded by | Notes |
|---|---|---|
| Session start and end | Hooks | session.started and session.ended |
| Built-in tool calls (shell, file reads and edits) | Hooks | tool.invoked and tool.completed with timing and status |
| MCP tool calls routed through Omnodex | Omnodex MCP server and hooks | The proxy records parameters (unless redacted), timing, status, and response size |
MCP servers left in mcp_config.json | Hooks only | The proxy does not see them |
Hooks and the MCP server record different layers, so a routed call can appear once from each. Use redact_parameters in omnodex-proxy.json to keep parameter values out of the proxy’s records.
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.
If you already have an API token from the dashboard:
omnodex connect --token omx_your_token_hereWith the Omnodex MCP server connected, you can also ask the agent to call omnodex_connect, which runs the same flow without the CLI.
If a stream is disconnected or revoked in the dashboard, run omnodex connect again. Your earlier history stays under the original stream.
View results
Section titled “View results”omnodex dashboardAntigravity events carry interceptor: "antigravity-hook" (hooks) or interceptor: "mcp-proxy" (MCP server), so you can tell the sources apart.
Troubleshooting
Section titled “Troubleshooting”omnodex is missing or shows an error in MCP settings or /mcp:
- Run the
commandandargsfrom the entry yourself, in the host’s shell. The proxy should start and wait for input. If it exits, fixomnodex-proxy.json: the proxy starts even when an upstream is down, but a config file it cannot parse is still an error. - Check that the JSON is valid and that
omnodexsits insidemcpServers, next to your other servers, not besidemcpServers. - Check that every path is absolute, uses the host’s path style, and uses doubled backslashes on Windows.
- Confirm you edited the file for the surface you are using:
~/.gemini/config/for the Desktop App,~/.gemini/antigravity-cli/foragy. - Fully restart Antigravity after changing MCP servers.
omnodex connects but its tools are greyed out (Windows Desktop App): create the tool cache folder from step 4 and restart.
Hooks not firing:
- Run
omnodex statusin the project and confirm.agents/hooks.jsonhas anomnodexentry. - On Windows, confirm the hooks were installed from the same host (PowerShell or WSL) that runs Antigravity.
- Check
launcher.login your Omnodex home.Could not locate antigravity hook shimmeansomnodex-config.jsonis missing or has the wrongantigravitypath.
Events not appearing in the dashboard:
- On Windows with both hosts in use, events are split between
C:\Users\<you>\.omnodexand/home/<you>/.omnodex. See Windows and WSL to view both. - Run
omnodex replayto rebuild the read model.
Next steps
Section titled “Next steps”- MCP Proxy for Any Client - How the proxy works with other clients
- Running Detection - Risk detection works the same across all interceptors
- Events and Traces - The event model