{"command":{"effect":"write","timeoutSeconds":120,"inputSchema":{"type":"object","description":"Creates an image given a prompt using a GPT Image model. [Learn more](https://developers.openai.com/api/docs/guides/images-vision).\n","properties":{"body":{"$ref":"#/definitions/CreateImageRequest"}},"required":["body"],"additionalProperties":false,"definitions":{"CreateImageRequest":{"type":"object","properties":{"prompt":{"description":"A text description of the desired image(s). The maximum length is 32000 characters.","type":"string","examples":["A cute baby sea otter"]},"model":{"anyOf":[{"type":"string"},{"type":"string","enum":["gpt-image-1.5","gpt-image-2","gpt-image-2-2026-04-21","gpt-image-2.5-sunburst","gpt-image-2.5-sunburst-2026-09-08","gpt-image-2.5-flare","gpt-image-2.5-flare-2026-09-08","gpt-image-1","gpt-image-1-mini","chatgpt-image-latest","dall-e-2","dall-e-3"]}],"description":"The GPT image model to use for image generation. Specify a model explicitly.\nSupported models include `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,\n`gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,\n`gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,\n`gpt-image-2.5-flare-2026-09-08`, and `chatgpt-image-latest`.\n\n`gpt-image-1` was shut down on October 23, 2026. Use\n`gpt-image-2.5-sunburst` or `gpt-image-2.5-flare` instead.\n","examples":["gpt-image-2.5-flare"]},"n":{"type":["integer","null"],"minimum":1,"maximum":10,"default":1,"description":"The number of images to generate. Must be between 1 and 10.","examples":[1]},"quality":{"anyOf":[{"type":"string","enum":["low","medium","high","xhigh","max","auto","standard","hd"]},{"type":"null"}],"default":"auto","description":"The quality of the image that will be generated.\n\n- `auto` (default value) will automatically select the best quality for the given\n  model.\n- `high`, `medium` and `low` are supported for the GPT image models.\n- `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including their `2026-09-08`\n  snapshots, also support `xhigh` and `max`.\n","examples":["medium"]},"response_format":{"type":["string","null"],"enum":["url","b64_json",null],"description":"Legacy response format parameter for retired image models. Unsupported for GPT image models, which always return base64-encoded images."},"output_format":{"anyOf":[{"type":"string","enum":["png","jpeg","webp"]},{"type":"null"}],"default":"png","description":"The format in which the generated images are returned. This parameter is only supported for the GPT image models. Must be one of `png`, `jpeg`, or `webp`.","examples":["png"]},"output_compression":{"type":["integer","null"],"default":100,"description":"The compression level (0-100%) for the generated images. This parameter is only supported for the GPT image models with the `webp` or `jpeg` output formats, and defaults to 100.","examples":[100]},"stream":{"type":["boolean","null"],"default":false,"description":"Generate the image in streaming mode. Defaults to `false`. See the\n[Image generation guide](https://developers.openai.com/api/docs/guides/image-generation) for more information.\nThis parameter is only supported for the GPT image models.\n","examples":[false],"enum":[false,null]},"partial_images":{"$ref":"#/definitions/PartialImages"},"size":{"anyOf":[{"type":"string"},{"type":"string","enum":["auto","1024x1024","1536x1024","1024x1536","256x256","512x512","1792x1024","1024x1792"]},{"type":"null"}],"default":"auto","description":"The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing.","examples":["1024x1024"]},"moderation":{"anyOf":[{"type":"string","enum":["low","auto"]},{"type":"null"}],"default":"auto","description":"Control the content-moderation level for images generated by the GPT image models. Must be either `low` for less restrictive filtering or `auto` (default value).","examples":["low"]},"background":{"anyOf":[{"type":"string","enum":["transparent","opaque","auto"]},{"type":"null"}],"default":"auto","description":"Set the background of the generated image(s). This parameter is only supported for\nthe GPT image models. Must be one of `transparent`, `opaque`, or `auto` (default\nvalue). When `auto` is used, the model will automatically determine the best\nbackground for the image.\n\n`gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including their `2026-09-08`\nsnapshots, support `opaque` and `transparent` backgrounds. Transparent backgrounds\nare available for supported GPT Image models. For `gpt-image-2` and\n`gpt-image-2-2026-04-21`, this support is in preview. When using `transparent`,\nset the output format to `png` or `webp`.\n","examples":["transparent"]},"style":{"type":["string","null"],"enum":["vivid","natural",null],"description":"Legacy style parameter for retired image models. Unsupported for GPT image models; describe the desired style in the prompt instead.","examples":["vivid"]},"safety_identifier":{"type":["string","null"],"maxLength":128,"description":"A stable identifier for an end user in your organization, used for safety monitoring and abuse detection. Hash a username or email address to avoid sending identifying information. A non-empty value takes precedence over the deprecated `user` parameter. If omitted, null, or empty, the API uses `user` when available. [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).","examples":["user-1234"]},"user":{"type":"string","description":"Deprecated: use `safety_identifier` instead. This parameter remains accepted for backward compatibility and is used when `safety_identifier` is omitted, null, or empty. [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).","examples":["user-1234"]}},"required":["model","prompt"]},"PartialImages":{"anyOf":[{"type":"integer","maximum":3,"minimum":0,"default":0,"description":"The number of partial images to generate. This parameter is used for\nstreaming responses that return partial images. Value must be between 0 and 3.\nWhen set to 0, the response will be a single image sent in one streaming event.\n\nNote that the final image may be sent before the full number of partial images\nare generated if the full image is generated more quickly.\n","examples":[1]},{"type":"null"}]}}},"name":"Create image","id":"openai.createimage","example":{"body":{"model":"gpt-image-2.5-flare","prompt":"A cute baby sea otter"}},"maxRequests":1,"summary":false}}