{
  "id": "openai/gpt-image-2",
  "name": "GPT Image 2",
  "type": "image",
  "vendor": "OpenAI",
  "description": "OpenAI’s GPT Image 2 model for fast, high-quality text-to-image generation and reference-image editing with flexible sizes.",
  "supports": [
    {
      "id": "txt->img",
      "label": "Text → Image",
      "description": "Generate an image from a text prompt"
    },
    {
      "id": "img->img",
      "label": "Image → Image",
      "description": "Transform or edit a reference image with a prompt"
    },
    {
      "id": "inputs",
      "label": "Inputs",
      "description": "Supports reference/input images"
    }
  ],
  "modes": {
    "txt->img": {},
    "img->img": {
      "inputs": {
        "rules": [
          {
            "type": "image",
            "max": 16
          }
        ]
      }
    }
  },
  "roles": [],
  "output": {
    "aspectRatios": [
      "1:1",
      "4:3",
      "3:4",
      "16:9",
      "9:16",
      "3:2",
      "2:3",
      "5:4"
    ],
    "has4k": false
  },
  "prompt": {
    "negativePrompt": false
  },
  "pricing": {
    "currency": "USD",
    "perImage": 0.12,
    "perInputImage": 0.02
  },
  "license": {
    "commercialUse": null,
    "url": null
  },
  "releaseDate": "2026-04-21",
  "version": null,
  "samples": [
    {
      "mode": "txt->img",
      "language": "ts",
      "code": "import Mynth from \"@mynthio/sdk\";\n\nconst mynth = new Mynth();\n\nconst task = await mynth.image.generate({\n  model: \"openai/gpt-image-2\",\n  prompt: \"A lighthouse at dusk, 35mm film\",\n  size: \"16:9\",\n});\n\nconsole.log(task.urls[0]);"
    },
    {
      "mode": "txt->img",
      "language": "curl",
      "code": "curl https://api.mynth.io/image/generate \\\n  -H \"Authorization: Bearer $MYNTH_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"model\": \"openai/gpt-image-2\",\n    \"prompt\": \"A lighthouse at dusk, 35mm film\",\n    \"size\": \"16:9\"\n  }'"
    },
    {
      "mode": "txt->img",
      "language": "cli",
      "code": "npx @mynthio/cli image generate \\\n  -m openai/gpt-image-2 \\\n  -p \"A lighthouse at dusk, 35mm film\" \\\n  -s 16:9"
    },
    {
      "mode": "img->img",
      "language": "ts",
      "code": "import Mynth from \"@mynthio/sdk\";\n\nconst mynth = new Mynth();\n\nconst task = await mynth.image.generate({\n  model: \"openai/gpt-image-2\",\n  prompt: \"The same lighthouse, now in heavy fog\",\n  inputs: [\"https://cdn.example.com/lighthouse.png\"],\n});\n\nconsole.log(task.urls[0]);"
    },
    {
      "mode": "img->img",
      "language": "curl",
      "code": "curl https://api.mynth.io/image/generate \\\n  -H \"Authorization: Bearer $MYNTH_API_KEY\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n    \"model\": \"openai/gpt-image-2\",\n    \"prompt\": \"The same lighthouse, now in heavy fog\",\n    \"inputs\": [\"https://cdn.example.com/lighthouse.png\"]\n  }'"
    },
    {
      "mode": "img->img",
      "language": "cli",
      "code": "npx @mynthio/cli image generate \\\n  -m openai/gpt-image-2 \\\n  -p \"The same lighthouse, now in heavy fog\" \\\n  -i https://cdn.example.com/lighthouse.png"
    }
  ],
  "showcase": [],
  "guide": {
    "title": "Working with GPT Image 2",
    "body": "GPT Image 2 is OpenAI's image model for production work: layouts with dense,\nreadable text, edits that stay faithful to the source, and scenes that draw on\nwhat the model knows about the world rather than on a reference image. OpenAI\nreleased it on 21 April 2026, as the snapshot `gpt-image-2-2026-04-21`.\n\n### What it is good at\n\n- **Typography.** Posters, packaging, menus and UI mockups with text that reads,\n  including long lines and small sizes.\n- **Multilingual text.** Text rendered in scripts other than Latin.\n- **Edits with references.** Up to 16 input images per request, in any role.\n  Describe what should change and what must stay.\n- **World knowledge.** Recognisable places, objects and styles from the prompt\n  alone, without an image to copy from.\n- **Flexible framing.** Eight aspect ratios from 9:16 to 16:9, each at a native\n  resolution around 2K.\n\n### Prompting\n\nWrite the prompt the way you would brief a designer: the subject, the setting,\nthe composition, then the finish.\n\n- Put any text that must appear in quotes, and say where it goes:\n  `a poster with the headline \"Night Market\" across the top`.\n- Name the medium and the light: `35mm film, overcast daylight`, or\n  `studio product shot, soft box from the left`.\n- For an edit, say what stays the same before what changes:\n  `keep the model and the jacket; replace the street with a beach at dusk`.\n- Ask for one image and refine the prompt before raising `count`. Every image\n  is charged, and a better prompt costs nothing.\n\n### Rights\n\nOpenAI assigns the rights in outputs to you, and commercial use is allowed.\nAttribution is optional. OpenAI does not train on data sent through its\nbusiness API unless you opt in."
  },
  "links": {
    "page": "https://mynth.io/models/openai%2Fgpt-image-2",
    "json": "https://mynth.io/models/openai%2Fgpt-image-2.json",
    "txt": "https://mynth.io/models/openai%2Fgpt-image-2.txt",
    "md": "https://mynth.io/models/openai%2Fgpt-image-2.md",
    "playground": "https://mynth.io/playground?_m=openai%2Fgpt-image-2",
    "homepage": "https://platform.openai.com/docs/models/gpt-image-2",
    "apiDocs": "https://mynth.io/docs/api-reference/endpoints/image/generate.md",
    "quickstart": "https://mynth.io/docs/getting-started.md",
    "sdk": "https://mynth.io/docs/sdks/typescript.md"
  },
  "family": [
    {
      "id": "openai/gpt-image-2.5-flare",
      "name": "GPT Image 2.5 Flare",
      "page": "https://mynth.io/models/openai%2Fgpt-image-2.5-flare",
      "md": "https://mynth.io/models/openai%2Fgpt-image-2.5-flare.md"
    },
    {
      "id": "openai/gpt-image-2.5-sunburst",
      "name": "GPT Image 2.5 Sunburst",
      "page": "https://mynth.io/models/openai%2Fgpt-image-2.5-sunburst",
      "md": "https://mynth.io/models/openai%2Fgpt-image-2.5-sunburst.md"
    }
  ],
  "similar": [
    {
      "id": "luma/uni-1-max",
      "name": "Luma UNI-1 Max",
      "page": "https://mynth.io/models/luma%2Funi-1-max",
      "md": "https://mynth.io/models/luma%2Funi-1-max.md"
    },
    {
      "id": "bytedance/seedream-pro",
      "name": "Seedream Pro",
      "page": "https://mynth.io/models/bytedance%2Fseedream-pro",
      "md": "https://mynth.io/models/bytedance%2Fseedream-pro.md"
    },
    {
      "id": "alibaba/qwen-image-2.1-pro",
      "name": "Qwen Image 2.1 Pro",
      "page": "https://mynth.io/models/alibaba%2Fqwen-image-2.1-pro",
      "md": "https://mynth.io/models/alibaba%2Fqwen-image-2.1-pro.md"
    },
    {
      "id": "alibaba/qwen-image-3.0",
      "name": "Qwen Image 3.0",
      "page": "https://mynth.io/models/alibaba%2Fqwen-image-3.0",
      "md": "https://mynth.io/models/alibaba%2Fqwen-image-3.0.md"
    },
    {
      "id": "alibaba/qwen-image-3.0-pro",
      "name": "Qwen Image 3.0 Pro",
      "page": "https://mynth.io/models/alibaba%2Fqwen-image-3.0-pro",
      "md": "https://mynth.io/models/alibaba%2Fqwen-image-3.0-pro.md"
    }
  ]
}