ccg-mcp
Enables Claude Code Desktop to call OpenAI Codex/GPT-5 and Gemini APIs via stdio MCP, without requiring local CLI tools.
README
CCG-MCP - Codex/Gemini API 版 MCP server for Claude Code
CCG-MCP 提供两个 stdio MCP server,让 Claude Code Desktop 直接通过 API 调用 OpenAI Codex/GPT-5 与 Gemini,不依赖本地 codex/gemini CLI。
安装与启动
本地目录:
uvx --from D:/code/promet/AutoGEO/.claude/ccg-mcp codex-api-mcp
uvx --from D:/code/promet/AutoGEO/.claude/ccg-mcp gemini-api-mcp
Git 仓库:
uvx --from <git-url> codex-api-mcp
uvx --from <git-url> gemini-api-mcp
Windows settings.json 示例
{
"mcpServers": {
"codex-api": {
"command": "uvx",
"args": ["--from", "D:/code/promet/AutoGEO/.claude/ccg-mcp", "codex-api-mcp"],
"env": {
"OPENAI_API_KEY": "${env:OPENAI_API_KEY}"
}
},
"gemini-api": {
"command": "uvx",
"args": ["--from", "D:/code/promet/AutoGEO/.claude/ccg-mcp", "gemini-api-mcp"],
"env": {
"GOOGLE_API_KEY": "${env:GOOGLE_API_KEY}"
}
}
}
}
macOS settings.json 示例
{
"mcpServers": {
"codex-api": {
"command": "uvx",
"args": ["--from", "/path/to/ccg-mcp", "codex-api-mcp"],
"env": {
"OPENAI_API_KEY": "$OPENAI_API_KEY"
}
},
"gemini-api": {
"command": "uvx",
"args": ["--from", "/path/to/ccg-mcp", "gemini-api-mcp"],
"env": {
"GOOGLE_API_KEY": "$GOOGLE_API_KEY"
}
}
}
}
Tool schema
codex-api.exec
exec(
prompt: str,
role: str = "",
model: str = "gpt-5-codex",
reasoning_effort: str = "medium",
workdir: str = ""
) -> str
prompt:完整用户任务,不截断。role:非空时作为 developer/system 上下文拼到模型输入前面。model:默认gpt-5-codex,可按账号可用性覆盖。reasoning_effort:传给 OpenAI Responses API 的 reasoning effort。workdir:作为工作目录上下文传入模型,不授予文件系统访问能力。
gemini-api.exec
exec(
prompt: str,
role: str = "",
model: str = "gemini-3.1-pro-preview",
workdir: str = ""
) -> str
prompt:完整用户任务,不截断。role:非空时作为 system instruction。model:默认gemini-3.1-pro-preview,可覆盖。workdir:作为工作目录上下文传入模型。
已知限制
- 速率限制:API 可能返回 429;server 会把错误结构化为 JSON 字符串返回。
- 模型可用性:默认模型取决于账号权限、地区和供应商发布状态。
- API 成本:长 prompt、多轮并行调用和高 reasoning effort 会产生更高费用。
- 本地代理:如网络需要代理,请通过系统环境变量或 SDK 支持的代理方式配置。
- 文件访问:这两个 server 只调用远程模型,不直接读取本地工作区文件。
烟测
python tests/smoke_test.py
烟测会分别启动两个 MCP server,通过 stdio 初始化并发送 ping,验证 MCP 通道、API 可达性和非空响应。
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.