Replace Excalidraw canvas
replace_canvasReplace an existing Excalidraw canvas with a complete new document using atomic revision-controlled updates to prevent conflicts and maintain data integrity.
Instructions
Validates, restores, and atomically replaces one complete standard document.
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": {
"projectPath": "<projectPath>",
"canvasPath": "<canvasPath>",
"baseRevision": "<baseRevision>",
"mutationId": "<mutationId>",
"document": "<document>"
},
"name": "replace_canvas"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| document | Yes | ||
| canvasPath | Yes | Full workspace-relative canvas path under projectPath, for example designs/m3/main.excalidraw. Never pass only main.excalidraw. | |
| mutationId | Yes | ||
| projectPath | Yes | Full workspace-relative project path, for example designs/m3. | |
| baseRevision | Yes |