Skip to main content
Glama

Delete document

delete_document
Destructive

Remove a document from the property or tenant it is linked to; if that is its only link, the document is deleted.

Instructions

Remove a document from the property/tenant it is linked to (deletes it if that was its only link).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
confirmNoSet true once the user has approved writes for this session
entityIdYesThe property/tenant id the document is linked to
documentIdYes
entityTypeNoproperty

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A3.5/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, so the safety profile is covered. The description adds real behavioral context beyond that: removal detaches the document from a specific property/tenant and only destroys it when no other link exists. It still omits irreversibility and the session-confirmation gate, which lives only in the schema.

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?

A single sentence with the decisive detail (conditional deletion) placed inline rather than padded out. No filler or redundant restatement of the title.

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?

For a destructive mutation with no output schema, the description covers the core semantics but leaves open whether the action is reversible, what happens to a document with multiple links, and that a confirm value is needed. Adequate but with visible gaps.

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 coverage is 50%: entityId and confirm are documented in the schema, but documentId and entityType carry no schema description. The description's reference to 'the property/tenant it is linked to' adds context for the entity parameters, but it does nothing to clarify documentId or the entityType default.

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

Purpose4/5

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

States a specific verb (Remove) and resource (document), and adds the meaningful nuance that removal only becomes a true delete when the link was the document's only one. It implicitly separates itself from link_document and delete_property/delete_tenant, though it never names a sibling explicitly.

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?

There is no guidance on when to use this versus link_document (to unlink) or the other delete_* tools, and no mention that a `confirm` flag is required before the write is accepted. The agent must infer timing and prerequisites entirely from the schema.

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