Model guide

GPT Image 2 API: pricing, sizes and working code

GPT Image 2 is OpenAI's image generation and editing model, released in April 2026. This guide covers the sizes and inputs it accepts, what an image costs, and requests you can run with one API key.

What GPT Image 2 is

OpenAI released GPT Image 2 in April 2026; its API snapshot is gpt-image-2-2026-04-21. OpenAI describes it as its "state-of-the-art image generation model for fast, high-quality image generation and editing", and says it "supports flexible image sizes and high-fidelity image inputs". On Revana that comes down to:

  • Three output sizes: 1K, 2K and 4K.
  • 9 aspect ratios, from square and portrait to 21:9 and 5:2 for headers and banners.
  • Up to 16 input images for edits and compositions: products, logos, people and style references.
  • Generation and editing in one model, with the same request format as every other model on Revana.

Typical jobs: product shots, ad creatives, social images, website banners, mockups, and edits to existing photos.

Inputs and limits

OptionGPT Image 2
Model idgpt-image-2
Taskstext to image and image editing
Resolution1K, 2K and 4K
Aspect ratio1:1, 3:4, 4:3, 2:3, 3:2, 9:16, 16:9, 21:9 and 5:2
Input imagesone image to edit as image_url, or up to 16 as image_urls
Routesone route

Image requests use the same fields as video, without duration and audio. A size or ratio the model does not list is rejected with a 422 before anything is charged.

GPT Image 2 pricing (October 2026)

GPT Image 2 is billed per generated image, by output size. Prices from the Revana catalogue in October 2026:

GPT Image 2 price per image
ResolutionPer image100 images1,000 images
1K$0.02$2.00$20.00
2K$0.02$2.00$20.00
4K$0.03$3.00$30.00

Each job's price is held from your prepaid balance when you submit it and charged only when the image is delivered; a failed job releases the hold. The charge comes back on the generation as cost_usd. The pricing page lists credit packs and every model's prices.

The previous model, GPT Image 1.5, is still listed. Its catalogue prices vary by aspect ratio and quality, from $0.01 for a low-quality square image to $0.16 for a high-quality 3:2 image.

Generate an image with GPT Image 2

Send POST /v1/generations with "model": "gpt-image-2", a prompt, a size and an aspect ratio. You get a 202 with a generation id; poll it until the status is succeeded. Images usually take seconds. This 2K square image costs $0.02.

cURL
export REVANA_API_KEY="sr_live_..."

# 1. Submit the job (returns 202 with the generation id)
curl https://api.revana.si/v1/generations \
  -H "Authorization: Bearer $REVANA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-image-2",
    "input": {
      "prompt": "Flat-lay product photo of a matte black water bottle on a terracotta background, hard midday shadow. A small white card next to the bottle reads \"STAY COLD\" in black sans-serif letters.",
      "resolution": "2K",
      "aspect_ratio": "1:1"
    },
    "max_cost_usd": 0.1
  }'

# 2. Poll with the id from step 1 until status is "succeeded" or "failed"
curl https://api.revana.si/v1/generations/gen_01JBX7Q2M4 \
  -H "Authorization: Bearer $REVANA_API_KEY"
Python
import os
import time

import requests

API = "https://api.revana.si/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['REVANA_API_KEY']}"}

resp = requests.post(f"{API}/generations", headers=HEADERS, json={
    "model": "gpt-image-2",
    "input": {
        "prompt": "Flat-lay product photo of a matte black water bottle on a terracotta background, hard midday shadow. A small white card next to the bottle reads \"STAY COLD\" in black sans-serif letters.",
        "resolution": "2K",
        "aspect_ratio": "1:1",
    },
    "max_cost_usd": 0.1,
})
resp.raise_for_status()
job = resp.json()

while job["status"] in ("queued", "running"):
    time.sleep(5)
    job = requests.get(f"{API}/generations/{job['id']}", headers=HEADERS).json()

if job["status"] == "succeeded":
    print(job["output"]["urls"], job["cost_usd"])
else:
    print("Failed:", job["error"])
Node.js
// Node 18 or later. Save as generate.mjs and run: node generate.mjs
const API = "https://api.revana.si/v1";
const headers = {
  Authorization: `Bearer ${process.env.REVANA_API_KEY}`,
  "Content-Type": "application/json",
};

const res = await fetch(`${API}/generations`, {
  method: "POST",
  headers,
  body: JSON.stringify({
    model: "gpt-image-2",
    input: {
      prompt: "Flat-lay product photo of a matte black water bottle on a terracotta background, hard midday shadow. A small white card next to the bottle reads \"STAY COLD\" in black sans-serif letters.",
      resolution: "2K",
      aspect_ratio: "1:1",
    },
    max_cost_usd: 0.1,
  }),
});
if (!res.ok) throw new Error(`${res.status} ${await res.text()}`);
let job = await res.json();

while (job.status === "queued" || job.status === "running") {
  await new Promise((r) => setTimeout(r, 5000));
  job = await (await fetch(`${API}/generations/${job.id}`, { headers })).json();
}

if (job.status === "succeeded") console.log(job.output.urls, job.cost_usd);
else console.error("Failed:", job.error);

A finished generation, with the image link in output.urls. Links expire, so copy the file to your own storage:

Response
{
  "id": "gen_01JC4K2W9T",
  "model": "gpt-image-2",
  "status": "succeeded",
  "output": {
    "urls": [
      "https://cdn.revana.si/g/gen_01JC4K2W9T/0.png"
    ]
  },
  "cost_usd": 0.02,
  "attempts": 1,
  "error": null,
  "created_at": "2026-10-19T14:02:11Z",
  "completed_at": "2026-10-19T14:02:29Z"
}

Send your product shot and logo as image_urls, refer to them by position, and pick a wide ratio. To edit a single photo instead, send it as image_url and describe the change.

Request body
{
  "model": "gpt-image-2",
  "input": {
    "prompt": "A website banner. The sneaker from the first image on the right, floating above a soft shadow. The logo from the second image at the top left. The words \"NEW SEASON\" in large white letters on a warm orange gradient. Keep the logo exactly as it is.",
    "image_urls": [
      "https://example.com/sneaker.png",
      "https://example.com/logo.png"
    ],
    "resolution": "2K",
    "aspect_ratio": "5:2"
  },
  "max_cost_usd": 0.1
}

Prompt tips for GPT Image 2

  • Brief it like a designer. Subject, setting, composition, lighting, style, then any text, in that order.
  • Quote the exact words and say where they go and how they should look.
  • Pick the ratio for the channel. 1:1 for feeds, 9:16 for stories and reels, 16:9 or 21:9 for headers, 5:2 for banners.
  • Number your inputs. "The logo from the second image" leaves no doubt when you send several.
  • Say what must not change. In edits, name what to keep (faces, labels, logos) as clearly as what to change.
  • Proofread. Check spelling and small text in every image before it goes out.

GPT Image 2 or Nano Banana Pro?

Both generate and edit images up to 4K from text and input images, with the same request format. The catalogue differences:

GPT Image 2 and Nano Banana Pro compared
GPT Image 2Nano Banana Pro
MakerOpenAIGoogle
Resolution1K, 2K and 4K1K, 2K and 4K
Aspect ratios910
Input imagesup to 16up to 14
Price from$0.02 / image$0.04 / image
Routesone routeone route

We do not publish a quality ranking. Run the prompts that matter to you through both; because the request format is the same, switching is a one-word change to model. Our Nano Banana Pro guide covers that model in the same detail.

Routing and fallback

GPT Image 2 has one route on Revana today. For models with more than one route, the router tries the cheapest first and moves on if it fails, always at the listed price. With one route there is nothing to fall back to: if it fails, the job ends as failed and costs nothing.

Plan for failed jobs: retry later, or fall back in your own code to a second image model with a different model string.

Browse every image model on the models page, read the docs, or get an API key.

Frequently asked questions

How much does the GPT Image 2 API cost?

In October 2026, GPT Image 2 costs $0.02 per image at 1K, $0.02 at 2K and $0.03 at 4K. A batch of 100 images at 1K is $2.00.

When was GPT Image 2 released?

OpenAI released GPT Image 2 in April 2026. Its API snapshot is gpt-image-2-2026-04-21.

Which sizes and aspect ratios does GPT Image 2 support?

Sizes 1K, 2K and 4K, and the aspect ratios 1:1, 3:4, 4:3, 2:3, 3:2, 9:16, 16:9, 21:9 and 5:2.

How many input images can I send to GPT Image 2?

Up to 16, as image_urls. To edit a single image, send it as image_url.

Should I use GPT Image 2 or Nano Banana Pro?

Test both on your own prompts. In the catalogue, GPT Image 2 takes up to 16 input images and lists 9 aspect ratios; Nano Banana Pro takes up to 14 and lists 10. Both go up to 4K.

Is GPT Image 1.5 still available?

Yes. Its prices vary by aspect ratio and quality, from $0.01 to $0.16 per image in October 2026.

Generate with GPT Image 2

Use GPT Image 2, Nano Banana Pro and every video model with one key. Prepaid credit from $10, charged only for delivered images.