Skip to main content
Glama

trash_get_quality_sizes

Retrieve TRaSH Guides recommended file size ranges for media quality levels in Radarr or Sonarr to optimize storage and quality settings.

Instructions

Get TRaSH Guides recommended min/max/preferred sizes for each quality level

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
serviceYesWhich service
typeNoContent type: 'movie', 'anime' for Radarr; 'series', 'anime' for Sonarr

Implementation Reference

  • Core handler function in TrashClient that fetches, caches, and returns TRaSH quality size recommendations for movies/series/anime from GitHub JSON files.
    async getQualitySizes(service: TrashService, type?: string): Promise<TrashQualitySize[]> {
      const sizeTypes = service === 'radarr'
        ? ['movie', 'anime']
        : ['series', 'anime'];
    
      const sizes: TrashQualitySize[] = [];
    
      for (const sizeType of sizeTypes) {
        const key = `${service}/${sizeType}`;
        let size = cache.getQualitySize(key);
    
        if (!size) {
          try {
            size = await fetchJSON<TrashQualitySize>(
              `${TRASH_BASE_URL}/${service}/quality-size/${sizeType}.json`
            );
            cache.setQualitySize(key, size);
          } catch {
            continue;
          }
        }
    
        if (!type || size.type === type) {
          sizes.push(size);
        }
      }
    
      return sizes;
    }
  • MCP server request handler for the tool call, which extracts parameters, invokes trashClient.getQualitySizes, formats the output, and returns the response.
    case "trash_get_quality_sizes": {
      const { service, type } = args as { service: TrashService; type?: string };
      const sizes = await trashClient.getQualitySizes(service, type);
      return {
        content: [{
          type: "text",
          text: JSON.stringify({
            service,
            type: type || 'all',
            profiles: sizes.map(s => ({
              type: s.type,
              qualities: s.qualities.map(q => ({
                quality: q.quality,
                min: q.min + ' MB/min',
                preferred: q.preferred === 1999 ? 'unlimited' : q.preferred + ' MB/min',
                max: q.max === 2000 ? 'unlimited' : q.max + ' MB/min',
              })),
            })),
          }, null, 2),
        }],
      };
    }
  • src/index.ts:673-689 (registration)
    Registration of the tool in the MCP TOOLS array, defining the name, description, and input schema.
    name: "trash_get_quality_sizes",
    description: "Get TRaSH Guides recommended min/max/preferred sizes for each quality level",
    inputSchema: {
      type: "object" as const,
      properties: {
        service: {
          type: "string",
          enum: ["radarr", "sonarr"],
          description: "Which service",
        },
        type: {
          type: "string",
          description: "Content type: 'movie', 'anime' for Radarr; 'series', 'anime' for Sonarr",
        },
      },
      required: ["service"],
    },
  • TypeScript interface defining the structure of quality size data returned by the tool.
    export interface TrashQualitySize {
      trash_id: string;
      type: string;
      qualities: Array<{
        quality: string;
        min: number;
        preferred: number;
        max: number;
      }>;
    }
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. While it indicates this is a read operation ('Get'), it doesn't describe important behavioral aspects like whether this requires authentication, what format the output returns, if there are rate limits, or whether the data is cached. The description is functional but lacks operational context.

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 communicates the core purpose without any wasted words. It's appropriately sized for a simple lookup tool and front-loads the essential information immediately.

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?

Given this is a read-only tool with 2 parameters (100% schema coverage) but no output schema, the description adequately covers the purpose but leaves gaps. Without annotations or output schema, the description should ideally mention what the return format looks like (e.g., structured quality data) or any important constraints. It's minimally complete but could provide more operational context.

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 schema already fully documents both parameters with descriptions and enums. The description doesn't add any additional parameter semantics beyond what's in the schema. According to scoring rules, when schema coverage is high (>80%), the baseline is 3 even with no param info in the description.

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 clearly states the specific action ('Get'), the resource ('TRaSH Guides recommended min/max/preferred sizes'), and the target ('for each quality level'). It distinguishes itself from sibling tools like 'trash_get_naming' or 'trash_get_profile' by focusing specifically on quality size recommendations rather than naming conventions or profile configurations.

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

Usage Guidelines3/5

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

The description implies usage context (when working with TRaSH Guides for quality sizing), but doesn't explicitly state when to use this tool versus alternatives like 'trash_get_profile' or service-specific quality profile tools. It mentions the purpose but lacks explicit guidance on prerequisites or exclusion criteria.

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