SiYuan MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| SIYUAN_URL | No | Full SiYuan URL, overrides HOST and PORT if set. | |
| SIYUAN_HOST | No | SiYuan host, default 127.0.0.1, ignored if SIYUAN_URL is set. | 127.0.0.1 |
| SIYUAN_PORT | No | SiYuan port, default 6806, ignored if SIYUAN_URL is set. | 6806 |
| SIYUAN_TOKEN | Yes | SiYuan API Token, required for authentication. | |
| SIYUAN_MCP_DEBUG | No | Set to '1' to output debug info to stderr. | 0 |
| SIYUAN_MCP_TIMEOUT_MS | No | Timeout per API request in milliseconds. | 120000 |
| SIYUAN_MCP_UPLOAD_ROOTS | No | Colon/semicolon-separated list of allowed upload directories for local files. | current working directory |
| SIYUAN_MCP_MAX_TEXT_CHARS | No | Maximum text preview length for MCP. | 30000 |
| SIYUAN_MCP_MAX_RESPONSE_BYTES | No | Maximum response byte size. | 10485760 |
| SIYUAN_MCP_PROTECT_DESTRUCTIVE | No | Explicitly set to 'true' or '1' to block destructive operations. | false |
| SIYUAN_MCP_WRITE_PATH_PREFIXES | No | Comma-separated allowed write path prefixes in workspace. | /data/assets,/temp |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {} |
| resources | {} |
Tools
Functions exposed to the LLM to take actions
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| 最近更新的 10 篇文档 | 仅返回必要字段,避免将整篇正文注入上下文 |
| 所有笔记本 |
TDQS
Scored across 69 tools
Each tool targets a distinct resource and action. Even where similar operations exist (e.g., rename by path vs ID), the descriptions clearly differentiate the parameter style. The set is well-organized by category (notebooks, docs, blocks, databases, files), minimizing confusion.
All tool names follow a consistent verb_noun pattern using snake_case. Variations like 'rename_doc_by_id' or 'get_hpath_by_path' follow a predictable extension scheme. No mixing of styles or ambiguous verbs.
69 tools is large but appropriate for the comprehensive SiYuan note-taking domain, covering notebooks, documents, blocks, databases, files, and utilities. While slightly overwhelming, each tool serves a specific purpose and the scope justifies the count.
The tool surface covers all major CRUD operations for notebooks, documents, blocks, and databases, plus file management, export, templating, and system utilities. There are no obvious dead ends or missing essential operations for the stated purpose.