Skip to main content
Glama

confluence_build_code_macro

Generate HTML storage format code macros for Confluence to safely insert code blocks and prevent InvalidValueException errors.

Instructions

生成 Confluence (KMS) 的代码宏(storage format HTML),用于安全插入代码块,避免 InvalidValueException 错误。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes代码内容(原始文本,会自动用 CDATA 包裹并处理特殊序列)
languageNo可选:语言(支持常见别名,如 js/ts/sh/yml,会自动归一化;无法识别时将省略 language 参数)
linenumbersNo可选:是否显示行号(true/false)
collapseNo可选:是否折叠(true/false)
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It mentions safety ('安全插入代码块') and error avoidance ('避免 InvalidValueException 错误'), which hints at behavioral traits like input sanitization. However, it lacks details on permissions required, rate limits, whether it's a read or write operation (implied write from '插入'), response format, or error handling beyond the named exception. For a tool with no annotations, this is insufficient disclosure.

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

Conciseness4/5

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

The description is a single, efficient sentence that front-loads the key purpose. It avoids redundancy and wastes no words, though it could be slightly more structured (e.g., by separating purpose from benefits). It's appropriately sized for the tool's complexity.

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

Completeness3/5

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

Given no annotations, no output schema, and 4 parameters with full schema coverage, the description is minimally adequate. It covers the 'what' and 'why' (purpose and error avoidance) but lacks details on behavioral aspects, output, or integration context. For a tool that likely performs a write operation (inserting code), more completeness is needed, but the schema handles parameters well.

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 the schema fully documents all parameters (code, language, linenumbers, collapse). The description doesn't add any parameter-specific semantics beyond what's in the schema—it doesn't explain parameter interactions, default behaviors beyond schema defaults, or usage examples. With high schema coverage, the baseline is 3, and the description doesn't compensate with extra insights.

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?

The description clearly states the tool's purpose: '生成 Confluence (KMS) 的代码宏(storage format HTML),用于安全插入代码块,避免 InvalidValueException 错误。' It specifies the verb ('生成' - generate), resource ('代码宏' - code macro), and context (Confluence/KMS). However, it doesn't explicitly differentiate from sibling tools like 'confluence_update_page' or 'confluence_create_page' that might also handle content insertion, though the focus on code macros is reasonably distinct.

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 description implies usage context: '用于安全插入代码块,避免 InvalidValueException 错误。' This suggests it should be used when inserting code blocks into Confluence to prevent errors. However, it doesn't provide explicit guidance on when to use this tool versus alternatives (e.g., vs. general page update tools for non-code content), nor does it mention prerequisites or exclusions. The guidance is present but not comprehensive.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/caijohnny/confluence-node'

If you have feedback or need assistance with the MCP directory API, please join our Discord server