Parameter | Type | Required? | Description |
---|---|---|---|
prompt | String | yes | Image generation prompt. |
model_type | String | no (default "small") | Model type, one of: "small", "medium", "large". Larger models have higher quality, longer generation time, and higher cost. |
aspect_ratio | String | no (default "1:1") | Image aspect ratio, one of: "1:1", "2:3", "3:2", "3:4", "4:3", "4:5", "5:4", "16:9", "9:16". |
image_size | String | no (default "thumbnail") | Image size, one of: "thumbnail" (256 px), "small" (512 px), "medium" (1024 px), "large" (1440 px). |
creativity | Integer | no (default 2) | Variability and creativity of image generation. Only used in "medium" and "large" models. |
photorealistic | Boolean | no (default false) | If true, generate photorealistic images. Only used in "large" model. |
random_seed | Integer | no (default null) | If set, it results in deterministic generation. |
Warning: for model size "small", image size must be "thumbnail" or "medium"' |
When successful, returns:
{
'image_generation_task': {
'id': 1
}
}