Skip to main content
POST
Error

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

multipart/form-data
image
file
required

Source image to edit (single-image form; gpt-image-1 and DALL·E 2). At least one of image or image[] is required

prompt
string
required

Text description of the desired edit

model
string
required

Model ID

image[]
file[]

Repeatable field carrying several source images (gpt-image-1, up to 16). At least one of image or image[] is required

Maximum array length: 16
mask
file

PNG whose transparent areas mark where the image should be edited

n
integer

Number of images to generate

Required range: x >= 1
size
string

Output size, e.g. 1024x1024

quality
string

Output quality (model-specific)

response_format
string

url or b64_json (DALL·E 2 only; gpt-image-1 always returns b64_json)

user
string

End-user identifier forwarded to the provider

Response

OK

background
string
created
integer
data
object[]
output_format
string
provider
string

Provider is a gateway addition, stamped like every other routed response, so clients can tell which provider served the request.

quality
string
size
string
usage
object
Last modified on August 24, 2026