from typing import Dict
from fastmcp import FastMCP
class ClusterTools:
def __init__(self, search_client):
self.search_client = search_client
def register_tools(self, mcp: FastMCP):
@mcp.tool()
def get_cluster_health() -> Dict:
"""Returns basic information about the health of the cluster."""
return self.search_client.get_cluster_health()
@mcp.tool()
def get_cluster_stats() -> Dict:
"""Returns high-level overview of cluster statistics."""
return self.search_client.get_cluster_stats()
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/cr7258/elasticsearch-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server