Skip to content
OpenAIImage

GPT Image 2

gpt-image-2

GPT Image 2 combines OpenAI's GPT-5.4 with advanced image generation capabilities from GPT Image 2, enabling fully integrated multimodal workflows. It allows users to seamlessly transition between reasoning, coding, and visual generation within a single interaction, making it well suited for creative, development, and agent-driven applications that require both intelligence and visual output. Billed by tokens at OpenAI's price: text input US$5, image input US$8 and image output US$30 per 1M tokens.

Context
272K tokens
Endpoint

Get API KeyCompare

Pricing

Input$2.50 / 1M
Output$15.00 / 1M
Cache Write (5m)Not applicable
Cache Write (1h)Not applicable
Cache ReadNot applicable

Quick Start

Select an endpoint and copy a working example for this model.

Endpoint
python
from openai import OpenAI client = OpenAI(    api_key="YOUR_API_KEY",    base_url="https://api.apertis.ai/v1") response = client.chat.completions.create(    model="gpt-image-2",    messages=[        {"role": "user", "content": "Hello!"}    ],    max_tokens=1024,    temperature=0.7) print(response.choices[0].message.content) # Optional: Enable context compression to reduce token usage# response = client.chat.completions.create(#     model="gpt-image-2",#     messages=[{"role": "user", "content": "Hello!"}],#     extra_body={"compression": {"enabled": True, "model": "gpt-4.1-mini"}}# )

Supported Parameters

API docs
Common5 params
modelpromptsizequalityresponse_format
Extended4 params
nstylebackgroundoutput_format

Cursor IDE Model IDs

Use these namespaced identifiers in Cursor IDE to avoid conflicts with built-in models.

gpt-image-2

Questions about GPT Image 2

How much does GPT Image 2 cost on Apertis?

GPT Image 2 costs $2.50 per 1M input tokens and $15.00 per 1M output tokens on Apertis.

What is GPT Image 2's context window?

GPT Image 2 has a context window of 272K tokens.

Which company develops GPT Image 2?

GPT Image 2 is developed by OpenAI.

Which model ID do I use to call GPT Image 2?

Use the model ID gpt-image-2 to call GPT Image 2.

Compare with Other Models

See how this model compares to others from the same provider.