Skip to main content
Glama

get_cluster_info

Retrieve cluster details like name, ID, software version, and node count from Cohesity DataProtect for data protection management and monitoring.

Instructions

Get Cohesity cluster information including name, ID, software version, and node count

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The async handler function for 'get_cluster_info' tool that fetches cluster information by calling client.getV2('cluster') and returns the JSON-formatted result. Includes error handling that returns an error message if the API call fails.
    async () => {
      try {
        const cluster = await client.getV2("cluster");
        return toolResult(JSON.stringify(cluster, null, 2));
      } catch (error) {
        return toolResult(`Error fetching cluster info: ${error}`, true);
      }
    },
  • Tool registration using server.tool() which defines the tool name 'get_cluster_info', description, empty schema object (no parameters), and the async handler function.
    server.tool(
      "get_cluster_info",
      "Get Cohesity cluster information including name, ID, software version, and node count",
      {},
      async () => {
        try {
          const cluster = await client.getV2("cluster");
          return toolResult(JSON.stringify(cluster, null, 2));
        } catch (error) {
          return toolResult(`Error fetching cluster info: ${error}`, true);
        }
      },
    );
  • Empty schema object {} indicating the tool accepts no input parameters.
    {},
  • CohesityClient.getV2() method that constructs and executes the GET request to the Cohesity V2 API endpoint. Used by the handler to fetch cluster information.
    async getV2(
      path: string,
      params?: Record<string, string>,
    ): Promise<unknown> {
      return this.request("GET", `${this.baseUrlV2}/${path}`, undefined, params);
    }
  • src/index.ts:43-43 (registration)
    Top-level registration where registerClusterTools is called with the MCP server instance and CohesityClient to register all cluster tools including 'get_cluster_info'.
    registerClusterTools(server, client);

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/fredriksknese/mcp-cohesity'

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