Skip to main content
Glama
mcp-synology

mcp-synology

list_files

Read-only

Lists files and folders directly inside a Synology folder, one level deep, with name pattern filtering, sorting and paging. Use it to browse a directory's contents before searching deeper.

Instructions

List the files and folders directly inside one folder (one level; subfolders' contents aren't listed). To find files anywhere below a folder by name, extension, size or date, use search_files. Folders show no size; for a folder's total, use get_dir_size. DSM sorts folders and files separately: ascending lists folders first, descending files first. A long listing is paged, and the reply says which offset is next.

Input Schema

NameRequiredDescriptionDefault
pathYesThe folder to list (`/video/TV Shows`).
limitNoMost items to return; `0` returns them all.
offsetNoItems to skip; a reply with more says which offset is next.
patternNoName filter, case-insensitive: a bare word matches anywhere in the name; with `*` or `?` the whole name must match (`*.mkv`); commas separate alternatives (`*.mkv,*.mp4`).
sort_byNo`name` (default), `size`, `mtime` (modified), `crtime` (created), `atime` (accessed), `ctime` (changed), `user` (the owner) or `type`.name
filetypeNo`all` (default), `file` or `dir`.all
sort_directionNo`asc` (default) or `desc`.asc

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed8 schema fields changedv0.9.1
    • addedInput schema / properties / filetype / description
      Added value: +"`all` (default), `file` or `dir`."
    • addedInput schema / properties / limit / description
      Added value: +"Most items to return; `0` returns them all."
    • addedInput schema / properties / offset / description
      Added value: +"Items to skip; a reply with more says which offset is next."
    • addedInput schema / properties / path / description
      Added value: +"The folder to list (`/video/TV Shows`)."
    • addedInput schema / properties / pattern / description
      Added value: +"Name filter, case-insensitive: a bare word matches anywhere in the name; with `*` or `?` the whole name must match (`*.mkv`); commas separate alternatives (`*.mkv,*.mp4`)."
    • addedInput schema / properties / sort_by / description
      Added value: +"`name` (default), `size`, `mtime` (modified), `crtime` (created), `atime` (accessed), `ctime` (changed), `user` (the owner) or `type`."
    • addedInput schema / properties / sort_direction / description
      Added value: +"`asc` (default) or `desc`."
    • changedOutput schema / (root)
      Previous value: -{
      -  "properties": {
      -    "result": {
      -      "title": "Result",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "result"
      -  ],
      -  "title": "tool_list_filesOutput",
      -  "type": "object"
      -}New value: +null
  2. Changed1 schema field changedv0.8.0
    • removedInput schema / properties / additional
      Removed value: -{
      -  "items": {
      -    "type": "string"
      -  },
      -  "type": "array"
      -}
  3. Changed12 schema fields changedv0.7.0
    • addedInput schema / properties / additional
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • removedInput schema / properties / filetype / title
      Removed value: -"Filetype"
    • removedInput schema / properties / limit / title
      Removed value: -"Limit"
    • removedInput schema / properties / offset / title
      Removed value: -"Offset"
    • removedInput schema / properties / path / title
      Removed value: -"Path"
    • removedInput schema / properties / pattern / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • removedInput schema / properties / pattern / default
      Removed value: -null
    • removedInput schema / properties / pattern / title
      Removed value: -"Pattern"
    • addedInput schema / properties / pattern / type
      Added value: +"string"
    • removedInput schema / properties / sort_by / title
      Removed value: -"Sort By"
    • removedInput schema / properties / sort_direction / title
      Removed value: -"Sort Direction"
    • removedInput schema / title
      Removed value: -"tool_list_filesArguments"
  4. First observedv0.4.1

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already cover the read-only, non-destructive profile, and the description adds genuinely non-obvious behavior: DSM sorts folders and files in separate groups (so ascending puts folders first, descending files first) and long listings are paged with the next offset reported in the reply. It stops short of describing per-item fields or permission/error behavior, so not a 5.

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 compact sentences, each earning its place: scope first, alternatives second, output caveats third, sorting/paging last. No filler or restatement of the tool name.

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?

With no output schema, the description supplies the key return-shape facts an agent needs (paged results, next offset, folders have no size), which is exactly the right compensation. It omits what other per-item fields come back, a minor gap for a read-only listing tool with full parameter documentation.

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 coverage is 100%, so the baseline is 3, but the description adds meaning the schema cannot: the folder-vs-file sort grouping that determines what sort_direction actually yields, and the paging contract tying limit/offset to the reported next offset. Pattern and filetype semantics are left to the schema.

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+resource ('List the files and folders') and immediately bounds scope ('directly inside one folder (one level; subfolders' contents aren't listed)'). It also names the sibling it is not (search_files for recursive lookups), so an agent can distinguish it without opening any schema.

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

Usage Guidelines5/5

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

Explicitly routes to alternatives with conditions: use search_files to find files anywhere below by name/extension/size/date, and get_dir_size for a folder's total size. It also pre-empts a likely misuse by noting folders report no size.

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