Skip to main content
POST

Authorization

  • Auth Type: Bearer Auth (In: header)
  • Format: Authorization: Bearer <YOUR_API_KEY>
  • Description: Use Bearer <YOUR_API_KEY>. Format: Authorization: Bearer sk-xxxxxx.
  • API Key: where API Key is your AGCloud API KEY
Edit images using gpt-image-2.6-sunburst. The multipart examples match the existing gateway upload convention; the path is /v1/images/edits (plural images).

Request Examples

Use the boundary produced by the multipart encoder. Java explicitly constructs a matching boundary and body. Go, Java, PHP, and C# print the response JSON; decode data[0].b64_json to save the image, as shown in the Python and JavaScript examples. The success response is illustrative; replace the Base64 placeholder with actual image data before decoding. OpenAI GPT Image responses use data[].b64_json, not image URLs. Do not send response_format or style; describe the desired style in prompt.

Request Parameters

See the OpenAI edit reference. Checked November 12, 2026. See the generation parameter definitions for format restrictions and official documentation discrepancies. Optional controls depend on gateway support. input_fidelity support is not established for this model; omit it. Do not send legacy response_format or style. SVG editing is not promised because the upstream guide and edit schema conflict.