Create image edit
Creates an edited or extended image given an original image and a prompt.
Last updated on
Creates an edited or extended image given an original image and a prompt.
Last updated on
In: header
Model identifier in the format providerSlug/modelSlug, e.g., qwen/qwen-image-edit.
binarybinary11 <= value <= 6"url""url" | "b64_json"curl -X POST "https://api.openroute.cn/v1/images/edits" \ -H "Content-Type: application/json" \ -d '{ "model": "qwen/qwen-image-edit", "image": "string", "prompt": "A sunlit indoor lounge area with a pool containing a flamingo" }'The image to edit. Can be a file (multipart/form-data) or a Base64-encoded string/URL (application/json).
An additional image whose fully transparent areas indicate where image should be edited. Can be a file (multipart/form-data) or a Base64-encoded string/URL (application/json).
A text description of the desired image(s).
The number of images to generate. Must be between 1 and 6.
The size of the generated images. Supported sizes include 1024x1024, etc.
The format in which the generated images are returned. url returns image URL, b64_json returns base64-encoded image.
A unique identifier representing your end-user, used for logging and auditing.
Specify vendor slug. If not specified, will be automatically selected based on priority.
curl -X POST "https://api.openroute.cn/v1/images/edits" \
-H "Content-Type: application/json" \
-d '{
"model": "qwen/qwen-image-edit",
"image": "string",
"prompt": "A sunlit indoor lounge area with a pool containing a flamingo"
}'{
"created": 1589478378,
"data": [
{
"url": "http://example.com",
"b64_json": "string",
"revised_prompt": "string"
}
]
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}