Logo van Obsidian Advanced

Obsidian Advanced

Community
ToKiDoO

Advanced MCP server for interacting with Obsidian via the Local REST API community plugin. It empowers AI agents (like Claude) to deeply understand your vault's structure, links, and content—beyond basic read/write operations.

UitgeverToKiDoO
Repositorymcp-obsidian-advanced
TaalPython
Forks
5
Sterren
18
Beschikbare tools
16
Transporttypestdio
Categorieën
LicentieMIT
Links
  • Koppel tools aan AI-workflows

    Obsidian Advanced biedt MCP-functionaliteit die compatibele AI-clients en agenten kunnen gebruiken.

  • 16 beschikbare tools

    Bekijk hieronder de aanroepbare acties, inclusief namen en beschrijvingen als de server die beschikbaar stelt.

  • Configuratie om direct te kopiëren

    Gebruik de installatievoorbeelden om deze server in je favoriete MCP-client te configureren.

  • Indicatoren van opensource-interesse

    18 sterren en 5 forks in de gekoppelde repository.

Advanced MCP Tools for Obsidian

Advanced MCP server for interacting with Obsidian via the Local REST API community plugin. It empowers AI agents (like Claude) to deeply understand your vault's structure, links, and content—beyond basic read/write operations.

Key advanced features, powered by the obsidiantools library:

  • Vault tree structure discovery to map your note hierarchy
  • NetworkX graph analysis of note connections for LLM-friendly insights
  • Execution of Obsidian commands directly from AI
  • Batch file reading with metadata and link details
  • Access to your currently active note for real-time context
  • Opening notes/files in new Obsidian leaves for seamless editing

This setup lets AI agents work alongside you, boosting productivity by efficiently navigating and enhancing your knowledge base.

Components

Tools

The server implements multiple tools to interact with Obsidian:

Core File Operations

  • obsidian_list_files_in_dir: Lists all files and directories in a specific Obsidian directory
  • obsidian_batch_get_files: Return the contents and metadata of one or more notes (.md files) in your vault
  • obsidian_put_file: Create a new file in your vault or update the content of an existing one
  • obsidian_append_to_file: Append content to a new or existing file in the vault
  • obsidian_patch_file: Insert content into an existing note relative to a heading, block reference, or frontmatter field
  • obsidian_delete_file: Delete a file or directory from your vault

Search Operations

  • obsidian_simple_search: Simple search for documents matching a specified text query across all files in the vault
  • obsidian_complex_search: Complex search for documents using a JsonLogic query with support for 'glob' and 'regexp' pattern matching

Note Management

  • obsidian_get_active_note: Get the content and metadata of the currently active note in Obsidian
  • obsidian_periodic_notes: Get current periodic note for the specified period (daily, weekly, monthly, quarterly, yearly)
  • obsidian_recent_periodic_notes: Get most recent periodic notes for the specified period type
  • obsidian_recent_changes: Get recently modified files in the vault
    • NOTE: This tool requires the Dataview community plugin to function. Make sure to install the Dataview plugin in your vault.

Vault Analysis

  • obsidian_understand_vault: Get a comprehensive understanding of the vault structure including directory tree and NetworkX graph of note connections
  • obsidian_open_files: Open one or more files in the vault in a new leaf
  • obsidian_list_commands: List all available commands you can run in obsidian interface
  • obsidian_execute_commands: Execute one or more commands in obsidian interface

Example prompts

Its good to first instruct Claude (or any other MCP client) to use Obsidian. Then it will always call the tool. For instance,

The use prompts like this:

  • "Expand on the Marketing section of the report I'm currently working on in obsidian"
    • Claude will use obsidian_get_active_note, read it, then edit the note.
  • "Search for all files where Azure CosmosDb is mentioned and quickly explain to me the context in which it is mentioned"
  • "Summarize the last meeting notes and put them into a new note 'summary meeting.md'. Add an introduction so that I can send it via email."

Configuration

Environment Variables

For this MCP server, there are 2 required environment variables that need to be configured:

  • OBSIDIAN_API_KEY: Obtain this by installing the Obsidian REST API plugin, and go into settings.
  • OBSIDIAN_VAULT_PATH: The absolute path to your vault must be set in order for tools (e.g. obsidian_understand_vault) to function properly.

Additionally, there are 3 optional environment variables that could be altered:

  • OBSIDIAN_HOST: Could be changed in the Obsidian REST API plugin settings. Defaults to 127.0.0.1 as per the plugin's default settings.
  • OBSIDIAN_PORT: Could be changed in the Obsidian REST API plugin settings. Defaults to 27124 as per the plugin's default settings.
  • INCLUDE_TOOLS: This variable controls which tools would be available for use.
    • Write the name of the tool(s) you want to include (name listed above), separated by commas.
    • For instance, if you only want the obsidian_understand_vault and obsidian_simple_search tool, you would set INCLUDE_TOOLS="obsidian_understand_vault,obsidian_simple_search" in the .env or in the server config.

There are two ways to configure the environment with the Obsidian REST API Key.

  1. Add to server config (PREFERRED):
json
{
  "mcp-obsidian-advanced": {
    "command": "uvx",
    "args": [
      "mcp-obsidian-advanced"
    ],
    "env": {
      "OBSIDIAN_API_KEY": "%3Cyour_api_key_here%3E",
      "OBSIDIAN_HOST": "<your_obsidian_host>",
      "OBSIDIAN_PORT": "<your_obsidian_port>",
      "OBSIDIAN_VAULT_PATH": "</path/to/your/vault>",
      "INCLUDE_TOOLS": ""
    }
  }
}

Sometimes Claude has issues detecting the location of uv / uvx. You can use which uvx to find and paste the full path in above config in such cases.

  1. Create a .env file in the working directory with the following variables (only OBSIDIAN_API_KEY and OBSIDIAN_VAULT_PATH are required):
OBSIDIAN_API_KEY=your_api_key_here
OBSIDIAN_HOST=your_obsidian_host
OBSIDIAN_PORT=your_obsidian_port
OBSIDIAN_VAULT_PATH=/path/to/your/vault
INCLUDE_TOOLS=name_of_tool1,name_of_tool2,...

Note: You can find the API key, Host and Port in the Obsidian plugin config Default port is 27124 if not specified Default host is 127.0.0.1 if not specified

Quickstart

Install

Installing via Smithery

To install Advanced Obsidian MCP Server for Claude Desktop automatically via Smithery:

bash
npx -y @smithery/cli install @ToKiDoO/mcp-obsidian-advanced --client claude

Obsidian REST API

You need the Obsidian REST API community plugin running: https://github.com/coddingtonbear/obsidian-local-rest-api

  • You can install it by going to "Community Plugins" in Obsidian, search it up.

Install and enable it in the settings and copy the api key.

Claude Desktop

On MacOS: ~/Library/Application\ Support/Claude/claude_desktop_config.json

On Windows: %APPDATA%/Claude/claude_desktop_config.json

Published Servers Configuration:

json
{
  "mcpServers": {
    "mcp-obsidian-advanced": {
      "command": "uvx",
      "args": [
        "mcp-obsidian-advanced"
      ],
      "env": {
        "OBSIDIAN_API_KEY": "<your_api_key_here>",
        "OBSIDIAN_VAULT_PATH": "/path/to/your/vault/"
      }
    }
  }
}

Development/Unpublished Servers Configuration

json
{
  "mcpServers": {
    "mcp-obsidian": {
      "command": "uv",
      "args": [
        "--directory",
        "/dir/to/mcp-obsidian-advanced",
        "run",
        "mcp-obsidian"
      ],
      "env": {
        "OBSIDIAN_API_KEY": "<your_api_key_here>",
        "OBSIDIAN_VAULT_PATH": "/path/to/your/vault/"
      }
    }
  }
}

Development

Additional Documentation for obsidiantools Library and Obsidian REST API

Additional documentation for the obsidiantools library and Obsidian REST API can be found in the docs directory.

  • obsidiantools_in_15_minutes_documentation.md is a ipynb file that demonstrates use cases for obsidiantools.
  • obsidian_rest_api_documentation.yaml is a yaml file that demonstrates use cases for the Obsidian REST API.

Building

To prepare the package for distribution:

  1. Sync dependencies and update lockfile:
bash
uv sync

Debugging

Since MCP servers run over stdio, debugging can be challenging. For the best debugging experience, we strongly recommend using the MCP Inspector.

You can launch the MCP Inspector via npm with this command:

bash
npx @modelcontextprotocol/inspector uv --directory /path/to/mcp-obsidian-advanced run mcp-obsidian-advanced

Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.

You can also watch the server logs with this command:

bash
tail -n 20 -f ~/Library/Logs/Claude/mcp-server-mcp-obsidian-advanced.log

Installatie

TypingMind
Vereisten:

Node.js 18+

{
  "mcpServers": {
    "mcp-obsidian-advanced": {
      "command": "uvx",
      "args": [
        "mcp-obsidian-advanced"
      ],
      "env": {
        "OBSIDIAN_API_KEY": "<your_api_key_here>",
        "OBSIDIAN_VAULT_PATH": "/path/to/your/vault/"
      }
    }
  }
}

Beschikbare tools

  • obsidian_list_commands

    List all available commands you can run in obsidian interface. For commands used on specific notes, make sure to open a note first.

  • obsidian_open_files

    Open one or more files in the vault in a new leaf.

  • obsidian_periodic_notes

    Get current periodic note for the specified period. Returns both comprehensive metadata (tags, links, titles, etc.) and note content using the enhanced API approach.

  • obsidian_recent_periodic_notes

    Get most recent periodic notes for the specified period type. When include_content=True, return notes' comprehensive metadata (tags, links, titles, etc.) and note content using the enhanced API approach.

  • obsidian_append_to_file

    Append content to a new or existing file in the vault.

  • obsidian_list_files_in_dir

    Lists all files and directories that exist in a specific Obsidian directory.

  • obsidian_simple_search

    Simple search for documents matching a specified text query across all files in the vault. Use this tool when you want to do a simple text search

  • obsidian_patch_file

    Insert content into an existing note relative to a heading, block reference, or frontmatter field.

  • obsidian_delete_file

    Delete a file or directory from the vault.

  • obsidian_put_file

    Create a new file in your vault or update the content of an existing one in your vault.

  • obsidian_batch_get_files

    Return the contents and metadata of one or more notes (.md files) in your vault.

  • obsidian_understand_vault

    Get a comprehensive understanding of the vault structure. Returns: 1. directory tree representation and 2. NetworkX graph of note connections used to understand how different notes (.md) and other files (e.g. images, PDFs, referenced/attached) are connected. Combines filesystem directory structure with note relationship graph between notes (.md files).

  • obsidian_recent_changes

    Get recently modified files in the vault.

  • obsidian_get_active_note

    Get the content and metadata of the currently active note in Obsidian. Always returns the note that is most recently edited (edit with user).

  • obsidian_execute_commands

    Execute one or more commands in obsidian interface, in order. For commands used on specific notes, make sure to open a note first.

  • obsidian_complex_search

    Complex search for documents using a JsonLogic query. Supports standard JsonLogic operators plus 'glob' and 'regexp' for pattern matching. Results must be non-falsy.

           Use this tool when you want to do a complex search, e.g. for all documents with certain tags etc.
           ALWAYS follow query syntax in examples.
    
           Examples
            1. Match all markdown files
            {"glob": ["*.md", {"var": "path"}]}
    
            2. Match all markdown files with 1221 substring inside them
            {
              "and": [
                { "glob": ["*.md", {"var": "path"}] },
                { "regexp": [".*1221.*", {"var": "content"}] }
              ]
            }
    
            3. Match all markdown files in Work folder containing name Keaton
            {
              "and": [
                { "glob": ["*.md", {"var": "path"}] },
                { "regexp": [".*Work.*", {"var": "path"}] },
                { "regexp": ["Keaton", {"var": "content"}] }
    

Gebruik Obsidian Advanced MCP met meerdere AI-modellen

TypingMind koppelt MCP-tools aan de werkruimte. Zodra Obsidian Advanced is verbonden, kun je deze dus met verschillende AI-modellen in TypingMind gebruiken, zonder de verbinding voor elk model apart in te stellen. Deze MCP-integratie draait lokaal via de TypingMind MCP-connector op je apparaat.

Installatiehandleiding voor de lokale connector

Gebruik dit als de MCP-server toegang nodig heeft tot lokale bestanden, apps of privébronnen op je computer.

1

Open de MCP-instellingen

Ga in TypingMind naar Instellingen, Geavanceerde instellingen en vervolgens Model Context Protocol. Kies daar Connector instellen.

  1. Open TypingMind in je browser.
  2. Klik op het pictogram Instellingen.
  3. Ga naar Geavanceerde instellingen.
  4. Open het gedeelte Model Context Protocol.
  5. Klik op Connector instellen en kies Dit apparaat.
Instelscherm voor de TypingMind MCP-connector met Dit apparaat geselecteerd
2

Voer de connectoropdracht uit

Kies Dit apparaat, kopieer de opdracht uit TypingMind en voer deze uit in Terminal. Laat het proces draaien zolang je MCP gebruikt.

  1. Kopieer de installatieopdracht die TypingMind toont.
  2. Open Terminal op macOS of Windows Terminal op Windows.
  3. Plak de opdracht en voer deze uit.
  4. Keur de pakketinstallatie goed als Terminal vraagt of je wilt doorgaan.
  5. Laat het proces in het Terminal-venster draaien zolang je MCP-tools gebruikt.
3

Voeg Obsidian Advanced toe als server

Klik op Servers bewerken zodra de connectorstatus Gereed is en plak de MCP-serverconfiguratie.

  1. Wacht tot de connectorstatus Gereed aangeeft.
  2. Klik op Servers bewerken.
  3. Plak de MCP-serverconfiguratie van Obsidian Advanced.
  4. Sla de serverlijst op.
  5. Vernieuw om te controleren of de connector nog steeds klaar is voor gebruik.
MCP-instellingen van TypingMind met een actieve server en de knop Servers bewerken
{
  "mcpServers": {
    "obsidian-advanced": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-obsidian-advanced"
      ]
    }
  }
}
4

Gebruik de verbinding met verschillende modellen

Sla de serverlijst op, open Plug-ins en schakel de MCP-tools van Obsidian Advanced in. Selecteer vervolgens een ondersteund AI-model in TypingMind en gebruik de tools in de chat of wijs ze toe aan een AI-agent.

  1. Open de pagina Plug-ins in TypingMind.
  2. Schakel de MCP-tools van Obsidian Advanced in.
  3. Start een chat en kies het AI-model dat je wilt gebruiken.
  4. Gebruik de MCP-tools in een chat of wijs ze toe aan een AI-agent.
  5. Schakel wanneer nodig over naar een ander AI-model zonder opnieuw verbinding te maken met MCP.
TypingMind-chat met ingeschakelde MCP-tools en een geselecteerd AI-model
Kun je Obsidian Advanced gebruiken om me hiermee te helpen?
Obsidian Advanced
Zeker. Ik heb het gelezen.
Dit vond ik met Obsidian Advanced.

Veelgestelde vragen

Waarvoor wordt de MCP-server Obsidian Advanced gebruikt?

Obsidian Advanced is een MCP-server waarmee compatibele AI-clients verbinding kunnen maken met externe tools en context. In TypingMind hoef je deze MCP-server maar één keer toe te voegen om de tools beschikbaar te maken in je AI-werkruimte.

Kan ik Obsidian Advanced MCP met meerdere AI-modellen in TypingMind gebruiken?

Ja. TypingMind verbindt MCP-tools op werkruimteniveau. Daardoor kun je Obsidian Advanced gebruiken met verschillende AI-modellen, zoals Claude, ChatGPT, Gemini of andere modellen die je in TypingMind hebt ingesteld, zonder de MCP-server voor elk model afzonderlijk in te stellen.

Waarom Obsidian Advanced MCP gebruiken met TypingMind?

TypingMind is een van de beste interfaces voor chats met LLM's, omdat het meerdere AI-modellen, prompts, plug-ins, AI-agenten, API-sleutels en MCP-tools samenbrengt in één werkruimte. Als Obsidian Advanced verbonden is, kun je de MCP-tools ervan gebruiken met je favoriete modellen en je chatworkflow overzichtelijk houden in TypingMind.

Hoe verbind ik Obsidian Advanced MCP met TypingMind?

Obsidian Advanced werkt via de lokale MCP-connector van TypingMind. Dit is de beste optie als de MCP-server toegang nodig heeft tot lokale bestanden, desktopapps, opdrachtregeltools of privébronnen op je computer.

Welke tools biedt Obsidian Advanced MCP in TypingMind?

Obsidian Advanced biedt 16 MCP-tools die je kunt inschakelen via de pagina Plug-ins in TypingMind. Je kunt ze gebruiken in chats of toewijzen aan AI-agenten.

Moet ik mijn API-sleutels delen met TypingMind om Obsidian Advanced MCP te gebruiken?

Nee. TypingMind werkt in de eerste plaats lokaal en laat je de controle houden over je modelaanbieders, API-sleutels, prompts en MCP-configuratie. Als Obsidian Advanced authenticatie vereist, voeg je bij het maken van de verbinding de vereiste headers, OAuth-instellingen of lokale configuratie voor die MCP-server toe.

Gerelateerde MCP-servers

Toon alles

Maak nu je eigen AI-werkruimte

Schrijf je in voor onze nieuwsbrief en blijf op de hoogte van nieuwe functies en toekomstige weggeefacties 👇