Skip to main content
Convert a raster image (PNG, JPEG, WebP) into SVG via POST /v1/svgs/vectorizations. The flagship model is Arrow (arrow-preview), purpose-built for high-quality SVG vectorization.

Example

import { QuiverAI } from "@quiverai/sdk";

const client = new QuiverAI({
  bearerAuth: process.env["QUIVERAI_API_KEY"],
});

const result = await client.vectorizeSVG.vectorizeSVG({
  model: "arrow-preview",
  autoCrop: true,
  image: {
    url: "https://example.com/logo.png",
  },
});

Preparing the image

Cropping the input image tightly to the subject usually improves output quality. Use auto_crop as a fallback when you can’t crop manually.

Parameters

ParameterTypeDefaultDescription
modelstringRequired. Model identifier (e.g., arrow-preview).
imageobjectRequired. Input image as { url: "..." } or { base64: "..." }.
auto_cropbooleanfalseAutomatically crop the image to the dominant subject before vectorization.
target_sizeintegerSquare resize target in pixels (128—4096) applied before inference.
ninteger1Number of outputs to generate (1—16).
streambooleanfalseWhen true, returns a Server-Sent Events stream with progressive rendering phases (reasoning, draft, content).
temperaturenumber1Controls randomness (0—2). Lower values produce more deterministic output; higher values increase variety.
top_pnumber1Nucleus sampling (0—1). Limits token selection to the smallest set whose cumulative probability exceeds this value. Lower values make output more focused.
presence_penaltynumber0Penalizes tokens already present in prior output (-2 to 2). Positive values encourage the model to explore new patterns.
max_output_tokensintegerUpper bound for output token count (1—131072).