Skip to main content
Glama
jagoff

obsidian-mcp-complete

by jagoff

obsidian_daily_note

Read, create, update, or append daily notes in Obsidian vaults using configurable date-based folder and file patterns.

Instructions

Read, create, upsert, or append to a daily note using configurable date folder/pattern.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
vaultNoOptional configured vault name. Defaults to the server default vault.
dateNo
folderNo
patternNo
actionNoread
contentNo
frontmatterNoYAML frontmatter object.

Implementation Reference

  • The handler function for the obsidian_daily_note tool. It reads/creates/upserts/appends a daily note using configurable date, folder, and pattern. Uses the dailyPath helper to construct the file path.
    tool(
      "obsidian_daily_note",
      "Read, create, upsert, or append to a daily note using configurable date folder/pattern.",
      {
        vault: vaultArg,
        date: z.string().optional(),
        folder: z.string().optional(),
        pattern: z.string().optional(),
        action: z.enum(["read", "create", "upsert", "append"]).optional().default("read"),
        content: z.string().optional().default(""),
        frontmatter: frontmatterArg,
      },
      async (args) => {
        const date = args.date ?? new Date().toISOString().slice(0, 10);
        const notePath = dailyPath(date, args.folder ?? config.dailyFolder, args.pattern ?? config.dailyPattern);
        if (args.action === "read") return { path: notePath, content: (await vaults.readText(notePath, args.vault)).text };
        if (args.action === "append") return vaults.appendText(notePath, args.content, args.vault, { create: true });
        const text = args.frontmatter ? stringifyFrontmatter(args.frontmatter, args.content) : args.content;
        return vaults.writeText(notePath, text, args.vault, { overwrite: args.action === "upsert" });
      },
    );
  • Schema definition for obsidian_daily_note: accepts optional date, folder, pattern, action (read/create/upsert/append), content, and frontmatter.
    {
      vault: vaultArg,
      date: z.string().optional(),
      folder: z.string().optional(),
      pattern: z.string().optional(),
      action: z.enum(["read", "create", "upsert", "append"]).optional().default("read"),
      content: z.string().optional().default(""),
      frontmatter: frontmatterArg,
    },
  • src/tools.ts:961-981 (registration)
    Registration of the obsidian_daily_note tool via the local `tool()` helper function inside registerObsidianTools.
    tool(
      "obsidian_daily_note",
      "Read, create, upsert, or append to a daily note using configurable date folder/pattern.",
      {
        vault: vaultArg,
        date: z.string().optional(),
        folder: z.string().optional(),
        pattern: z.string().optional(),
        action: z.enum(["read", "create", "upsert", "append"]).optional().default("read"),
        content: z.string().optional().default(""),
        frontmatter: frontmatterArg,
      },
      async (args) => {
        const date = args.date ?? new Date().toISOString().slice(0, 10);
        const notePath = dailyPath(date, args.folder ?? config.dailyFolder, args.pattern ?? config.dailyPattern);
        if (args.action === "read") return { path: notePath, content: (await vaults.readText(notePath, args.vault)).text };
        if (args.action === "append") return vaults.appendText(notePath, args.content, args.vault, { create: true });
        const text = args.frontmatter ? stringifyFrontmatter(args.frontmatter, args.content) : args.content;
        return vaults.writeText(notePath, text, args.vault, { overwrite: args.action === "upsert" });
      },
    );
  • The dailyPath helper function that constructs the daily note file path from a date (YYYY-MM-DD), folder, and pattern string (supporting YYYY, MM, DD, {{date}} placeholders).
    function dailyPath(date: string, folder: string, pattern: string): string {
      const [year, month, day] = date.split("-");
      const file = pattern
        .replace(/YYYY/g, year ?? "")
        .replace(/MM/g, month ?? "")
        .replace(/DD/g, day ?? "")
        .replace(/\{\{date\}\}/g, date);
      return `${folder.replace(/\/+$/, "")}/${file}`;
    }
  • Default configuration for dailyFolder and dailyPattern used by obsidian_daily_note when not overridden in tool arguments.
    dailyFolder: env.OBSIDIAN_DAILY_FOLDER?.trim() || "00-Inbox",
    dailyPattern: env.OBSIDIAN_DAILY_PATTERN?.trim() || "YYYY-MM-DD.md",
Behavior3/5

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

Annotations show readOnlyHint=false and destructiveHint=false, so the description confirms it can perform both read and write operations. However, it does not disclose behaviors like what happens when reading a non-existent note or how append behaves if the note is missing. The description adds some context but not deep behavioral details.

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 a single sentence that efficiently communicates the tool's purpose and key differentiator. Every word is necessary and front-loaded with actions.

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?

Given the tool's complexity (7 parameters, multiple actions, no output schema), the description covers the essential purpose and key configurable aspect (date folder/pattern). It lacks details on conflict resolution or frontmatter merging, but the core functionality is well communicated.

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 low (29%). The description adds meaning for 'folder' and 'pattern' by mentioning 'configurable date folder/pattern', but does not explain 'date', 'content', or others. It partially compensates for the low 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 actions (Read, create, upsert, append) and the resource (daily note). It specifies 'configurable date folder/pattern', which distinguishes this tool from generic note manipulation siblings like obsidian_create_note or obsidian_append_to_note.

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 implies the tool is for daily notes with date-based organization, but does not explicitly state when to use it over alternatives or when not to use it. It provides clear context but lacks exclusionary guidance.

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