Skip to main content
Glama

CloudNet MCP 服务器

这是一个模型上下文协议 (MCP) 服务器,提供了对 CloudNet Service REST API v3 的接口访问。它使得 AI 助手能够安全准确地观测您的 CloudNet 节点和服务。

🌟 功能特性

  • 获取节点及信息: 列出所有集群节点并获取详细统计数据。

  • 管理服务: 列出活跃的智能服务,并可在服务器控制台上无缝执行命令 (execute_service_command)。

  • 玩家管理: 获取在线玩家 (get_online_players),查看详细的玩家资料 (get_player_info),将玩家从网络中踢出 (kick_player),发送消息 (send_player_message),以及通过代理或下游边界代表他们执行命令 (execute_player_command)。

基于 CloudNet Swagger 文档开发。

Related MCP server: RunCloud MCP Server

🛠 前置要求

  • Python 3.12+

  • uv 包管理器

📦 安装

git clone https://github.com/yourusername/cloudnet-mcp.git
cd cloudnet-mcp
uv sync

⚙️ 配置

运行前请设置以下环境变量:

  • CLOUDNET_URL: REST API 的 URL (默认为 http://127.0.0.1:2812/api/v3)

  • CLOUDNET_USER: 基本认证用户名

  • CLOUDNET_PASSWORD: 基本认证密码

🚀 运行

使用 uv:

uv run cloudnet-mcp

🔌 在 Claude Desktop 中使用

将此内容添加到您的 claude_desktop_config.json 中:

{
  "mcpServers": {
    "cloudnet": {
      "command": "uv",
      "args": [
        "--directory",
        "PATH/TO/YOUR/cloudnet-mcp",
        "run",
        "cloudnet-mcp"
      ],
      "env": {
        "CLOUDNET_URL": "http://127.0.0.1:2812/api/v3",
        "CLOUDNET_USER": "your_user",
        "CLOUDNET_PASSWORD": "your_password"
      }
    }
  }
}

CloudNet MCP 服务器

这是一个模型上下文协议 (MCP) 服务器,提供了对 CloudNet Service REST API v3 的接口访问支持。它使得 AI 助手能够安全准确地观测您的 CloudNet 节点和服务。

🌟 功能特性

  • 获取节点列表及信息: 查看整个 CloudNet 集群内所有节点的详细统计数据和信息

  • 管理服务 (Services): 获取运行中的智能服务列表,支持在服务端控制台远程异步执行命令 (execute_service_command)

  • 玩家管理与交互 (Player Management): 查询在线玩家列表或通过唯一下位码查询 (get_online_players, get_player_info)、全局踢出玩家 (kick_player)、互发消息聊天 (send_player_message) 以及代替玩家执行代理层或子服命令 (execute_player_command)

基于 CloudNet 官方 Swagger API 文档开发.

🛠 前置要求

  • Python 3.12 及以上版本

  • uv 包管理器

📦 安装指南

git clone https://github.com/yourusername/cloudnet-mcp.git
cd cloudnet-mcp
uv sync

⚙️ 参数配置

在运行前,请配置以下环境变量:

  • CLOUDNET_URL: CloudNet REST API 地址 (默认: http://127.0.0.1:2812/api/v3)

  • CLOUDNET_USER: 基本认证的用户名

  • CLOUDNET_PASSWORD: 基本认证的密码

🚀 运行方法

使用 uv:

uv run cloudnet-mcp

🔌 在 Claude Desktop 中使用

将以下配置添加至您的 claude_desktop_config.json:

{
  "mcpServers": {
    "cloudnet": {
      "command": "uv",
      "args": [
        "--directory",
        "PATH/TO/YOUR/cloudnet-mcp",
        "run",
        "cloudnet-mcp"
      ],
      "env": {
        "CLOUDNET_URL": "http://127.0.0.1:2812/api/v3",
        "CLOUDNET_USER": "您的用户名",
        "CLOUDNET_PASSWORD": "您的密码"
      }
    }
  }
}

Available Tools

9 tools
execute_player_commandC

Executes a command for a given player

NameRequiredDescriptionDefault
identifierYesThe name or unique id of the player
commandYesThe command to execute (without prefixing slash)
redirectToServerNoRedirect downstream if not found on proxy

TDQS

C2.8/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description is very brief and does not disclose behavioral traits such as permissions required, side effects, or whether the command execution is synchronized. No annotations are provided to compensate.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise (one sentence) but lacks important details. It is efficient but not sufficiently informative for an agent to fully understand usage.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema and no annotations, the description should provide more context about the behavior and return value. It is insufficient for a complete understanding of the tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema covers 100% of the parameters with descriptions. The tool description adds no additional meaning beyond what the schema already provides, so baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's action (execute a command) and target (a given player). It is a specific verb-resource pair, but does not distinguish from the sibling tool 'execute_service_command' which executes commands on a service.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives like kick_player or send_player_message. The description lacks any context for the agent to choose this tool over others.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

execute_service_commandC

Executes the specified command on a service console

NameRequiredDescriptionDefault
identifierYesThe name or unique id of the service
commandYesThe command to execute on the service

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided; the description only says 'executes the specified command', implying a write operation but no details on destructive potential, authorization needs, or side effects.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence of 8 words, very concise. It could be slightly improved with additional context while remaining brief.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the simplicity (2 params, no output schema, no annotations), the description is minimal and does not explain return values or behavior. Incomplete for safe invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% (both parameters have descriptions). The description adds no extra meaning beyond the schema, so baseline of 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('executes the specified command') and the target ('service console'). It distinguishes from sibling 'execute_player_command' by specifying 'service console', but does not explicitly differentiate.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use or not use this tool, nor any mention of prerequisites or alternatives. The description lacks context for decision-making.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_node_infoB

Get detailed information about a specific node

NameRequiredDescriptionDefault
node_idYesThe ID of the node

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description should disclose behavioral traits. It merely states the function without mentioning read-only nature, permissions, or any side effects, leaving the agent to infer from the verb 'get'.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

One sentence with no extraneous words. Highly efficient and front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite simplicity, the lack of output schema and any hint of what 'detailed information' includes makes the description incomplete. An agent cannot anticipate the return structure.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% with parameter description 'The ID of the node'. The tool description adds no additional context beyond the schema, baseline of 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Get detailed information about a specific node' clearly states the verb (Get) and resource (node), effectively distinguishing it from sibling 'get_nodes' which lists multiple nodes.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives like 'get_nodes' or 'get_player_info'. The description lacks context for tool selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_nodesA

List all nodes in the CloudNet cluster

NameRequiredDescriptionDefault

No parameters

TDQS

A3.5/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden for behavioral disclosure. It implies a read-only list operation but omits any details about authentication, rate limits, or error conditions. The simplicity partially excuses this, but more context would be beneficial.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, concise sentence that is front-loaded with the purpose. Every word adds value, and there is no wasted text.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (no parameters, no output schema), the description is minimally adequate. It states the purpose but does not hint at the return format or any limitations, which would be helpful for an agent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool has zero parameters and the schema description coverage is 100%. The description adds no parameter-level detail (none needed), and the baseline for 0 parameters is 4.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool lists all nodes in the CloudNet cluster, using a specific verb ('List') and resource ('nodes'). This distinguishes it from siblings like get_node_info which likely retrieves a single node.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like get_node_info, nor does it mention any prerequisites or contexts. It only states the basic function.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_online_playersB

Get a list of online players based on the query parameters

NameRequiredDescriptionDefault
limitNoThe maximum amount of players to respond with
skipNoThe amount of players to skip
sortNoSort players by name

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, and the description does not disclose behavioral traits such as authentication requirements, rate limits, or behavior when no players are online. It is simply a read operation, but lacks any additional context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence with no extraneous information. It is front-loaded and to the point.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is simple and has no output schema, but the description could be improved by noting that it returns a list of player objects or mentioning pagination behavior. It is adequate but not thorough.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% with descriptions for all three parameters (limit, skip, sort). The description adds no additional meaning beyond what is already in the schema, so baseline score of 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly identifies the action (get) and resource (online players), and implies filtering via query parameters. It distinguishes from siblings like get_player_info which returns a single player, but could be more specific about the scope.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool vs alternatives such as get_players (nonexistent) or other player-related tools. No exclusion criteria or context provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_player_infoB

Get a player by their unique id or name

NameRequiredDescriptionDefault
identifierYesThe name or unique id of the player

TDQS

B3.3/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, and description lacks details like read-only nature, permission requirements, or return format. Minimal behavioral disclosure.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence, 9 words, direct and efficient. No extraneous information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Adequate for a simple lookup tool, but lacks details about return value or scope. Could be more complete given no output schema and no annotations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema has 100% coverage; description merely restates the schema meaning. No additional semantic value beyond what the schema already provides.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states it retrieves a player by identifier (name or id). Distinguishes from siblings like get_online_players (multiple players) and get_nodes (different resource).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives. Does not mention that get_online_players is for listing multiple players or that execute_player_command is for actions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_servicesA

List all smart services

NameRequiredDescriptionDefault

No parameters

TDQS

A3.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description must fully disclose behavior. It only says 'List all smart services', implying a read-only operation, but does not explicitly state that it is non-destructive, has no side effects, or any other behavioral traits. The minimal information is insufficient.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence with no extra words. It is front-loaded and efficient, earning its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple list tool with no parameters and no output schema, the description provides the essential purpose. However, it could be slightly more complete by indicating that it returns a list of service identifiers or summaries, but the current level is adequate.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

There are no parameters, so the baseline score is 4. The description adds no parameter-specific information, which is acceptable given the absence of parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('List') and the resource ('all smart services'), making the purpose unambiguous. It distinguishes itself from sibling list tools by specifying 'services' rather than nodes, players, or other entities.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives like get_nodes or get_player_info. The description does not mention any conditions or context for use.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

kick_playerC

Kicks a given player from the entire network

NameRequiredDescriptionDefault
identifierYesThe name or unique id of the player
messageYesThe kick message/reason

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description must disclose behavioral traits. It only says 'kicks' without explaining effects (e.g., immediate disconnection), required permissions, or what happens to the player's session. Essential context is missing.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single clear sentence with no wasted words. It is front-loaded and easy to parse, though it sacrifices detail for brevity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite low complexity (2 required params, no output schema), the description fails to explain the tool's side effects or return behavior. For a destructive action like kicking, more context is needed, such as whether confirmation is required or if the action is irreversible.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema already covers both parameters with descriptions (identifier and message). The tool description adds no additional meaning beyond the schema, so it meets the baseline for 100% coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action (kicks) and the target (a given player from the entire network), which distinguishes it from sibling tools like send_player_message or get_online_players. However, it could be more specific about the scope (e.g., network vs server).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives such as execute_player_command or send_player_message. The description lacks context about prerequisites or appropriate scenarios.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

send_player_messageB

Sends a chat message to a given player

NameRequiredDescriptionDefault
identifierYesThe name or unique id of the player
messageYesThe chat message to send

TDQS

B3.3/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, and the description omits behavioral traits such as required permissions, player status checks, rate limits, or error handling.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence, no unnecessary words, perfectly efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema is provided, and the description does not explain return values or side effects. For a simple action, this is adequate but not complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and both parameters are clearly described. The tool description adds no extra meaning beyond the schema, meeting baseline expectation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states the verb ('sends') and resource ('chat message to a given player'), distinguishing it from sibling tools like kick_player or execute commands.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool vs alternatives, preconditions (e.g., player must be online), or when not to use it.

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.

  1. 9 tool updatesv0.1.0
    • First observedexecute_player_command
    • First observedexecute_service_command
    • First observedget_node_info
    • First observedget_nodes
    • First observedget_online_players
    • First observedget_player_info
    • First observedget_services
    • First observedkick_player
    • First observedsend_player_message

TDQS

A3.5/5.0

Scored across 9 tools

Disambiguation5/5

Each tool targets a distinct action: player vs service commands, node info vs list, player info vs online list, kick vs message. No overlap.

Naming Consistency5/5

All tools follow a consistent verb_noun pattern in snake_case: execute, get, kick, send. Naming is predictable.

Tool Count5/5

9 tools is well-scoped for a cluster management server covering nodes, services, and players. Feels complete without bloat.

Completeness4/5

Covers essential node listing/info, player operations, and service commands. Missing service lifecycle (create/delete) and node actions, but core workflows are present.

Maintenance

ActivityInactive
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers

  • A
    license
    B
    quality
    D
    maintenance
    Enables AI assistants to interact with and manage Minecraft servers through a standardized interface, supporting server monitoring, player management, log analysis, and command execution.
    11
    1
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Enables AI clients like Codex and Claude Code to manage Minecraft servers through the Exaroton API, including status, logs, crash diagnostics, player management, and guarded server actions with confirmation.
    MIT