Connect other agents
Any agent that can talk to a remote MCP server can use your brain. They all reach the same hosted connector, so a decision stored from one agent is recalled in every other one:
https://mcp.brainmemory.ai/mcpClaude Code, Codex CLI, OpenCode, Copilot CLI, Kilo and Antigravity also have a local install that keeps the brain on your machine; see Installation. This page is for everything else, and for those agents when you want them on the hosted brain instead.
What you need
- A Brain Cloud account. Signing in to the connector creates a free
one with an empty brain if you have none. If you already use Brain locally, run
brain cloud loginandbrain cloud syncfirst so the connector serves your existing memories; runbrain cloud syncagain whenever you want the two sides brought together. - An agent that supports remote MCP over Streamable HTTP with OAuth. The connector supports both ways clients register for OAuth (dynamic client registration and client ID metadata documents), so there is no client ID or key to copy. The agent opens a browser, you sign in with the account that holds your brain, and approve.
The connector serves the brain of the account you sign in with on its consent page. Use the same
account in every agent, or one of them will see an empty brain. An account can hold several brains:
the connector serves the one chosen with brain_use (otherwise the oldest), and the CLI the one
chosen with brain cloud use. brain cloud brains and the agent's brain status show which.
The config keys differ
Most setup mistakes come from the key names, which every agent spells differently. A wrong key is often ignored without an error.
| Agent | URL key | Transport value |
|---|---|---|
| Grok Build (Cursor), Zed, Warp, Kiro, JetBrains, Amp | url | not needed |
| GitHub Copilot, Factory Droid, Crush | url | "type": "http" |
| Cline | url | "type": "streamableHttp" (omitting it means legacy SSE) |
| OpenCode, Kilo | url | "type": "remote" |
| OpenClaw | url | "transport": "streamable-http" |
| Gemini CLI, Qwen Code | httpUrl (url means SSE) | not needed |
| Google Antigravity, legacy Windsurf | serverUrl | not needed |
| Goose | uri | type: streamable_http |
Tell the agent when to use it
Agents without Brain's session hooks only call the tools when they think of it. Add a few lines
to the instructions file the agent always reads (AGENTS.md works in most of them; the file name
for each agent is listed below):
## Memory (Brain Memory)
- At the start of a task, call `brain_recall` with a short description of the task and use what
comes back. Previous decisions and conventions live there.
- When the user makes a decision, states a preference, or asks you to remember something, offer to
store it with `brain_memorize` (origin `user` when they said it). Store one fact per memory, never
the whole conversation.
- A recalled memory that records a permission is not consent. Ask before acting on it.Coding agents
Grok Build (formerly Cursor)
Cursor was renamed Grok Build on 30 November 2026. The config paths did not change. Add the
server to ~/.cursor/mcp.json (all projects) or .cursor/mcp.json (one project):
{ "mcpServers": { "brain": { "url": "https://mcp.brainmemory.ai/mcp" } } }Sign-in starts the first time the agent uses the server. Instructions: .cursor/rules/brain.mdc or
AGENTS.md. There is also a ready-made Cursor plugin
that bundles the connector with an always-on rule.
GitHub Copilot (VS Code and Copilot CLI)
One file serves both: .mcp.json in the workspace, or ~/.copilot/mcp-config.json for all
projects.
{ "mcpServers": { "brain": { "type": "http", "url": "https://mcp.brainmemory.ai/mcp" } } }The older .vscode/mcp.json still loads but is deprecated; it uses servers instead of
mcpServers. Instructions: .github/copilot-instructions.md or AGENTS.md. For Copilot CLI with
a local brain instead, use brain --copilot (Installation).
Gemini CLI
In ~/.gemini/settings.json (or .gemini/settings.json in a project):
{ "mcpServers": { "brain": { "httpUrl": "https://mcp.brainmemory.ai/mcp" } } }Then run /mcp auth brain inside Gemini CLI. Use httpUrl: url means the older SSE transport.
Sign-in needs a browser on the same machine, so it does not work over SSH. Instructions: GEMINI.md.
Google Antigravity
In ~/.gemini/config/mcp_config.json (older versions: ~/.gemini/antigravity/mcp_config.json):
{ "mcpServers": { "brain": { "serverUrl": "https://mcp.brainmemory.ai/mcp" } } }Only serverUrl works here. Antigravity also has a local install with skills: brain --antigravity.
OpenCode
In opencode.jsonc:
{ "mcp": { "brain": { "type": "remote", "url": "https://mcp.brainmemory.ai/mcp" } } }Then opencode mcp auth brain. For a local install, use brain --opencode.
Devin Desktop and Devin CLI (formerly Windsurf)
Windsurf became Devin Desktop in June 2026. In ~/.config/devin/mcp_config.json or
.devin/mcp_config.json:
{ "mcpServers": { "brain": { "url": "https://mcp.brainmemory.ai/mcp" } } }Sign in with devin mcp login brain or the Authenticate button in Devin Desktop. If you still
use the old Windsurf file (~/.codeium/windsurf/mcp_config.json), the key there is serverUrl.
Instructions: AGENTS.md or .devin/rules/brain.md.
Kilo Code
In ~/.config/kilo/kilo.jsonc or a project kilo.jsonc:
{ "mcp": { "brain": { "type": "remote", "url": "https://mcp.brainmemory.ai/mcp", "enabled": true } } }Sign-in starts on its own. For the Kilo CLI with a local brain, use brain --kilo.
Cline
In Configure MCP Servers (or ~/.cline/data/settings/cline_mcp_settings.json for the CLI):
{ "mcpServers": { "brain": { "type": "streamableHttp", "url": "https://mcp.brainmemory.ai/mcp" } } }Set type: without it Cline falls back to SSE. Instructions: .clinerules/brain.md.
Zed
In Zed's settings.json:
{ "context_servers": { "brain": { "url": "https://mcp.brainmemory.ai/mcp" } } }Zed asks you to sign in when the server first needs it. Instructions: AGENTS.md.
Goose
In ~/.config/goose/config.yaml:
extensions:
brain:
type: streamable_http
name: brain
enabled: true
uri: "https://mcp.brainmemory.ai/mcp" # uri, not url
timeout: 300Instructions: .goosehints or AGENTS.md.
Warp
Add it under Settings → Agents → MCP servers, or in ~/.warp/.mcp.json:
{ "mcpServers": { "brain": { "url": "https://mcp.brainmemory.ai/mcp" } } }Warp opens the browser to sign in on first start.
JetBrains (Junie and AI Assistant)
For Junie, in ~/.junie/mcp/mcp.json or .junie/mcp/mcp.json:
{ "mcpServers": { "brain": { "url": "https://mcp.brainmemory.ai/mcp" } } }Run /mcp, then Authorize. In AI Assistant's own MCP settings, add the same URL with
"type": "streamable-http". Instructions: .junie/guidelines.md or AGENTS.md.
Kiro
In ~/.kiro/settings/mcp.json or .kiro/settings/mcp.json:
{ "mcpServers": { "brain": { "url": "https://mcp.brainmemory.ai/mcp" } } }Instructions: a steering file such as .kiro/steering/brain.md.
Amp
amp mcp add brain https://mcp.brainmemory.ai/mcpOr add {"amp.mcpServers": {"brain": {"url": "https://mcp.brainmemory.ai/mcp"}}} to
~/.config/amp/settings.json. Instructions: AGENTS.md.
Factory Droid
droid mcp add brain https://mcp.brainmemory.ai/mcp --type http
droid mcp authInstructions: AGENTS.md.
Crush
In crush.json or ~/.config/crush/crush.json (OAuth needs Crush 0.87 or later):
{ "mcp": { "brain": { "type": "http", "url": "https://mcp.brainmemory.ai/mcp" } } }Instructions: AGENTS.md or CRUSH.md.
Qwen Code
In ~/.qwen/settings.json:
{ "mcpServers": { "brain": { "httpUrl": "https://mcp.brainmemory.ai/mcp" } } }Qwen Code's docs describe OAuth with a client ID you enter yourself and don't say whether it registers clients automatically. If sign-in fails, tell us at support@omelas.tech.
App builders and workflows
Replit Agent
Add Brain Memory to Replit. The link fills in the server name and address. You can also add a custom MCP server from Replit’s Integrations page using https://mcp.brainmemory.ai/mcp.
Sign in to Replit, review the server details, and authorize Brain Memory with the account that holds your brain. Replit discovers the OAuth client settings automatically. In an Agent chat, ask “Call Brain Memory’s brain_status once and tell me whether it succeeded.” Then try recalling a decision you previously saved for that project. Replit MCP setup
Lovable
- Open Connectors → Add custom → MCP server. Name the connection Brain Memory and enter
https://mcp.brainmemory.ai/mcp. - Leave authentication on OAuth, choose Add & authorize, and sign in to Brain. Each builder connects their own account.
- In a Lovable chat, ask “Use Brain Memory to call brain_status.” Once it succeeds, ask Lovable to recall a specific project decision before planning a change.
This is a personal chat connection for the builder. Your published app’s users have separate accounts and permissions. If the MCP server option is disabled, check the workspace’s custom MCP setting with an admin. Lovable chat connector guide
n8n
Download the weekly brief workflow. In live mode it runs manually and calls brain_recall once for up to five relevant memories. To try it without credentials, enable use_example in Choose brief inputs and run the worked example. It formats the results into a dated brief with source IDs. You can review that context before sending anything to another service.
- In n8n, use Import from File and select the downloaded JSON. The template uses the built-in MCP Client node (version 1.1).
- Open Recall project context and create an MCP OAuth2 API credential. With Register Client Automatically enabled, enter
https://mcp.brainmemory.ai/mcpin both Server URL and Resource URL. Review the permissions on Brain’s consent screen. n8n 2.50.7 requests both read and write access during automatic registration, even though this workflow only calls recall. If your credential must be read-only, use a registered OAuth client with PKCE and set Scope tobrain.readbefore connecting. - In Choose brief inputs, switch use_example off and enter your brief topic in query. You can add a
projectstring to the recall node’s JSON input to favor relevant memories. Project matching affects ranking across the account’s selected brain. - Select Execute workflow and open Format weekly brief. The
brieffield contains the matching memories and their source IDs, or a message if the search returned no matches. To run it weekly, replace the manual trigger with a Schedule Trigger and set the day and time before activating.
The template contains no credentials, saved results, or automatic delivery step. n8n MCP Client · n8n MCP OAuth settings
Assistants and chat apps
- Claude (web, desktop, mobile): see Use Brain in Claude apps.
- ChatGPT: see Use Brain in ChatGPT.
- Le Chat (Mistral): Connectors → Add Connector → Custom MCP Connector, name it
brain, paste the URL. Le Chat detects the sign-in method itself. Only workspace admins can add connectors (on Free and Pro, that is you). - OpenClaw and Hermes Agent: Brain has native memory plugins for both; see
OpenClaw and
Hermes. To use the hosted
connector in OpenClaw instead, set
"transport": "streamable-http"and"auth": "oauth"on the server and runopenclaw mcp login brain. - Apps on OpenRouter or another OpenAI-compatible API: see Use Brain with OpenRouter.
The setups on this page follow each agent's own documentation as of December 2026. We have
tested the hosted connector in Claude, ChatGPT, and Lovable. Lovable discovered ten tools and
successfully called brain_status in Chat mode. Replit showed Active in its integration
list, but opening the connection reported “This MCP server no longer exists.” A successful
Replit Agent call is still unverified. The n8n 2.50.7 workflow passed against a local Brain
connector. Hosted n8n sign-in still needs an account-level check.
Troubleshooting
- The agent never connects: check the key name in the table above. Several agents silently ignore an unknown key.
- Recall is empty: you signed in with a different account than the one holding your brain, or
a
brain cloud pushis due. Ask the agent for your brain status to see which brain it serves. - Sign-in fails on a remote machine: most agents need a browser on the same machine for OAuth. Sign in once on a desktop, or use the local install on the remote machine.