Developers · API reference
Crisp Vector API
This is the exact same model that powers the website, hosted on Replicate. Send it a single logo, a list of files or a zip archive from Node, Python or plain HTTP, and get clean SVGs back, billed straight to your own Replicate account.
- Model
- gregpriday/crisp-vector
- Version
- f74491378327… pinned
- Runs on
- Replicate, CPU
- Price
- $0.25 per 1,000 logos about 2.5 s billed per logo
- Input
- One image, a list or a zip PNG, JPEG, WebP, GIF, BMP, TIFF · up to 10 MB and 16 MP each
- Output
- One SVG for every image
- Clients
- Node, Python, HTTP

TideWater.png.png
1536×15361.7 MB
POST /v1/predictions
replicate.run(
'gregpriday/crisp-vector:f744…',
{ input: { images: [logo] } }
) ● succeeded1 imagedefault settings
000.svg.svg
2 paths759 points11.5 KB
Quickstart
All you need is a Replicate account. Replicate runs the model and bills you for the time it uses, so there’s nothing to sign up for here. Pick your language once and every example on this page will follow it.
Get a Replicate token
Sign in to Replicate and create an API token. Calls are billed to that account by the second.
Create a tokenSet it, and install the client
The official client reads the token from the environment.
Terminal
export REPLICATE_API_TOKEN=r8_… npm install replicateConvert a logo
Save the code as
convert.mjsnext tologo.png, then runnode convert.mjs. The SVG is saved next to them with the background removed, using the same settings as the website. The code is below.
Convert one logo · convert.mjs
import Replicate from 'replicate';
import fs from 'node:fs/promises';
// Reads REPLICATE_API_TOKEN.
const replicate = new Replicate();
const png = await fs.readFile('logo.png');
const [svg] = await replicate.run(
'gregpriday/crisp-vector:f74491378327e1454dd5f8c55efdd845d0ed69931240e2c681fa6d1b5aa52b93',
{ input: { images: [png] } }
);
await fs.writeFile('logo.svg', svg); Inputs
Only images is required. Everything else
defaults to what the website uses, so leaving the options alone gets you the website’s settings,
with Background on Remove.
images array of files or URLs Required
The logos to convert, or a .zip of them. Each one becomes an SVG, and they’re converted in parallel.
Pass public URLs or local files. The Node and Python clients upload local files for you. With plain HTTP, a small file can go inline as a data URL.
- Formats
- PNG, JPEG, WebP, GIF, BMP, TIFF, or a .zip of them
- Size
- Up to 10 MB and 16 megapixels each
- Large images
- Processed at 2048 px on the long side
- Output
- One SVG per image, named by its position
qualitystringHow much work goes into each shape.
refinedDefault The best result. What the website uses.balancedSkips the vertex network and stroke rebuild. About 25 to 40% faster.fastThe quickest and roughest.
backgroundstringWhat happens to the colour behind the logo.
removeDefault A transparent background.keepThe estimated solid background, added as a rectangle.
gradientsbooleanWhether smooth gradients are kept as gradients.
trueDefault Smooth colour gradients come out as SVG gradients.falseNo gradients in the file: every shape gets a solid fill.
enclosedstringBackground-coloured shapes inside the mark, like the middle of an O.
holeDefault Cut out, so the page shows through.fillPainted in the background colour.
Output
You get back a list of file URLs, one for each image. The Node and Python clients give you files you can save straight to disk. Plain HTTP gives you the URLs.
A real response, trimmed · response.json
{
"id": "…",
"status": "succeeded",
"output": [
"https://replicate.delivery/xezq/…/000.svg"
],
"logs": "input 1 -> 000.svg (0.11 s)\n1 image(s) in 0.11 s",
"metrics": {
"images": 1,
"paths": 3,
"predict_time": 0.218
}
} When an input fails · response.json
"error": "… input 2: not a PNG, JPEG, WebP, GIF, BMP or TIFF image" Named by position
000.svg is the first image, 001.svg the second, and so on. Images from a zip go in name order and keep their names, like 003-acme.svg.
Not sorted
The output list comes back in any order, so match each SVG to its input by file name, not by where it sits in the list.
Deleted after an hour
Replicate deletes a call’s inputs, outputs and logs after an hour, so download the SVGs rather than storing the links.
Errors say which file
A bad file fails the call, and the error gives its position (counting from 1) so you know which one to take out.
Converting a batch
If you’ve got a folder of logos, zip it and send the one file. This example also keeps the background as a shape and trades a little polish for speed.
Convert a batch · batch.mjs
import Replicate from 'replicate';
import fs from 'node:fs/promises';
const replicate = new Replicate();
const zip = await fs.readFile('logos.zip');
const output = await replicate.run(
'gregpriday/crisp-vector:f74491378327e1454dd5f8c55efdd845d0ed69931240e2c681fa6d1b5aa52b93',
{
input: {
images: [zip],
quality: 'balanced',
background: 'keep'
}
}
);
// The list isn't in input order.
// The file names are: 000-acme.svg, …
for (const svg of output) {
const { pathname } = svg.url();
const name = pathname.split('/').pop();
await fs.writeFile(name, svg);
} Price and limits
Replicate bills your account for the CPU time each call uses, with no plan and no minimum. Logos are small, so 1,000 of them come to about $0.25.
- per 1,000 logos at the measured pace
- $0.25
- billed per logo, on average
- 2.5 s
- seconds a cold start can add, after the model has been idle
- 10 to 80
- and 16 megapixels, per image
- 10 MB
owner/model:versionPin the version
Every example here names version f7449137, so an update to the model can’t change your output. The newest version is on the Versions tab.
Prefer: waitWait, or get called back
Prefer: wait holds the request open for up to 60 seconds and returns the SVGs if they’re done by then. For anything longer, pass a webhook and Replicate posts the finished call to it.
Cancel-After: 10mSet a deadline
Cancel-After stops a call that runs too long, so a stuck batch can’t bill you for hours. The website uses ten minutes.
2048 pxSend what it will use
Anything over 2048 px is processed at 2048 px anyway, so resize big images first and upload less.
How I worked out the price · Replicate CPU (4 vCPU, 8 GB) at $0.0001/s × about 2.5 s per logo × 1,000 = about $0.25. Measured 2 Oct 2026: ten logos in one batch billed 24.6 s. Bigger, busier logos take longer. Sources: Replicate pricing, the model.
Common questions
Price, cold starts, batches and what happens to your images.
No. Downloading SVGs on the website is free, whereas the API runs on your own Replicate account and bills you for CPU time. At the pace I measured, that comes to about $0.25 per 1,000 logos.
For the same image, yes. The website calls this model and version with every input on its default, except background, which follows the Remove and Keep switch. The website does redraw a few files before it sends them (HEIC and AVIF images, and anything over 16 megapixels), so those can come out slightly differently.
It probably had to start up. After the model has been idle for a while, the next call can wait 10 to 80 seconds while it boots. Calls usually start sooner while it’s warm, and a batch in one call only waits once.
The limits are per image, not on how many you send, and a list or a zip both work. A call takes about as long as its images would one after another, so split a big batch into calls that finish well inside your Cancel-After deadline. Batching saves round trips and only waits for a cold start once, but the CPU time you’re billed is about the same.
No. API calls go straight from your code to Replicate, under your account and its terms. Replicate deletes each call’s inputs and outputs after an hour.
The same ones as on the website: flat marks, wordmarks, badges, and logos with gradients and light shading, which come back as real SVG gradients. Soft see-through shadows get approximated, tiny blurred text can’t be recovered, and photos aren’t a good fit.