Skip to content

Edit image

POST
/v1/images/edits
curl --request POST \
--url https://api.mirapi.ai/v1/images/edits \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '"{\n \"model\": \"qwen-image-edit-plus\",\n \"input\": {\n \"messages\": [\n {\n \"role\": \"user\",\n \"content\": [\n {\n \"image\": \"https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20250925/fpakfo/image36.webp\"\n },\n {\n \"text\": \"Generate an image that matches the depth map, following this description: a battered red bicycle parked on a muddy path, with a dense primeval forest in the background\"\n }\n ]\n }\n ]\n },\n \"parameters\": {\n \"n\": 2,\n \"negative_prompt\": \" \",\n \"prompt_extend\": true,\n \"watermark\": false\n }"'

Bailian qwen-image series image editing

Media typeapplication/json
object
model
required
string
input
required
object
messages
required
Array<object>
object
role
string
content
Array<object>
object
image
string
text
string
parameters
object
n
integer
negative_prompt
string
prompt_extend
boolean
watermark
boolean
size
string
Example
{
"model": "qwen-image-edit-plus",
"input": {
"messages": [
{
"role": "user",
"content": [
{
"image": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20250925/fpakfo/image36.webp"
},
{
"text": "Generate an image that matches the depth map, following this description: a battered red bicycle parked on a muddy path, with a dense primeval forest in the background"
}
]
}
]
},
"parameters": {
"n": 2,
"negative_prompt": " ",
"prompt_extend": true,
"watermark": false
}

Image generated

Media typeapplication/json
object
created
integer
data
Array<object>
object
url
string
b64_json
string
revised_prompt
string
Examplegenerated
{
"created": 1,
"data": [
{
"url": "example",
"b64_json": "example",
"revised_prompt": "example"
}
]
}