POST /v1/svgs/vectorizations.
The flagship model is Arrow (arrow-preview), purpose-built for high-quality SVG vectorization.
Example
- Node.js SDK
- cURL
Preparing the image
Cropping the input image tightly to the subject usually improves output quality. Useauto_crop as a fallback when you can’t crop manually.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
model | string | — | Required. Model identifier (e.g., arrow-preview). |
image | object | — | Required. Input image as { url: "..." } or { base64: "..." }. |
auto_crop | boolean | false | Automatically crop the image to the dominant subject before vectorization. |
target_size | integer | — | Square resize target in pixels (128—4096) applied before inference. |
n | integer | 1 | Number of outputs to generate (1—16). |
stream | boolean | false | When true, returns a Server-Sent Events stream with progressive rendering phases (reasoning, draft, content). |
temperature | number | 1 | Controls randomness (0—2). Lower values produce more deterministic output; higher values increase variety. |
top_p | number | 1 | Nucleus sampling (0—1). Limits token selection to the smallest set whose cumulative probability exceeds this value. Lower values make output more focused. |
presence_penalty | number | 0 | Penalizes tokens already present in prior output (-2 to 2). Positive values encourage the model to explore new patterns. |
max_output_tokens | integer | — | Upper bound for output token count (1—131072). |