Skip to main content
Glama

lidarr_get_root_folders

Retrieve root folder paths, storage capacity, and unmapped directories from Lidarr for music library management and organization.

Instructions

Get root folders and storage info from Lidarr (Music). Shows paths, free space, and unmapped folders.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • src/index.ts:127-135 (registration)
    Tool registration definition for lidarr_get_root_folders (template used when lidarr is configured). Includes name, description, and input schema (empty object).
      name: `${serviceName}_get_root_folders`,
      description: `Get root folders and storage info from ${displayName}. Shows paths, free space, and unmapped folders.`,
      inputSchema: {
        type: "object" as const,
        properties: {},
        required: [],
      },
    },
    {
  • src/index.ts:177-177 (registration)
    Call to addConfigTools for Lidarr, which registers the lidarr_get_root_folders tool.
    if (clients.lidarr) addConfigTools('lidarr', 'Lidarr (Music)');
  • MCP tool call handler for lidarr_get_root_folders. Dispatches to LidarrClient.getRootFoldersDetailed(), formats response with folder details including free space and unmapped folders count.
    // Root folders
    case "sonarr_get_root_folders":
    case "radarr_get_root_folders":
    case "lidarr_get_root_folders":
    case "readarr_get_root_folders": {
      const serviceName = name.split('_')[0] as keyof typeof clients;
      const client = clients[serviceName];
      if (!client) throw new Error(`${serviceName} not configured`);
      const folders = await client.getRootFoldersDetailed();
      return {
        content: [{
          type: "text",
          text: JSON.stringify({
            count: folders.length,
            folders: folders.map(f => ({
              id: f.id,
              path: f.path,
              accessible: f.accessible,
              freeSpace: formatBytes(f.freeSpace),
              freeSpaceBytes: f.freeSpace,
              unmappedFolders: f.unmappedFolders?.length || 0,
            })),
          }, null, 2),
        }],
      };
    }
  • Core implementation: LidarrClient.getRootFoldersDetailed() fetches root folders from Lidarr API endpoint /rootfolder (uses v1 API).
    async getRootFoldersDetailed(): Promise<RootFolder[]> {
      return this.request<RootFolder[]>('/rootfolder');
    }
  • Type definition for RootFolder used in getRootFoldersDetailed() response.
    export interface RootFolder {
      id: number;
      path: string;
      accessible: boolean;
      freeSpace: number;
      unmappedFolders?: Array<{ name: string; path: string }>;
    }
Behavior3/5

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

With no annotations provided, the description carries the full burden. It discloses what information is returned ('paths, free space, and unmapped folders'), which is useful behavioral context. However, it doesn't mention whether this is a read-only operation, potential rate limits, authentication requirements, or error conditions.

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 a single, efficient sentence that front-loads the core purpose ('Get root folders and storage info') and adds specific details about what information is shown. Every word earns its place with no redundancy or wasted space.

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 zero-parameter tool with no output schema, the description provides adequate information about what the tool does and what data it returns. However, without annotations or output schema, it could benefit from more behavioral context about the operation's safety, response format, or potential limitations.

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?

The tool has zero parameters with 100% schema description coverage, so the baseline is 4. The description appropriately doesn't discuss parameters since none exist, and it focuses on the tool's purpose and output instead.

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?

The description clearly states the tool's purpose with specific verbs ('Get root folders and storage info') and resource ('from Lidarr (Music)'), distinguishing it from general Lidarr tools. However, it doesn't explicitly differentiate from sibling root folder tools like 'radarr_get_root_folders' or 'readarr_get_root_folders' beyond mentioning Lidarr specifically.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites, appropriate contexts, or compare it to other Lidarr tools like 'lidarr_get_albums' or 'lidarr_get_artists' that might provide related information.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/aplaceforallmystuff/mcp-arr'

If you have feedback or need assistance with the MCP directory API, please join our Discord server