Skip to main content
Glama

Rename or move a file

files_rename
Destructive

Rename or MOVE a file or directory: from and to are paths relative to root, and may point into different directories. To move several items into a folder in one call, use files.move.

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": {
      "id": "<id>",
      "root": "<root>",
      "from": "<from>",
      "to": "<to>"
    },
    "name": "files_rename"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYes
toYesNew path, e.g. 'main.py' to move it to the root.
fromYesCurrent path, e.g. 'app/main.py'.
rootYesDirectory both paths are relative to. Default '/'./

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.9/5.0
Behavior3/5

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

The annotations already declare this is destructive, non-read-only, and non-idempotent, so the safety profile is mostly supplied structurally. The description adds useful cross-directory move semantics, but it does not disclose overwrite behavior, permission requirements, or what happens if the destination 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.

Conciseness5/5

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

The description is two short sentences with the core operation front-loaded and the exception/alternative clearly appended. There is no redundant wording or unnecessary setup.

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?

For a destructive mutation with no output schema, the description covers the basic action and path semantics but leaves important behavioral details unstated, especially destination collision handling and failure modes. It is adequate for selection and basic invocation but not fully 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 coverage is 75%, with `to`, `from`, and `root` already documented in the input schema. The description reinforces that both paths are relative to root and can point into different directories, but it does not explain the `id` parameter or add much beyond the schema for the documented fields.

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 states a specific operation on a specific resource: rename or move a file or directory. It also clarifies that paths are relative to root and may cross directories, which distinguishes it from a simple same-directory rename.

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 explicitly routes bulk item moves to `files.move`, giving a clear alternative for that case. However, it does not cover other decision points such as whether destination overwrites are allowed or when to use this instead of copy/delete workflows.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources