# draw_shape

The Line, Rectangle and Ellipse tools: draw a line, rectangle or ellipse between two points (from, to; for rectangles and ellipses they are opposite corners of the bounding box, inclusive). filled fills rectangles and ellipses. Brush, ink and mirror options apply.

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

## Facts

- Tool: `draw_shape`
- 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: Other (Low risk)
- Registry record: grade F, identity unverified
- Server rate-limited: no
- Parameters: 12 (4 required)
- Recommended policy verdict: Rate-limited

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `to` | array | yes | End point / opposite corner [x, y] (inclusive). |
| `doc` | string | no | Document id (see doc_list); optional when only one document is open. |
| `ink` | string | no | simple (default; replaces pixels, transparent erases), alpha (blend over), lock_alpha (recolor only opaque pixels), behind (paint under existing pixels), shadin |
| `from` | array | yes | Start point / first corner [x, y]. |
| `color` | string | yes | Color as "#RRGGBB" or "#RRGGBBAA" (also "#RGB", "#RGBA", "rgb(r,g,b)", "rgba(r,g,b,a)" with a in 0-1 or 0-255, a CSS basic name like "red", or "transparent"). A |
| `frame` | integer | no | Frame (default: the active frame). |
| `layer` | object | no | Layer index or name (default: the active layer). Must not be a group. |
| `shape` | string | yes |  |
| `filled` | boolean | no | Fill rectangles and ellipses (default: outline only). |
| `mirror` | string | no | Symmetry: also draw mirrored (horizontal = left/right, vertical = top/bottom) across the canvas center, or across `mirror_axis_x` / `mirror_axis_y`. |
| `brush_size` | integer | no | Brush size in pixels, 1-64 (default 1). |
| `brush_shape` | string | no | square (default) or circle (round brush for sizes above 1). |

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": "draw_shape",
    "arguments": {
      "to": [],
      "from": [],
      "color": "<color>",
      "shape": "<shape>"
    }
  }
}
```

## Why draw_shape is rated Low

Without any rule in front of it, every call an agent makes to draw_shape happens silently: no trail, no cap, no way to know it misbehaved until something breaks downstream.

Risk signals: High parameter count (16 properties)

## Use case

AI agents call draw_shape as a supporting operation in Pixmith workflows.

## 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": {
    "draw_shape": {
      "limits": [
        {
          "counter": "draw_shape_rate",
          "window": "minute",
          "max": 60,
          "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
- `tween` — Execute — https://policylayer.com/tools/pixmith-mcp/tween.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_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
