GC

g-core/gcore-mcp-server

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

11 stars 6 forks 质量 82 趋势 22Apache-2.0

Gcore official MCP server

概览

MCP (Model Context Protocol) server for Gcore API. This server provides tools for interacting with Gcore Cloud API via LLM assistants. As we have multiple resources available, providing all of them at once to most LLM clients can overwhelm the model and lead to confusion among the tools. For most clients, it is recommended to specify only the necessary resources for your task to ensure optimal performance and clarity. Some clients, like Claude Code, handle this differently — see below. Add the server to your Cursor IDE configuration file (~/.cursor/mcp.json): Add the server to your Claude Code configuration file (~/.claude.json): Setting GCORE_TOOLS=* loads all available tools, which works well with Claude Code thanks to its feature. Unlike other clients, Claude Code defers tool schema loading — tool schemas are only fetched on demand when they match a query. This means registering many tools doesn't bloat the context window.

README

以下为原文 README 节选,完整内容请查看原文。

Gcore MCP Server

MCP (Model Context Protocol) server for Gcore API. This server provides tools for interacting with Gcore Cloud API via LLM assistants.

Usage

Note: As we have multiple resources available, providing all of them at once to most LLM clients can overwhelm the model and lead to confusion among the tools. For most clients, it is recommended to specify only the necessary resources for your task to ensure optimal performance and clarity. Some clients, like Claude Code, handle this differently — see below.

Integration with Cursor IDE

Add the server to your Cursor IDE configuration file (~/.cursor/mcp.json):

{
  "mcpServers": {
    "gcore-mcp-server": {
      "command": "uvx",
      "args": ["--from", "gcore-mcp-server@git+https://github.com/G-Core/gcore-mcp-server.git", "gcore-mcp-server"],
      "env": {
        "GCORE_API_KEY": "4***1",
        "GCORE_TOOLS": "instances,management,cloud.gpu_baremetal.clusters.*"
      }
    }
  }
}

Integration with Claude Code

Add the server to your Claude Code configuration file (~/.claude.json):

{
  "mcpServers": {
    "gcore-mcp-server": {
      "command": "uvx",
      "args": ["--from", "gcore-mcp-server@git+https://github.com/G-Core/gcore-mcp-server.git", "gcore-mcp-server"],
      "env": {
        "GCORE_API_KEY": "4***1",
        "GCORE_TOOLS": "*"
      }
    }
  }
}

Setting GCORE_TOOLS=* loads all available tools, which works well with Claude Code thanks to its Tool Search feature. Unlike other clients, Claude Code defers tool schema loading — tool schemas are only fetched on demand when they match a query. This means registering many tools doesn’t bloat the context window.

Claude Code shows a warning when tools exceed 10% of the context window. With deferred loading, this isn’t an issue even with all tools enabled.

The uvx command runs the server in a temporary environment without requiring a persistent installation. See Running in a Temporary Environment for more details.

Note: You can find instructions on how to obtain a Gcore API Key here.

Optional variables:

  • GCORE_BASE_URL: “https://api.gcore.com”,
  • GCORE_CLOUD_PROJECT_ID: “1”,
  • GCORE_CLOUD_REGION_ID: “76”,
  • GCORE_CLIENT_ID: “2”,
  • GCORE_ALLOWED_HOSTS: “” (HTTP transport only; loopback names always allowed)
  • GCORE_ALLOWED_ORIGINS: “” (HTTP transport only)

HTTP transport security

The HTTP transport (GCORE_TRANSPORT=http) validates the Host and Origin headers of every request, as required by the MCP Streamable HTTP specification.

在 GitHub 查看完整 README

安装

uvx --from gcore-mcp-server@git+https://github.com/G-Core/gcore-mcp-server.git gcore-mcp-server
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "gcore-mcp-server": { "command": "uvx", "args": ["--from", "gcore-mcp-server@git+https://github.com/G-Core/gcore-mcp-server.git", "gcore-mcp-server"], "env": { "GCORE_API_KEY": "4***1", "GCORE_TOOLS": "instances,management,cloud.gpu_baremetal.clusters.*" } } } }