Skip to main content
Glama
Tdarr MCP Server

Tdarr MCP Server

by OrellBuehler

scan_library

Start a Tdarr library file scan to add new files, rescan from scratch, or scan specific paths; use it to refresh library contents, then poll scanner status for progress.

Instructions

Start a file scan on a library (POST /api/v2/scan-files). 'scanFindNew' adds files not yet in the database, 'scanFresh' rescans everything from scratch, and 'scanFolderWatcher' scans a specific list of file paths. Scanning is asynchronous — poll get_scanner_status for progress.

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": {
      "library_id": "<library_id>",
      "mode": "<mode>"
    },
    "name": "scan_library"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeYesScan mode. scanFresh discards existing scan results for the library.
pathNoFolder to scan, for scanFresh and scanFindNew. Defaults to the library's own folder.
pathsNoExplicit list of file paths, required for scanFolderWatcher
library_idYesLibrary ID (dbID), from list_libraries

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.2.0
    • removedInput schema / additionalProperties
      Removed value: -false
  2. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations declare readOnlyHint=false and destructiveHint=false; the description goes beyond them by disclosing that the operation is asynchronous and must be followed by polling get_scanner_status. It also conveys that scanFresh rebuilds from scratch, which is behavioral context not obvious from the mode name alone. It does not state whether a scan can be canceled or what happens to in-flight results via a sibling tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

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

Three compact clauses: what it does, what the modes mean, and the async/polling follow-up — front-loaded with no filler. Slight overlap with the schema's own mode descriptions, but nothing wasted.

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 4-parameter, no-output-schema action tool this covers purpose, mode choice, and the required follow-up call, which is what an agent needs to invoke it correctly. Missing only edge-case behavior (scan already running, invalid path handling) that could otherwise force the agent to guess.

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 description coverage is 100%, so the enum and path/paths semantics are already documented in the input schema; the description largely restates them. It adds no new detail such as path format, absolute vs relative paths, or mutual exclusivity rules between path and paths.

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 gives a specific verb and resource ('Start a file scan on a library') plus the backing endpoint POST /api/v2/scan-files, then enumerates the three modes with a one-clause gloss for each. An agent can tell this apart from read-only siblings like get_scanner_status or scan_file_details without opening the 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?

Mode selection is effectively spelled out: scanFindNew for incremental adds, scanFresh for a full rescan, scanFolderWatcher for an explicit path list. It also says to poll get_scanner_status rather than wait, which routes the agent correctly after the call. No explicit 'do not use when' or precondition (e.g. library must exist / be idle) is given.

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