Docs
Image to SVG
Send an image to POST /v1/generate and VectorMojo redraws it as a clean SVG with live text. It is a redraw, not a pixel trace.
# base64 -i on macOS; base64 -w0 on Linux
IMG=$(base64 -i whiteboard.png | tr -d '\n')
curl https://api.vectormojo.com/api/v1/generate \
-H "Authorization: Bearer $BRUSH_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"prompt": "Redraw this whiteboard as a clean flow, left to right.",
"image": { "media_type": "image/png", "data": "'"$IMG"'" },
"aspect": "16:9",
"sync": true
}' The image field
| Field | What it takes |
|---|---|
image.media_type | image/png, image/jpeg or image/webp |
image.data | The file as plain base64 (no data: prefix). Up to 7,000,000 characters, about 5 MB of image. |
- VectorMojo reads the first bytes of the file. If they are not a PNG, JPEG or WebP, or do not match
media_type, the call gets400 invalid_image. - The REST API takes the image itself, not a link. (The MCP server's
generate-designtool takes animage_url.) - All other generate fields work as usual. A
promptis optional: use it to say what to change or keep.labelsare checked letter for letter. - The canvas comes from
sizeoraspect(default 16:10), not from the image.
What comes back
The same job and design as any generate. VectorMojo reads what the image shows, every word in it, its colours and its layout, then draws it again as vector shapes and live text.
- Works best on diagrams, whiteboard sketches, screenshots, charts, logos and icons.
- Hand-drawn lines come back as clean shapes, and handwriting as a normal font.
- A photo of a real scene comes back as a simple drawing, not a copy.
Price and your image
An image to SVG job costs the same as a generate on the same model (prices). VectorMojo does not keep the image once the job has ended. The design it made is kept with your other designs.
Designs are AI-generated. Outputs can contain factual mistakes, so review every design before you use it.