Images

Edit an image

Edit or inpaint an image, or combine multiple reference images, via multipart/form-data. Served by OpenAI gpt-image-2.

post/images/edits

Request

  • Base URL
    https://api.orcarouter.ai/v1
  • URL
    https://api.orcarouter.ai/v1/images/edits
  • Auth
    HTTP bearer

Request body multipart/form-data

modelstring required
imagestring binary required

The image to edit, sent as multipart/form-data. To pass multiple reference images, repeat the field as image[].

maskstring binary

Optional. A PNG whose transparent region marks the area to repaint. Must match the dimensions of image.

promptstring required
ninteger
sizestring
response_format'url' | 'b64_json'

Example request

{
  "model": "openai/gpt-image-2",
  "size": "1024x1024"
}

Response

OK

createdinteger

Changes

No recorded changes to this operation across all 2 revisions of this API.