Find gpt-image-1 in your repo before Oct 23: a Python scan
OpenAI shuts gpt-image-1 down on 2026-10-23, five weeks before the other GPT Image ids. A Python scan splits them by date and maps each hit to a Sume model id.

To find every gpt-image-1 call in a codebase, grep for the exact id and exclude its siblings: a plain search for gpt-image-1 also matches gpt-image-1-mini and gpt-image-1.5, which retire on a different day. OpenAI's deprecations page (read 2026-10-05) lists gpt-image-1 with a shutdown date of October 23, 2026, announced on April 22, and names gpt-image-2.5-sunburst or gpt-image-2.5-flare as the replacement. That is 18 days from today.
The three other ids on the same page, gpt-image-1-mini, gpt-image-1.5 and chatgpt-image-latest, were announced on June 2 and shut down on December 1, 2026, which is 57 days out. The script below prints one line per hit and tags each with the date it dies, so you can fix the October 23 hits first. Treat hits in tests, fixtures and docs the same way as hits in production code: a fixture that names a retired id keeps passing until the day a live call replays it, and then fails with no code change on your side.
Which id dies when
Use this table to sort scan output. Every row names the same two replacements, so the dates are the only thing that changes your order of work.
| Id | Announced | Shutdown | Replacement |
|---|---|---|---|
| gpt-image-1 | 2026-04-22 | 2026-10-23 | gpt-image-2.5-sunburst or gpt-image-2.5-flare |
| gpt-image-1-mini | 2026-06-02 | 2026-12-01 | gpt-image-2.5-sunburst or gpt-image-2.5-flare |
| gpt-image-1.5 | 2026-06-02 | 2026-12-01 | gpt-image-2.5-sunburst or gpt-image-2.5-flare |
| chatgpt-image-latest | 2026-06-02 | 2026-12-01 | gpt-image-2.5-sunburst or gpt-image-2.5-flare |
The scan
The scan reads any text file under 1 MB, so it also finds ids in .env.example, YAML, Terraform, notebooks stored as JSON, and test fixtures. It skips .git, node_modules, .venv and dist; add your own generated-code directories to SKIP if the output is noisy.
The first pattern matches gpt-image-1 only when it is not followed by a word character, a hyphen, or a dot and a digit, and not preceded by one. That keeps openai/gpt-image-1 and quoted strings, and drops gpt-image-1-mini, gpt-image-1.5 and gpt-image-10. Run it from the repo root: python scan.py .
import pathlib
import re
import sys
EARLY = re.compile(r"(?<![\w.-])gpt-image-1(?![\w-]|\.\d)")
LATE = re.compile(
r"(?<![\w.-])(gpt-image-1-mini|gpt-image-1\.5|chatgpt-image-latest)(?![\w-])"
)
SKIP = {".git", "node_modules", ".venv", "dist"}
def scan(root):
for path in pathlib.Path(root).rglob("*"):
if path.is_dir() or SKIP & set(path.parts) or path.stat().st_size > 1_000_000:
continue
try:
lines = path.read_text(encoding="utf-8").splitlines()
except (UnicodeDecodeError, OSError):
continue
for number, line in enumerate(lines, 1):
if EARLY.search(line):
print(f"2026-10-23 {path}:{number}: {line.strip()[:90]}")
elif LATE.search(line):
print(f"2026-12-01 {path}:{number}: {line.strip()[:90]}")
scan(sys.argv[1] if len(sys.argv) > 1 else ".")What to put in its place on Sume
Sume's Image API lists ChatGPT Image 2.5 as openai/gpt-image-2.5 (Flare) and openai/gpt-image-2.5-sunburst. The catalog has no gpt-image-1 row, so a string swap is the first step and not the last one. Both ids take text-to-image, up to 16 image references, an optional mask_url, and background: auto|transparent|opaque.
If you only want the replacement to work and have no preference between the two, either id satisfies OpenAI's note. Auto routing on Sume uses Flare, per the Image API page. Sunburst and Flare use the same Fal token rates on Sume, so the choice does not change the price.
Check each hit before you replace it
For every line the scan prints, read the request around it. These are the fields that most often need a change.
quality: if you omit it, Sume defaults tohighfor ChatGPT Image 2.5.low,mediumandhighare still valid, andauto,xhighandmaxare new.autoreserves themaxprice.- Size: custom sizes need both edges as multiples of 16, a longest edge of 3840 at most, an aspect ratio up to 3:1, and between 655,360 and 8,294,400 pixels. OpenAI's image generation guide (read 2026-10-05) lists the same rules and recommends 1024x1024, 1536x1024 and 1024x1536.
- Parameters the catalog does not list: Sume answers
400 unsupported_parameterand does not drop the field silently, so a leftover option fails loudly in your first test. - Output: Sume returns hosted URLs in
data[].url, not inline base64, so code that decodesb64_jsonneeds a download step instead.
Next step
Commit the scan output as a checklist, replace the October 23 hits first, and run one low-quality call per code path against openai/gpt-image-2.5 to confirm the request is accepted. If a call is slow, Sume returns 202 with a job envelope instead of an image; poll it as described in Jobs and results. Then move the December 1 ids in the same pass, since the replacements are identical.
To keep the check honest after the fact, count the October 23 hits and exit with a non-zero status when the count is above zero. Run that in CI from now on, and a stray gpt-image-1 added by a branch that predates this work fails the build instead of failing in production.
Sources
Related posts
More in Developers
- Find video models with 1:1, 9:16 and 16:9: filter the Sume catalog
One Python call to GET /v1/videos/models lists which Sume video models cover square, vertical and widescreen, so one prompt can feed Feed, Reels and in-stream.
- Firebase allows 1-hour HTTP functions; don't hold a Sume job open
Firebase HTTP functions can run up to an hour and Cloud Tasks covers longer work. Even so, submit Sume jobs async and take the result by webhook or status poll.
- 'first_frame_url must match image_url': two names, one value
image_url and first_frame_url are aliases on Video Router. Send both only if the strings are identical, same for end_image_url and last_frame_url, or get a 400.
- Fix a first frame with Ideogram 4.5, then send it to Omni image_url
Correct text or a prop in a still with Ideogram 4.5 on Sume, then use the edited image as the Gemini Omni 1.1 Flash first frame. Two jobs, one shot.
Written by Sume