Variation
POST
/api/v1/taskThis enpoint from PiAPI's Midjourney API generates different versions of the selected image, corresponding to the Variations
commands from the offical Midjourney.
Request
Your API Key for authorization
The task ID of the parent task.
Image index to do the variation - valid values can be 1, 2, 3, 4, high_variation, & low_variation.
High_variation and low_variation are only valid for both V5.2 and V6 tasks (high_variation means vary_strong, low_variation stands for vary_subtle; high_variation and low_variation are meant to use upon upscaled(u1/u2/u3/u4) task, not original imagine/blend task
The prompt for the operation.
This parameter dictates the ouput image's aspect ratio value.
Use this parameter to skip our internal prompt check.
{
"model": "midjourney",
"task_type": "variation",
"input": {
"origin_task_id": "8409f94e-dd6a-4e5d-874d-3a074e72dcd0",
"index": "1",
"prompt": "angry cat wearing a hat",
"aspect_ratio": "16:9",
"skip_prompt_check": false
},
"config": {
"service_mode": "",
"webhook_config": {
"endpoint": "",
"secret": ""
}
}
}
Request samples
Responses
OK - Successful Response
{
"code": 200,
"data": {
"task_id": "6a216a6c-f775-4318-9200-16afe2bd2584",
"model": "midjourney",
"task_type": "variation",
"status": "pending",
"config": {
"service_mode": "public",
"webhook_config": {
"endpoint": "",
"secret": ""
}
},
"input": {},
"output": {
"image_url": "",
"image_urls": null,
"temporary_image_urls": null,
"discord_image_url": "",
"actions": [],
"progress": 0,
"intermediate_image_urls": null
},
"meta": {},
"detail": null,
"logs": [],
"error": {
"code": 0,
"raw_message": "",
"message": "",
"detail": null
}
},
"message": "success"
}