Back to Gallery
GPT Image 2.0, OpenAI's latest image model, is capable of making fine-grained, detailed edits to images.
$0.133/image 2026-04-21
Install
pip install requestsRun the model
import requests
response = requests.post(
"https://api.runflow.io/v1/run/gpt-image-2/edit",
headers={"Authorization": "Bearer RUNFLOW_API_KEY"},
json={
"prompt": "Replace the background with a sunlit seaside cafe at golden hour, keep the su...",
"image_urls": [
"https://public.runflow.io/images/models/_base/portrait-woman-studio.png"
]
},
)
data = response.json()
print(data["images"][0]["url"])Input schema
| Parameter | Type | Description |
|---|---|---|
| prompt | string | The prompt for image generation |
| image_urls | image_list | The URLs of the images to use as a reference for the generation. |
| num_images | integer | Number of images to generate |
| output_format | string | Output format for the images |
| image_size | string | The size of the generated image. Use 'auto' to infer from input images. |
| mask_url | image | The URL of the mask image to use for the generation. This indicates what part of the image to edit. |
| quality | string | Quality for the generated image |
| sync_mode | boolean | If `True`, the media will be returned as a data URI and the output data won't be available in the request history. |
Output schema
| Field | Type | Description |
|---|---|---|
| outputs | json | Unified output array. |
| seed | json | Seed used for generation, or null. |
| timing | json | Provider timing info, or null. |
| nsfw_detected | json | NSFW flag, or null. |
Related models
GPT Image 1.5
openai/gpt-image-1.5
GPT Image 1.5 generates high-fidelity images with strong prompt adherence, prese...
$0.133/image
GPT Image 2
openai/gpt-image-2
GPT Image 2.0, OpenAI's latest image model, is capable of creating extremely det...
$0.133/image
Tag Removal
runflow/tag-removal
Remove price tags, stickers, and labels from product images while preserving the...
$0.14/request
Product Isolation
runflow/product-isolation
Isolate the main product from a busy scene onto a clean background, using an opt...
$0.27/request
Start generating with GPT Image 2 Edit
Get API access in minutes. No GPU setup, no infrastructure to manage.