Skip to main content
Glama

delete_node

Remove a knowledge node and its associated connections, votes, and proofs from the Agent-hive knowledge graph. Only the original creator can perform this action.

Instructions

Delete a knowledge node and all its edges, votes, and proofs. Only the creating agent can delete.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesNode UUID to delete

Implementation Reference

  • The implementation of the delete_node tool handler, which deletes a node by UUID using a DELETE request.
    // Tool: delete_node
    server.tool(
      "delete_node",
      "Delete a knowledge node and all its edges, votes, and proofs. Only the creating agent can delete.",
      {
        id: z.string().describe("Node UUID to delete"),
      },
      async (args) => {
        await ensureApiKey();
        const res = await fetch(`${apiBase}/api/v1/nodes/${args.id}`, {
          method: "DELETE",
          headers: headers(),
        });
        const result = await res.json();
        return { content: [{ type: "text" as const, text: JSON.stringify(result, null, 2) }] };
      },
    );
Behavior4/5

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

With no annotations provided, the description carries full burden and does well by disclosing key behavioral traits: it's destructive (deletes node and related data) and has an authorization requirement (creator-only). It could improve by mentioning if deletion is permanent or reversible, but covers essential safety and access context.

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 two concise sentences with zero waste: the first states the action and scope, the second adds critical usage constraint. It is front-loaded with the core purpose and efficiently structured.

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

Completeness4/5

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

For a destructive tool with no annotations and no output schema, the description is reasonably complete—it explains what gets deleted and who can do it. It could be more complete by hinting at response format or error cases, but covers key context given the complexity.

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 description coverage is 100%, so the schema already documents the 'id' parameter as a 'Node UUID to delete'. The description does not add meaning beyond this, such as format examples or validation rules, meeting the baseline for high 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?

The description clearly states the specific action ('Delete') and target resource ('a knowledge node'), with additional detail about cascading effects ('and all its edges, votes, and proofs'). It distinguishes from siblings like edit_node or flag_node by specifying irreversible removal.

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

Usage Guidelines4/5

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

The description provides clear context for when to use ('Only the creating agent can delete'), establishing an access control prerequisite. However, it does not explicitly mention when not to use or name alternatives (e.g., flag_node for reporting issues instead of deletion).

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/kelvinyuefanli/agent-hive'

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