Skip to main content
Glama
morz-mcp

morz-mcp

by cumany

morz-mcp

A local Model Context Protocol server that exposes a folder of Markdown notes (a Morz vault) to AI clients over stdio.

  • Works with any MCP-capable client that can launch a local process.

  • Reads and writes ordinary .md files; the Morz desktop app is optional.

  • No network service, no port, no account, no API key.

  • Requires Node.js 22.18+.

Install

Single-file bundle (no npm)

Download morz-mcp.mjs from Releases once a release is published, or build it from source:

npm ci
npm run bundle
node bundle/morz-mcp.mjs --vault "D:/Notes"

Point the client at the file:

{
  "mcpServers": {
    "morz": {
      "command": "node",
      "args": ["D:/path/to/morz-mcp.mjs", "--vault", "D:/Notes"]
    }
  }
}

npm

Once the package is published:

npx -y morz-mcp@0.1.0 --vault "D:/Notes"
{
  "mcpServers": {
    "morz": {
      "command": "npx",
      "args": ["-y", "morz-mcp@0.1.0", "--vault", "D:/Notes"]
    }
  }
}

This speaks MCP on stdio, so it looks silent when run in a terminal. Configure your client to launch it instead of running it in a shell.

Related MCP server: obsidian-vault-mcp

Vault discovery

The server resolves the vault root in this order:

  1. --vault <folder>

  2. MORZ_VAULT environment variable

  3. the manifest written by the Morz desktop app at <appDataDir>/com.morz.editor/morz.json

In Morz desktop, Settings → General → MCP only writes that manifest; it does not start this server or open a port. The setting can be disabled, and the manifest is then cleared. Using --vault makes the server independent of the desktop app.

Tools

Tool

Purpose

list_vaults

Known vaults and the active one

list_notes

Recursive Markdown notes (hidden/system folders excluded)

read_note

Read a note, returns mtime for optimistic concurrency

write_note

Create/overwrite a note; accepts expectedMtime

append_to_note

Append text; accepts expectedMtime

delete_note

Soft-delete into .trash (restorable in Morz)

search_notes

Substring search with title weighting and hit lines

get_tags

Tags with usage counts

get_backlinks

Notes linking to a note, with line numbers

get_outgoing_links

Wikilinks, embeds and internal Markdown links

get_vault_stats

Note count, size, word count, top tags, recent notes

get_note_info

Title, tags, mtime, outgoing/backlink counts

Resources: note:///<relative-path>.

Safety model

  • Path fence: every path must stay inside the vault root; absolute paths, drive letters, UNC paths, .. and NUL are rejected.

  • Optimistic concurrency: pass expectedMtime from read_note when writing; if the file changed since the read, the write is refused and the current mtime is returned.

  • Soft delete: delete_note moves to .trash; it never hard-deletes.

  • No auth: this is a local stdio process. The client controls who can launch it.

  • Unsaved editor buffers are not visible: the server reads files on disk. If the Morz editor has unsaved changes, save before asking an agent to edit the same note.

Not supported in v1: rename/move, daily-note templates, IndexedDB/browser libraries, Android SAF workspaces, and cloud sync.

Development

npm ci
npm test        # type check, build and the 15-check stdio smoke test
npm run bundle  # single-file build in bundle/

The smoke test creates a temporary vault and exercises the handshake, all 12 tools, the path fence, the stale-write guard and editor-compatible trash. See CONTRIBUTING.md.

License

MIT. The Morz application itself is proprietary; this MCP server is a separate MIT-licensed component (see LICENSE).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables reading, searching, and writing an Obsidian vault directly on disk without Obsidian running, and walking its wikilink graph for backlinks, N-hop neighbors, unresolved links, and orphans. Available over Streamable HTTP with bearer auth, stdio, or a Claude Desktop extension.
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables AI harnesses such as ZCode and Claude Code to browse, search, edit, and create notes in an Obsidian vault through seven fine-grained tools over stdio. It works directly on the vault's filesystem without requiring Obsidian to be running, with built-in protections against accidental deletion or overwriting.
      10
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Exposes a local Markdown vault to AI agents over stdio, letting them search, read, create, update (with mtime-guarded writes), and append notes, as well as list and manage saved views. Write permissions can be toggled per group in settings, and all changes land as plain Markdown/YAML files in the chosen folder.
      MIT