# tween

Animate a layer (or group) by keyframes instead of redrawing it: properties x, y (offset in pixels), rotation (degrees, clockwise), scale_x, scale_y (1 = 100%), opacity (0-1). Between keys the value follows the key's ease: linear, hold, in_quad, out_quad, in_out_quad, in_out_cubic, out_back, out_bounce, or bezier with control points [x1, y1, x2, y2]. Actions: info (keys, pivot, options, the transform at frame), set_key, set_keys (several properties at one frame), remove_key (alias: delete_key), move_key, set_ease, set_pivot / reset_pivot (rotation/scale center), set_options (rotsprite, snap_scale, ignore_opacity), copy_keys / paste_keys, bake (render the tween into real cels: mode all / range / frame; new_layer puts them on a new layer; keep_source keeps the keys), bake_all. Tween rig (the app's Tween panel Parent picker): a layer can have a tween parent, so its transform is the parent's composed with its own about its own pivot: rotate a thigh and the shin, whose pivot is the knee, follows (thigh -> shin -> boot, body -> arm). Actions set_parent (parent = a layer; fails for a cycle, a group or a tilemap), clear_parent, get_parent, children (direct children of layer), composed_transform (at frame: matrix [a, b, c, d, e, f] with x' = a*x + c*y + e, y' = b*x + d*y + f including all ancestors, rotation in degrees, scale_x, scale_y and where the layer's pivot is on the canvas; a child without keys of its own just follows its parent). Opacity is not inherited. info shows parent, children and the effective frame range. bake and bake_all are rig-aware (a child bakes with its composed transform; baking a child alone detaches it; a layer that still has children needs keep_source or bake_all). The parent link is saved with the document. Tweened layers already render and export animated; bake when you need real per-frame pixels to edit.

Agent View of the PolicyLayer registry record for `tween`. HTML page: https://policylayer.com/tools/pixmith-mcp/tween

## Facts

- Tool: `tween`
- Server: Pixmith (`pixmith-mcp`) — https://policylayer.com/tools/pixmith-mcp.md
- Install: `npx -y pixmith-mcp`
- Homepage: https://www.npmjs.com/package/pixmith-mcp
- Risk category: Execute (High risk)
- Registry record: grade F, identity unverified
- Server rate-limited: no
- Parameters: 12 (1 required)
- Recommended policy verdict: Rate-limited

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `x` | number | no | set_pivot: pivot in canvas pixels. |
| `y` | number | no | set_pivot: pivot in canvas pixels. |
| `to` | integer | no | move_key: destination; copy_keys/bake range: last frame. |
| `doc` | string | no | Document id (see doc_list); optional when only one document is open. |
| `ease` | string | no | Ease from this key to the next (default linear). |
| `from` | integer | no | move_key/copy_keys/bake range: first frame. |
| `mode` | string | no | bake: all (default), range (from..to) or frame. |
| `frame` | integer | no | Key frame (default: active); info: frame to evaluate; paste_keys: where to paste; bake mode frame: the frame. |
| `layer` | object | no | Layer or group (default: active). |
| `value` | number | no | set_key: value. |
| `action` | string | yes | set_parent: Tween rig: give the layer a parent. |
| `bezier` | array | no | bezier ease: [x1, y1, x2, y2] (like CSS cubic-bezier). |

Parameters from the server's own tool schema.

## Example call (MCP tools/call, JSON-RPC 2.0)

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "tween",
    "arguments": {
      "action": "<action>"
    }
  }
}
```

## Why tween is rated High

tween triggers real processes with real consequences. An agent gone sideways doesn't fire it once. It starts dozens of builds, sends mass notifications, or burns through compute before anyone looks up.

Risk signals: High parameter count (26 properties)

## Use case

AI agents invoke tween to trigger actions in Pixmith. What it does depends on the arguments the agent supplies, and its effects often reach beyond the immediate call: builds kicked off, notifications sent, workflows started.

## Recommended policy (PolicyLayer)

Verdict: **Rate-limited**. Enforced by the PolicyLayer MCP gateway (https://policylayer.com/mcp-gateway) before a call reaches Pixmith:

```json
{
  "version": "1",
  "default": "deny",
  "tools": {
    "tween": {
      "limits": [
        {
          "counter": "tween_rate",
          "window": "minute",
          "max": 10,
          "scope": "grant"
        }
      ]
    }
  }
}
```

## Other tools on Pixmith (58)

- `brush` — Destructive — https://policylayer.com/tools/pixmith-mcp/brush.md
- `cel` — Destructive — https://policylayer.com/tools/pixmith-mcp/cel.md
- `clipboard` — Destructive — https://policylayer.com/tools/pixmith-mcp/clipboard.md
- `filter` — Destructive — https://policylayer.com/tools/pixmith-mcp/filter.md
- `frame` — Destructive — https://policylayer.com/tools/pixmith-mcp/frame.md
- `help` — Destructive — https://policylayer.com/tools/pixmith-mcp/help.md
- `iso_grid` — Destructive — https://policylayer.com/tools/pixmith-mcp/iso-grid.md
- `layer` — Destructive — https://policylayer.com/tools/pixmith-mcp/layer.md
- `palette` — Destructive — https://policylayer.com/tools/pixmith-mcp/palette.md
- `slice` — Destructive — https://policylayer.com/tools/pixmith-mcp/slice.md
- `tag` — Destructive — https://policylayer.com/tools/pixmith-mcp/tag.md
- `terrain` — Destructive — https://policylayer.com/tools/pixmith-mcp/terrain.md
- `terrain_paint` — Destructive — https://policylayer.com/tools/pixmith-mcp/terrain-paint.md
- `trace` — Destructive — https://policylayer.com/tools/pixmith-mcp/trace.md
- `doc_new` — Execute — https://policylayer.com/tools/pixmith-mcp/doc-new.md
- `draw_curve` — Execute — https://policylayer.com/tools/pixmith-mcp/draw-curve.md
- `draw_text` — Execute — https://policylayer.com/tools/pixmith-mcp/draw-text.md
- `free_transform` — Execute — https://policylayer.com/tools/pixmith-mcp/free-transform.md
- `render` — Execute — https://policylayer.com/tools/pixmith-mcp/render.md
- `run_lua` — Execute — https://policylayer.com/tools/pixmith-mcp/run-lua.md
- `sprite_size` — Execute — https://policylayer.com/tools/pixmith-mcp/sprite-size.md
- `transaction` — Execute — https://policylayer.com/tools/pixmith-mcp/transaction.md
- `transform` — Execute — https://policylayer.com/tools/pixmith-mcp/transform.md
- `color_mode` — Other — https://policylayer.com/tools/pixmith-mcp/color-mode.md
- `draw_pixels` — Other — https://policylayer.com/tools/pixmith-mcp/draw-pixels.md
- `draw_polygon` — Other — https://policylayer.com/tools/pixmith-mcp/draw-polygon.md
- `draw_shape` — Other — https://policylayer.com/tools/pixmith-mcp/draw-shape.md
- `draw_stroke` — Other — https://policylayer.com/tools/pixmith-mcp/draw-stroke.md
- `gradient` — Other — https://policylayer.com/tools/pixmith-mcp/gradient.md
- `history_goto` — Other — https://policylayer.com/tools/pixmith-mcp/history-goto.md
- …and 28 more: https://policylayer.com/tools/pixmith-mcp.md

## For agents

This record is a snapshot. Live verdicts and the full registry:

- Check every server in your MCP config at once: `npx -y policylayer stack`
- Vet a server before you add it: install the mcp-precheck skill — `npx skills add https://policylayer.com` (skill text: https://policylayer.com/skill.md)
- Query the registry over MCP: endpoint `https://api.policylayer.com/mcp` — tools `check_mcp_server`, `check_mcp_stack`, `check_tool`, `search_registry`, `get_change_events`

---

Source: the PolicyLayer MCP registry — one continuously verified record per MCP server. Full record: https://policylayer.com/registry?q=pixmith-mcp · API: https://policylayer.com/registry/api · Policy library: https://policylayer.com/policies/pixmith-mcp
