Connect Gavana to Antigravity
Antigravity is Google’s agent-first IDE. MCP works the same way across all three surfaces — Antigravity 2.0, the Antigravity IDE, and the Antigravity CLI — because they share one configuration format and one config file.
Antigravity is an IDE process, not a browser tab, so it reaches Gavana’s hosted endpoints directly with no origin restrictions.
Connect with full access
https://app.gavana.ai/mcp
This is the default Gavana connection. Its consent screen asks for eight permissions — every permission except reference:extract, which no MCP tool uses — and the connection stays active until you revoke it.
Where the config lives
~/.gemini/config/mcp_config.json global — all Antigravity surfaces
<project>/.agents/mcp_config.json per-workspace — this project onlyThe global path sits under ~/.gemini/, the same directory Gemini CLI uses, but config/mcp_config.json is a different file from Gemini CLI’s ~/.gemini/settings.json. Editing one does nothing for the other. If you have already set up Gemini CLI, you still need this file — and if Antigravity cannot see your server, the first thing to check is that you edited the right one.
Add the server
Normal connection:
{
"mcpServers": {
"gavana": {
"serverUrl": "https://app.gavana.ai/mcp"
}
}
}That bare entry is the complete configuration. Antigravity handles OAuth automatically for servers that support dynamic client registration, and Gavana does — so no oauth block, no client ID, no client secret.
The remote field is serverUrl. url and httpUrl are not the field to use here — httpUrl belongs to Gemini CLI, and Antigravity’s own docs state that legacy url and httpUrl fields are not supported. One field covers both streamable HTTP and SSE; there is no separate transport setting.
If the file already has an mcpServers object, add the gavana entry to it rather than replacing the whole file.
Getting to the config from the UI
Each surface has its own route to the same file.
Antigravity 2.0 — click the Settings button at the bottom left of your screen, select Customizations, and review the Installed MCP Servers section. Add MCP opens the MCP Store; each installed entry gets a trash-can to uninstall, a toggle to disable or enable, and a refresh button.
Antigravity IDE — click … at the top of the editor’s agent side panel and select MCP Servers, then Manage MCP Servers, then View raw config. That opens mcp_config.json for direct editing. Once installed, the server’s tools and resources are automatically available to the editor.
Antigravity CLI — type /mcp in the prompt panel and press Enter to open the interactive MCP Manager Overlay. It shows live status rings for active, disconnected, and loading servers, and lets you reload server configurations or inspect real-time connection logs.
Complete the OAuth flow
This is the step people get stuck on. Antigravity’s OAuth is not a pure browser round-trip — you have to bring a code back into the app by hand.
Open Agent Settings
Press Cmd+, on Mac, or Ctrl+, on Windows and Linux.
Go to Customizations
Find gavana in the list and click the Authenticate button next to it.
Sign in
Your browser opens Gavana’s sign-in and consent screen. Approve it.
Copy the authorization code
The browser hands you an authorization code. Copy it.
Paste it back
Return to the settings panel, paste the code into the field, and click Submit.
The server reconnects automatically once the code is accepted. Access tokens are stored at ~/.gemini/antigravity/mcp_oauth_tokens.json; expired tokens are refreshed for you and invalid ones are removed.
Verify
In the CLI, /mcp shows gavana with a live status ring. In 2.0 and the IDE, the server appears under Settings → Customizations → Installed MCP Servers with a toggle and a refresh button.
Then ask for something read-only:
Using Gavana, list my canvases and read the most recently updated one. Report its
handle, revision, node count, and connection count. Do not change anything.Tool approvals
By default, unconfigured MCP tools run in Ask mode — Antigravity requires your approval before each execution. Leave it that way. On the full endpoint it is the difference between reading a plan and paying for one.
You can widen that with policy patterns — mcp(gavana/canvas_list) for a single tool, mcp(gavana/*) for the whole server, mcp(*) for everything. If you auto-approve anything, auto-approve individual read tools, never the server wildcard on the full endpoint.
Resulting permission surface
Normal connection
The consent screen groups the request under Canvases and images, Elements and saved references, and Image and video generation. It asks for eight permissions: canvas:read, canvas:write, asset:read, element:read, element:write, image:generate, video:generate, and job:manage. There is no partial approval on this path.
Antigravity lists 17 core tools — canvas reads and writes, task canvas creation, image import and generation, video, Elements, model discovery, and Run status — and can call every other hosted tool by exact name. generate_image_in_canvas and generate_video can charge among the listed tools; edit_image_in_canvas, generate_product_photoshoot_in_canvas, run_canvas_workflow, recipe_run, and work_execute can charge when called by name. Full table: hosted MCP tools.
Cost exposure: real.
Read-only connection
In Gavana, open Settings → Connect an agent, choose Other, and turn on Read-only access before you copy the address. Use that address in place of the one above, under the server name gavana-readonly. Its consent screen asks only for canvas:read and element:read.
| Can | Cannot |
|---|---|
| List and read canvases and Elements | Create, update, move, or delete anything |
| Validate a canvas graph | View image assets, or save an image |
| Read stored Work and Recipe details | Create or run a workflow, a Recipe, or Work |
| Read Gavana’s own agent guidance | Generate an image or a video, or observe a Run |
| Spend a single credit |
It serves the tools marked read-only in the hosted tools reference. Cost exposure: none.
disabledTools on the server entry lets you hide specific tools from the agent, and disabled switches the whole server off without deleting it. Both are convenience, not a security boundary — the connection you approved and the Ask-mode approvals are the boundary.
The local stdio server
Antigravity can also launch Gavana’s local server as a child process, which exposes the full local tool catalog and signs in with your Gavana CLI login or a Personal Access Token rather than OAuth. Use command, args, and env in place of serverUrl:
{
"mcpServers": {
"gavana": {
"command": "npx",
"args": ["-y", "@gavana.ai/mcp@0.5.1"],
"env": {
"GAVANA_BASE_URL": "https://app.gavana.ai",
"GAVANA_AGENT_TOKEN": "PASTE_YOUR_TOKEN_HERE"
}
}
}
}Needs Node.js 20 or newer. With a Gavana CLI login on this machine (gavana auth login) you can leave the token out: the server reads that login. The real permission surface here is the credential’s scopes, not the tool list — a tool called outside them fails with a permission error. Add "GAVANA_MCP_READ_ONLY": "true" for a hard read-only server, or "GAVANA_MCP_TOOLSETS" to narrow the catalog; scoping the token is still the stronger control.
mcp_config.json now contains a live credential. Never commit the workspace copy at .agents/mcp_config.json — put it in .gitignore before you paste the token, not after. If it leaks, revoke that token immediately and create a new one — see the safety contract.
Disconnect
Remove the gavana entry from mcp_config.json, or uninstall it from Settings → Customizations → Installed MCP Servers. Then revoke the connection in Gavana under Settings → Connect an agent → Connected — revocation takes effect immediately. Deleting ~/.gemini/antigravity/mcp_oauth_tokens.json clears the local copy but does not revoke anything server-side.
If you used the local stdio path with a token, revoke that token in the same list.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
| Server never appears | Edited ~/.gemini/settings.json instead of ~/.gemini/config/mcp_config.json | Edit the Antigravity file; they are different |
| Server appears but never connects | url or httpUrl used as the field name | Rename the field to serverUrl |
| Stuck at “authenticating” forever | Authorization code never pasted back | Reopen Agent Settings → Customizations → Authenticate and complete the paste-and-Submit step |
| Authentication succeeded, calls still fail | Stale token from an earlier attempt | Refresh the server, or re-run Authenticate |
| Every tool call halts for approval | Ask mode, the default | Intended — approve per call, or scope a policy to specific read tools |
| Generation is refused | A read-only connection, or a grant without the generation scopes | Reconnect with the normal address and approve the eight permissions |
| Connection times out on start (stdio path) | Antigravity applies a launch timeout to MCP servers, and the first npx fetch is slow | Run npx -y @gavana.ai/mcp@0.5.1 once in a terminal to warm the cache, or raise Antigravity’s configurable MCP launch timeout |
More: MCP troubleshooting.
Security notes
- The hosted server accepts OAuth bearer tokens only. Do not attempt to use a
cba_…Personal Access Token there — that is the local MCP and API path. - Webhooks are not available through MCP by design: a signing secret must never enter model-visible tool arguments or tool logs. Use the CLI or the API when you need callbacks.
- Generation is billed through your Gavana account — your own saved provider key, a key your workspace owner shares, or Gavana credit — never through Google.