Skip to main content
Glama

get_root_suites

Retrieve top-level test suites without parent structures from a Zebrunner project to organize and manage test cases effectively.

Instructions

🌳 Get root suites (suites with no parent) from project

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_keyYesProject key (e.g., 'android' or 'ANDROID')
formatNoOutput formatjson

Implementation Reference

  • The primary handler method in ZebrunnerToolHandlers class that implements the get_root_suites tool logic: fetches root suites from API client, enriches with hierarchy information, formats the output, and returns MCP-compatible content response.
    async getRootSuites(projectKey: string, format: OutputFormat = 'json') {
      try {
        const rootSuites = await this.client.getRootSuites(projectKey);
        const enrichedSuites = HierarchyProcessor.enrichSuitesWithHierarchy(rootSuites);
        const formattedData = FormatProcessor.format(enrichedSuites, format);
        
        return {
          content: [
            {
              type: "text" as const,
              text: typeof formattedData === 'string' ? formattedData : JSON.stringify(formattedData, null, 2)
            }
          ]
        };
      } catch (error: any) {
        return {
          content: [
            {
              type: "text" as const,
              text: `Error retrieving root suites: ${error.message}`
            }
          ]
        };
      }
  • MCP server tool registration for 'get_root_suites', including inline Zod input schema validation and handler invocation.
    server.tool(
      "get_root_suites",
      "Get only root-level test suites with hierarchy information",
      {
        projectKey: z.string().min(1),
        format: z.enum(['dto', 'json', 'string']).default('json')
      },
      async (args) => toolHandlers.getRootSuites(args.projectKey, args.format)
    );
  • Inline Zod schema defining input parameters for get_root_suites tool: projectKey (required string) and format (optional enum).
      projectKey: z.string().min(1),
      format: z.enum(['dto', 'json', 'string']).default('json')
    },
  • API client helper method that retrieves all test suites and filters to root-level ones (no parentSuiteId), called by the main handler.
    async getRootSuites(projectKey: string): Promise<ZebrunnerTestSuite[]> {
      const allSuites = await this.getAllTestSuites(projectKey);
      return allSuites.filter(suite => !suite.parentSuiteId);
    }
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It implies a read-only operation ('Get') but doesn't specify permissions, rate limits, pagination, or error handling. The description adds minimal context beyond the basic action, leaving gaps in understanding how the tool behaves in practice.

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 with no wasted words. It front-loads the core purpose ('Get root suites') and includes a relevant emoji for visual clarity. Every element earns its place, making it easy to scan and understand quickly.

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 read-only tool with 2 parameters and 100% schema coverage but no output schema, the description is minimally adequate. It states what the tool does but lacks details on return values, error cases, or integration with sibling tools. Without annotations or output schema, more behavioral context would improve completeness, but it meets the basic threshold.

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 fully documents both parameters (project_key and format). The description doesn't add any meaning beyond what the schema provides, such as explaining the significance of 'root suites' in relation to parameters. Baseline 3 is appropriate as the schema handles parameter documentation adequately.

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 action ('Get') and resource ('root suites from project'), specifying that root suites are those with no parent. It distinguishes from siblings like 'get_all_subsuites' or 'get_suite_hierarchy' by focusing on root-level suites only. However, it doesn't explicitly contrast with these siblings in the text.

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 like 'get_all_subsuites', 'get_suite_hierarchy', or 'list_test_suites'. It lacks context about prerequisites, such as needing a valid project key, and doesn't mention any exclusions or specific scenarios where this tool is preferred.

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/maksimsarychau/mcp-zebrunner'

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