Skip to main content
Glama

ugreen_restore_file

Restores a file or directory from the NAS recycle bin using a valid recycle_path from a deletion receipt or recycle listing; use dry_run only to preview, not confirm recovery.

Instructions

从回收站恢复一个 NAS 文件或目录,recycle_path 必须使用删除结果 data.receipt.final_path 或回收站列表返回的路径。dry_run 无法确认路径真的处于回收站,不能把预演当作已恢复。仅操作用户指定的对象;写操作失败后先查询当前状态,不自动重试。权限由绿联令牌与 NAS 账户决定。

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": {
      "recycle_path": "<recycle_path>"
    },
    "name": "ugreen_restore_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
dry_runNo
recycle_pathYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.0

TDQS

A4/5.0
Behavior4/5

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

Beyond the annotations (readOnlyHint=false, destructiveHint=false, idempotentHint=false), it discloses that dry_run does not verify the path is actually in the recycle bin, and prescribes querying current state after a write failure rather than auto-retrying. It also states that authorization depends on the UGREEN token and NAS account. It does not say what happens if the target path already exists.

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 action is front-loaded in the first clause, followed by path-provenance, dry_run caveat, failure policy, and permissions in a logical order. Dense but each sentence carries operational content; a slight tightening of the policy clauses would help.

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 two-parameter mutation with no output schema and no parameter descriptions, the definition covers provenance, dry-run semantics, failure handling, and authorization. Missing only the outcome when the destination already exists and any indication of what a successful restore returns.

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?

Schema description coverage is 0%, so the description must carry both parameters, and it largely does: recycle_path is tied to specific upstream sources (data.receipt.final_path or recycle-bin listing), and dry_run is defined by what it cannot confirm. Minor gap: no format/example for recycle_path beyond its provenance.

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 opens with a specific verb and resource ('从回收站恢复一个 NAS 文件或目录'), which is unambiguous and distinct from sibling operations like delete_file or file_stat. It does not explicitly name a sibling to contrast with, so it falls short of the top mark.

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

Usage Guidelines4/5

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

It gives concrete when-to-use constraints: recycle_path must originate from data.receipt.final_path or a recycle-bin listing, dry_run must not be treated as a completed restore, and only user-specified objects should be touched. It stops short of naming alternative tools (e.g., what to call to locate a path if neither source is available).

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