Skip to main content
Glama
jagoff

obsidian-mcp-complete

by jagoff

obsidian_create_note

Create a Markdown note in an Obsidian vault with optional YAML frontmatter, wiki-links, and content; supports custom path and overwrite.

Instructions

Create a new Markdown note with optional frontmatter and related wiki-links.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
vaultNoOptional configured vault name. Defaults to the server default vault.
pathYesVault-relative path. Absolute paths and traversal are rejected.
contentNo
frontmatterNoYAML frontmatter object.
relatedNo
overwriteNo

Implementation Reference

  • src/tools.ts:448-465 (registration)
    Registration of the obsidian_create_note tool with its schema (vault, path, content, frontmatter, related, overwrite) and the handler function that creates a new Markdown note.
    tool(
      "obsidian_create_note",
      "Create a new Markdown note with optional frontmatter and related wiki-links.",
      {
        vault: vaultArg,
        path: pathArg,
        content: z.string().default(""),
        frontmatter: frontmatterArg,
        related: z.array(z.string()).optional().default([]),
        overwrite: z.boolean().optional().default(false),
      },
      async (args) => {
        const body = withRelated(args.content, args.related);
        const text = args.frontmatter ? stringifyFrontmatter(args.frontmatter, body) : body;
        return vaults.writeText(vaults.notePath(args.path), text, args.vault, { overwrite: args.overwrite });
      },
      { destructiveHint: false, idempotentHint: false },
    );
  • Zod schema for obsidian_create_note defining input parameters: vault (optional), path (required), content (default empty string), frontmatter (optional record), related (optional array of wiki-link targets), and overwrite (optional boolean).
    {
      vault: vaultArg,
      path: pathArg,
      content: z.string().default(""),
      frontmatter: frontmatterArg,
      related: z.array(z.string()).optional().default([]),
      overwrite: z.boolean().optional().default(false),
    },
  • Handler function for obsidian_create_note. Builds the note body with related wiki-links via withRelated(), optionally stringifies frontmatter, and writes the note via vaults.writeText().
    async (args) => {
      const body = withRelated(args.content, args.related);
      const text = args.frontmatter ? stringifyFrontmatter(args.frontmatter, body) : body;
      return vaults.writeText(vaults.notePath(args.path), text, args.vault, { overwrite: args.overwrite });
    },
  • Helper function withRelated() that appends a '## Related' section with [[wiki-links]] to the note content when an array of related paths is provided.
    function withRelated(content: string, related: string[]): string {
      if (related.length === 0) return content;
      const links = related.map((item) => `- [[${item.replace(/\.md$/i, "")}]]`).join("\n");
      return `${content.replace(/\s*$/, "\n\n")}## Related\n${links}\n`;
    }
Behavior3/5

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

Annotations are minimal (readOnlyHint=false, destructiveHint=false). Description adds creation behavior but omits details like overwrite semantics, error handling, or constraints. Adequate but not comprehensive.

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?

Single sentence with clear verb and key features, front-loaded and without unnecessary words.

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?

Given 6 parameters, nested objects, no output schema, and many sibling tools, the description is too brief. Lacks information on return values, error handling, and detailed behavior.

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 50%. Description mentions frontmatter and wiki-links but does not elaborate on vault, content, or overwrite parameters beyond schema. Baseline 3 due to partial 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?

Clearly states 'Create a new Markdown note' with optional frontmatter and wiki-links, distinguishing it from sibling tools like append or delete.

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 guidance on when to use this tool versus alternatives like obsidian_append_to_note or obsidian_update_note. Does not mention conditions or context for use.

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/jagoff/obsidian-mcp'

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