Skip to main content
Glama
rad-security

RAD Security

Official
by rad-security

list_clusters

Retrieve and display Kubernetes clusters managed by RAD Security for security monitoring and management.

Instructions

List Kubernetes clusters managed by RAD Security

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
page_sizeNoNumber of clusters per page for list_clusters (default: 50)
pageNoPage number to retrieve for list_clusters (default: 1)

Implementation Reference

  • The core handler function that executes the list_clusters tool by calling the RAD Security API to retrieve a paginated list of clusters.
    export async function listClusters(
      client: RadSecurityClient,
      page_size: number = 50,
      page: number = 1,
    ): Promise<any> {
      const params: Record<string, any> = { page_size, page };
      return client.makeRequest(
        `/accounts/${client.getAccountId()}/clusters`,
        params
      );
    }
  • Zod schema defining the input parameters for the list_clusters tool: page_size and page.
    export const ListClustersSchema = z.object({
      page_size: z.number().optional().default(50).describe("Number of clusters per page for list_clusters (default: 50)"),
      page: z.number().optional().default(1).describe("Page number to retrieve for list_clusters (default: 1)"),
    });
  • src/index.ts:150-153 (registration)
    Tool registration in the ListTools response, defining the name, description, and input schema for discovery.
      name: "list_clusters",
      description: "List Kubernetes clusters managed by RAD Security",
      inputSchema: zodToJsonSchema(clusters.ListClustersSchema),
    },
  • src/index.ts:754-768 (registration)
    Handler registration in the CallToolRequest switch statement, parsing args with schema and delegating to the listClusters handler.
    case "list_clusters": {
      const args = clusters.ListClustersSchema.parse(
        request.params.arguments
      );
      const response = await clusters.listClusters(
        client,
        args.page_size,
        args.page
      );
      return {
        content: [
          { type: "text", text: JSON.stringify(response, null, 2) },
        ],
      };
    }

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/rad-security/mcp-server'

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