Repository navigation
feat: lownotes-mcp bridge for MCP clients - #113
Merged
Merged
Conversation
LowNotes serves the open vault to MCP clients over a per-user named pipe (Windows) or Unix socket, after a token handshake. The token lives in the OS credential store and never reaches the webview. Tools list, read and search notes and read links and backlinks; a resource template exposes notes by path. Off by default, and only vaults listed in the MCP settings are served. Closes #101
MCP clients launch lownotes-mcp, which reads the token from the OS credential store, checks that the pipe it reached belongs to the same Windows user, completes the handshake and relays stdio to the running app. When LowNotes is closed or MCP is off, it answers the first request with a JSON-RPC error that says why. Tauri bundles the binary next to the app; the release workflow adds it to the portable archives, the universal macOS build and the Arch packages, and the bundle smoke test checks the .deb ships it. Closes #102
# Conflicts: # src-tauri/Cargo.toml
# Conflicts: # src-tauri/Cargo.toml # src-tauri/src/credentials.rs # src-tauri/src/lib.rs # src-tauri/src/mcp.rs
This was referenced Oct 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #109 (MCP server); the base becomes
mainonce #109 merges.MCP clients (Claude Desktop, Claude Code, Cursor) launch local servers as a process and talk over stdio.
lownotes-mcpis that process: it relays between the client's stdio and the running LowNotes.The bridge
src-tauri/src/bin/lownotes-mcp.rs, a console binary. It callsmcp_bridge::run()in the library, so it shares the endpoint and credential code with the app.default-run = "lownotes"keepscargo runandtauri devon the app.settings.json, without writing the file. When MCP is off, or the app has not created a token yet, the bridge says so instead.GetNamedPipeServerProcessId, then the process token's SID).OKhandshake, bytes are copied both ways, flushing every chunk to stdout. The bridge exits when either side closes.tracing, atwarnby default (LOWNOTES_LOGoverrides it). No note content or token.Shipping
src/bin/*next to the app, so the NSIS/MSI installers, the.app, and the.deb,.rpmand AppImage packages include it.release.yml:lownotes-mcp;lipoon each beforetauri bundle;PKGBUILD.ciand the AUR template) installs/usr/bin/lownotes-mcpwith its own checksum.bundle.ymlchecks that the debug.debships/usr/bin/lownotes-mcp.Tests
initializeandtools/calland checks the exit code when the client closes.echo '{"jsonrpc":"2.0","id":1,"method":"initialize"}' | lownotes-mcpprints the error and exits 1.Full AGENTS.md verification on Windows:
bun install --frozen-lockfile,version:check,check,check:e2e,bun test, the Python script tests,cargo fmt --check,cargo clippy --lib --bins --tests -D warnings,cargo test --locked --lib,bun run buildandtest:e2eall pass.Not verified locally: the macOS universal release path and the Arch package. Both run only in the release workflow.
Closes #102