Skip to main content
Glama

list-projects

Retrieve all projects from QA Studio; optionally filter by project name for targeted results.

Instructions

List all projects in QA Studio

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
searchNoOptional search query to filter projects by name

Implementation Reference

  • src/index.ts:49-83 (registration)
    Registration of the 'list-projects' tool via server.registerTool(), including its input schema (optional 'search' parameter) and the async handler function
    // Register tool: list-projects
    server.registerTool(
      'list-projects',
      {
        description: 'List all projects in QA Studio',
        inputSchema: {
          search: z.string().optional().describe('Optional search query to filter projects by name')
        }
      },
      async (args) => {
        try {
          const { search } = args;
          const query = search ? `?search=${encodeURIComponent(search)}` : '';
          const data = await apiRequest(`/projects${query}`);
          return {
            content: [
              {
                type: 'text' as const,
                text: JSON.stringify(data, null, 2)
              }
            ]
          };
        } catch (error) {
          return {
            content: [
              {
                type: 'text' as const,
                text: `Error: ${error instanceof Error ? error.message : String(error)}`
              }
            ],
            isError: true
          };
        }
      }
    );
  • The handler function for 'list-projects' - calls the API endpoint /projects with an optional search query, returns the JSON response, or an error message on failure
    async (args) => {
      try {
        const { search } = args;
        const query = search ? `?search=${encodeURIComponent(search)}` : '';
        const data = await apiRequest(`/projects${query}`);
        return {
          content: [
            {
              type: 'text' as const,
              text: JSON.stringify(data, null, 2)
            }
          ]
        };
      } catch (error) {
        return {
          content: [
            {
              type: 'text' as const,
              text: `Error: ${error instanceof Error ? error.message : String(error)}`
            }
          ],
          isError: true
        };
      }
    }
  • Input schema for 'list-projects' defining an optional 'search' string parameter to filter projects by name
    {
      description: 'List all projects in QA Studio',
      inputSchema: {
        search: z.string().optional().describe('Optional search query to filter projects by name')
      }
  • The apiRequest helper function used by the handler to make authenticated API calls to the QA Studio backend
    // Helper function to make API requests
    async function apiRequest(endpoint: string, options: RequestInit = {}): Promise<any> {
      const url = `${API_URL}${endpoint}`;
      const response = await fetch(url, {
        ...options,
        headers: {
          'Content-Type': 'application/json',
          'X-API-Key': API_KEY,
          ...options.headers
        }
      });
    
      if (!response.ok) {
        const error = await response.text();
        throw new Error(`API Error (${response.status}): ${error}`);
      }
    
      return response.json();
    }
Behavior2/5

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

No annotations exist, so the description must convey behavioral traits. It only states 'List all projects,' implying a read operation, but fails to mention potential side effects, pagination, rate limits, or authorization needs.

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?

The description is a single, concise sentence with no unnecessary words. It could be slightly improved by noting the optional filter, but it is efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description lacks details about return values (e.g., project fields), pagination, or output format. Given the absence of an output schema and annotations, the description should provide more context to be complete.

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% with one optional parameter 'search' already described. The description adds no additional context beyond what the schema provides, so baseline score of 3 is appropriate.

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 (List) and resource (projects in QA Studio), distinguishing it from sibling tools like list-test-runs. The phrase 'all projects' is slightly misleading given the optional search parameter, but the overall purpose is clear.

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?

No guidance is provided on when to use this tool versus siblings (e.g., create-test-case, list-test-runs). The description does not indicate any alternative tools or conditions for use.

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/QAStudio-Dev/mcp-server'

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