openai_edit_image
Modify an existing image by providing a reference image URL and a text description of the desired changes. Uses AI to add, remove, or transform elements.
Instructions
Edit or modify existing images using OpenAI image models via AceDataCloud.
Applies AI-powered edits to existing images based on text descriptions.
Can modify, extend, or transform images while preserving desired elements.
Use this when:
- You want to modify an existing image
- You need to add, remove, or change elements in an image
- You want to apply a specific style or transformation to an image
Returns:
JSON response containing the edited image URL(s) or base64 data.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| n | No | Number of images to generate (1-10). Default is 1. | |
| size | No | Output image dimensions as 'WIDTHxHEIGHT' or 'auto'. Default is '1024x1024'. gpt-image-2 accepts any custom dimensions (multiples of 16, longer side ≤ 3840, total pixels ≤ 8,294,400). Common presets — 1K: '1024x1024', '1536x1024', '1024x1536', '1792x1024', '1024x1792'; 2K (1.5× rate): '2048x2048', '2048x1536', '1536x2048', '2048x1152', '1152x2048'; 4K (1.5× rate): '2880x2880', '3264x2448', '2448x3264', '3840x2160', '2160x3840'. dall-e-2: '256x256', '512x512', '1024x1024'. | 1024x1024 |
| image | Yes | Reference image URL(s). Accepts a single URL string or an array of URLs for multi-image editing. The image(s) to use as the starting point for edits. | |
| model | No | The image model to use for editing. Options: 'gpt-image-1' (default), 'gpt-image-1.5', 'gpt-image-2', 'dall-e-3', 'nano-banana' variants. | gpt-image-1 |
| prompt | Yes | Text description of the desired edit. Max 1000 characters for gpt-image models. Describe what you want to change or add to the image. | |
| quality | No | Output quality. Options: 'auto' (default), 'high', 'medium', 'low', 'standard'. | auto |
| background | No | Background handling. 'transparent' removes background, 'opaque' keeps it, 'auto' decides automatically. | |
| callback_url | No | Optional webhook URL. When provided, returns task_id immediately and POSTs result to this URL when complete. | |
| output_format | No | Output file format. Options: 'png' (default), 'jpeg', 'webp'. | png |
| input_fidelity | No | How closely to follow the reference image. 'high' preserves more detail, 'low' allows more creative freedom. | |
| response_format | No | How to return the image. 'url' (default) returns a URL, 'b64_json' returns base64-encoded image data. | url |
| output_compression | No | Compression level (0-100%) for jpeg/webp output. Default is 100. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |