@thenamesalex/obsidian-mcp
v0.1.5
Published
MCP server for Obsidian Local REST API with LLM-wiki-oriented note organization tools
Readme
obsidian-mcp
MCP (Model Context Protocol) server for Obsidian Local REST API:
- plain markdown notes
- consistent note structure (summary + tags + related notes)
- fast retrieval/search + safe write tools for organization
This project mirrors the structure of aha-mcp:
src/index.tsserver entrypointsrc/client.tsHTTP clientsrc/models/typessrc/tools/read.tsread-only toolssrc/tools/write.tswrite tools
Requirements
- Node.js 18+
- Obsidian with the Local REST API plugin enabled
- API key from the plugin settings
Environment
Copy .env.example to .env and set values:
OBSIDIAN_API_KEY(required)OBSIDIAN_BASE_URL(optional, defaulthttp://127.0.0.1:27123)
Install and build
npm install
npm run buildRun
OBSIDIAN_API_KEY=... OBSIDIAN_BASE_URL=http://127.0.0.1:27123 node dist/index.jsMCP config example
{
"mcpServers": {
"obsidian": {
"command": "node",
"args": ["/absolute/path/to/obsidian-mcp/dist/index.js"],
"env": {
"OBSIDIAN_API_KEY": "your_obsidian_api_key",
"OBSIDIAN_BASE_URL": "http://127.0.0.1:27123"
}
}
}
}Tools
Read tools
get_obsidian_status: confirm API status/authget_note: read markdown or note JSON metadatasearch_notes: simple text search with context snippets
Write tools
create_structured_note: create a Karpathy-style template noteupsert_note: create/replace note contentappend_note: append contentpatch_note: heading/block/frontmatter patch operationsmove_note: copy+delete move operationdelete_note: delete a note by vault-relative path
