Skip to main content
Glama
tao12345666333

Civo MCP Server

delete_kubernetes_cluster

Delete a Kubernetes cluster by specifying its ID and region to free up resources.

Instructions

Delete a Kubernetes cluster on Civo

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesCluster ID
regionYesRegion identifier

Implementation Reference

  • The handler (switch case) that executes the delete_kubernetes_cluster tool logic. Validates args (id, region), calls deleteCluster API, and returns the result.
    case 'delete_kubernetes_cluster': {
      if (
        typeof args !== 'object' ||
        args === null ||
        typeof args.id !== 'string' ||
        typeof args.region !== 'string'
      ) {
        throw new Error('Invalid arguments for delete_kubernetes_cluster');
      }
    
      const result = await deleteCluster(
        args as { id: string; region: string }
      );
      return {
        content: [
          {
            type: 'text',
            text: `Deleted Kubernetes cluster ${args.id}: ${result.result}`,
          },
        ],
        isError: false,
      };
    }
  • The API helper function 'deleteCluster' that sends a DELETE request to Civo API endpoint /v2/kubernetes/clusters/{id} with region parameter.
    export async function deleteCluster(params: {
      id: string;
      region: string;
    }): Promise<any> {
      checkRateLimit();
    
      const url = new URL(`${CIVO_API_URL}/kubernetes/clusters/${params.id}`);
      url.searchParams.set('region', params.region);
    
      const response = await fetch(url.toString(), {
        method: 'DELETE',
        headers: {
          Authorization: `Bearer ${CIVO_API_KEY}`,
        },
      });
    
      if (!response.ok) {
        throw new Error(
          `Civo API error: ${response.status} ${response.statusText}`
        );
      }
    
      return response.json();
    }
  • The tool schema definition (Tool object) for delete_kubernetes_cluster, defining name, description, and inputSchema with required 'id' and 'region' string fields.
    export const DELETE_KUBERNETES_CLUSTER_TOOL: Tool = {
      name: 'delete_kubernetes_cluster',
      description: 'Delete a Kubernetes cluster on Civo',
      inputSchema: {
        type: 'object',
        properties: {
          id: {
            type: 'string',
            description: 'Cluster ID',
          },
          region: {
            type: 'string',
            description: 'Region identifier',
          },
        },
        required: ['id', 'region'],
      },
    };
  • src/index.ts:88-90 (registration)
    Registration of the tool in the server's capabilities.tools map.
      [DELETE_KUBERNETES_CLUSTER_TOOL.name]: DELETE_KUBERNETES_CLUSTER_TOOL,
      [LIST_KUBERNETES_VERSIONS_TOOL.name]: LIST_KUBERNETES_VERSIONS_TOOL,
    },
  • src/index.ts:115-118 (registration)
    Registration of the tool in the ListToolsRequestSchema handler (returned as one of the available tools).
        DELETE_KUBERNETES_CLUSTER_TOOL,
        LIST_KUBERNETES_VERSIONS_TOOL,
      ],
    }));
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, and description lacks details on irreversibility, cascading effects, or required authentication, leaving the AI agent underinformed about behavioral traits.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence with no redundant words, efficiently conveying the core purpose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Lacks details about return values, deletion effects, or confirmation requirements, making it incomplete for a deletion tool despite clear schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema already describes both parameters (id and region) with clear descriptions, so description adds no extra value. Baseline score of 3 applies due to full schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states 'Delete a Kubernetes cluster on Civo' with a specific verb and resource, distinguishing it from sibling tools like delete_instance and delete_network.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives, no prerequisites or conditions like cluster state or permissions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/tao12345666333/civo-mcp'

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