Text-to-Image / Image Edit Task API Usage

Common Conventions

  • All interfaces require request headers Authorization: Bearer <apiKey> and Topview-Uid: <userId>
  • Successful response unified structure: { "code": "200", "message": "Success", "result": { ... } }
  • After task submission, returns taskId. Frontend polls the query interface to get results

I. Text-to-Image

1.1 Submit Task

POST /v1/common_task/text2image/task/submit

Request Headers

ParameterTypeRequiredDescription
Topview-UidstringYesUser ID

Request Body (JSON)

ParameterTypeRequiredDescription
modelstringYesModel display name, e.g., "Nano Banana 2", "Seedream 5.0", see supported models table below
promptstringYesPositive prompt text; some models have length limits (e.g., Midjourney v8.x ≤ 1024, Reve Image V2 ≤ 4000; most others with a limit use 10000)
aspectRatiostringYesAspect ratio, supported values vary by model, see supported models table below
resolutionstringModel-dependentResolution, e.g., "512p", "1K", "2K", "4K"; required for some models, not supported by others, see supported models table below
qualitystringModel-dependentQuality tier (case-insensitive). GPT Image 2 / Reve Image: low / medium / high, default medium; GPT Image 2.5 Flare / Sunburst: low / medium / high / xhigh / max, default medium; Midjourney v8.2: low / medium / high / ultra, default ultra; Midjourney v8.1: low / ultra, default ultra; Midjourney v7: low / medium / ultra, default ultra; not allowed for other models
generateCountintegerYesNumber of images to generate, 1~4
boardIdstringNoBoard ID. When provided, a task record will be created in the Board

Supported Models and Parameter Constraints

Note: The model parameter should use the model display name (e.g., "Nano Banana 2"), not the code.

Model NameAspect Ratio Options (aspectRatio)Resolution (resolution)Quality (quality)Remarks
Nano Banana 29:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 4:1, 1:4, 8:1, 1:8512p, 1K, 2K, 4K (required)Not supported, do not passSupports 14 aspect ratios; prompt ≤ 10000
Nano Banana 2 Lite9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 4:1, 1:4, 8:1, 1:81K (required, only supports 1K)Not supported, do not passSupports 14 aspect ratios; prompt ≤ 10000
Nano Banana Pro1:1, 2:3, 3:2, 3:4, 4:3, 4:5, 5:4, 9:16, 16:9, 21:91K, 2K, 4K (required)Not supported, do not passSupports 10 aspect ratios; prompt ≤ 10000
Nano Banana9:16, 3:4, 1:1, 4:3, 16:9Not supported, do not passNot supported, do not pass
Seedream 5.0 Proauto, 9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K (required)Not supported, do not passauto means the model automatically determines the aspect ratio; prompt ≤ 10000
Seedream 5.0 Liteauto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:92K (required, only supports 2K)Not supported, do not passJSON standard name; Seedream 5.0 is a compatibility alias; prompt ≤ 10000
Seedream 5.0auto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:92K (required, only supports 2K)Not supported, do not passCompatibility alias, equivalent to Seedream 5.0 Lite; prompt ≤ 10000
Seedream 4.5auto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:92K, 4K (required)Not supported, do not passauto means the model automatically determines the aspect ratio
Seedream 4.0auto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:91K, 2K, 4K (required)Not supported, do not passauto means the model automatically determines the aspect ratio
Reve Image V2auto, 9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 5:4, 4:5, 21:9, 2:1, 1:2, 17:9, 3:1, 1:3, 4:1, 1:44K (required, only supports 4K)Not supported, do not passSupports 18 aspect ratios; prompt ≤ 4000
Reve Image9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:91K, 2K, 4K (required)low / medium / high (optional, default medium)Text-to-Image only; prompt ≤ 10000
Midjourney v8.29:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:11K, 2K (required)low / medium / high / ultra (optional, default ultra)Supports 13 aspect ratios; prompt ≤ 1024
Midjourney v8.19:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:11K, 2K (optional, default 1K)low / ultra (optional, default ultra)Supports 13 aspect ratios; prompt ≤ 1024
Midjourney v79:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:11K (optional, default 1K, only supports 1K)low / medium / ultra (optional, default ultra)Supports 13 aspect ratios; prompt ≤ 10000
Qwen Image 3.0 Pro9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 21:9, 9:21, 2:1, 1:2, 5:4, 4:52K (required, only supports 2K)Not supported, do not passSupports 13 aspect ratios; prompt ≤ 10000
Qwen Image 3.09:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 21:9, 9:21, 2:1, 1:2, 5:4, 4:52K (required, only supports 2K)Not supported, do not passSupports 13 aspect ratios; prompt ≤ 10000
Wan 2.7 Image Pro9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:21K, 2K, 4K (required)Not supported, do not pass
Wan 2.7 Image9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:21K, 2K (required)Not supported, do not pass
Kling V3 Omni9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K, 4K (required)Not supported, do not pass
Kling V39:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K (required)Not supported, do not pass
Kling 2.19:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K (required)Not supported, do not pass
Grok Image Quality1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 2:1, 1:2, 20:9, 9:20, 19.5:9, 9:19.51K, 2K (required)Not supported, do not passSupports 13 aspect ratios
Grok Image1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 2:1, 1:2, 20:9, 9:20, 19.5:9, 9:19.51K, 2K (required)Not supported, do not passSupports 13 aspect ratios
GPT Image 2.5 Flare9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:1, 210:297, 297:2101K, 2K, 4K (required)low / medium / high / xhigh / max (optional, default medium)Supports 15 aspect ratios (including paper ratios); prompt ≤ 10000
GPT Image 2.5 Sunburst9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:1, 210:297, 297:2101K, 2K, 4K (required)low / medium / high / xhigh / max (optional, default medium)Supports 15 aspect ratios (including paper ratios); prompt ≤ 10000
GPT Image 29:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:1, 210:297, 297:2101K, 2K, 4K (required)low / medium / high (optional, default medium)Supports 15 aspect ratios (including paper ratios); prompt ≤ 10000
Kontext-Pro9:16, 3:4, 1:1, 4:3, 16:9Not supported, do not passNot supported, do not pass
Imagen 49:16, 3:4, 1:1, 4:3, 16:9Not supported, do not passNot supported, do not pass
  • aspectRatio: Required for all models, must be one of the supported ratios for that model
  • resolution: Models marked as "required" must pass this parameter; models marked as "optional, default xxx" may omit it (API fills the default); models marked as "not supported, do not pass" will return an error if provided
  • quality: Supported only by GPT Image 2, GPT Image 2.5 Flare / Sunburst, Reve Image, and Midjourney series; GPT/Reve default to medium when omitted, Midjourney defaults to ultra; other models return an error if provided
  • prompt: Required; models with a length limit return an error when exceeded
  • generateCount: 1~4, required

Request Example

POST /v1/common_task/text2image/task/submit
Topview-Uid: user_123

{
  "model": "GPT Image 2",
  "prompt": "A futuristic city skyline at dusk, neon lights reflected on wet streets, cinematic composition",
  "aspectRatio": "16:9",
  "resolution": "2K",
  "quality": "high",
  "generateCount": 2
}

Response Example

{
  "code": "200",
  "message": "Success",
  "result": {
    "taskId": "task_t2i_20251128001",
    "status": "success",
    "noticeUuid": "uuid_abc"
  }
}

If boardId is provided, the response will additionally return boardTaskIds and boardId fields.


1.2 Query Task Result

GET /v1/common_task/text2image/task/query

Request Parameters (Query)

ParameterTypeRequiredDefaultDescription
taskIdstringYes-Task ID returned from submission
needCloudFrontUrlbooleanNofalseWhether to return CloudFront URL

Request Example

GET /v1/common_task/text2image/task/query?taskId=task_t2i_20251128001
Topview-Uid: user_123

Response Example (In Progress)

{
  "code": "200",
  "message": "Success",
  "result": {
    "taskId": "task_t2i_20251128001",
    "status": "running",
    "errorMsg": null,
    "costCredit": "0.000",
    "images": []
  }
}

Response Example (Success)

{
  "code": "200",
  "message": "Success",
  "result": {
    "taskId": "task_t2i_20251128001",
    "status": "success",
    "errorMsg": null,
    "costCredit": "0.400",
    "images": [
      {
        "status": "success",
        "errorMsg": null,
        "fileId": "file_img_001",
        "filePath": "https://cdn.example.com/images/output_001.jpg",
        "width": 2560,
        "height": 1440,
        "boardTaskId": null
      },
      {
        "status": "success",
        "errorMsg": null,
        "fileId": "file_img_002",
        "filePath": "https://cdn.example.com/images/output_002.jpg",
        "width": 2560,
        "height": 1440,
        "boardTaskId": null
      }
    ]
  }
}

Response Example (Failure)

{
  "code": "200",
  "message": "Success",
  "result": {
    "taskId": "task_t2i_20251128001",
    "status": "fail",
    "errorMsg": "Model service unavailable",
    "costCredit": "0.000",
    "images": []
  }
}

II. Image Edit

Image editing supports generating edited images by providing one or more reference images + a prompt. Supports instruction-based modifications, style transfer, and other scenarios.

2.1 Submit Task

POST /v1/common_task/image_edit/task/submit

Request Headers

ParameterTypeRequiredDescription
Topview-UidstringYesUser ID

Request Body (JSON)

ParameterTypeRequiredDescription
modelstringYesModel display name, e.g., "Seedream 5.0", "Kontext-Pro", see supported models table below
promptstringYesEdit prompt text; some models have length limits (e.g., Midjourney v8.x ≤ 1024, Reve Image V2 ≤ 4000; most others with a limit use 10000)
inputImageFileIdsstring[]Model-dependentList of reference image fileIds; required by default; models marked "reference images optional" allow an empty list or omission; max count varies by model (get fileId from upload interface)
aspectRatiostringYesAspect ratio; Seedream / Nano Banana / Kontext-Pro / Reve Image V2 and others support "auto" (follow input image ratio), see supported models table below
resolutionstringModel-dependentResolution, e.g., "512p", "1K", "2K", "4K"; required for some models, not supported by others, see supported models table below
qualitystringModel-dependentQuality tier (case-insensitive). GPT Image 2 / Reve Image Edit / Reve Image Remix: low / medium / high, default medium; GPT Image 2.5 Flare / Sunburst: low / medium / high / xhigh / max, default medium; Midjourney v8.2: low / medium / high / ultra, default ultra; Midjourney v8.1: low / ultra, default ultra; Midjourney v7: low / medium / ultra, default ultra; not allowed for other models
generateCountintegerYesNumber of images to generate, 1~4
boardIdstringNoBoard ID. When provided, a task record will be created in the Board

Supported Models and Parameter Constraints

Note: The model parameter should use the model display name (e.g., "Seedream 5.0"), not the code.

Model NameAspect Ratio Options (aspectRatio)Resolution (resolution)Quality (quality)Max Input ImagesRemarks
Nano Banana 2auto, 9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 4:1, 1:4, 8:1, 1:8512p, 1K, 2K, 4K (required)Not supported, do not pass14auto follows input image ratio; reference images optional; prompt ≤ 10000
Nano Banana 2 Liteauto, 9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 4:1, 1:4, 8:1, 1:81K (required, only supports 1K)Not supported, do not pass14auto follows input image ratio; reference images optional; prompt ≤ 10000
Nano Banana Proauto, 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, 5:4, 9:16, 16:9, 21:91K, 2K, 4K (required)Not supported, do not pass6auto follows input image ratio; reference images optional; prompt ≤ 10000
Nano Bananaauto, 9:16, 3:4, 1:1, 4:3, 16:9Not supported, do not passNot supported, do not pass6auto follows input image ratio
Seedream 5.0 Proauto, 9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K (required)Not supported, do not pass10auto follows input image ratio; prompt ≤ 10000
Seedream 5.0 Liteauto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:92K (required, only supports 2K)Not supported, do not pass14JSON standard name; Seedream 5.0 is alias; prompt ≤ 10000
Seedream 5.0auto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:92K (required, only supports 2K)Not supported, do not pass14Compatibility alias; prompt ≤ 10000
Seedream 4.5auto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:92K, 4K (required)Not supported, do not pass14auto follows input image ratio
Seedream 4.0auto, 9:16, 3:4, 1:1, 4:3, 16:9, 21:91K, 2K, 4K (required)Not supported, do not pass5auto follows input image ratio
Reve Image V2auto, 9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 5:4, 4:5, 21:9, 2:1, 1:2, 17:9, 3:1, 1:3, 4:1, 1:44K (required, only supports 4K)Not supported, do not pass8auto follows input image ratio; prompt ≤ 4000
Reve Image Editauto, 9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:91K, 2K, 4K (required)low / medium / high (optional, default medium)1Image Edit only; single image mode; prompt ≤ 10000
Reve Image Remixauto, 9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:91K, 2K, 4K (required)low / medium / high (optional, default medium)6Image Edit only; multi-image mode; prompt ≤ 10000
Midjourney v8.29:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:11K, 2K (required)low / medium / high / ultra (optional, default ultra)4Supports 13 aspect ratios; prompt ≤ 1024
Midjourney v8.19:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:11K, 2K (optional, default 1K)low / ultra (optional, default ultra)4Supports 13 aspect ratios; prompt ≤ 1024
Midjourney v79:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:11K (optional, default 1K, only supports 1K)low / medium / ultra (optional, default ultra)4Supports 13 aspect ratios; prompt ≤ 10000
Qwen Image 3.0 Pro9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 21:9, 9:21, 2:1, 1:2, 5:4, 4:52K (required, only supports 2K)Not supported, do not pass3Reference images optional; prompt ≤ 10000
Qwen Image 3.09:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 21:9, 9:21, 2:1, 1:2, 5:4, 4:52K (required, only supports 2K)Not supported, do not pass3Reference images optional; prompt ≤ 10000
Wan 2.7 Image Pro9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:21K, 2K (required)Not supported, do not pass9Reference images optional
Wan 2.7 Image9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:21K, 2K (required)Not supported, do not pass9Reference images optional
Kling V3 Omni9:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K, 4K (required)Not supported, do not pass10Reference images optional
Kling V39:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K (required)Not supported, do not pass4Reference images optional
Kling 2.19:16, 3:4, 2:3, 1:1, 3:2, 4:3, 16:9, 21:91K, 2K (required)Not supported, do not pass4Reference images optional
Grok Image Quality1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 2:1, 1:2, 20:9, 9:20, 19.5:9, 9:19.51K, 2K (required)Not supported, do not pass3
Grok Image1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 2:1, 1:2, 20:9, 9:20, 19.5:9, 9:19.51K, 2K (required)Not supported, do not pass3
GPT Image 2.5 Flare9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:1, 210:297, 297:2101K, 2K, 4K (required)low / medium / high / xhigh / max (optional, default medium)16Supports 15 aspect ratios (including paper ratios); prompt ≤ 10000
GPT Image 2.5 Sunburst9:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:1, 210:297, 297:2101K, 2K, 4K (required)low / medium / high / xhigh / max (optional, default medium)16Supports 15 aspect ratios (including paper ratios); prompt ≤ 10000
GPT Image 29:16, 3:4, 1:1, 4:3, 16:9, 2:3, 3:2, 5:4, 4:5, 21:9, 9:21, 1:2, 2:1, 210:297, 297:2101K, 2K, 4K (required)low / medium / high (optional, default medium)16Supports 15 aspect ratios (including paper ratios); prompt ≤ 10000
Kontext-Proauto, 9:16, 3:4, 1:1, 4:3, 16:9Not supported, do not passNot supported, do not pass1Specialized for image editing; single image mode
  • inputImageFileIds: Required by default; models marked "reference images optional" allow an empty list or omission
  • aspectRatio: Required for all models, must be one of the supported ratios for that model
  • resolution: Models marked as "required" must pass this parameter; models marked as "optional, default xxx" may omit it (API fills the default); models marked as "not supported, do not pass" will return an error if provided
  • quality: Supported only by GPT Image 2, GPT Image 2.5 Flare / Sunburst, Reve Image Edit/Remix, and Midjourney series; GPT/Reve default to medium when omitted, Midjourney defaults to ultra; other models return an error if provided
  • prompt: Required; models with a length limit return an error when exceeded
  • generateCount: 1~4, required

Request Example

POST /v1/common_task/image_edit/task/submit
Topview-Uid: user_123

{
  "model": "GPT Image 2",
  "prompt": "Change the background to a snowy mountain landscape, keep the subject unchanged",
  "inputImageFileIds": ["file_src_img_001"],
  "aspectRatio": "1:1",
  "resolution": "2K",
  "quality": "medium",
  "generateCount": 1
}

Request Example (Multi-Image Reference)

POST /v1/common_task/image_edit/task/submit
Topview-Uid: user_123

{
  "model": "Nano Banana 2",
  "prompt": "Blend the style of both images into a unified artistic composition",
  "inputImageFileIds": ["file_img_style001", "file_img_content001"],
  "aspectRatio": "1:1",
  "resolution": "2K",
  "generateCount": 2
}

Response Example

{
  "code": "200",
  "message": "Success",
  "result": {
    "taskId": "task_ie_20251228001",
    "status": "success",
    "noticeUuid": "uuid_ie_xyz"
  }
}

If boardId is provided, the response will additionally return boardTaskIds and boardId fields.


2.2 Query Task Result

GET /v1/common_task/image_edit/task/query

Request Parameters (Query)

ParameterTypeRequiredDefaultDescription
taskIdstringYes-Task ID returned from submission
needCloudFrontUrlbooleanNofalseWhether to return CloudFront URL

Request Example

GET /v1/common_task/image_edit/task/query?taskId=task_ie_20251228001
Topview-Uid: user_123

Response Example (Success)

{
  "code": "200",
  "message": "Success",
  "result": {
    "taskId": "task_ie_20251228001",
    "status": "success",
    "errorMsg": null,
    "costCredit": "0.200",
    "images": [
      {
        "status": "success",
        "errorMsg": null,
        "fileId": "file_edited_001",
        "filePath": "https://cdn.example.com/images/edited_001.jpg",
        "width": 2560,
        "height": 1440,
        "boardTaskId": null
      }
    ]
  }
}

Response Example (Partial Success)

{
  "code": "200",
  "message": "Success",
  "result": {
    "taskId": "task_ie_20251228002",
    "status": "success",
    "errorMsg": "Partial tasks failed (1/2): Content policy violation",
    "costCredit": "0.200",
    "images": [
      {
        "status": "success",
        "errorMsg": null,
        "fileId": "file_edited_002",
        "filePath": "https://cdn.example.com/images/edited_002.jpg",
        "width": 2560,
        "height": 1440,
        "boardTaskId": null
      },
      {
        "status": "fail",
        "errorMsg": "Content policy violation",
        "fileId": null,
        "filePath": null,
        "width": null,
        "height": null,
        "boardTaskId": null
      }
    ]
  }
}

III. Common Specifications

Task Status Enumeration

Status ValueMeaning
initTask submitted, waiting for processing
runningTask is being processed
successTask completed successfully
failTask failed, see errorMsg field for error reason

Polling Recommendations

Recommended polling interval: 3–5 seconds, timeout should be set to 5 minutes.

Sub-tasks in images

When generateCount > 1, the images list contains multiple sub-task results. Each sub-task has an independent status.

  • Parent task status=success: All sub-tasks are completed (some sub-tasks may be fail, check the sub-task's status and errorMsg)
  • Parent task status=fail: All sub-tasks failed

When partial failures occur, the parent task's errorMsg summarizes the failure reasons, e.g., "Partial tasks failed (1/2): Content policy violation".

Query Response Fields

FieldTypeDescription
taskIdstringTask ID
statusstringTask status, see enumeration above
errorMsgstringError message (has value when task fails or partially fails)
costCreditnumberCredits consumed by task (floating point number)
boardIdstringAssociated Board ID (returned if task comes from Board)
imagesarrayList of generated image results, each item contains: status, errorMsg, fileId, filePath, width, height, boardTaskId

IV. Credit Billing Explanation

totalCost = unitCost × generateCount

Credit types: Text-to-Image is common_task_text2image, Image Edit is common_task_image_edit.

Billing Explanation: Credits are deducted when the task is submitted, settled based on actual consumption when the task succeeds, and refunded if the task fails.

Pricing Rules:

  • Models that support quality: prefer pricing[resolution_quality] (e.g., pricing["2K_high"], pricing["1K_ultra"]); when omitted, GPT Image 2 / GPT Image 2.5 / Reve series default to medium, Midjourney series default to ultra
  • Models with resolution but without quality: price by pricing[resolution] (e.g., pricing["2K"])
  • Models without resolution parameter: price by pricing["default"]

4.1 Text-to-Image (textToImage) Pricing Table


Models Billed by Resolution (Unit: Credits/Generation, generateCount=1)

For models that support quality, the table below shows the default-tier price (GPT/Reve: medium; Midjourney: ultra). See the Midjourney and GPT Image 2.5 resolution × quality detail tables below for full combinations.

Model Name512p1K2K4K
Nano Banana 20.250.400.600.85
Nano Banana 2 Lite0.30
Nano Banana Pro0.800.801.40
Seedream 5.0 Pro0.400.80
Seedream 5.0 Lite0.20
Seedream 5.00.20
Seedream 4.50.200.20
Seedream 4.00.150.150.15
Reve Image V22.00
Reve Image1.601.802.00
Midjourney v8.20.501.00
Midjourney v8.10.501.00
Midjourney v70.50
Qwen Image 3.0 Pro0.80
Qwen Image 3.00.30
Grok Image Quality0.601.00
Grok Image0.300.30
GPT Image 2.5 Flare0.200.320.44
GPT Image 2.5 Sunburst0.200.320.44
GPT Image 20.200.801.40
Kling 2.10.150.15
Kling V30.300.30
Kling V3 Omni0.300.300.60
Wan 2.7 Image0.400.40
Wan 2.7 Image Pro0.800.800.80

Midjourney resolution × quality Detail (Unit: Credits/Generation, generateCount=1)

Model NameResolutionlowmediumhighultra
Midjourney v8.21K0.500.500.500.50
Midjourney v8.22K1.001.001.001.00
Midjourney v8.11K0.500.50
Midjourney v8.12K1.001.00
Midjourney v71K0.500.500.50

When quality is omitted for Midjourney, billing uses ultra. Unsupported tiers must not be passed.


GPT Image 2.5 resolution × quality Detail (Unit: Credits/Generation, generateCount=1)

Model NameResolutionlowmediumhighxhighmax
GPT Image 2.5 Flare1K0.120.200.520.841.76
GPT Image 2.5 Flare2K0.200.320.961.603.52
GPT Image 2.5 Flare4K0.240.441.482.565.64
GPT Image 2.5 Sunburst1K0.120.200.520.841.76
GPT Image 2.5 Sunburst2K0.200.320.961.603.52
GPT Image 2.5 Sunburst4K0.240.441.482.565.64

When quality is omitted for GPT Image 2.5, billing uses medium. Text-to-Image and Image Edit use the same prices.


Fixed Price Models (Unit: Credits/Generation, not differentiated by resolution)

Model NameUnit Price
Nano Banana0.30
Kontext-Pro0.50
Imagen 40.50

4.2 Image Edit (imageEdit) Pricing Table

Image Edit pricing follows Text-to-Image model pricing in general. Image Edit does not include Imagen 4 or Reve Image (text-to-image edition); Reve Image Edit / Reve Image Remix support Image Edit only; Reve Image V2, Midjourney, and Qwen Image 3.0 series support both Text-to-Image and Image Edit; Wan 2.7 Image Pro in Image Edit supports only 1K/2K (no 4K pricing).


Models Billed by Resolution (Unit: Credits/Generation, generateCount=1)

For models that support quality, the table below shows the default-tier price (GPT/Reve: medium; Midjourney: ultra). See the Midjourney and GPT Image 2.5 resolution × quality detail tables below for full combinations.

Model Name512p1K2K4K
Nano Banana 20.250.400.600.85
Nano Banana 2 Lite0.30
Nano Banana Pro0.800.801.40
Seedream 5.0 Pro0.400.80
Seedream 5.0 Lite0.20
Seedream 5.00.20
Seedream 4.50.200.20
Seedream 4.00.150.150.15
Reve Image V22.00
Reve Image Edit1.601.802.00
Reve Image Remix1.601.802.00
Midjourney v8.20.501.00
Midjourney v8.10.501.00
Midjourney v70.50
Qwen Image 3.0 Pro0.80
Qwen Image 3.00.30
Grok Image Quality0.601.00
Grok Image0.300.30
GPT Image 2.5 Flare0.200.320.44
GPT Image 2.5 Sunburst0.200.320.44
GPT Image 20.200.801.40
Kling 2.10.150.15
Kling V30.300.30
Kling V3 Omni0.300.300.60
Wan 2.7 Image0.400.40
Wan 2.7 Image Pro0.800.80

Midjourney resolution × quality Detail (Unit: Credits/Generation, generateCount=1)

Model NameResolutionlowmediumhighultra
Midjourney v8.21K0.500.500.500.50
Midjourney v8.22K1.001.001.001.00
Midjourney v8.11K0.500.50
Midjourney v8.12K1.001.00
Midjourney v71K0.500.500.50

When quality is omitted for Midjourney, billing uses ultra. Unsupported tiers must not be passed. Image Edit pricing matches Text-to-Image.


GPT Image 2.5 resolution × quality Detail (Unit: Credits/Generation, generateCount=1)

Model NameResolutionlowmediumhighxhighmax
GPT Image 2.5 Flare1K0.120.200.520.841.76
GPT Image 2.5 Flare2K0.200.320.961.603.52
GPT Image 2.5 Flare4K0.240.441.482.565.64
GPT Image 2.5 Sunburst1K0.120.200.520.841.76
GPT Image 2.5 Sunburst2K0.200.320.961.603.52
GPT Image 2.5 Sunburst4K0.240.441.482.565.64

When quality is omitted for GPT Image 2.5, billing uses medium. Image Edit pricing matches Text-to-Image.


Fixed Price Models (Unit: Credits/Generation, not differentiated by resolution)

Model NameUnit Price
Nano Banana0.30
Kontext-Pro0.50