canvas_add_image
Places an image on a tldraw canvas from an HTTPS or data URI URL, creating the asset and image shape. Pass real pixel dimensions when known, since the canvas does not measure the file.
Instructions
Place an image on a canvas from a URL (creates the tldraw asset + image shape). Pass real dimensions when known; the canvas does not measure the file.
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": {
"canvas": "<canvas>",
"src": "<src>"
},
"name": "canvas_add_image"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| h | No | Display height (default 300) | |
| w | No | Display width; pass the real pixel width when known (default 400) | |
| x | No | ||
| y | No | ||
| src | Yes | Image URL (https or data URI). For local files, upload to Roam first (e.g. the roam MCP's file_upload) and pass the resulting URL. | |
| name | No | Filename shown in summaries | |
| page | No | Tldraw page to target (name or page record id), for canvases with several pages — see canvas_read `pages`. Omit on single-page canvases. | |
| graph | No | Graph name or nickname. Auto-selects if only one graph is configured. | |
| canvas | Yes | Canvas page title (e.g. 'Canvas/My Map') or its 9-char page uid |