Skip to main content
Glama

Transform layer

transform_layer

Transform a layer’s pixels by moving, scaling, rotating, skewing, or flipping them around a pivot, with an option to affect only selected pixels.

Instructions

Move / scale / rotate / skew / flip a layer's pixels (or only the selected pixels with selectionOnly, which also moves the selection). Order: translate, rotate, skew, scale around origin.

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": "transform_layer"
  }
}

Input Schema

NameRequiredDescriptionDefault
flipNo
skewNo[skewX, skewY] degrees
layerNoLayer id, name, or index (0 = bottom, -1 = top). Default: the active layer.
scaleNouniform factor or [sx, sy]
originNoPivot: [x,y], "center" (canvas) or "content" (content bbox center, default)
rotateNodegrees clockwise
translateNo[dx, dy] px
selectionOnlyNoTransform only selected pixels

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.3/5.0
Behavior2/5

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

No annotations exist, so the description carries the full behavioral burden. It does disclose two genuinely useful traits — the fixed transform order (translate, rotate, skew, scale around origin) and that selectionOnly also relocates the selection — but says nothing about whether the operation is destructive/undoable, how masks or layer bounds are affected, or what happens with an empty selection or unknown layer. For a mutation tool with zero annotation coverage these are material omissions.

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?

Two sentences, front-loaded with the operation set and followed by the ordering constraint; no filler. The slash-delimited verb list is terse but readable, and the parenthetical is placed where it matters rather than trailing at the end.

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?

All 8 parameters are optional, there is no output schema and no annotations, so the description must justify default behavior on its own. It explains the operation set and ordering but omits return/confirmation behavior, undo semantics, and the failure modes of selectionOnly or an unresolvable layer id — gaps that matter for a no-required-param mutation.

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

Parameters4/5

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

Schema coverage is 88%, so the baseline is 3, and the description earns above baseline by documenting cross-parameter semantics the schema cannot express: the fixed application order of translate, rotate, skew and scale, all anchored around origin. It also clarifies that selectionOnly moves the selection alongside the pixels. Remaining parameters (flip enum, layer resolution) are already covered by 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?

The description names five concrete operations (move/scale/rotate/skew/flip) against a specific resource (a layer's pixels), so an agent can immediately tell this is a pixel-level geometric transform rather than a metadata edit like update_layer. It stops short of naming any sibling or stating the boundary explicitly, which keeps it at 4 rather than 5.

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 is only implied through the operation list and the selectionOnly parenthetical; there is no explicit 'use this when...' guidance, no statement of prerequisites (e.g. that selectionOnly requires an active selection), and no routing to alternative tools. An agent can infer when it applies, but nothing steers it away from misuse.

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