Create or edit images

中文版本: 查看中文文档

Create a new image from a text prompt, or edit one or more input images depending on the selected model.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params

Create or edit images. model is the short model name. If omitted, the server defaults to nanobanana-pro.
For text-to-image, send an empty image_urls array. For image editing, send one or more image_urls.

Mode support:

  • Text-to-image only: grok-2-image
  • Editing only: seedream-4.5-seq, seedream-5.0-lite-seq, grok-imagine-image
  • Text-to-image + editing: nanobanana-pro, nano-banana-2, nano-banana-2-fast, seedream-4.5, seedream-5.0-lite, gpt-image-2

Model-specific parameters:

  • Supported ratio values vary by model.
  • resolution is supported only by nanobanana-pro, nano-banana-2, nano-banana-2-fast, and gpt-image-2.
  • quality is supported only by gpt-image-2.
  • num_images is supported only by seedream-4.5-seq and seedream-5.0-lite-seq, with a maximum of 15.

string

Text prompt for image generation.

image_urls
array of strings

Empty for text-to-image. Non-empty for image editing.

image_urls
string
enum

Optional. Defaults to nanobanana-pro.

string
enum

Supported values vary by model. See the request body description.

string
enum

Supported only by selected models. See the request body description.

Allowed:
string
enum

Supported only by gpt-image-2.

Allowed:
int32
1 to 15

Supported only by seedream-4.5-seq and seedream-5.0-lite-seq.

int32

Number of concurrent outputs to generate.

boolean
Response

Language
Credentials
Bearer
API Key
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json