Skip to main content
Glama
mcp-synology

mcp-synology

get_dir_size

Read-only

Calculate the total size of a folder and everything below it, including file and folder counts, to answer how much space a directory uses on your Synology NAS.

Instructions

Calculate the total size of a folder, including everything below it: total size, file count and folder count. This is the tool for 'how much space does X use' questions. Counts only what this DSM user can read: a subfolder it can't read is left out without notice. A very large tree can take minutes, and the call gives up after a timeout (120 s unless the server is configured otherwise).

Input Schema

NameRequiredDescriptionDefault
pathYesThe folder to measure (`/video/TV Shows`).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.9.1
    • addedInput schema / properties / path / description
      Added value: +"The folder to measure (`/video/TV Shows`)."
    • changedOutput schema / (root)
      Previous value: -{
      -  "properties": {
      -    "result": {
      -      "title": "Result",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "result"
      -  ],
      -  "title": "tool_get_dir_sizeOutput",
      -  "type": "object"
      -}New value: +null
  2. Changed2 schema fields changedv0.7.0
    • removedInput schema / properties / path / title
      Removed value: -"Path"
    • removedInput schema / title
      Removed value: -"tool_get_dir_sizeArguments"
  3. First observedv0.4.1

TDQS

A4.5/5.0
Behavior5/5

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

Annotations only declare read-only/non-destructive; the description adds genuinely non-obvious behavior: permission-scoped counting with silent omission of unreadable subfolders, runtime that can reach minutes on large trees, and a 120 s timeout that aborts the call. These are exactly the operational facts an agent needs before invoking it.

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?

Four sentences in priority order: what it computes, when to reach for it, the permission caveat, then the performance/timeout caveat. No repetition of the schema or the annotations.

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

Completeness5/5

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

No output schema exists, so the description compensates by naming the three returned metrics, and it also covers the two failure modes an agent must anticipate (unreadable subfolders, timeout). Nothing material is left undefined for a one-parameter read 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?

There is a single required parameter and schema coverage is 100%, with the schema already supplying an example path, so the schema carries the load. The description adds no format, path-relative, or permission detail about the argument beyond what is structured, so the 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?

States a specific verb and resource ('Calculate the total size of a folder') and enumerates the three values returned (total size, file count, folder count), which separates it from get_file_info and list_files. The scope 'including everything below it' makes the recursive nature explicit.

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?

Explicitly frames the trigger question ('how much space does X use'), giving a clear context for selection. It does not name a sibling alternative or an exclusion (e.g., use get_file_info for a single file's size), so it falls short of a full when/when-not routing statement.

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