Documentation

Gemini CLI

Gemini CLI can connect to Northsun (formerly Mnemix) through its Streamable HTTP MCP transport. Register the endpoint with an authorization header, verify connection state with gemini mcp list, inspect the tools with /mcp, and run a read-only lookup. This is a custom MCP connection, not a Google partnership or a guarantee that Northsun's broader MCP schemas remain unchanged.

Prerequisites

  • Gemini CLI installed with MCP support.
  • MNEMIX_API_KEY exported in the shell where you run the setup command.
  • A controlled test caller already present in the Northsun tenant.

Gemini CLI stores project MCP configuration in .gemini/settings.json by default. A bearer header contains a credential, so this guide uses user scope and keeps the resulting file outside a repository. Gemini CLI currently documents environment expansion for an MCP server's env block, but not for remote HTTP headers.

Add Northsun

The official Gemini CLI command supports Streamable HTTP and custom headers:

gemini mcp add \
  --scope user \
  --transport http \
  --header "Authorization: Bearer $MNEMIX_API_KEY" \
  mnemix \
  https://mcp.mnemix.ai/mcp

Your shell history normally retains the variable reference, while Gemini CLI receives the expanded value and persists the resolved bearer header in the user settings file. Run this only on a trusted machine, keep the file out of source control and shared backups, and rotate the key if that file is exposed. Northsun does not yet offer an OAuth flow for this connection.

The resulting server entry uses this shape in settings.json:

{
  "mcpServers": {
    "mnemix": {
      "httpUrl": "https://mcp.mnemix.ai/mcp",
      "headers": {
        "Authorization": "Bearer ..."
      },
      "trust": false
    }
  }
}

Keep trust: false during initial verification so Gemini asks before tool calls. Do not copy or commit a generated settings file containing the resolved key.

Verify the connection

From the shell:

gemini mcp list

Inside Gemini CLI, use /mcp to inspect servers, tools, prompts, and resources. Then:

  1. Confirm the mnemix server reports connected.
  2. Confirm caller_lookup is present.
  3. Run caller_lookup with a controlled caller already in the tenant.
  4. Treat 404 as a valid empty state and 401 as a failed credential path.

Tool discovery proves protocol compatibility; the read-only call proves authenticated product access.

Common failures

SymptomLikely causeFix
gemini mcp list shows disconnectedURL, network, or authorization header is wrongRun /mcp for detailed diagnostics and verify the endpoint exactly.
401 unauthorizedThe shell expanded an empty or invalid keyConfirm MNEMIX_API_KEY exists without printing it, remove the bad entry, and add it again.
Server was added to the wrong scopeDefault project scope was used unintentionallyRemove it from that scope and re-add with --scope user only if global access is intended.
Gemini calls a tool without the expected approvalThe server was configured with trust: trueSet trust to false while validating or handling sensitive tenants.
A tool is missing or renamedNorthsun MCP schema evolvedInspect /mcp; do not copy an older tool call blindly.

Remove the connection or rotate the key

Remove the user-scoped entry with:

gemini mcp remove --scope user mnemix

If a settings file, recording, process listing, or log may have exposed the value, revoke or rotate the Northsun key before reconnecting. Removing a server does not revoke its key.

Stable and beta boundaries

The API reference owns the frozen three-endpoint REST surface. MCP also exposes broader contact and governed-context tools that evolve independently; inspect /mcp whenever Gemini CLI or Northsun changes. No Beacon or proactive-delivery capability is implied by successful tool discovery.

This is an interoperability guide for a custom MCP server. It does not claim Google endorsement, official support, native integration, or certification.

Related links