Skip to main content
Glama
Buu-AI

Buu AI MCP Server

genrequest_get_all

Retrieve all GenRequests associated with a specific subthread ID on the Buu AI MCP Server to manage and organize team data efficiently.

Instructions

[PRIVATE] - Get all team's GenRequests by subthread ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
subthreadIdYesSubthread ID to retrieve all associated GenRequests

Implementation Reference

  • The handler function that executes the 'genrequest_get_all' tool logic: performs a GraphQL query using getSubthreadGenRequestsQuery for the given subthreadId and returns the JSON response or an error.
    async ({ subthreadId }) => {
      try {
        const response = await client.request(getSubthreadGenRequestsQuery, {
          subthreadId,
        });
        return { content: [{ type: 'text', text: JSON.stringify(response) }] };
      } catch (error) {
        console.error('Error calling genrequest_get_all:', error);
        return {
          isError: true,
          content: [
            {
              type: 'text',
              text: `Error: Failed to retrieve GenRequests. ${error}`,
            },
          ],
        };
      }
    }
  • Input schema using Zod for the 'genrequest_get_all' tool, defining the required subthreadId parameter.
    {
      subthreadId: z.string().describe('Subthread ID to retrieve all associated GenRequests'),
    },
  • Registration of the 'genrequest_get_all' tool on the MCP server using server.tool(), including description, input schema, and handler function.
    server.tool(
      'genrequest_get_all',
      "[PRIVATE] - Get all team's GenRequests by subthread ID",
      {
        subthreadId: z.string().describe('Subthread ID to retrieve all associated GenRequests'),
      },
      async ({ subthreadId }) => {
        try {
          const response = await client.request(getSubthreadGenRequestsQuery, {
            subthreadId,
          });
          return { content: [{ type: 'text', text: JSON.stringify(response) }] };
        } catch (error) {
          console.error('Error calling genrequest_get_all:', error);
          return {
            isError: true,
            content: [
              {
                type: 'text',
                text: `Error: Failed to retrieve GenRequests. ${error}`,
              },
            ],
          };
        }
      }
    );
  • GraphQL query definition 'getSubthreadGenRequestsQuery' used by the genrequest_get_all handler to fetch GenRequests for a subthread.
    const getSubthreadGenRequestsQuery = gql`
      query GetSubthreadGenRequests($subthreadId: String!) {
        getSubthreadGenRequests(subthreadId: $subthreadId) {
          ... on GenRequestsPage {
            items {
              _id
              subthreadId
              teamId
              status
              metadata
              type
              images {
                alt
                keyS3
                size
                type
                url
              }
              model_mesh {
                alt
                keyS3
                size
                type
                url
              }
              timings {
                inference
              }
              credits
              createdAt
              updatedAt
              address
            }
            metadata {
              limit
              offset
              orderBy
              orderDirection
              numElements
              total
              page
              pages
            }
          }
          ... on HandledError {
            code
            message
          }
        }
      }
    `;
  • src/index.ts:47-47 (registration)
    Invocation of registerGenRequestTools which registers the genrequest_get_all tool (among others) to the MCP server instance.
    registerGenRequestTools(server, buuServerClient);
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. It indicates a read operation ('Get') but doesn't specify permissions, rate limits, pagination, or return format. The '[PRIVATE]' tag adds some context about access restrictions, but details are sparse, making it inadequate for a tool with no annotation coverage.

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, efficient sentence that front-loads key information ('Get all team's GenRequests'). The '[PRIVATE]' tag is placed upfront for immediate context. However, it could be slightly more structured by separating the access note from the core functionality.

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, no output schema, and a single parameter with full schema coverage, the description is incomplete. It lacks details on behavioral traits like permissions or return values, and doesn't compensate for the absence of structured fields, making it insufficient for effective tool invocation in a complex environment.

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 the parameter 'subthreadId' fully documented in the schema. The description adds minimal value by reiterating the parameter's role ('by subthread ID'), but doesn't provide additional syntax, format, or examples beyond what the schema already states, meeting the baseline for high coverage.

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 ('all team's GenRequests'), specifying the scope ('by subthread ID'). It distinguishes from siblings like 'subthread_get' or 'team_get_all' by focusing on GenRequests within a subthread. However, it doesn't fully explain what GenRequests are, leaving some ambiguity.

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 when needing all GenRequests for a specific subthread ID, but provides no explicit guidance on when to use this versus alternatives like 'subthread_get' or 'generate_image'. It lacks prerequisites, exclusions, or named alternatives, leaving usage context inferred rather than clearly defined.

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

Related 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/Buu-AI/buu-mcp-server'

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