Skip to main content
Glama

add_decorations

Place multiple decorations on a page at set coordinates, control stacking order, and layer them below text or nodes to build poster, card, and slide layouts.

Instructions

把装饰素材放到一页上(一次可放多个,按顺序叠放;list_assets 的 decorations 查 id):每项给 decoration、x、y(盒子左上角的页面坐标)、width(不给按页面短边的默认比例),高度按装饰的宽高比算。color(#RRGGBB)换掉装饰本来的主色(手绘线条和贴纸换整体颜色,标签换底色,字色自动取黑或白);text 换标签上的字;rotation 旋转(度);below 填同页一个顶层节点的 id 或图层名,装饰就放在它下面一层(荧光笔、胶带、色块垫在文字下面时用),不给则放在最上层。用 documentId 时就地更新这份文档,返回每个装饰的 nodeId、path 和盒子;之后可以用 apply_actions 改,用 check_document 检查有没有压住文字。

Input Schema

NameRequiredDescriptionDefault
itemsYes要放的装饰,按顺序叠放
slideIdNo放在哪一页,默认文档当前页(activeSlideId)
documentNo完整的 v44(或 v1–43 旧版)文档 JSON,可替代 documentId
documentIdNo创建或修改文档的工具返回的 documentId(推荐:不必来回传整份文档)
documentPathNo文档 JSON 文件的路径,可替代 documentId
includeDocumentNo同时返回完整文档 JSON(默认只返回 documentId 和 version)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations, the description carries the full load and does so richly: stacking order for multiple items, default width from the page's short edge, height derived from aspect ratio, per-type color semantics (lines/stickers recolor, labels recolor background, text auto black/white), layering relative to a top-level node, in-place update via documentId, and the return payload (nodeId、path、盒子).

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?

Front-loaded with the action and dense with actionable detail; every clause carries information. It is a single semicolon-chained sentence, which makes it harder to scan than it could be, but there is essentially no filler.

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 6-parameter mutation tool with no annotations and no output schema, the description covers what is created, defaults, layering, the document-passing options, return fields, and the follow-up tools. Nothing an agent needs to invoke it correctly is missing.

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 coverage is already 100%, but the description still adds real meaning beyond it — how color behaves per decoration type, that text only affects labels, what `below` means in z-order terms, and the default width/height derivation. This is value on top of the schema, not restatement.

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+resource (把装饰素材放到一页上), states batch scope (一次可放多个,按顺序叠放), and tells where decoration ids come from (list_assets 的 decorations 查 id). An agent can distinguish this from apply_actions or add_template_pages without opening any schema.

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

Usage Guidelines4/5

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

It gives concrete conditional guidance: use `below` for highlighters/tape/color blocks that must sit under text, and it states the follow-up path (改 with apply_actions, 检查 with check_document). It does not say when NOT to use this tool versus a sibling, so it falls just short of explicit alternative routing.

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