curl --request POST \
--url https://api.ppinfra.com/v3/async/img2img \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '{
"extra": {
"response_image_type": "<string>"
},
"request": {
"model_name": "<string>",
"image_base64": "<string>",
"prompt": "<string>",
"width": 123,
"height": 123,
"image_num": 123,
"steps": 123,
"guidance_scale": 123,
"sampler_name": "<string>",
"negative_prompt": "<string>",
"sd_vae": "<string>",
"controlnet": {
"units": [
{
"model_name": "<string>",
"image_base64": "<string>",
"strength": 123,
"preprocessor": "<string>",
"guidance_start": 123,
"guidance_end": 123
}
]
},
"seed": 123,
"loras": [
{
"model_name": "<string>",
"strength": 123
}
],
"embeddings": [
{
"model_name": "<string>"
}
],
"clip_skip": {},
"strength": {},
"ip_adapters": [
{
"model_name": "<string>",
"image_base64": "<string>",
"strength": {}
}
]
}
}'
{
"task_id": "<string>"
}
curl --request POST \
--url https://api.ppinfra.com/v3/async/img2img \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '{
"extra": {
"response_image_type": "<string>"
},
"request": {
"model_name": "<string>",
"image_base64": "<string>",
"prompt": "<string>",
"width": 123,
"height": 123,
"image_num": 123,
"steps": 123,
"guidance_scale": 123,
"sampler_name": "<string>",
"negative_prompt": "<string>",
"sd_vae": "<string>",
"controlnet": {
"units": [
{
"model_name": "<string>",
"image_base64": "<string>",
"strength": 123,
"preprocessor": "<string>",
"guidance_start": 123,
"guidance_end": 123
}
]
},
"seed": 123,
"loras": [
{
"model_name": "<string>",
"strength": 123
}
],
"embeddings": [
{
"model_name": "<string>"
}
],
"clip_skip": {},
"strength": {},
"ip_adapters": [
{
"model_name": "<string>",
"image_base64": "<string>",
"strength": {}
}
]
}
}'
{
"task_id": "<string>"
}
application/json
Show properties
png, webp, jpeg
Hide properties
filter.types=checkpoint
来获取可用模型列表。Euler a,Euler,LMS,Heun,DPM2,DPM2 a,DPM++ 2S a,DPM++ 2M,DPM++ SDE,DPM fast,DPM adaptive,LMS Karras,DPM2 Karras,DPM2 a Karras,DPM++ 2S a Karras,DPM++ 2M Karras,DPM++ SDE Karras,DDIM,PLMS,UniPC
filter.types=vae
来获取可用模型列表。Show properties
Hide properties
filter.types=controlnet
来获取可用模型列表,如果 Checkpoint 为 SDXL 模型时,请额外指定请求参数 filter.types=controlnet&filter.is_sdxl=true
来获取可用模型列表。scribble_hed,softedge_hed,scribble_hedsafe,softedge_hedsafe,depth_midas,mlsd,openpose,openpose_face,openpose_faceonly,openpose_full,openpose_hand,dwpose,scribble_pidinet,softedge_pidinet,scribble_pidsafe,softedge_pidsafe,normal_bae,lineart_coarse,lineart_realistic,lineart_anime,lineart,depth_zoe,shuffle,mediapipe_face,canny,depth,depth_leres,depth_leres++
Show properties
filter.types=textualinversion
来获取可用模型列表。Show properties
ip-adapter_sd15.bin, ip-adapter_sdxl.bin