创建任务 flux-kontext-apps/multi-image-kontext-max
POST /replicate/v1/models/flux-kontext-apps/multi-image-kontext-max/predictions
说明
概览
| Method | POST |
|---|---|
| Path | /replicate/v1/models/flux-kontext-apps/multi-image-kontext-max/predictions |
| Type | http |
| Status | 1 |
| Module | 2102810 |
| Folder | 62419371 |
参数
{ "query": [], "path": [], "cookie": [], "header": [ { "required": false, "description": "", "type": "string", "id": "GTujCrB2It", "enable": true, "name": "Authorization", "sampleValue": "Bearer {{YOUR_API_KEY}}" } ] }
请求体
{ "type": "application/json", "parameters": [], "jsonSchema": { "type": "object", "properties": { "input": { "type": "object", "properties": { "prompt": { "type": "string", "description": "关于如何组合或转换两个输入图像的文本描述。" }, "aspect_ratio": { "type": "string", "description": "生成图像的长宽比。使用“match_input_image”来匹配输入图像的长宽比。默认值:“match_input_image”" }, "input_image_1": { "type": "string", "description": "第一个输入图像。必须是 jpeg、png、gif 或 webp 格式。" }, "input_image_2": { "type": "string", "description": "第二个输入图像。必须是 jpeg、png、gif 或 webp 格式。" }, "output_format": { "type": "string", "description": "生成图像的输出格式。默认值:“png”。" }, "safety_tolerance": { "type": "integer", "description": "安全容差,0 表示最严格,2 表示最宽松。2 是目前允许的最大值。默认值:2" } }, "required": [ "prompt", "input_image_1", "input_image_2" ], "x-apifox-orders": [ "prompt", "aspect_ratio", "input_image_1", "input_image_2", "output_format", "safety_tolerance" ] } }, "x-apifox-orders": [ "input" ] }, "mediaType": "", "examples": [ { "value": "{\n \"input\": {\n \"prompt\": \"Put the woman into a white t-shirt with the text on it\",\n \"aspect_ratio\": \"1:1\",\n \"input_image_1\": \"https://replicate.delivery/pbxt/N5rSeJrCafWpmJuLb62moY8pSMEpSBBwSf7N6hxyIn4fNYMa/w8msa88d01rm80cq3hzsqrdehg.png\",\n \"input_image_2\": \"https://replicate.delivery/pbxt/N5rSdTCgBqIRvbkedcfLfS5xTSEEOqMtX9FsR1hLK9JYryml/0_1.webp\",\n \"output_format\": \"png\",\n \"safety_tolerance\": 2\n }\n }", "mediaType": "application/json", "description": "" } ], "oasExtensions": "" }
响应
[ { "id": 729622649, "name": "成功", "code": 200, "contentType": "json", "jsonSchema": { "type": "object", "properties": { "id": { "type": "string" }, "model": { "type": "string" }, "version": { "type": "string" }, "input": { "type": "object", "properties": { "aspect_ratio": { "type": "string" }, "input_image_1": { "type": "string" }, "input_image_2": { "type": "string" }, "output_format": { "type": "string" }, "prompt": { "type": "string" }, "safety_tolerance": { "type": "integer" } }, "required": [ "aspect_ratio", "input_image_1", "input_image_2", "output_format", "prompt", "safety_tolerance" ] }, "logs": { "type": "string" }, "output": { "type": "null" }, "data_removed": { "type": "boolean" }, "error": { "type": "null" }, "status": { "type": "string" }, "created_at": { "type": "string" }, "urls": { "type": "object", "properties": { "cancel": { "type": "string" }, "get": { "type": "string" }, "stream": { "type": "string" }, "web": { "type": "string" } }, "required": [ "cancel", "get", "stream", "web" ] } }, "required": [ "id", "model", "version", "input", "logs", "output", "data_removed", "error", "status", "created_at", "urls" ] }, "itemSchema": {}, "description": "", "mediaType": "", "headers": [], "oasExtensions": "" } ]
响应示例
[ { "name": "成功示例", "responseId": 729622649, "data": "{\n \"id\": \"b6k38vmb01rme0crb4bbr2apw4\",\n \"model\": \"flux-kontext-apps/multi-image-kontext-max\",\n \"version\": \"hidden\",\n \"input\": {\n \"aspect_ratio\": \"1:1\",\n \"input_image_1\": \"https://replicate.delivery/pbxt/N5rSeJrCafWpmJuLb62moY8pSMEpSBBwSf7N6hxyIn4fNYMa/w8msa88d01rm80cq3hzsqrdehg.png\",\n \"input_image_2\": \"https://replicate.delivery/pbxt/N5rSdTCgBqIRvbkedcfLfS5xTSEEOqMtX9FsR1hLK9JYryml/0_1.webp\",\n \"output_format\": \"png\",\n \"prompt\": \"Put the woman into a white t-shirt with the text on it\",\n \"safety_tolerance\": 2\n },\n \"logs\": \"\",\n \"output\": null,\n \"data_removed\": false,\n \"error\": null,\n \"status\": \"starting\",\n \"created_at\": \"2025-07-30T02:08:26.368Z\",\n \"urls\": {\n \"cancel\": \"https://api.replicate.com/v1/predictions/b6k38vmb01rme0crb4bbr2apw4/cancel\",\n \"get\": \"https://api.replicate.com/v1/predictions/b6k38vmb01rme0crb4bbr2apw4\",\n \"stream\": \"https://stream.replicate.com/v1/files/bcwr-4lncowbqyyr5toyxguv6tr47ffpade3muguvemzik5let3hnlryq\",\n \"web\": \"https://replicate.com/p/b6k38vmb01rme0crb4bbr2apw4\"\n }\n}", "description": "", "oasKey": "", "oasExtensions": "", "id": 649167807 } ]