Import a draw.io, Visio, Lucid, Excalidraw, PlantUML or other diagram
import_diagramConvert draw.io, Visio, Mermaid, and other diagram files into editable notes, lines, and frames on a slate while preserving shape positions and returning the slate link.
Instructions
Turn a diagram file from another tool (draw.io, Visio, Lucidchart, Excalidraw, tldraw, Graphviz, PlantUML, Mermaid, XMind, FreeMind, OPML, Markdown outline) into editable notes, lines and frames on a slate, keeping where its shapes were drawn. Returns the slate link. The full reference is in describe, methods ["slates.importDiagram"].
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "import_diagram"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | The file, base64 (at most 5 MB). Give this or text. | |
| mode | No | save (the default) writes; preview returns what would change and saves nothing. The response says which happened. | save |
| name | No | The new slate's name (without shareId). | |
| text | No | A text format (Graphviz, PlantUML, Mermaid, an outline, draw.io XML, OPML ...) as plain text, instead of data. | |
| format | No | The format, when the file name does not say it. | |
| confirm | No | The confirmation id from a confirmation_required result, once the person agreed. | |
| shareId | No | Draw beside what this slate holds. Leave out to make a new private slate. | |
| fileName | No | The file's name; its extension names the format when format is left out. Without either, the format comes from what the file holds. | |
| projectId | No | Make the new slate in this project or folder (without shareId; you need to be an editor of it). | |
| idempotencyKey | No | Send with confirm: the idempotencyKey from the confirmation_required result. |