
blueblueeyes/siyuan-mcp-server
Developer toolsЭта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал
一个 MCP 服务器实现,提供与思源笔记系统的集成,使 AI 模型能够访问和操作笔记数据。
Обзор
一个 MCP 服务器实现,提供与思源笔记系统的集成,使 AI 模型能够访问和操作笔记数据。 An MCP server implementation that provides integration with the SiYuan Note system, enabling AI models to access and manipulate note data. * 笔记本管理 | Notebook Management * 文档操作 | Document Operations * 内容块控制 | Block Control * 文件和资源管理 | File and Asset Management * SQL 查询支持 | SQL Query Support * 属性管理 | Attribute Management * 导出和转换 | Export and Conversion * 系统功能 | System Functions All commands support detailed documentation via the help command. For example: * assets.uploadAssets - 上传资源文件 | Upload assets * attr.setBlockAttrs - 设置块属性 | Set block attributes * attr.getBlockAttrs - 获取块属性 | Get block attributes * block.insertBlock - 插入内容块 | Insert a block * block.updateBlock - 更新内容块 | Update block content * block.deleteBlock - 删除内容块 | Delete a block * block.moveBlock - 移动内容块 | Move a block * block.getBlockKramdown - 获取块的 Markdown 内容 | Get block Kramdown content * convert.pandoc - 使用 Pandoc 转换内容 | Convert content using Pandoc
README
Показан фрагмент оригинального README. Открыть оригинал.
SiYuan Note MCP Server
一个 MCP 服务器实现,提供与思源笔记系统的集成,使 AI 模型能够访问和操作笔记数据。
An MCP server implementation that provides integration with the SiYuan Note system, enabling AI models to access and manipulate note data.
功能特性 | Features
- 笔记本管理 | Notebook Management
- 文档操作 | Document Operations
- 内容块控制 | Block Control
- 文件和资源管理 | File and Asset Management
- SQL 查询支持 | SQL Query Support
- 属性管理 | Attribute Management
- 导出和转换 | Export and Conversion
- 系统功能 | System Functions
命令列表 | Command List
所有命令都支持使用 help 查询获取详细说明。例如:
All commands support detailed documentation via the help command. For example:
{
"type": "help",
"params": {
"type": "block.insertBlock"
}
}
资源管理 | Asset Management
assets.uploadAssets- 上传资源文件 | Upload assets
属性管理 | Attribute Management
attr.setBlockAttrs- 设置块属性 | Set block attributesattr.getBlockAttrs- 获取块属性 | Get block attributes
内容块操作 | Block Operations
block.insertBlock- 插入内容块 | Insert a blockblock.updateBlock- 更新内容块 | Update block contentblock.deleteBlock- 删除内容块 | Delete a blockblock.moveBlock- 移动内容块 | Move a blockblock.getBlockKramdown- 获取块的 Markdown 内容 | Get block Kramdown content
格式转换 | Format Conversion
convert.pandoc- 使用 Pandoc 转换内容 | Convert content using Pandoc
导出功能 | Export Functions
export.exportNotebook- 导出笔记本 | Export notebookexport.exportDoc- 导出文档 | Export document
文件操作 | File Operations
file.getFile- 获取文件内容 | Get file contentfile.putFile- 写入文件内容 | Put file contentfile.removeFile- 删除文件 | Remove filefile.readDir- 读取目录内容 | List files in directory
文档树操作 | File Tree Operations
filetree.createDocWithMd- 使用 Markdown 创建文档 | Create document with Markdownfiletree.renameDoc- 重命名文档 | Rename documentfiletree.removeDoc- 删除文档 | Remove documentfiletree.moveDocs- 移动文档 | Move documentsfiletree.getHPathByPath- 获取文档可读路径 | Get document HPath by pathfiletree.getHPathByID- 通过 ID 获取文档可读路径 | Get document HPath by ID
网络代理 | Network Proxy
network.forwardProxy- 网络请求代理 | Forward proxy request
笔记本管理 | Notebook Management
notebook.lsNotebooks- 列出所有笔记本 | List all notebooksnotebook.openNotebook- 打开笔记本 | Open notebooknotebook.closeNotebook- 关闭笔记本 | Close notebooknotebook.renameNotebook- 重命名笔记本 | Rename notebooknotebook.createNotebook- 创建笔记本 | Create notebooknotebook.removeNotebook- 删除笔记本 | Remove notebooknotebook.getNotebookConf- 获取笔记本配置 | Get notebook configurationnotebook.setNotebookConf- 设置笔记本配置 | Set notebook configuration
通知提醒 | Notifications
notification.pushMsg- 发送消息通知 | Push message notificationnotification.pushErrMsg- 发送错误通知 | Push error message notification
查询功能 | Query Functions
query.sql- 执行 SQL 查询 | Execute SQL query
Установка
npx -y @onigeya/siyuan-mcp-serverКонфигурация
{
"mcpServers": {
"siyuan": {
"command": "npx",
"args": [
"-y",
"@onigeya/siyuan-mcp-server"
],
"env": {
"SIYUAN_TOKEN": "your-siyuan-token"
}
}
}
}