One URL for every MCP client.
Point Claude Code, Cursor, VS Code, Windsurf or Claude Desktop at the hosted server with your key and an app user header, or add it to claude.ai or ChatGPT and sign in. The model gets 8 memory tools and asks for what it needs.
- URL
- https://api.alexein.ai/v1/mcp
- Transport
- Streamable HTTP, JSON responses
- Auth
- Authorization: Bearer <key>, or sign-in (OAuth)
- App user
- X-Alexein-User: <your user's id>, or chosen at sign-in
- Tools
- 8 read; memory_add and memory_feedback with a write key or Read and save
Connect in one step
A key, and whose memory the agent should read: your own, as me, with a personal key from My memory, or one of your app's users, by its id, with a project key from the console. Nothing to install: the server is hosted, and speaks MCP over Streamable HTTP.
Keep the key in an environment variable. Cursor reads ${env:ALEXEIN_API_KEY} from yours.
A personal key from My memory › Keys at memory.alexein.ai, and X-Alexein-User: me. Only you can read this memory.
claude mcp add --transport http alexein \
https://api.alexein.ai/v1/mcp \
--header "Authorization: Bearer $ALEXEIN_API_KEY" \
--header "X-Alexein-User: me"{
"mcpServers": {
"alexein": {
"url": "https://api.alexein.ai/v1/mcp",
"headers": {
"Authorization": "Bearer ${env:ALEXEIN_API_KEY}",
"X-Alexein-User": "me"
}
}
}
}A project key from API keys in the console, and the id your app has for the user in X-Alexein-User, such as user_42.
claude mcp add --transport http alexein \
https://api.alexein.ai/v1/mcp \
--header "Authorization: Bearer $ALEXEIN_API_KEY" \
--header "X-Alexein-User: user_42"{
"mcpServers": {
"alexein": {
"url": "https://api.alexein.ai/v1/mcp",
"headers": {
"Authorization": "Bearer ${env:ALEXEIN_API_KEY}",
"X-Alexein-User": "user_42"
}
}
}
}The tools
Reads the REST API publishes, under the names a model calls them by. Only memory_search counts as a retrieval, found or not; every other read tool is free. memory_add counts 1 event for each new item, and memory_feedback 1 event.
| Tool | What it answers | Arguments | Metered |
|---|---|---|---|
| Find | |||
| memory_search | What memory holds for a question: what is known now, dated facts and excerpts, each with a ref | query, before?, after?, filters? | 1 retrieval |
| memory_latest | The most recent excerpts, newest first | k?, place?, after?, before?, filters? | Free |
| Open the sources | |||
| memory_open | A fact with the excerpts it came from, or an excerpt whole, by its ref | ref | Free |
| memory_around | The excerpts either side of one, in its conversation | ref, width? | Free |
| Over time | |||
| memory_subject | One person or thing by name, its whole story oldest first: its values now, its facts, the conversations about it and how it relates to others | name, limit? | Free |
| memory_open_items | Issues and pull requests still open, and follow-ups not yet done, with how long each has waited | kind?, provider?, place?, mine?, within_days?, limit? | Free |
| memory_how_they_work | How the person works, as readable cards: the routines they follow and how they write in each place, each card with the facts it rests on | who?, surface? | Free |
| memory_summary | How much this memory holds, from when to when, its sources and what is known now | date? | Free |
| Write, with a write key or a Read and save connection | |||
| memory_add | Saves the facts the person tells it, one per item, in their words; never secrets | items (text, kind?, author?, role?, session?, id?, about?, at?, expires?) | 1 event per new item |
| memory_feedback | Tells memory a search was wrong, missed the answer or served, by its search_id | search_id, verdict, note? | 1 event |
The account is never a tool argument
Which memory a call reads comes from the key and the X-Alexein-User header, set once in the client's config, or from the signed sign-in token of a claude.ai or ChatGPT connection. No tool has a field that could name another user.
A model that could name an account could name somebody else's.
POST /v1/mcp
Authorization: Bearer tm_AbC1234…
X-Alexein-User: user_42
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "memory_search",
"arguments": { "query": "Where does Alice live?" }
}
}{
"jsonrpc": "2.0",
"id": 2,
"result": {
"content": [{
"type": "text",
"text": "{\"query\": \"Where does Alice live?\", \"answerable\": true, \"memories\": […]}"
}],
"isError": false
}
}Writes need a key that writes
A read key lists only the read tools, so an agent handed one cannot change memory. Mint a write key when the agent should save what it learns, and memory_add and memory_feedback appear in its tool list.
| Key | Tools |
|---|---|
| Read key | 8 |
| Write key | 10 |
Give your agent a memory in one command.
10,000 events and 1,000 retrievals a month on Free. No card needed.