Skip to main content
Glama

delete_file

Destructive

Delete notes, attachments, or folders from an Obsidian vault, moving them to .trash by default for recovery; set permanent to erase them and see which links will break.

Instructions

Delete a note, attachment or folder. Default moves it to the vault's .trash folder (recoverable); permanent:true deletes it. Reports links that will break.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "file": "<file>"
    },
    "name": "delete_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileYes
vaultNoVault name, id or folder path (see list_vaults). Default: OBSIDIAN_VAULT or the vault open in Obsidian.
permanentNo
recursiveNoRequired to delete a non-empty folder

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

The annotations already declare destructiveHint=true and non-idempotent, but the description adds genuinely new behavior: the default is a recoverable move to the vault's .trash folder, and permanent:true is the irrecoverable path. It also discloses a return-side effect ('Reports links that will break'), which annotations cannot convey.

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?

Three short sentences, front-loaded with the resource set, then the default/recoverable behavior, then the escape hatch and side effect. No filler.

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 4-parameter tool with strong annotations and no output schema, the definition covers recoverability, the permanent override, and the breaking-link report. The only real gap is the format expected for the required `file` argument and the folder/recursive interaction.

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?

At 50% schema coverage, the description compensates well for `permanent` by explaining exactly what it toggles, and `vault`/`recursive` are documented in the schema. However the required `file` parameter is undocumented in both places — no hint whether it takes a vault-relative path, a name, or a wikilink.

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?

States a specific verb ('Delete') plus the exact resource set ('a note, attachment or folder'), which also implicitly separates it from the tag/task deletion siblings. An agent can tell what entity this operates on without opening the schema.

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

Usage Guidelines3/5

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

Usage context is only implied: it is clear this is the removal tool for notes/attachments/folders, but nothing says when to prefer it over move_file (to archive) or when permanent deletion is appropriate. No explicit exclusions or prerequisites (e.g. folder must be empty unless recursive) are stated here.

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

Deploy Server

Other Tools