Skip to main content
Glama

Search media files

search-media-files
Read-onlyIdempotent

Find media filenames in Anki's collection.media folder using glob patterns, with limit and offset paging for sorted results.

Instructions

Returns a bounded, sorted page of filenames from Anki's current collection.media folder.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "search-media-files"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNo
offsetNo
patternNoAnkiConnect glob pattern such as "*.mp3", "_logo*", or "gehen*"*

Output Schema

NameRequiredDescriptionDefault
filesYes
totalYes
offsetYes
hasMoreYes
patternYes
returnedYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

B3.1/5.0
Behavior3/5

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

The annotations already declare readOnly, idempotent, non-destructive, and closed-world, so the safety profile is covered. The description adds useful behavior: results are a bounded, sorted page rather than an unbounded dump. It does not state the sort key, how the glob matches case or paths, or what an invalid pattern yields.

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?

A single front-loaded sentence with zero filler. The return shape (bounded, sorted page of filenames) and the scope (collection.media) are stated up front and nothing is repeated from annotations or schema.

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?

With an output schema present and rich read-only annotations, the description needn't explain return values or safety. However, for a three-parameter search tool it leaves out sorting behavior, glob semantics, and any routing guidance among closely related media siblings, which are the remaining gaps an agent would care about.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 33% — only 'pattern' carries a description (with glob examples) in the schema; limit and offset have only defaults and ranges. The description never mentions pagination parameters or the pattern glob, so it does not compensate for the coverage gap; 'bounded ... page' only faintly signals limit/offset.

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?

States a specific verb and resource: 'Returns a ... page of filenames from Anki's current collection.media folder.' The media-folder scope distinguishes it from search-cards/search-notes and from get-media-file or find-media-references, though it doesn't name those siblings explicitly.

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

Usage Guidelines2/5

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

There is no when-to-use guidance, no exclusions, and no pointer to alternatives such as find-media-references (for references) or get-media-file (for a single file). An agent must infer from the resource noun alone that this is a listing/search operation.

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