Skip to content
Retain7

Retain7 for Gemini CLI

Shared memory for Gemini CLI

A Gemini CLI session answers from your files and the prompt in front of it. The conventions your team settled in other tools, and the dead ends they already hit, are not there unless you paste them in.

How it works

One memory, shared across your tools

One gemini mcp add command registers the server. Run /mcp auth retain7, approve in the browser, and Gemini CLI can search and save to the same project memory as the rest of your tools.

Saved in Codex

Ship every user-facing change behind a feature flag.

Found in Gemini CLI

The next session searches before it answers, so the decision is already in its context.

An example memory, not customer data.

Setup

Add Retain7 to Gemini CLI

A minute or two, once. The same steps are in the docs.

  1. Run this once in a terminal. It adds Retain7 for every repository.

    gemini mcp add --transport http --scope user retain7 https://retain7.com/mcp
  2. In Gemini CLI, run this and approve in the browser:

    /mcp auth retain7
  3. So every session checks the team memory before it answers, add this line to ~/.gemini/GEMINI.md:

    This team keeps its project memory in Retain7. Before answering how this project does something, call the retain7 memory_search tool.

Questions about Gemini CLI

Why does the command say --transport http?

Retain7 speaks streamable HTTP, which is the http transport in Gemini CLI. The older url setting in settings.json is for SSE servers.

How does Gemini CLI sign in to Retain7?

It detects that the server needs OAuth. Run /mcp auth retain7 and it opens your browser, then stores the tokens in ~/.gemini/mcp-oauth-tokens.json.

Does it apply to every repository?

The command shown uses --scope user, so yes. Leave the scope off and it applies only to the current project, through that project's .gemini/settings.json.

Does the sign-in need a browser on the same machine?

Yes. Gemini CLI redirects back to a local port on the machine it runs on.

Give Gemini CLI a memory that lasts.

Free for 14 days on the Team plan. No card needed.