Skip to main content
Glama

get_project_descendants

Retrieve descendant projects from a WebSim project to explore related content and hierarchical relationships within the platform.

Instructions

Get projects that are descendants of a WebSim project

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idYesWebSim project ID
limitNoNumber of descendants to return (default: 20)
offsetNoNumber of descendants to skip (default: 0)

Implementation Reference

  • MCP tool handler for 'get_project_descendants'. Validates input with ProjectIdSchema, fetches descendants using apiClient, formats and returns JSON response.
    handler: async (args) => {
      const { project_id, limit = 20, offset = 0 } = ProjectIdSchema.parse(args);
      const result = await apiClient.getProjectDescendants(project_id, limit, offset);
      return {
        content: [{
          type: "text",
          text: JSON.stringify({
            success: true,
            data: result,
            message: `Successfully retrieved ${result.items?.length || 0} descendants for project ${project_id}`
          }, null, 2)
        }]
      };
  • Input schema defining parameters for get_project_descendants tool: project_id (required), optional limit and offset.
    inputSchema: {
      type: "object",
      properties: {
        project_id: {
          type: "string",
          description: "WebSim project ID"
        },
        limit: {
          type: "number",
          description: "Number of descendants to return (default: 20)",
          default: 20
        },
        offset: {
          type: "number",
          description: "Number of descendants to skip (default: 0)",
          default: 0
        }
      },
      required: ["project_id"]
  • server.js:436-472 (registration)
    Full tool registration in the tools array, including name, description, inputSchema, and handler reference for get_project_descendants.
    {
      name: "get_project_descendants",
      description: "Get projects that are descendants of a WebSim project",
      inputSchema: {
        type: "object",
        properties: {
          project_id: {
            type: "string",
            description: "WebSim project ID"
          },
          limit: {
            type: "number",
            description: "Number of descendants to return (default: 20)",
            default: 20
          },
          offset: {
            type: "number",
            description: "Number of descendants to skip (default: 0)",
            default: 0
          }
        },
        required: ["project_id"]
      },
      handler: async (args) => {
        const { project_id, limit = 20, offset = 0 } = ProjectIdSchema.parse(args);
        const result = await apiClient.getProjectDescendants(project_id, limit, offset);
        return {
          content: [{
            type: "text",
            text: JSON.stringify({
              success: true,
              data: result,
              message: `Successfully retrieved ${result.items?.length || 0} descendants for project ${project_id}`
            }, null, 2)
          }]
        };
      }
  • Core API helper method in WebSimAPIClient that constructs and executes the HTTP request to fetch project descendants with pagination.
    async getProjectDescendants(projectId, limit = 20, offset = 0) {
      const params = new URLSearchParams({ limit: limit.toString(), offset: offset.toString() });
      return this.makeRequest(`/api/v1/projects/${projectId}/descendants?${params}`);
    }
  • Shared Zod validation schema used by get_project_descendants handler (and others) to parse and validate the project_id parameter.
    const ProjectIdSchema = z.object({
      project_id: z.string().describe('WebSim project ID')
    });
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the action ('Get projects') but lacks details on permissions, rate limits, pagination behavior (beyond schema defaults), or response format. This is inadequate for a tool with parameters and no output schema.

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 directly states the tool's purpose without unnecessary words. It is front-loaded and appropriately sized for its function, with zero wasted content.

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?

Given no annotations and no output schema, the description is incomplete. It doesn't explain what 'descendants' entail (e.g., nested projects), return values, or error conditions. For a tool with parameters and potential complexity in hierarchical data, more context is needed to guide the agent effectively.

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 the parameters (project_id, limit, offset). The description adds no additional meaning beyond implying the tool operates on WebSim projects, which is already covered in the schema. Baseline 3 is appropriate as the schema handles parameter semantics effectively.

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 verb ('Get') and resource ('projects that are descendants of a WebSim project'), making the purpose understandable. It distinguishes from some siblings like 'get_project_by_id' or 'list_all_projects' by specifying descendant retrieval, though it doesn't explicitly differentiate from all similar tools like 'list_user_projects' in terms of scope.

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, exclusions, or compare it to sibling tools like 'list_all_projects' or 'list_user_projects' for context, leaving the agent to infer usage based on the name alone.

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/gigachadtrey/websimm'

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