Skip to main content
Glama

Copy file

copy_file
Destructive

Copies a file to a new path inside the vault while keeping the original; respects folder write policies and requires a rev to overwrite existing destinations.

Instructions

Copy a file to a new path inside the vault; the source stays. The destination follows the rules of write_file: overwriting an existing file needs its current rev in a zone with overwrite="rev" and is refused with overwrite="never"; read-only zones and the trash are refused. Directories are not copied.

Input Schema

NameRequiredDescriptionDefault
revNoCurrent rev of the destination file, required to overwrite it in a zone with overwrite="rev".
sourceYes
destinationYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.1.0

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the destructiveHint/readOnly annotations by disclosing overwrite=rev requirements, overwrite=never refusal, read-only zone and trash refusals, and that directories are not copied. This is exactly the behavioral context an agent needs for a destructive mutation.

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?

Two tight sentences, with the copy-vs-move distinction front-loaded and the overwrite/refusal rules following economically. No wasted phrasing.

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 mutation tool with no output schema, the description covers overwrite modes, refusal conditions, and directory limitation well. It stops short of describing the returned result (e.g., new path/rev), a minor omission.

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 only 33%, with source and destination undocumented in the schema. The description clarifies rev's role via the overwrite="rev" scenario, but source/destination are only implicitly defined by the tool's copy semantics, leaving modest gaps for the low coverage level.

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?

States the specific verb and resource (copy a file) and immediately clarifies 'the source stays,' which distinguishes it from the move_file sibling. An agent can select it without opening either schema.

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?

Explains the destination's overwrite semantics by referencing write_file and enumerates refusal cases (read-only zones, trash, directories). It implies when copy is appropriate but doesn't explicitly name move_file as the alternative when the source should be removed.

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