Skip to main content
Glama
lucaszarzur

CherryTree MCP Server

by lucaszarzur

append_codebox_to_node

Append a codebox or raw XML to a CherryTree node, with automatic byte-level audit and rollback on XML parse failure.

Instructions

Append a codebox (or raw XML content) to an existing node.

Args: node_id: Node ID. code: Code content (ignored if content_xml is set). syntax: Syntax language. text_before: Text before codebox (ignored if content_xml is set). text_after: Text after codebox (ignored if content_xml is set). content_xml: Raw CherryTree XML to append. See create_node docs for format.

Returns: Confirmation message followed by byte-by-byte audit report. On XML parse failure, backup is restored automatically (ROLLBACK).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeNo
syntaxNosh
node_idYes
text_afterNo
content_xmlNo
text_beforeNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

Since no annotations are provided, the description carries the full behavioral burden. It discloses parameter precedence (code/text are ignored if content_xml is set), automatic rollback on XML parse failure, and a byte-by-byte audit report in the return value. It could additionally note mutation/persistence side effects, but append semantics already imply modification.

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?

The description is compact, front-loaded with the core action, and organized into clear Args/Returns sections. Each line adds necessary information, with no filler or repetition of schema defaults.

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

Completeness5/5

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

For a tool with six parameters, raw XML input, rollback behavior, and an output schema, the description covers all necessary invocation details: parameter meanings, precedence rules, return format, and failure recovery. It is complete enough for an agent to call correctly without needing additional context.

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

Parameters5/5

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

Schema description coverage is 0%, and the description fully compensates by defining every parameter: node_id, code, syntax, text_before, text_after, and content_xml. It also adds critical semantic nuance, such as which parameters are ignored when content_xml is provided.

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

Purpose5/5

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

The description opens with a specific verb and resource: 'Append a codebox (or raw XML content) to an existing node.' It also explicitly scopes the target to an existing node, which distinguishes it from create_node_with_codebox without ambiguity.

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?

Usage context is implied clearly: use this when appending to an existing node. However, it does not explicitly name alternatives like create_node_with_codebox or update_node_content, nor does it state when not to use this tool in favor of those siblings.

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