geminicli-mcp
geminicli-mcp
헤드리스 Gemini CLI를 래핑하는 상태 비저장(stateless) MCP 서버입니다.
stdio 전송, 클라이언트당 프로세스 생성(spawn-per-client)
두 가지 도구:
gemini_prompt,gemini_prompt_with_context세션 없음,
working_dir없음, 타임아웃 강제 적용 없음서버 프로세스의
cwd에서 실행됨
설치
npm install
npm run build바이너리는 geminicli-mcp로 노출됩니다(package.json#bin 참조).
Related MCP server: gemini-cli-mcp
도구
gemini_prompt
필드 | 타입 | 필수 | 비고 |
prompt | string | 예 | 프롬프트 텍스트 |
model | string | 아니오 | 예: |
CLI의 응답 텍스트를 반환합니다.
gemini_prompt_with_context
필드 | 타입 | 필수 | 비고 |
prompt | string | 예 | 프롬프트 텍스트 |
context | string | 예 |
|
model | string | 아니오 | 예: |
CLI의 응답 텍스트를 반환합니다.
환경 변수
GEMINI_CLI_BIN—gemini바이너리 경로를 재정의합니다.자식 프로세스 환경은
NO_COLOR=1및TERM=dumb으로 정리됩니다.
Available Tools
2 toolsgemini_promptA
Invoke the headless Gemini CLI with a single prompt. Stateless — each call is an independent turn. Runs in the MCP server's current working directory.
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Prompt text sent to the Gemini CLI. | |
| model | No | Optional model identifier (e.g., gemini-2.5-pro). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It discloses key behavioral traits: statelessness, independence of calls, and execution directory. However, it lacks details on permissions, rate limits, error handling, or output format. For a tool with no annotations, this is adequate but leaves gaps in behavioral context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is highly concise and front-loaded: three short sentences with zero waste. Each sentence adds value—stating the purpose, behavioral trait (statelessness), and execution context—earning its place efficiently.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no annotations, no output schema, and 2 parameters with full schema coverage, the description is minimally complete. It covers purpose and basic behavior but lacks details on output, errors, or advanced usage. For a stateless CLI tool, this is adequate but not comprehensive.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already documents both parameters ('prompt' and 'model') fully. The description doesn't add any parameter-specific meaning beyond what the schema provides, such as examples or constraints. Baseline 3 is appropriate when the schema does the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Invoke the headless Gemini CLI with a single prompt.' It specifies the verb ('invoke') and resource ('Gemini CLI'), and distinguishes it from the sibling tool by noting it's 'stateless — each call is an independent turn.' However, it doesn't explicitly name the sibling tool for full differentiation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides clear context for usage: 'Stateless — each call is an independent turn' and 'Runs in the MCP server's current working directory.' This implies when to use it (for independent prompts) and hints at an alternative (the sibling tool likely handles context). However, it doesn't explicitly name the sibling or state when-not-to-use scenarios.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
gemini_prompt_with_contextA
Invoke the headless Gemini CLI with a prompt plus a separate context block. Stateless — each call is an independent turn. The context is prepended to the prompt inside a tag. Runs in the MCP server's current working directory.
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Prompt text sent to the Gemini CLI. | |
| context | Yes | Context block prepended to the prompt (e.g., file contents, prior notes). | |
| model | No | Optional model identifier (e.g., gemini-2.5-pro). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It discloses key behavioral traits: statelessness, context prepending inside a <context> tag, and execution in the MCP server's current working directory. However, it lacks details on permissions, rate limits, error handling, or output format, which are important for a CLI invocation tool with no output schema.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is highly concise and well-structured: three sentences that efficiently cover purpose, behavior, and execution context without redundancy. Each sentence adds distinct value, and it's front-loaded with the core functionality.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's moderate complexity (3 parameters, no annotations, no output schema), the description is partially complete. It covers the basic operation and statelessness but lacks details on output format, error conditions, or model-specific behaviors. Without an output schema, the description should ideally hint at return values or response structure, which it doesn't, leaving gaps for an AI agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already documents all three parameters (prompt, context, model) with descriptions. The description adds minimal value beyond the schema, mentioning that context is 'prepended to the prompt inside a <context> tag' and that the tool is stateless, but doesn't provide additional syntax, format, or usage details for the parameters. This meets the baseline of 3 for high schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Invoke the headless Gemini CLI with a prompt plus a separate context block.' It specifies the verb ('invoke'), resource ('Gemini CLI'), and distinguishes it from the sibling tool 'gemini_prompt' by mentioning the separate context block. However, it doesn't explicitly name the sibling for differentiation, keeping it at 4 rather than 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides some usage context: 'Stateless — each call is an independent turn' and 'Runs in the MCP server's current working directory.' It implies when to use this tool (for prompts with separate context blocks) but doesn't explicitly state when to use it versus the sibling 'gemini_prompt' or other alternatives, nor does it provide exclusions or prerequisites.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
2 tool updates
v0.1.0- First observed
gemini_prompt - First observed
gemini_prompt_with_context
TDQS
Scored across 2 tools
The two tools have clearly distinct purposes: one handles simple prompts, while the other adds a separate context block. The descriptions explicitly differentiate them, making misselection unlikely. However, the core functionality is similar, which could cause minor confusion in edge cases.
Both tools follow a consistent 'gemini_prompt' prefix with descriptive suffixes ('with_context'), using snake_case throughout. The naming pattern is predictable and clearly indicates their relationship and differences.
With only 2 tools, the server feels thin for a CLI interface, potentially lacking operations like configuration management, history, or batch processing. While the tools cover basic prompt execution, the scope seems limited compared to typical CLI toolkits.
The server is severely incomplete for a Gemini CLI domain, missing essential operations such as model selection, parameter tuning, file handling, conversation history, or error management. Agents will face dead ends when trying to perform common CLI tasks beyond basic prompting.
Maintenance
Related MCP Connectors
MCP server for OpenAI API (chat completions, image generation, embeddings) via AceDataCloud
Focused MCP server for OpenAI image/audio generation (v2.0.0). Wraps endpoints via HAPI CLI.
MCP server for AI dialogue using various LLM models via AceDataCloud
An MCP server that provides an API to LLMs to manage their JumpCloud resources.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceAn MCP server that wraps the Gemini CLI to provide tools for executing prompts, managing chat sessions, and accessing CLI extensions. It supports both local stdio and remote SSE transports for flexible integration with MCP clients.1-
- AlicenseAqualityDmaintenanceA secure MCP server that wraps the Google Gemini CLI, allowing clients to query Gemini models using local OAuth sessions without requiring an API key. It provides tools for model interaction and diagnostics with built-in protection against command injection.27 npm5MIT
- FlicenseAqualityDmaintenanceWraps the Gemini CLI as an MCP server, enabling AI tools to perform Gemini queries, interactive sessions, and extension management via a unified tool.11-
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that wraps the Gemini CLI, enabling AI assistants to send prompts, research topics, analyze code, and summarize content using Gemini.13MIT