More modelsGoogleImagen4 fast

Generate image with google/imagen4-fast

Generates an image using the google/imagen4-fast model.

POST
/api/v1/model/generateImage
AuthorizationBearer <token>

API key is required to authorize requests. Obtain a key from your Atlas Cloud dashboard.

In: header

modelstring

model name

seed?integer

The random seed to use for the generation.

promptstring

The positive prompt for image generation.

enable_prompt_expansion?boolean

If set to true, the prompt optimizer will be enabled.

Defaultfalse
num_images?integer

The number of images to generate.

Default1
Range1 <= value <= 4
aspect_ratio?string

The aspect ratio of the generated image.

Value in"1:1" | "16:9" | "9:16" | "4:3" | "3:4"
resolution?string

The resolution of the output image.

Value in"1k"
negative_prompt?string

The negative prmpt for generating the output.

enable_base64_output?boolean

If enabled, the output will be encoded into a BASE64 string instead of a URL. This property is only available through the API.

Defaultfalse
enable_sync_mode?boolean

If set to true, the function will wait for the result to be generated and uploaded before returning the response. It allows you to get the result directly in the response. This property is only available through the API.

Defaultfalse

Response Body

curl -X POST "https://api.atlascloud.ai/api/v1/model/generateImage" \  -H "Content-Type: application/json" \  -d '{    "model": "google/imagen4-fast",    "prompt": "A serene landscape with mountains reflected in a crystal clear lake at sunset"  }'
{
  "id": "string",
  "urls": {},
  "model": "string",
  "status": "string",
  "outputs": [
    "string"
  ],
  "created_at": "2019-08-24T14:15:22Z",
  "has_nsfw_contents": [
    true
  ]
}