draw_rectangle
Draw rectangle shapes, outlined or filled, on the Aseprite canvas in one undoable step. Specify position, size, and hex color to add precise boxes during editing.
Instructions
Draws a rectangle (outline or filled) on the canvas in a single undo transaction.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"x": "<x>",
"y": "<y>",
"width": "<width>",
"height": "<height>",
"color": "<color>"
},
"name": "draw_rectangle"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | Top-left X | |
| y | Yes | Top-left Y | |
| color | Yes | Hex color | |
| width | Yes | Width in pixels | |
| filled | No | Whether to fill interior | |
| height | Yes | Height in pixels | |
| layerName | No | ||
| layerIndex | No | ||
| frameNumber | No | ||
| returnPreview | No |