创建任务
测试中
POST
https://api.deerapi.com/replicate/v1/predictions
Replicate
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.deerapi.com/replicate/v1/predictions' \
--header 'Authorization: Bearer {{api-key}}' \
--header 'Prefer: wait=10' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "stability-ai/stable-diffusion-3.5-large",
"input": {
"prompt": "black forest gateau cake spelling out the words \"FLUX SCHNELL\", tasty, food photography, dynamic shot"
}
}'
响应示例响应示例
{
"id": "r4prrv83g9rma0cnh0vbhqhb2g",
"model": "black-forest-labs/flux-schnell",
"version": "hidden",
"input": {
"prompt": "black forest gateau cake spelling out the words \"FLUX SCHNELL\", tasty, food photography, dynamic shot"
},
"logs": "",
"output": [
"https://replicate.delivery/xezq/QqAPxL5nRxpRClFy7oV3WuDdNnMIAsreRI0tivKvDpBaK1LKA/out-0.webp"
],
"data_removed": false,
"error": null,
"status": "processing",
"created_at": "2025-03-12T02:36:36.098Z",
"urls": {
"cancel": "https://api.replicate.com/v1/predictions/r4prrv83g9rma0cnh0vbhqhb2g/cancel",
"get": "https://api.replicate.com/v1/predictions/r4prrv83g9rma0cnh0vbhqhb2g",
"stream": "https://stream.replicate.com/v1/files/bcwr-ctgqnxzmppcbcbpvpygk5qnsd4nmxzw2zkofxfcx2cfl2f4pl3fq"
}
}
请求参数
Header 参数
Authorization
string
必需
示例值:
Bearer {{api-key}}
Prefer
string
wait time
默认值:
wait=10
示例值:
wait=10
Body 参数application/json
返回响应
修改于 2025-04-02 06:07:30