Skip to main content
Glama

paint_layer

Manage painting layers by ID or unique name, including creating, selecting, reordering, updating properties, duplicating, deleting, merging, flattening, stamping visible content, and applying masks.

Instructions

Manage layers by id or unique name. Indices bottom-to-top. create inserts above the active layer unless position (top/bottom) or index is given; reorder takes index or position top/bottom. stamp_visible adds a merged copy of everything visible (default at the top). name names created, duplicated or stamped layers; names are unique (an existing explicit name is an error, automatic names get ' 2'). merge_down accepts a clipped or non-normal upper layer (blended with the lower one only). properties (on create or update): name, opacity(0..1), blend, visible, locked, alpha_lock, clipping. Results include index and layer_count; list reports object_count (paint_object lists objects).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "paint_layer"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNoraster
nameNo
indexNo
actionNolist
layer_idNoTarget layer id or unique layer name; the active layer stays unchanged. Default: active layer
positionNo
propertiesNo
document_idNoTarget this document instead of the shared active one (recommended when several agents share the server)
include_backgroundNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.5.0

TDQS

A4/5.0
Behavior4/5

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

With no annotations supplied, the description carries the full burden and does disclose real behavior: unique-name enforcement, errors on duplicate explicit names, automatic ' 2' suffixes, merge_down's blending constraint, bottom-to-top indexing, and what results contain (index, layer_count). It stops short of stating whether delete, clear, flatten or merge_down are destructive/undoable, which matters most for a mutation tool.

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?

Dense and front-loaded: scope first, then per-action rules, then result shape. Almost every clause carries new information, though the long semicolon-chained sentence is harder to scan than a short bulleted structure would be.

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?

For a 17-action, 9-parameter tool with no output schema and no annotations, this is a solid but partial spec: it covers create/reorder/stamp_visible/merge_down/list and result fields, yet 8+ actions and 2 parameters remain undefined, leaving an agent unable to predict behavior for a substantial part of the surface.

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 coverage is only 22%, so the description must compensate. It adds meaning for name, index, position and properties (with the opacity 0..1 range and the full property list), but leaves kind and include_background unexplained and never documents info, select, duplicate, update, delete, clear, rasterize, flatten or the four mask_* actions.

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?

States a concrete verb and resource ("Manage layers by id or unique name") and immediately differentiates itself from a sibling by noting that list reports object_count while paint_object lists objects. The action-by-action notes make clear that this is the layer-level counterpart to object-level tools.

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?

Gives clear conditional guidance inside the tool: create inserts above the active layer unless position/index is given, reorder takes an index or top/bottom, and merge_down only applies to a clipped or non-normal upper layer. It also routes object enumeration to paint_object. It does not, however, say when to prefer this tool over paint_document or paint_selection for overlapping jobs.

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