Integrations

Claude Code

Connect Memo over MCP, add automatic recall on session start, capture durable facts at session end, and install /memo commands.

Integrations4 pages

Claude Code gets the most out of Memo because it can call tools and run hooks. A full setup has three layers, and each one is useful on its own:

MCP
What it does
Six memory tools, available on demand
Needs
A token and one command
Hooks
What it does
Recall at session start, capture at session end
Needs
The capture CLI
Commands
What it does
/memo:remember, /memo:search, /memo:context, /memo:status, /memo:pause, /memo:resume
Needs
The capture CLI

1. Connect the MCP server

terminal
claude mcp add --transport http memo https://memo.uno/api/mcp \
  --header "Authorization: Bearer memo_..."

Run /mcp inside Claude Code to confirm the connection. The tools appear as mcp__memo__memory_search, mcp__memo__memory_context, mcp__memo__memory_add, mcp__memo__memory_list, mcp__memo__memory_get and the rest of the set.

2. Add automatic recall

Without hooks, recall depends on the model deciding to call a tool. The SessionStart hook removes that decision: at the start of every session, Claude Code runs a command that fetches a context pack for the current repository and injects it as additional context before your first prompt.

in a repository
node scripts/memo-capture.mjs install-claude
or for every project
node scripts/memo-capture.mjs install-claude --global

That writes two hooks to the nearest .claude/settings.json (or your home directory with --global):

.claude/settings.json
{
  "hooks": {
    "SessionStart": [
      { "hooks": [{ "type": "command", "command": "node \".../memo-capture.mjs\" session-start", "timeout": 20 }] }
    ],
    "Stop": [
      { "hooks": [{ "type": "command", "command": "node \".../memo-capture.mjs\" session", "timeout": 30 }] }
    ]
  }
}
  • SessionStart recalls the pack for the repository, truncates it to 3,800 characters and injects it. It never blocks a session; with no token or with capture paused it exits silently.
  • Stop reads the session transcript, keeps only your own recent messages and sends them to the Inbox for review.
Auto-recall

Recalled context is only as good as your stored memory. If a session starts with conventions that feel stale, edit them in Dashboard → Code — the next session will pick up the new value.

3. Install the slash commands

terminal
node scripts/memo-capture.mjs install-commands

This writes six commands to ~/.claude/commands/memo/, which Claude Code exposes as:

/memo:remember <text>
What it does
Calls memory_add with the right kind, category or type, and reports whether the write was created, merged or superseded.
/memo:search <query>
What it does
Searches both stores and answers from the results with memory ids.
/memo:context
What it does
Loads a coding pack for the current repository and keeps it as background for the session.
/memo:status
What it does
Runs the CLI status check: server, token, proxy, capture state and an auth probe.
/memo:pause / /memo:resume
What it does
Turns hook capture off or back on without uninstalling anything.

Using the CLI directly

memo-capture configure --url <url> --token <token>
Purpose
Save credentials to ~/.memo/config.json (0600).
memo-capture recall [--preset coding] [--task text]
Purpose
Print a context pack for the current repository.
memo-capture status
Purpose
Check server, token and capture state; probe /api/context.
memo-capture pause | resume
Purpose
Stop or restart hook capture.
memo-capture print-config
Purpose
Print the hook JSON to paste manually.

Configuration

MEMO_URL
Effect
Override the saved server URL.
MEMO_TOKEN
Effect
Override the saved token.
MEMO_PROXY
Effect
Route requests through a proxy; the CLI then uses curl.
MEMO_CAPTURE_DISABLED=1
Effect
Disable capture for this shell without touching the config.
MEMO_RECALL_CHARS
Effect
Character budget for injected context (default 3,800).
MEMO_DEBUG=1
Effect
Print what a hook would send.

Troubleshooting

  • Tools missing in `/mcp` — the header is case-sensitive: Authorization: Bearer memo_....
  • 401 in status — the token was revoked or belongs to another account. Mint a new one and run configure again.
  • Recall is empty — the pack is built for the repository of the current directory. Run memo-capture recall there to see what the hook would receive.
  • Nothing is captured — check memo-capture status; capture may be paused, or the session may contain no durable sentences. MEMO_DEBUG=1 prints the payload.