Skip to main content
POST
/
v1
/
tasks
GPT-Image Series
curl --request POST \
  --url https://www.qingbo.dev/v1/tasks \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "<string>",
  "action": "<string>",
  "prompt": "<string>",
  "n": 123,
  "seed": 123,
  "aspect_ratio": "<string>",
  "resolution": "<string>",
  "image_urls": [
    "<string>"
  ],
  "callback_url": "<string>",
  "callback_events": [
    "<string>"
  ]
}
'
{
  "task_id": "task-wave1775285160b950328499",
  "model": "gpt-image-2",
  "action": "generate",
  "status": "queued",
  "created_at": 1775285160040,
  "progress": 0
}

Documentation Index

Fetch the complete documentation index at: https://docs.qingbo.dev/llms.txt

Use this file to discover all available pages before exploring further.

OpenAI’s GPT-Image generation models, across three generations:
  • GPT-Image-2 — flagship new release, expanded to 13 ratios × 1K/2K/4K resolution tiers with independent billing, up to 16 reference images, with transparent background and mask inpainting support
  • GPT-Image-1.5 Official — upgraded GPT-Image-1 with significantly improved visual quality and instruction following
  • GPT-Image-1 Official — multimodal generation model integrating text and image understanding, suited for high-quality generation and editing
Per-image billing. Supports text-to-image / image-to-image / editing / mask inpainting / multi-image reference.

Pricing

ModelPrice (per image)
gpt-image-2$0.006375
gpt-image-1.5-official$0.09044
gpt-image-1-official$0.11356

Mode Quick Reference

ModeTrigger FieldsSupported Versions
Text-to-imageprompt only, action: "generate" (default)All
Image-to-image+ image_urls + action: "image2image"All
Image editing+ image_urls + action: "edit"All
Multi-image reference+ image_urls (multiple) + action: "reference"All (up to 16)
Inpainting (mask)+ image_urls + mask_url + action: "inpaint"All

Examples

curl -X POST https://www.qingbo.dev/v1/tasks \
  -H "Authorization: Bearer $WAVE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-image-2",
    "prompt": "未来主义城市夜景,霓虹灯映在湿润街面,电影感构图",
    "aspect_ratio": "16:9",
    "resolution": "2k"
  }'
{
  "task_id": "task-wave1775285160b950328499",
  "model": "gpt-image-2",
  "action": "generate",
  "status": "queued",
  "created_at": 1775285160040,
  "progress": 0
}
After submitting, poll task status with GET /v1/tasks/{task_id}. See Task System for details.

Available Models

Model IDDescription
gpt-image-2Flagship new release, 13 ratios × 1K/2K/4K, up to 16 reference images
gpt-image-1.5-officialUpgraded GPT-Image-1 with significantly improved visual quality and instruction following
gpt-image-1-officialMultimodal text + image understanding, suited for high-quality generation and editing

Common Parameters

model
string
required
Pick one from the Available Models list
action
string
default:"generate"
Operation type, allowed values:
  • generate — text-to-image (default)
  • image2image — image-to-image (requires image_urls)
  • edit — image editing
  • reference — multi-image reference fusion
  • inpaint — inpainting (requires mask_url)
prompt
string
required
Image description text; supports both Chinese and English
n
integer
default:"1"
Number of images to generate (multiple per call)
seed
integer
default:"-1"
Random seed; -1 means random. A fixed value reproduces similar results.
aspect_ratio
string
default:"1:1"
Aspect ratio. Values depend on the model:
  • GPT-Image-2: auto / 1:1 / 3:2 / 2:3 / 4:3 / 3:4 / 5:4 / 4:5 / 16:9 / 9:16 / 2:1 / 1:2 / 21:9 / 9:21 (14 total)
  • GPT-Image-1.5 / 1 official: 1:1 / 3:2 / 2:3 (3 only)
resolution
string
Output resolution. GPT-Image-2 only accepts an explicit value:
  • 1k — 1K tier
  • 2k — 2K tier
  • 4k — 4K tier (only 6 ratios available: 16:9 / 9:16 / 2:1 / 1:2 / 21:9 / 9:21)
GPT-Image-1.5 / 1 official does not accept this field and uses the model default.
image_urls
string[]
Reference image URL array, up to 16; base64 inline upload also supported
callback_url
string
Webhook callback URL, invoked when the task reaches a terminal state. See Callback Mechanism.
callback_events
string[]
Callback event filter, e.g. ["completed", "failed"]

Model-Specific Parameters

Supported actions: generate / image2image / edit / reference / inpaintaspect_ratio (14): auto / 1:1 / 3:2 / 2:3 / 4:3 / 3:4 / 5:4 / 4:5 / 16:9 / 9:16 / 2:1 / 1:2 / 21:9 / 9:21resolution: 1k / 2k / 4k (4K limited to 16:9 / 9:16 / 2:1 / 1:2 / 21:9 / 9:21)Highlights: 13 ratios × three resolution tiers with independent billing, up to 16 reference images (URL / base64), OpenAI per-image pixel ceiling of 8.29M.
quality
string
default:"auto"
Generation quality, allowed values:
  • auto — automatic (default)
  • low — low quality
  • medium — medium quality
  • high — high quality
background
string
default:"auto"
Background handling, allowed values:
  • auto — automatic (default)
  • opaque — opaque
  • transparent — transparent background (not supported on the official channel)
mask_url
string
Mask image URL for inpainting (used with action: "inpaint")
moderation
string
default:"auto"
Content moderation level, allowed values:
  • auto — automatic (default)
  • low — low restriction
output_format
string
default:"png"
Output format, allowed values:
  • png — default
  • jpeg
  • webp
output_compression
integer
Output compression rate, range 0-100. Effective only for jpeg / webp.
style
string
Style preset
official_fallback
boolean
default:"false"
Switch to the gpt-image-2-official channel

Resource Limits

ItemLimit
Reference image countUp to 16 (URL or base64)
Per-image pixel ceiling8.29M pixels (OpenAI’s official limit)
Per-image size≤ 30MB; supports JPG/PNG/WEBP
Output resolutionGPT-Image-2 up to 4K (select ratios); others use default
Output filePNG (default) / JPEG / WEBP (GPT-Image-2 only); URLs valid for 24 hours
Transparent backgroundbackground: transparent only supported on non-official channels