POST
/
images
/
edits
curl --request POST \
  --url https://api.openai.com/v1/images/edits \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form 'prompt=A cute baby sea otter wearing a beret' \
  --form model=dall-e-2 \
  --form n=1 \
  --form size=1024x1024 \
  --form response_format=url \
  --form user=user-1234
{
  "created": 123,
  "data": [
    {
      "b64_json": "<string>",
      "url": "<string>",
      "revised_prompt": "<string>"
    }
  ]
}

Authorizations

Authorization
string
header
required

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

Body

multipart/form-data

Response

200 - application/json

OK

The response is of type object.