Skip to main content
Glama
Obsidian CDP MCP Server

Obsidian CDP MCP Server

obsidian_write_file

Write or update a file in an Obsidian vault by specifying a vault-relative path and content. Use it to create notes or modify existing files through the MCP server.

Instructions

Write or update content to a file in the Obsidian vault.

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": {
      "path": "<path>",
      "content": "<content>"
    },
    "name": "obsidian_write_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesPath to the file relative to vault root
contentYesContent to write to the file

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.9.2

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden, and it omits the single most important fact: whether an existing file's content is replaced or appended to when the path already exists. It also says nothing about permission requirements, recoverability of overwritten content, or vault-targeting behavior.

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

Conciseness4/5

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

A single well-formed sentence with no filler and the action front-loaded. It is efficiently worded; the problem is under-specification rather than verbosity, which is scored elsewhere.

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?

For an unannotated write tool with no output schema, the definition is thin: it does not disclose overwrite semantics, whether a missing file is created, or what a successful call returns. An agent could invoke it correctly by path and content but cannot predict the destructive consequences.

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%, with both required parameters (path, content) documented in the schema itself, so the baseline is 3. The description adds no meaning beyond that — no path conventions, no size limits, and no clarification of whether content is raw text or supports frontmatter.

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 pair and resource: "Write or update content to a file in the Obsidian vault." An agent can tell this mutates vault file content, but the description never distinguishes it from the sibling obsidian_patch_file, which presumably performs partial edits, so the boundary between the two is left to inference.

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 when-to-use or when-not-to-use guidance is given. With obsidian_patch_file, obsidian_insert_at_cursor, and obsidian_replace_selection as close alternatives, the description offers nothing to route the agent between a full write and a partial edit.

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