The API supports four output formats, selected via the 'format' field in the request body. SVG is vector output suitable for print and responsive web use — infinitely scalable, typically 5–40 KB per code. PNG is raster, lossless, transparent background supported, good for web and mixed-media embedding, typically 2–15 KB. JPEG is lossy raster, always opaque, suited for embedding in photos or flat-color backgrounds, typically 3–20 KB. WebP is lossy raster with broad modern browser support, best for web use where file size matters, typically 1–10 KB.
Output size is configurable via the 'size' field, from 64×64 to 2048×2048 pixels. SVG ignores this numerically — it's always vector — but uses the size hint to set its default viewBox. For print workflows, generate SVG whenever possible; you avoid all resolution concerns and the final print processor handles scaling.
Every styling option available in the web generator — body shape, eye shape, colors, gradients, logo overlay — is available via the API with the same option names. The full request schema lives in the OpenAPI spec at /api/openapi.json.