Skip to content
中文

POST /replicate/v1/predictions

Method: POSTEndpoint: /replicate/v1/predictions

https://replicate.com/lucataco/flux-schnell-lora?input=http FLUX.1-Schnell LoRA

Request Parameters

Header Parameters

text
Content-Type
string
Required
Example:
application/json
Authorization
string
Optional
Default Value:
Bearer {{YOUR_API_KEY}}

Body Parameters application/json

text
version
string
Required
input
object
Required
seed
integer
Required
image
string
Required
steps
integer
Required
prompt
string
Required
cfg_scale
integer
Required
scheduler
string
Required
sampler_name
string
Required
negative_prompt
string
Required
denoising_strength
number
Required
outpaint_direction
string
Required
overlay_original_img
boolean
Required
Example
{
"version"
:
"2a6b576af31790b470f0a8442e1e9791213fa13799cbb65a9fc1436e96389574"
,
"input"
:
{
"prompt"
:
"a beautiful castle frstingln illustration"
,
"hf_lora"
:
"alvdansen/frosting_lane_flux"
,
"lora_scale"
:
0.8
,
"num_outputs"
:
1
,
"aspect_ratio"
:
"1:1"
,
"output_format"
:
"webp"
,
"output_quality"
:
80
,
"prompt_strength"
:
0.8
,
"num_inference_steps"
:
4
}
}

Example Request

Shell

bash
curl --location --request POST '/replicate/v1/predictions' \
--header 'Authorization: Bearer {{YOUR_API_KEY}}' \
--header 'Content-Type: application/json' \
--data-raw '{
    "version": "2a6b576af31790b470f0a8442e1e9791213fa13799cbb65a9fc1436e96389574",
    "input": {
      "prompt": "a beautiful castle frstingln illustration",
      "hf_lora": "alvdansen/frosting_lane_flux",
      "lora_scale": 0.8,
      "num_outputs": 1,
      "aspect_ratio": "1:1",
      "output_format": "webp",
      "output_quality": 80,
      "prompt_strength": 0.8,
      "num_inference_steps": 4
    }
  }'

Response

🟢 200 Success

Content Type: application/json

Response Schema

text
object

Example

json
{}