generateWithStyle
Generate new images that match the visual style of a reference image: supply a style_image (URL or base64) plus a text prompt describing what to create and an optional image_type (defaults to sprite). The job result is an array of image results, each with a url; request n (1-4) to control the number of variations. The style_image is uploaded and validated, and an image larger than 15MB is rejected with HTTP 400. Credits are held when the job is accepted and refunded if it fails or is cancelled; the charge scales with the number of images produced. Use this instead of createImage when style consistency with an existing asset matters; use editImage to alter the content of a specific image rather than borrow its style, and removeBackground to isolate a subject. Pass an optional request_id to tag the results so you can retrieve them later via listGenerations (type image). Async generation job: returns {id, status} - poll getApiJob (job and credit contract: see the server instructions).
Credits: This endpoint consumes 0.5 credits per result.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| requestBody | Yes | Payload for generating new content while maintaining the visual style of a reference image |