# openai/gpt-image-2.6-flare/text-to-image > Transform natural language prompts into detailed visuals with GPT Image 2.6 Flare. Supports precise typography, transparent backgrounds, flexible aspect ratios and resolutions, adjustable image complexity, and SVG vector output and GIF animation. Advanced defaults: high input fidelity for edits, JPEG/WebP compression 100, GIF frame delay 200ms, SVG creator 5.4-mini with default reasoning, and model-default complexity. ## Overview - **Endpoint**: `https://api.shortapi.ai/api/v1/job/create` - **Model ID**: `openai/gpt-image-2.6-flare/text-to-image` - **Category**: text-to-image - **Kind**: inference ## Pricing PNG / JPEG / WebP (USD per image): Low: 1K $0.025, 2K $0.051, 4K $0.084 Medium: 1K $0.044, 2K $0.089, 4K $0.148 High: 1K $0.053, 2K $0.108, 4K $0.179 XHigh: 1K $0.094, 2K $0.191, 4K $0.317 Max: 1K $0.211, 2K $0.429, 4K $0.712 SVG (USD per image, complete price including conversion; n=1; creator 5.4-mini): Low: 1K $0.036, 2K $0.062, 4K $0.102 Medium: 1K $0.058, 2K $0.100, 4K $0.167 High: 1K $0.064, 2K $0.123, 4K $0.203 XHigh: 1K $0.109, 2K $0.205, 4K $0.333 Max: 1K $0.221, 2K $0.445, 4K $0.725 GIF (USD per animation; measured token costs rounded up to $0.001): Quality: 640x640/2 frames, 896x896/9 frames, 640x640/16 frames Low: $0.022, $0.075, $0.070 Medium: $0.038, $0.132, $0.123 High: $0.046, $0.160, $0.149 XHigh: $0.082, $0.284, $0.264 Max: $0.183, $0.638, $0.592 Only these size/frame-count combinations are priced. Frame delay does not change the price. Measured with Sunburst text-to-image; the same approved prices apply to Flare and edit. Total charge = unit price multiplied by n. Full upfront charge before generation. No extra token charges after generation. Failed requests are fully refunded. For more details, please check our pricing page. ## API Information This model can be used via our HTTP API or more conveniently via our client libraries. See the input and output schema below, as well as the usage examples. ### Input Schema The API accepts the following input parameters: - **`prompt`** (`string`, _required_): Text prompt, up to 32,000 characters. - Examples: "An action shot of a black lab swimming..." - **`background`** (`string`, _optional_): Background rendering mode. Use opaque for a non-transparent background or transparent for a transparent background. Transparency requires PNG or WebP output. - Default: `auto` - Options: "auto", "opaque", "transparent" - **`n`** (`int`, _optional_): Number of images or GIF animations, 1-10. SVG requires n=1. Upfront charge = unit price multiplied by n. - Default: `1` - Range: `1` to `10` - **`output_format`** (`string`, _optional_): Output format. SVG requires n=1 and uses an independent total price. GIF priced presets: 640x640/2 frames, 640x640/16 frames, 896x896/9 frames. - Default: `png` - Options: "png", "jpeg", "webp", "svg", "gif" - **`quality`** (`string`, _optional_): Image rendering quality. Defaults to medium and is explicitly sent to the image provider. auto is not supported. - Default: `medium` - Options: "low", "medium", "high", "xhigh", "max" - **`aspect_ratio`** (`string`, _optional_): Static image/SVG aspect ratio. GIF requires 1:1. - Default: `1:1` - Options: "1:1", "4:3", "3:4", "16:9", "9:16", "3:2", "2:3", "21:9", "9:21" - **`resolution`** (`string`, _optional_): Static image/SVG resolution. For GIF leave 1K; select pixel dimensions using size. No GIF 2K/4K. - Default: `1K` - Options: "1K", "2K", "4K" - **`size`** (`string`, _optional_): GIF only; default 896x896. Priced combinations: 896x896/9 frames; 640x640/2 or 16 frames. Ignored otherwise. - Default: `896x896` - Options: "640x640", "896x896" - **`frame_count`** (`int`, _optional_): GIF only; default 9. Priced combinations: 640x640/2, 640x640/16, 896x896/9. Other combinations unavailable. Ignored otherwise. - Default: `9` - Options: "2", "9", "16" ### Output Schema The API returns a JSON response with a `job_id` for tracking the request status. **Create Job Response:** ```json { "code": 0, "data": { "amount": "0.02", "job_id": "" } } ``` **Query Job Result (when status is 2, meaning succeeded):** ```json { "code": 0, "data": { "status": 2, "result": { "images": [{ "url": "https://..." }] } } } ``` ## Use Example To use this model, make an HTTP POST request to the API endpoint, then poll for results using the returned `job_id`. ### Bash (cURL) ```bash # Step 1: Create a job response=$(curl --request POST \ --url https://api.shortapi.ai/api/v1/job/create \ --header "Authorization: Bearer $SHORTAPI_KEY" \ --header "Content-Type: application/json" \ --data '{ "model": "openai/gpt-image-2.6-flare/text-to-image", "args": { "prompt": "A cinematic product photograph of a futuristic smartwatch on a black marble pedestal, dramatic studio lighting, highly detailed." }, "callback_url": "CALLBACK_URL" }') JOB_ID=$(echo "$response" | grep -o '"job_id": *"[^"]*"' | sed 's/"job_id": *//; s/"//g') # Step 2: Poll for results curl --request GET \ --url "https://api.shortapi.ai/api/v1/job/query?id=$JOB_ID" \ --header "Authorization: Bearer $SHORTAPI_KEY" ``` ### JavaScript (Fetch API) ```javascript // Step 1: Create a job const response = await fetch(`https://api.shortapi.ai/api/v1/job/create`, { method: "POST", headers: { "Authorization": `Bearer ${SHORTAPI_KEY}`, "Content-Type": "application/json" }, body: JSON.stringify({ "model": "openai/gpt-image-2.6-flare/text-to-image", "args": { "prompt": "A cinematic product photograph of a futuristic smartwatch on a black marble pedestal, dramatic studio lighting, highly detailed." }, "callback_url": "CALLBACK_URL" }) }); const data = await response.json(); const JOB_ID = data.job_id; // Step 2: Poll for results const result = await fetch(`https://api.shortapi.ai/api/v1/job/query?id=${JOB_ID}`, { method: "GET", headers: { "Authorization": `Bearer ${SHORTAPI_KEY}` } }); const resultData = await result.json(); console.log(resultData); ``` ### Python (Requests) ```python import requests # Step 1: Create a job url = "https://api.shortapi.ai/api/v1/job/create" payload = { "model": "openai/gpt-image-2.6-flare/text-to-image", "args": { "prompt": "A cinematic product photograph of a futuristic smartwatch on a black marble pedestal, dramatic studio lighting, highly detailed." }, "callback_url": "CALLBACK_URL" } headers = { "Authorization": f"Bearer {SHORTAPI_KEY}", "Content-Type": "application/json" } response = requests.post(url, headers=headers, json=payload) data = response.json() JOB_ID = data.get("job_id") # Step 2: Poll for results result_url = f"https://api.shortapi.ai/api/v1/job/query?id={JOB_ID}" result = requests.get(result_url, headers={"Authorization": f"Bearer {SHORTAPI_KEY}"}) print(result.json()) ```