Recraft Ai Recraft 20b Svg
Playground
Try it on WavespeedAI!Recraft-20B SVG generates fast, affordable SVG vector images ideal for scalable graphics and icons. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing.
Features
Recraft 20B SVG
Generate scalable vector graphics (SVG) from text descriptions with Recraft 20B. This specialized model creates clean, production-ready vector illustrations across a wide range of styles — perfect for icons, logos, UI elements, and print-ready graphics that scale infinitely.
Why It Looks Great
- True vector output: Generates SVG files that scale to any size without quality loss.
- Extensive style library: 12+ specialized illustration styles from icons to detailed engravings.
- Production-ready: Clean paths and optimized output for immediate use.
- Icon specialization: Dedicated icon style for UI/UX and app design.
- Prompt Enhancer: Built-in tool to refine your descriptions automatically.
- Flexible aspect ratios: Multiple format options for any use case.
Parameters
| Parameter | Required | Description |
|---|---|---|
| prompt | Yes | Text description of the vector graphic you want to generate. |
| aspect_ratio | No | Output format: 1:1, 16:9, 9:16, 4:3, 3:4, etc. Default: 1:1. |
| style | No | Vector style preset (see Style Guide below). Default: icon. |
How to Use
- Write your prompt — describe the vector graphic you want to create.
- Use Prompt Enhancer (optional) — click to automatically enrich your description.
- Set aspect ratio — choose the format that fits your use case.
- Choose style — select from the extensive style library.
- Run — click the button to generate.
- Download — save your SVG file.
Pricing
Flat rate per image generation.
| Output | Cost |
|---|---|
| Per SVG | $0.044 |
Style Guide
| Style | Description | Best For |
|---|---|---|
| icon | Clean, simple iconography | App icons, UI elements, symbols |
| vector_illustration | General vector artwork | Versatile illustrations |
| vector_illustration/cartoon | Cartoon-style vectors | Fun, playful graphics |
| vector_illustration/doodle_line_art | Hand-drawn doodle aesthetic | Casual, sketchy designs |
| vector_illustration/engraving | Classic engraving style | Vintage, premium designs |
| vector_illustration/flat_2 | Modern flat design | UI, infographics, web |
| vector_illustration/kawaii | Cute Japanese style | Stickers, cute characters |
| vector_illustration/line_art | Clean line-based art | Minimalist illustrations |
| vector_illustration/line_circuit | Circuit board aesthetic | Tech, electronics themes |
| vector_illustration/linocut | Block print style | Artistic, textured look |
| vector_illustration/seamless | Tileable patterns | Backgrounds, textures |
Best Use Cases
- Icon Design — Create app icons, UI elements, and symbol sets.
- Logo Creation — Generate scalable logo concepts and brand marks.
- UI/UX Assets — Produce vector elements for interfaces and apps.
- Print Graphics — Create illustrations that print at any size.
- Pattern Design — Generate seamless tileable patterns.
- Game UI — Design RPG icons, badges, and decorative elements.
Example Prompts
- “Oil-painted round icon of a forest elf girl, golden border, painterly brushwork, fantasy RPG UI design, decorative look”
- “minimalist coffee cup icon, single color, simple shapes, app icon style”
- “vintage engraving of a sailing ship, detailed linework, nautical theme”
- “kawaii cat face sticker, cute expression, pastel colors, round design”
- “seamless geometric pattern, art deco style, gold and black”
- “flat illustration of a mountain landscape, modern minimal style, travel poster”
Pro Tips for Best Results
- Use the icon style for clean, simple graphics suitable for apps and UI.
- For detailed artwork, try engraving or line_art styles.
- Use seamless style for backgrounds and tileable patterns.
- Describe border styles and framing for RPG/game UI elements.
- Include color preferences in your prompt for better control.
- SVG output can be edited in tools like Illustrator, Figma, or Inkscape.
Notes
- Output is true SVG format — infinitely scalable vector graphics.
- SVG files can be further edited in any vector graphics software.
- Processing time may vary based on complexity.
- Some styles work better for certain subjects — experiment to find the best match.
Authentication
For authentication details, please refer to the Authentication Guide.
API Endpoints
Submit Task & Query Result
# Submit the task
curl --location --request POST "https://api.wavespeed.ai/api/v3/recraft-ai/recraft-20b-svg" \
--header "Content-Type: application/json" \
--header "Authorization: Bearer ${WAVESPEED_API_KEY}" \
--data-raw '{
"aspect_ratio": "1:1",
"style": "vector_illustration",
"enable_base64_output": false
}'
# Get the result
curl --location --request GET "https://api.wavespeed.ai/api/v3/predictions/${requestId}/result" \
--header "Authorization: Bearer ${WAVESPEED_API_KEY}"
Parameters
Task Submission Parameters
Request Parameters
| Parameter | Type | Required | Default | Range | Description |
|---|---|---|---|---|---|
| prompt | string | Yes | - | The positive prompt for the generation. | |
| aspect_ratio | string | No | 1:1 | 1:1, 16:9, 9:16, 4:3, 3:4 | The aspect ratio of the generated media. |
| style | string | No | vector_illustration | vector_illustration, vector_illustration/cartoon, vector_illustration/doodle_line_art, vector_illustration/engraving, vector_illustration/flat_2, vector_illustration/kawaii, vector_illustration/line_art, vector_illustration/line_circuit, vector_illustration/linocut, vector_illustration/seamless, icon, icon/broken_line, icon/colored_outline, icon/colored_shapes, icon/colored_shapes_gradient, icon/doodle_fill, icon/doodle_offset_fill, icon/offset_fill, icon/outline, icon/outline_gradient, icon/uneven_fill | Style of the generated image. |
| enable_base64_output | boolean | No | false | - | If enabled, the output will be encoded into a BASE64 string instead of a URL. This property is only available through the API. |
Response Parameters
| Parameter | Type | Description |
|---|---|---|
| code | integer | HTTP status code (e.g., 200 for success) |
| message | string | Status message (e.g., “success”) |
| data.id | string | Unique identifier for the prediction, Task Id |
| data.model | string | Model ID used for the prediction |
| data.outputs | array | Array of URLs to the generated content (empty when status is not completed) |
| data.urls | object | Object containing related API endpoints |
| data.urls.get | string | URL to retrieve the prediction result |
| data.has_nsfw_contents | array | Array of boolean values indicating NSFW detection for each output |
| data.status | string | Status of the task: created, processing, completed, or failed |
| data.created_at | string | ISO timestamp of when the request was created (e.g., “2023-04-01T12:34:56.789Z”) |
| data.error | string | Error message (empty if no error occurred) |
| data.timings | object | Object containing timing details |
| data.timings.inference | integer | Inference time in milliseconds |
Result Request Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| id | string | Yes | - | Task ID |
Result Response Parameters
| Parameter | Type | Description |
|---|---|---|
| code | integer | HTTP status code (e.g., 200 for success) |
| message | string | Status message (e.g., “success”) |
| data | object | The prediction data object containing all details |
| data.id | string | Unique identifier for the prediction, the ID of the prediction to get |
| data.model | string | Model ID used for the prediction |
| data.outputs | string | Array of URLs to the generated content (empty when status is not completed). |
| data.urls | object | Object containing related API endpoints |
| data.urls.get | string | URL to retrieve the prediction result |
| data.status | string | Status of the task: created, processing, completed, or failed |
| data.created_at | string | ISO timestamp of when the request was created (e.g., “2023-04-01T12:34:56.789Z”) |
| data.error | string | Error message (empty if no error occurred) |
| data.timings | object | Object containing timing details |
| data.timings.inference | integer | Inference time in milliseconds |