Sora

GPT Image 2 API

Image APIHOT

GPT Image 2 API is built for production image generation workflows that need prompt-driven creation, reference image editing, and predictable API payloads. Use it to create campaign visuals, product shots, social creatives, and design mockups without leaving the SdanceAI generation flow.

The current integration exposes Text to Image and Image to Image variants with 1K, 2K, and 4K pricing tiers, plus common aspect ratios for square, vertical, horizontal, and portrait outputs.

Model Type:
Pricing

Lowest cost starts at $0.015/image

Selected model
Text to Image

1K: 3 credits - Text to Image - Fixed per generation

2K: 5 credits - Text to Image - Fixed per generation

4K: 8 credits - Text to Image - Fixed per generation

USD estimates use $0.005/credit with the best annual plan. Final billing follows the selected resolution and model variant.

Generate Image
New tasks appear here after you submit.
API Input

Core request fields

Use a compact payload for prompt, source images, aspect ratio, resolution, callback, and safety settings.

Request JSON
{
  "model": "gpt-image-2-text-to-image",
  "input": {
    "prompt": "A cinematic night city poster with neon reflections on a rainy street.",
    "aspect_ratio": "auto"
  }
}

Use Text to Image for generation

The playground, request sample, request fields, and pricing on this page follow the selected model type.

View detailed API docs

Open the full API documentation for endpoints, authentication, task polling, and payload details. /models/gpt-image-2.md

promptstringText prompt. Required, maximum 20,000 characters.
aspect_ratioenumThe aspect ratio of the generated image is set to auto by default. (auto, 1:1, 3:2, 2:3, 4:3, 3:4, 5:4, 4:5, 16:9, 9:16, 2:1, 1:2, 3:1, 1:3, 21:9, 9:21)
resolutionenumImage resolution: Note: Images with a 1:1 aspect ratio cannot be converted to 4K images. Images with the aspect ratio set to "auto" or without a specified aspect ratio parameter will only be converted to 1K images; otherwise, the task will fail to create. (1K, 2K, 4K)
Capabilities

What GPT Image 2 API adds to your image workflow

The page follows the same API-first structure as the reference: test the model, understand the fields, then move into integration.

Text-to-image creation

Turn structured prompts into production-ready visuals for posters, ads, thumbnails, concept art, and product scenes.

Reference image editing

Use image inputs to preserve subject context while changing style, background, layout, lighting, or product presentation.

Resolution tiers

Select 1K, 2K, or 4K output tiers to balance iteration cost, preview quality, and final asset sharpness.

API-ready payloads

Work with model IDs, callback URLs, prompt text, input image URLs, aspect ratios, and resolution fields in one predictable request.

Quick Start

From prompt test to image API request

A direct path for teams that want to validate image quality before wiring generation into an app or content pipeline.

1. Choose a mode

Select Text to Image for new visuals or Image to Image when you want reference-guided edits.

2. Submit generation

Call the API with your account key, model ID, prompt, optional input image URLs, aspect ratio, and resolution.

3. Poll and use

Track the task until it succeeds, then use the generated image result in your app, campaign, or asset library.

Use Cases

What you can create with GPT Image 2 API

Use the API when your product needs repeatable, high-quality image generation rather than one-off manual exports.

Product hero images and e-commerce visuals
Social posts, thumbnails, and ad creatives
Poster, flyer, and campaign key art
Reference-based outfit, background, and style edits
Design mockups and visual concept exploration
Batch creative generation for content pipelines
Community Showcase

Successful GPT Image 2 generations from the community

Browse public GPT Image 2 outputs that finished successfully, then open any case to inspect the prompt, settings, and result.

View more
GPT Image-2 - Text to Image preview 1
imageGPT Image-2

GPT Image-2 - Text to Image

Ultra-wide handheld photo from the back-left of a dark immersive 4D-style cinema, 16:9, 35mm anamorphic lens, tilted framing with motion blur. The huge screen glows intensely off-center to the right, lighting a silhouetted Japanese audience filming on their phones. On the screen: an epic live-action basketball championship game, a star player launches an impossible full-court shot as dozens of basketballs appear suspended dramatically in the air around him beneath bright arena lights. Screen-format logo on the left wall, "YOUR NAME" logo on the right wall. Heavy grain, deep blacks, photorealistic. 16:9

Jul 18, 2026View details
GPT Image-2 - Text to Image preview 1
imageGPT Image-2

GPT Image-2 - Text to Image

um homem sorridente com bastao de selfie, fazendo selfie em cima da sua moto custom nas montanhas com o por do sol aparente, homem feliz, mulher a sua garupa. selfie tirada enquanto ele pilota a moto com uma mão. foto natural e realista tirada de uma iphone 15

Jul 15, 2026View details
GPT Image-2 - Text to Image preview 1
imageGPT Image-2

GPT Image-2 - Text to Image

Foto candid ultra-realistis, rasio 9:16, kualitas sangat tinggi, diambil menggunakan kamera iPhone Pro (front camera). Seorang wanita muda Asia dengan wajah natural dan proporsional, fitur wajah lembut, ekspresi santai sedikit kosong namun tetap hidup. Rambut hitam diikat messy bun dengan beberapa helai rambut jatuh natural membingkai wajah, detail helai rambut sangat jelas. Kulit sangat realistis dengan detail mikro, pori-pori halus terlihat, tekstur kulit asli, tidak over smooth, tidak plastik, terdapat sedikit imperfection alami. Outfit Hanya ganti pakaian mengikuti gambar referensi. Transfer pakaian harus sangat akurat: detail kain, tekstur, jahitan, lipatan, dan jatuhnya pakaian terlihat realistis. Pose candid natural: badan sedikit condong ke depan ke arah kamera, perspektif seperti kamera dipegang atau diletakkan lebih rendah (slight low angle), kedua tangan di depan tubuh (seolah menopang atau di meja), ekspresi santai, tidak dibuat-buat. Background: kamar tidur sederhana realistis, lemari terbuka di sisi kiri dengan barang-barang kecil (botol, kotak) terlihat natural, gantungan baju di sisi kanan dengan beberapa pakaian tergantung, dinding warna netral putih/abu terang, suasana ruangan lived-in, tidak terlalu rapi. Pencahayaan: indoor lighting natural (lampu kamar), sedikit warm tone, pencahayaan merata, bayangan lembut dan realistis, tidak dramatis, tidak cinematic, dynamic range natural seperti kamera HP. Framing: medium shot (pinggang ke atas), slightly low angle, perspektif wide lens (26–28mm), framing natural seperti selfie. Fokus tajam natural di wajah dan tubuh, tidak over sharpen, sedikit softness khas kamera smartphone, detail terlihat jelas (kulit, rambut, kain, objek sekitar). Warna natural, tidak terlalu kontras, tidak HDR berlebihan. Photorealistic, true-to-life, authentic camera look, realistic imperfections, natural clarity, no overprocessing. Resolusi sangat tinggi Resolusi 99 k Full realistis superr Turbo HD high kontras realistis, ultra high resolution, super detail, high contrast realistis, Turbo HD rendering, maximum clarity, fine detail enhancement, tetap natural seperti foto asli, tidak terlihat seperti AI. 🚫 NEGATIVE PROMPT (WAJIB BANGET) blur, buram, low quality, noise kasar, grain berlebihan, soft focus ekstrem over smooth, kulit plastik, beauty filter, wajah terlalu flawless over sharpen, HDR berlebihan, warna terlalu tajam bokeh, depth of field berlebihan, background blur ekstrem distorsi wajah, anatomi rusak, proporsi aneh lighting tidak natural, overexposed, underexposed CGI, render, kartun, anime, AI look, fake image watermark, teks, kompresi, artifact

Jul 14, 2026View details
GPT Image-2 - Text to Image preview 1
imageGPT Image-2

GPT Image-2 - Text to Image

制作一个字母卡通 logo,内容:FSG AI,背景白色,图片干净

Jul 12, 2026View details
Production Notes

Built for real image API workflows

Account-gated execution

Users sign in, submit jobs, and consume credits through the existing SdanceAI generation flow.

Input image handling

Image to Image accepts source image URLs, so teams can keep references in their own asset pipeline while generating new variations.

Cost-aware resolution

Start with 1K for fast iteration, then move to 2K or 4K when the prompt and visual direction are ready.

FAQ

GPT Image 2 API questions

What is GPT Image 2 API best for?

It is best for prompt-based image generation and reference-guided image editing, including product visuals, ads, social creatives, posters, and design mockups.

What is the difference between Text to Image and Image to Image?

Text to Image starts from a prompt only. Image to Image uses one or more source image URLs plus a prompt, making it better for edits, variations, and reference-preserving workflows.

Which resolutions are available?

The current API configuration includes 1K, 2K, and 4K pricing tiers. Choose lower resolution for iteration and higher resolution for final assets.

Which aspect ratios can I use?

The available aspect ratios include auto, 1:1, 9:16, 16:9, 4:3, and 3:4. Match the ratio to your target channel before generating final assets.

How many input images can Image to Image use?

The configured image-to-image payload supports input image URL arrays, with up to 16 source images.

Where can I test it before integrating?

Use the playground on this page to test prompts, input image URLs, aspect ratio, resolution, and API payload behavior before moving into production.

Can I use GPT Image 2 API for commercial workflows?

This page is configured for production image workflows. For commercial use, review your account plan, credit balance, model availability, and applicable content policy requirements.

Does the API support callbacks?

Yes. The request schema includes an optional callback URL so your service can receive task completion notifications.

How should I manage cost?

Use 1K for prompt exploration and bulk drafts, then regenerate selected winners at 2K or 4K when you need sharper final output.

Can I edit existing product photos?

Yes. Use Image to Image with source image URLs and a prompt that describes the exact background, lighting, layout, or styling changes you need.

Start building

Turn GPT Image 2 into your image workflow

Open the generator, test a prompt or reference image, then use the API docs when you are ready to connect GPT Image 2 to production.

API-ready
workflow
1K-4K
resolution
16 images
references