对于支持以图生图的模型,你可以通过传入图片链接进行以图生图,具体的使用方法如下:

curl --location --request POST 'https://geekai.co/api/v1/images/generations' \
--header 'Content-Type: application/json' \
--header 'Authorization: $GEEKAI_API_KEY' \
--data '{
    "model":"kling-image-v1-5",
    "prompt":"修复这张破损的照片",
    "image_url":"https://static.geekai.co/storage/2025/04/02/broken-picture.jpg"
}'

多张图片以数组形式传递即可:

curl --location --request POST 'https://geekai.co/api/v1/images/generations' \
--header 'Content-Type: application/json' \
--header 'Authorization: $GEEKAI_API_KEY' \
--data '{
    "model": "gpt-image-1",
    "prompt": "将第一张图中的面料应用至第二张图的服装上,图片比例按照第二张图的来",
    "image": [
        "https://style3d-render.oss-cn-hangzhou.aliyuncs.com/test/针织.jpg",
        "https://style3d-render.oss-cn-hangzhou.aliyuncs.com/test/款式图.jpg"
    ]
}'

目前支持以图生图的模型有 gpt-image-1midjourney-imaginestable-image-ultrakling-image-v1-5kling-image-v1