How agents connect
Before you start
The hosted MCP server only needs your Cognee sign-in. Everything else needs two values from your workspace:1
Copy your workspace base URL
It looks like
https://tenant-<id>.aws.cognee.ai (or .gcp.cognee.ai for a workspace on Google Cloud) and is the API base URL in the Connection panel of the API Keys page. Agents and plugins ask for this URL (as “tenant URL”, “Cloud URL” or COGNEE_BASE_URL). The Tenant ID and User ID next to it are only for raw HTTP calls, so leave them out of agent setups.2
Create an API key
Click Create new key on the API Keys page and copy the key straight away: the full value is shown only once. Paste the key itself, without the
X-Api-Key: header name. Treat it like a password.COGNEE_API_KEY across several agents works: Claude Code, Codex and OpenCode installs that authenticate this way are still told apart by the prefixes on their session IDs (cc_, codex_, opencode_). Supported plugins can also get their own agent identity and labeled key, so each one can be tracked and revoked separately. See per-plugin agent identities.
Choose your agent
Coding agents
Claude Code (recommended)
One-paste plugin: sessions, recall and long-term memory across every session.
Codex
Enable hooks and install the plugin. Shares a dataset with Claude Code.
Cursor
Register Cognee as an MCP server for Cursor’s Agent mode.
VS Code (Cognee extension)
A citable project memory: remember, ask and recall in the editor.
Gemini CLI
Add Cognee to
~/.gemini/settings.json, then check /mcp.Cline
Paste the Cognee server into Cline’s MCP settings in VS Code.
Assistants and agent frameworks
ChatGPT
Add the Cognee app or the hosted MCP server, then sign in with Cognee.
Claude Desktop
Add the hosted connector, or run Cognee as a local MCP server.
OpenClaw
Cognee as OpenClaw’s memory provider, with multi-scope recall.
Hermes Agent
Drop-in memory provider in remote mode.
Grok Bot
Install the plugin and sign in with your Cognee account.
Chrome extension
Save pages you read to Cognee and ask about them from the browser.
Automation platforms
n8n
Install
n8n-nodes-cognee and add a Cognee API credential.Dify
Install the Cognee plugin by topoteretes from the Dify Marketplace.
Don’t see your agent? Anything that speaks MCP can use the hosted server, and any framework can call the SDK or REST API. See the Cloud SDK, the HTTP API and the full integration catalog.
FAQ
My agent or bot isn't listed (a Discord bot, a website chat, another agent framework)
My agent or bot isn't listed (a Discord bot, a website chat, another agent framework)
There is no built-in Discord or website integration. Connect your bot the way its framework allows:
- It supports remote MCP servers with OAuth: add
https://mcp.aws.cognee.ai/mcpand sign in with your Cognee account. See Cloud MCP. - It launches local MCP servers or only takes an API key: run
cognee-mcpyourself with your API base URL and an API key. - It is your own code: call
rememberandrecallfrom the Cloud SDK or the HTTP API with an API key. Pass asession_idto see each conversation on Sessions.
Do I need my own LLM or embedding API key?
Do I need my own LLM or embedding API key?
No. In Cognee Cloud your workspace runs graph extraction, embeddings and answers on models Cognee manages, and that work is paid for with your workspace credits. You can’t plug in your own LLM or embedding provider key, or choose the models, in Cloud.Your agent’s own model is a separate thing: Claude, ChatGPT, Gemini or a model you host yourself (on a laptop or a phone) can all use Cognee as memory, as long as the agent can reach it over MCP or HTTP. Settings such as
LLM_API_KEY, LLM_PROVIDER or EMBEDDING_MODEL in the plugin guides apply only to local mode, where Cognee runs on your machine. Leave them empty when you connect to Cloud.How do I keep each agent's memory separate?
How do I keep each agent's memory separate?
Give each agent its own dataset:
- Claude Code and Codex plugins: set
COGNEE_PLUGIN_DATASETper agent or per project, andCOGNEE_PLUGIN_RECALL_MODE=pinnedso recall stays on that dataset. Without both, the plugins shareagent_sessionsand recall searches every dataset you can read. See Choose a dataset. - Hermes Agent: set
COGNEE_PLUGIN_DATASET; a dataset of its own keeps recall pinned to it. - MCP clients (Claude, ChatGPT, Cursor, Grok Bot): each client writes to a default dataset named after it, but
recallwithout a dataset searches everything you can access. Two connectors in the same client, for example two Claude connectors, share that default. Name the dataset in the client’s instructions or project prompt (“always use the datasetsales_bot”). See Datasets. - VS Code extension: each repository already gets its own
vscode_<hash>dataset.