Skip to main content
Glama
j3k0

Elasticsearch Knowledge Graph for MCP

by j3k0

delete_zone

Remove a memory zone and all associated entities or relations from the Elasticsearch Knowledge Graph for MCP. Requires zone name and confirmation flag to execute deletion.

Instructions

Delete a memory zone and all its entities/relations.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
confirmYesConfirmation flag, must be true
nameYesZone name to delete (cannot be 'default')

Implementation Reference

  • Input schema definition and tool registration for the 'delete_zone' MCP tool, including required parameters 'name' and 'confirm'.
    {
      name: "delete_zone",
      description: "Delete a memory zone and all its entities/relations.",
      inputSchema: {
        type: "object",
        properties: {
          name: {
            type: "string",
            description: "Zone name to delete (cannot be 'default')"
          },
          confirm: {
            type: "boolean",
            description: "Confirmation flag, must be true",
            default: false
          }
        },
        required: ["name", "confirm"]
      }
    },
  • Execution handler for the 'delete_zone' tool within the CallToolRequestSchema handler. Validates confirmation, calls kgClient.deleteMemoryZone(name), and formats success/error responses.
    else if (toolName === "delete_zone") {
      const name = params.name;
      const confirm = params.confirm === true;
      
      if (!confirm) {
        return formatResponse({
          success: false,
          error: "Confirmation required. Set confirm=true to proceed with deletion."
        });
      }
      
      try {
        const result = await kgClient.deleteMemoryZone(name);
        
        if (result) {
          return formatResponse({
            success: true,
            message: `Zone "${name}" deleted successfully`
          });
        } else {
          return formatResponse({
            success: false,
            error: `Failed to delete zone "${name}"`
          });
        }
      } catch (error) {
        return formatResponse({
          success: false,
          error: `Error deleting zone: ${(error as Error).message}`
        });
      }
    }
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool deletes a zone and all its entities/relations, which implies a destructive, irreversible operation. However, it lacks details on permissions needed, error handling (e.g., if the zone doesn't exist), side effects, or confirmation requirements beyond the 'confirm' parameter. The description adds minimal behavioral context beyond the basic action.

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?

The description is a single, efficient sentence that directly states the tool's action and scope. It is front-loaded with the core purpose ('Delete a memory zone') and adds necessary detail ('and all its entities/relations') without redundancy. Every word earns its place, making it highly concise and well-structured.

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

Completeness3/5

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

Given the tool's destructive nature and lack of annotations or output schema, the description is minimally complete. It covers what the tool does but omits critical context like irreversible consequences, prerequisites, or error scenarios. For a deletion tool with no safety annotations, more guidance would be helpful, but the description meets a basic threshold.

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

Parameters4/5

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

Schema description coverage is 100%, so the schema fully documents both parameters ('name' and 'confirm'). The description adds no additional parameter semantics, but with high schema coverage, the baseline is 3. Since there are only 2 parameters and the schema is comprehensive, a score of 4 reflects that the description doesn't need to compensate and the tool's purpose is straightforward.

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?

The description clearly states the verb ('Delete') and resource ('a memory zone and all its entities/relations'), making the purpose specific and unambiguous. It distinguishes from sibling tools like 'delete_entities' and 'delete_relations' by specifying that it deletes the entire zone along with its contents, not just individual components.

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?

The description provides no guidance on when to use this tool versus alternatives. It does not mention prerequisites (e.g., whether the zone must exist or be empty), exclusions (e.g., cannot delete the 'default' zone, though this is hinted in the schema), or comparisons to siblings like 'merge_zones' or 'list_zones' for verification. Usage context is implied but not explicit.

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

Related 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/j3k0/mcp-brain-tools'

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