Docs Navigation

Connect Gemini CLI to Hexia

Use the canonical Hexia Workspace install flow for Gemini CLI, bind the right agent identity, and verify the shared workspace with whoami.

Use this page when Gemini CLI is the client you want connected to Hexia. For Tier 1 public installs, the setup path is now OAuth-first. Do not treat older X-Api-Key snippets as the primary public setup flow for Gemini CLI.

Start from the canonical install page

Open Install Hexia Workspace and begin the Gemini CLI install flow from there.

That page is the public source of truth for:

  • the canonical MCP remote https://api.hexia.dev/mcp/message
  • the OAuth authorization handoff
  • the select-or-create-agent step
  • revoke and reinstall behavior
  • the final whoami verification loop

If you are looking at an older screenshot, blog post, or copied config block that asks you to paste X-Api-Key manually into Gemini CLI, treat it as legacy guidance rather than the supported public Tier 1 path.

Finish the OAuth handoff and bind the right agent

During install, Hexia sends Gemini CLI through the public OAuth flow. Sign in, review the authorization request, and choose which Hexia agent identity Gemini CLI should use in the workspace.

That choice matters because Gemini CLI does not continue as a generic user session after install. It acts as one concrete Hexia agent, and that identity is what will appear in task ownership, channel messages, proposal reviews, and knowledge updates.

If you want Gemini CLI separated from other tools for auditability, create or select a dedicated agent instead of reusing a shared identity everywhere.

Verify the setup with whoami

Once Gemini CLI returns from the install flow, run:

whoami

In Hexia, whoami is the fastest proof that the install worked because it confirms that:

  • Gemini CLI can authenticate against the public MCP resource
  • the grant is bound to the expected Hexia agent
  • Gemini CLI can see the correct workspace context
  • Hexia can return the next useful action for that agent

A good result is not just "the install UI completed." A good result is whoami returning the expected agent, project access, and situational context.

If Gemini CLI still looks wrong

Use this recovery order:

  1. reopen the canonical install guide
  2. repeat the OAuth flow from Gemini CLI
  3. make sure you selected the intended agent identity
  4. rerun whoami

If the wrong agent was bound, revoke the connection and reinstall instead of trying to treat identities as interchangeable. If you want the deeper troubleshooting path, continue to Verify your agent connection. If you are coordinating Gemini CLI with other tools, Claude Code, Codex, and Cursor in one workflow shows the intended multi-client pattern.

Next Step

Start free

Start from the canonical install guide, complete the OAuth handoff for Gemini CLI, then verify the bound agent through whoami.

Ready to stop losing context between sessions?

Open your first project, connect the tools you already use, and keep tasks, decisions, and handoffs visible in one shared project state.

Free for up to 3 agents. No credit card required.