Skip to main content
Glama
SiYuan MCP Server
by MyrkoF

insert_block

Insert a markdown block into a SiYuan document or container block, optionally after a specified sibling, to add content at a precise position.

Instructions

Insert a markdown block into a document. To embed an existing database, use:

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "content": "<content>",
      "parentID": "<parentID>"
    },
    "name": "insert_block"
  }
}

Input Schema

NameRequiredDescriptionDefault
contentYesMarkdown content
parentIDYesParent block ID (the document or container block)
previousIDNoInsert after this sibling block ID (optional)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.1.1

TDQS

B3.4/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are supplied, so the description carries the full behavioral burden. It does not disclose permissions, whether insertion is append vs. positional by default, what happens if parentID or previousID is invalid, or what the tool returns. The embed example is useful but does not fill these behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, both front-loaded and purposeful. The first states the action; the second provides a specific content syntax example with no wasted wording.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple three-parameter insert tool with full schema coverage and no output schema, the definition covers the core action and an important embedding use case. It is not fully complete because it omits behavioral context such as insertion ordering, permissions, and error conditions.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so parentID, content, and previousID are already documented in the input schema. The description adds a valuable example of markdown content for embedding a database, but does not otherwise deepen parameter semantics beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: insert a markdown block into a document. It does not explicitly name how it differs from sibling tools like update_block or batch_block_ops, so sibling differentiation is left implicit rather than stated.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The only explicit usage guidance is the special embed snippet for an existing database. It does not say when to use insert_block versus update_block, batch_block_ops, or other alternatives, leaving the main routing decision implied.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.