Skip to main content
Glama

bruno_list_requests

Retrieve all API requests from a Bruno collection to view and manage endpoints for testing and validation.

Instructions

List all requests in a Bruno collection

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
collectionPathYesPath to the Bruno collection

Implementation Reference

  • The ListRequestsHandler class implements the IToolHandler interface for the 'bruno_list_requests' tool. It validates input, performs security checks, lists requests using BrunoCLI, and formats the output.
    export class ListRequestsHandler implements IToolHandler {
      private readonly brunoCLI: IBrunoCLI;
      private readonly formatter: RequestListFormatter;
    
      constructor(brunoCLI: IBrunoCLI) {
        this.brunoCLI = brunoCLI;
        this.formatter = new RequestListFormatter();
      }
    
      getName(): string {
        return 'bruno_list_requests';
      }
    
      async handle(args: unknown): Promise<ToolResponse> {
        const params = ListRequestsSchema.parse(args);
    
        // Security validation
        const validation = await validateToolParameters({
          collectionPath: params.collectionPath
        });
    
        if (!validation.valid) {
          logSecurityEvent({
            type: 'access_denied',
            details: `List requests blocked: ${validation.errors.join(', ')}`,
            severity: 'error'
          });
          throw new McpError(
            ErrorCode.InvalidRequest,
            `Security validation failed: ${validation.errors.join(', ')}`
          );
        }
    
        const requests = await this.brunoCLI.listRequests(params.collectionPath);
    
        return {
          content: [
            {
              type: 'text',
              text: this.formatter.format(requests)
            } as TextContent
          ]
        };
      }
    }
  • Zod schema for validating input parameters of the bruno_list_requests handler.
    const ListRequestsSchema = z.object({
      collectionPath: z.string().describe('Path to the Bruno collection')
    });
  • MCP protocol tool schema definition for 'bruno_list_requests' including input schema.
    {
      name: 'bruno_list_requests',
      description: 'List all requests in a Bruno collection',
      inputSchema: {
        type: 'object',
        properties: {
          collectionPath: {
            type: 'string',
            description: 'Path to the Bruno collection'
          }
        },
        required: ['collectionPath']
      }
    },
  • src/index.ts:284-298 (registration)
    Registration of all tool handlers in the ToolRegistry, including ListRequestsHandler for 'bruno_list_requests'.
    private registerToolHandlers(): void {
      const container = getContainer();
      const perfManager = container.get<PerformanceManager>(ServiceKeys.PERFORMANCE_MANAGER);
    
      // Register all tool handlers
      this.toolRegistry.register(new RunRequestHandler(this.brunoCLI));
      this.toolRegistry.register(new RunCollectionHandler(this.brunoCLI));
      this.toolRegistry.register(new ListRequestsHandler(this.brunoCLI));
      this.toolRegistry.register(new HealthCheckHandler(this.brunoCLI, this.configLoader, perfManager));
      this.toolRegistry.register(new DiscoverCollectionsHandler(this.brunoCLI));
      this.toolRegistry.register(new ListEnvironmentsHandler(this.brunoCLI));
      this.toolRegistry.register(new ValidateEnvironmentHandler(this.brunoCLI));
      this.toolRegistry.register(new GetRequestDetailsHandler(this.brunoCLI));
      this.toolRegistry.register(new ValidateCollectionHandler(this.brunoCLI));
    }
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 states it's a list operation but doesn't describe what 'list all requests' entails—whether it returns metadata, pagination behavior, format of results, or any constraints like rate limits or permissions needed. This leaves significant gaps in understanding the tool's behavior.

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 zero waste—it directly states the tool's purpose without unnecessary words. It's appropriately sized and front-loaded, making it easy for an agent to parse quickly.

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 the tool's complexity (a list operation with one parameter) and lack of annotations or output schema, the description is incomplete. It doesn't explain what 'list all requests' returns, how results are structured, or any behavioral traits, leaving the agent with insufficient context to use the tool 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?

The input schema has 100% description coverage, with 'collectionPath' clearly documented. The description doesn't add any parameter semantics beyond what the schema provides, such as examples or format details for the path. With high schema coverage, the baseline score of 3 is appropriate as the description doesn't compensate but also doesn't detract.

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 all requests') and target resource ('in a Bruno collection'), providing a specific verb+resource combination. However, it doesn't differentiate this tool from its sibling 'bruno_get_request_details' which might retrieve individual request details, leaving some ambiguity about when to use each.

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 'bruno_get_request_details' for individual requests or 'bruno_run_collection' for execution. There's no mention of prerequisites, context for usage, or exclusions, leaving the agent with minimal usage direction.

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/jcr82/bruno-mcp-server'

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