Skip to main content
Glama

workspace__ExecuteScriptOrCommand

Executes scripts or commands in batch across workspace resources, with optional gray rollout controls to run on a subset and stop when failures reach a threshold.

Instructions

[WORKSPACE] 批量执行脚本或命令。

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "project_id": "<project_id>"
    },
    "name": "workspace__ExecuteScriptOrCommand"
  }
}

Input Schema

NameRequiredDescriptionDefault
gray_countNo灰度资源数量。
project_idYes项目ID。
script_idsNo执行的脚本列表。
resource_idsNo执行脚本的资源列表。
resource_typeNo资源类型,如桌面(DESKTOP)。
execution_timeoutNo执行脚本的超时时间,单位分钟。
gray_resource_idsNo灰度执行脚本的资源列表。
gray_fail_thresholdNo灰度失败阈值,达到阈值后停止进行下一批资源执行脚本,小于gray_count。

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

C2.5/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden, yet it says nothing beyond 'batch execute'. It omits whether execution is destructive or reversible, what permissions or authorization are needed, how the gray/canary parameters (gray_count, gray_fail_threshold, gray_resource_ids) change behavior mid-run, and what happens when the timeout is hit.

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?

It is a single short sentence with no wasted wording and the batch scope is front-loaded, but it is under-specified rather than concise — no structure or detail orients the agent before it opens the schema.

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?

For an eight-parameter execution tool with canary/gray semantics, no annotations, and no output schema, the description is far too thin: it does not explain the interplay between resource_ids and gray_resource_ids, the failure-threshold behavior, or what the call returns.

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%, so all eight parameters are already documented in the schema, including the gray-release fields. The description adds no meaning beyond that, so the baseline of 3 applies.

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

Purpose3/5

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

The description gives a verb plus resource ('批量执行脚本或命令') and the [WORKSPACE] tag scopes it, but it is ambiguous: the schema only exposes script_ids and resource_ids, with no 'command' parameter, and it never distinguishes the tool from close siblings such as workspace__ExecuteDesktopPoolScript or coc__ExecuteScript.

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?

There is no statement of when to use this tool versus the many sibling execution tools, no prerequisites, and no mention of when a single-resource or desktop-pool execution tool would be more appropriate.

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

Deploy Server

Other Tools