MCP Hub
Back to servers

geminicli-mcp

A stateless MCP server that wraps the headless Gemini CLI, providing tools to send prompts to Google's Gemini models and receive text responses. It supports both simple prompts and prompts with contextual information.

glama
Updated
Apr 19, 2026

geminicli-mcp

Stateless MCP server wrapping the headless Gemini CLI.

  • stdio transport, spawn-per-client
  • two tools: gemini_prompt, gemini_prompt_with_context
  • no sessions, no working_dir, no timeout enforcement
  • runs in the server process's cwd

Install

npm install
npm run build

Binary is exposed as geminicli-mcp (see package.json#bin).

Tools

gemini_prompt

fieldtyperequirednotes
promptstringyesprompt text
modelstringnoe.g. gemini-2.5-pro

Returns the CLI's response text.

gemini_prompt_with_context

fieldtyperequirednotes
promptstringyesprompt text
contextstringyesprepended to the prompt inside <context>
modelstringnoe.g. gemini-2.5-pro

Returns the CLI's response text.

Env

  • GEMINI_CLI_BIN — override the gemini binary path.
  • Child process env is sanitized with NO_COLOR=1 and TERM=dumb.

Reviews

No reviews yet

Sign in to write a review