首页
学习
活动
专区
圈层
工具
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往
首页
学习
活动
专区
圈层
工具
MCP广场
MCP广场 >详情页
mcp-server云托管模式2025-06-160分享
github
通过模型上下文协议(Model Context Protocol)将 Inkdrop 笔记应用与 Claude AI 集成,允许 Claude 搜索、读取、创建和更新您 Inkdrop 数据库中的笔记。
By inkdropapp
2025-06-160
github
详情内容

Inkdrop MCP 服务器

这是一个为Inkdrop 本地 HTTP 服务器 API提供的模型上下文协议服务器。

Inkdrop 服务器 MCP 服务器

安装

  1. 设置本地 HTTP 服务器

  2. 将服务器配置添加到 Claude Desktop:

    • MacOS:~/Library/Application Support/Claude/claude_desktop_config.json
    • Windows:%APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "inkdrop": {
      "command": "npx",
      "args": ["-y", "@inkdropapp/mcp-server"],
      "env": {
        "INKDROP_LOCAL_SERVER_URL": "http://localhost:19840",
        "INKDROP_LOCAL_USERNAME": "你的本地服务器用户名",
        "INKDROP_LOCAL_PASSWORD": "你的本地服务器密码"
      }
    }
  }
}

组件

工具

  1. read-note:通过笔记 ID 从数据库中检索笔记的完整内容。
    • 必需输入:
      • noteId:要检索的笔记 ID。可以在笔记文档中找到,始终以 note: 开头。
  2. search-notes:列出包含给定关键字的所有笔记。
    • 必需输入:
      • keyword:要搜索的关键字。
    • 注意:结果包含截断的笔记正文(200 个字符)。使用 read-note 获取完整内容。
    • 支持高级搜索限定符,如 book:tag:status:title: 等。
  3. list-notes:列出满足指定条件的所有笔记。
    • 必需输入:
      • bookId:笔记本 ID。始终以 'book:' 开头。
    • 可选输入:
      • tagIds:用于过滤的标签 ID 数组。每个以 'tag:' 开头。
      • keyword:用于过滤笔记的关键字。
      • sort:排序字段(updatedAtcreatedAttitle)。默认:updatedAt
      • descending:反转输出顺序。默认:true
    • 注意:结果包含截断的笔记正文(200 个字符)。使用 read-note 获取完整内容。
  4. create-note:在数据库中创建新笔记。
    • 必需输入:
      • bookId:笔记本 ID。必须以 'book:' 开头或为 'trash'。
      • title:笔记标题。
      • body:Markdown 格式的笔记内容。
    • 可选输入:
      • status:笔记状态(noneactiveonHoldcompleteddropped)。
  5. update-note:更新数据库中的现有笔记。
    • 必需输入:
      • _id:笔记 ID。必须以 'note:' 开头。
      • _rev:修订 ID(CouchDB MVCC 令牌)。
      • bookId:笔记本 ID。必须以 'book:' 开头或为 'trash'。
      • title:笔记标题。
      • body:Markdown 格式的笔记内容。
    • 可选输入:
      • status:笔记状态(noneactiveonHoldcompleteddropped)。
  6. list-notebooks:检索所有笔记本的列表。
  7. list-tags:检索所有标签的列表。

调试

由于 MCP 服务器通过 stdio 运行,调试可能具有挑战性。为了获得最佳调试体验,我们强烈建议使用MCP 检查器

你可以通过 npm 使用以下命令启动 MCP 检查器:

npx @modelcontextprotocol/inspector "./dist/index.js"

确保环境变量配置正确。

启动后,检查器将显示一个 URL,你可以在浏览器中访问该 URL 开始调试。

你还可以使用以下命令查看服务器日志:

tail -n 20 -f ~/Library/Logs/Claude/mcp-server-inkdrop.log
通过SSE URL连接服务
Server已在腾讯云托管,可在连接后免费调用和在线进行工具测试~
工具测试
已支持Server下的5个工具,可选择工具进行在线测试
read-note
Retrieve the complete contents of the note by its ID from the database.
search-notes
List all notes that contain a given keyword. The result does not include entire note bodies as they are truncated in 200 characters. You have to retrieve the full note content by calling `read-note`. Here are tips to specify keywords effectively: ## Use special qualifiers to narrow down results You can use special qualifiers to get more accurate results. See the qualifiers and their usage examples: - **book** `book:Blog`: Searches for notes in the 'Blog' notebook. - **tag** `tag:JavaScript`: Searches for all notes having the 'JavaScript' tag. Read more about [tags](https://docs.inkdrop.app/manual/write-notes#tag-notes). - **status** `status:onHold`: Searches for all notes with the 'On hold' status. Read more about [statuses](/reference/note-statuses). - **title** `title:"JavaScript setTimeout"`: Searches for the note with the specified title. - **body** `body:KEYWORD`: Searches for a specific word in all notes. Equivalent to a [global search](#search-for-notes-across-all-notebooks). ### Combine qualifiers You can combine the filter qualifiers to refine data even more. **Find notes that contain the word 'Hello' and have the 'Issue' tag.** ```text Hello tag:Issue ``` **Find notes that contain the word 'Typescript,' have the 'Contribution' tag, and the 'Completed' status** ```text Typescript tag:Contribution status:Completed ``` ## Search for text with spaces To find the text that includes spaces, put the text into the double quotation marks ("): ```text "database associations" ``` ## Exclude text from search To exclude text from the search results or ignore a specific qualifier, put the minus sign (-) before it. You can also combine the exclusions. See the examples: - `-book:Backend "closure functions"`: Ignores the 'Backend' notebook while searching for the 'closure functions' phrase. - `-tag:JavaScript`: Ignores all notes having the 'JavaScript' tag. - `-book:Typescript tag:work "Data types"`: Ignores the 'Typescript' notebook and the 'work' tag while searching for the 'Data types' phrase. - `-status:dropped title:"Sprint 10.0" debounce`: Ignores notes with the 'Dropped' status while searching for the 'debounce' word in the note with the 'Sprint 10.0' title. - `-"Phrase to ignore" "in the rest of a sentence"`: Ignores the 'Phrase to ignore' part while searching for 'in the rest of a sentence'. Note that you can't specify excluding modifiers only without including conditions. **WARNING**: Make sure to enter a text to search for after the exclusion modifier. - ✅ Will work `-book:Backend "closure functions"` - ⛔️ Won't work `-book:Backend`. There's no query. Inkdrop doesn't understand what to search for.
create-note
Create a new note in the database
update-note
Update the existing note in the database
list-notebooks
Retrieve a list of all notebooks
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档