Skip to main content
Glama

get_cache_stats

Monitor server performance by retrieving cache statistics to track resource usage and optimize system efficiency.

Instructions

Get cache statistics for monitoring server performance.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Core handler function that collects and returns statistics from all five cache instances (tafsir, hadith, quran, recitation, search). This is the exact implementation of the tool logic.
    export function getAllCacheStats() { return { tafsir: getTafsirCache().getStats(), hadith: getHadithCache().getStats(), quran: getQuranCache().getStats(), recitation: getRecitationCache().getStats(), search: getSearchCache().getStats(), }; }
  • Tool dispatch/registration in the central executeTool switch statement, which calls the getAllCacheStats handler when 'get_cache_stats' is invoked.
    case 'get_cache_stats': { result = getAllCacheStats(); break; }
  • Tool schema definition including name, description, and empty input schema (no parameters required). Used for MCP tool registration and validation.
    { name: 'get_cache_stats', description: 'Get cache statistics for monitoring server performance.', inputSchema: { type: 'object', properties: {}, }, },

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/Prince77-7/quranMCP'

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