Skip to main content
Glama

diagnostics

Retrieve browser diagnostics to identify cache issues, errors, and performance metrics for troubleshooting Strudel.cc music coding sessions.

Instructions

Get detailed browser diagnostics including cache, errors, and performance

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Primary implementation of the diagnostics tool: collects browser connection status, page load status, editor readiness, audio connection, cache info, and error statistics via Puppeteer page evaluations.
    async getDiagnostics(): Promise<BrowserDiagnostics> { const diagnostics: BrowserDiagnostics = { browserConnected: this.browser !== null, pageLoaded: this._page !== null, editorReady: false, audioConnected: false, cacheStatus: { hasCache: this.editorCache.length > 0, cacheAge: this.cacheTimestamp > 0 ? Date.now() - this.cacheTimestamp : 0 }, errorStats: this.errorRecovery.getErrorStats() }; if (this._page) { try { diagnostics.editorReady = await this._page.evaluate(() => { return document.querySelector('.cm-content') !== null; }); diagnostics.audioConnected = await this._page.evaluate(() => { return (window as any).strudelAudioAnalyzer?.isConnected || false; }); } catch (error) { this.logger.warn('Failed to get diagnostics', error); } } return diagnostics;
  • Tool registration definition in the getTools() array, specifying name, description, and empty input schema for MCP tool listing.
    { name: 'diagnostics', description: 'Get detailed browser diagnostics including cache, errors, and performance', inputSchema: { type: 'object', properties: {} } },
  • MCP tool dispatcher in executeTool switch statement: handles 'diagnostics' calls, checks browser initialization, and delegates to StrudelController.getDiagnostics().
    case 'diagnostics': if (!this.isInitialized) { return { initialized: false, message: 'Browser not initialized. Run init first for full diagnostics.' }; } return await this.controller.getDiagnostics();
  • TypeScript interface defining the structure of BrowserDiagnostics returned by the diagnostics tool.
    export interface BrowserDiagnostics { browserConnected: boolean; pageLoaded: boolean; editorReady: boolean; audioConnected: boolean; cacheStatus: { hasCache: boolean; cacheAge: number; }; errorStats: Record<string, ErrorStats>; }

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/williamzujkowski/strudel-mcp-server'

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