Skip to main content
POST
/
images
/
edits
Edit an image
curl --request POST \
  --url https://api.orcarouter.ai/v1/images/edits \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form model=gpt-image-1 \
  --form image='@example-file' \
  --form 'prompt=<string>' \
  --form mask='@example-file' \
  --form n=1 \
  --form size=1024x1024 \
  --form response_format=url
{
  "created": 123,
  "data": [
    {
      "url": "<string>",
      "b64_json": "<string>",
      "revised_prompt": "<string>"
    }
  ]
}

Authorizations

Authorization
string
header
required

OrcaRouter API keys look like sk-orca-.... Pass them in the Authorization: Bearer sk-orca-... header.

Body

multipart/form-data
model
string
required
Example:

"gpt-image-1"

image
file
required
prompt
string
required
mask
file
n
integer
default:1
size
string
Example:

"1024x1024"

response_format
enum<string>
Available options:
url,
b64_json

Response

200 - application/json

OK

created
integer
data
object[]