Skip to main content
Glama

list_instruments

Display all active debug instruments to monitor and manage code instrumentation during debugging sessions.

Instructions

List all active debug instruments.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The switch case handler for the 'list_instruments' tool. It fetches all active instruments using sessionManager.getInstruments() and formats them into a text list, returning it via the MCP response format or a 'No active instruments' message if empty.
    case 'list_instruments': { const instruments = sessionManager.getInstruments(); if (instruments.length === 0) { return { content: [{ type: 'text', text: 'No active instruments.' }], }; } const list = instruments .map((i) => `- ${i.id}: ${i.file}:${i.line} [${i.capture.join(', ') || 'no capture'}]`) .join('\n'); return { content: [ { type: 'text', text: `Active instruments (${instruments.length}):\n\n${list}`, }, ], }; }
  • src/index.ts:93-100 (registration)
    Tool registration entry for 'list_instruments' in the ListToolsRequestHandler response, defining name, description, and empty input schema.
    { name: 'list_instruments', description: 'List all active debug instruments.', inputSchema: { type: 'object', properties: {}, }, },
  • SessionManager helper method that returns the array of all active Instrument objects stored in the session Map.
    getInstruments(): Instrument[] { if (!this.session) { return []; } return Array.from(this.session.instruments.values()); }

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/iarmankhan/agentic-debugger'

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