Claude MCP for Obsidian using Rest API

Hi Obsidian Community!

https://github.com/PublikPrinciple/obsidian-mcp-rest

I’m working on implementing an MCP (Model Context Protocol) server that integrates with Obsidian’s Local REST API plugin. The goal is to allow AI assistants like Claude to interact directly with Obsidian vaults in a secure, local manner.

Project Overview

Technical Details

The implementation uses:

  • Node.js/TypeScript
  • Obsidian Local REST API Plugin
  • Standard MCP communication via stdin/stdout

Current Features:

  • List vault notes
  • Read note contents
  • Write/update notes
  • Search functionality
  • Get note metadata

Current Issues

  1. TypeScript compilation errors relating to MCP type definitions
  2. Need guidance on best practices for Obsidian REST API integration
  3. Looking for input on security considerations when interfacing with Obsidian

Questions for the Community

  1. Has anyone implemented something similar using the Local REST API plugin?
  2. Are there specific Obsidian API considerations I should be aware of?
  3. Any recommendations for handling vault permissions safely?
  4. Looking for code review and security audit from experienced Obsidian plugin developers

How You Can Help

  1. Review the current implementation on GitHub
  2. Share experiences with Local REST API plugin
  3. Suggest improvements or best practices
  4. Help with TypeScript/Node.js implementation

Implementation Details

// Example of current tool implementation
export class ReadNoteTool extends BaseTool {
  constructor(api: ObsidianAPI) {
    super(
      api,
      'readNote',
      'Read the contents of a specific note',
      {
        type: 'object',
        required: ['path'],
        properties: {
          path: {
            type: 'string',
            description: 'Path to the note to read'
          }
        }
      }
    );
  }

  async execute(args: { path: string }): Promise<ToolResponse> {
    const note = await this.api.readNote(args.path);
    return {
      content: [{
        type: 'text',
        text: note.content
      }]
    };
  }
}
6 Likes

Love it, following :muscle:

Very cool reach out off post if down to collab

sounds cool! How this might differ from the one that is currently listed at the MCP Servers Github for Obsidian → GitHub - smithery-ai/mcp-obsidian: A connector for Claude Desktop to read and search an Obsidian vault.

Sounds interesting

I’m experimenting with “mcp-obsidian” and “obsidian-mcp-tools” atm

“obsidian-mcp-tools” installation is via community plugin “MCP Tools” which installs the MCP Server as a .exe in the Plugin Folder. I don’t really like this but it’s easier to setup and I can see a lot of people happy using this method.

mcp-obsidian requires manual installation but you can see the source code which is nice.

Which one is better is still to be determined.

What I really want to be able to do is not use Claude Desktop (free tier limits)
If I could find a way to integrate the Anthropic API that would be a lot more useful to me

Showcase video if you’re interested