Skip to main content
POST
/
v1
/
prediction
Create Model Prediction
curl --request POST \
  --url https://api.eachlabs.ai/v1/prediction \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "model": "flux-1-1-pro",
  "input": {
    "prompt": "A beautiful sunset over the ocean with vibrant colors",
    "aspect_ratio": "16:9"
  },
  "webhook_url": "https://your-app.com/webhook",
  "webhook_secret": "your-secret-key"
}
'
{
  "status": "success",
  "message": "Prediction created successfully",
  "predictionID": "abc123-def456-ghi789"
}

Documentation Index

Fetch the complete documentation index at: https://docs.eachlabs.ai/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-API-Key
string
header
required

API key for authentication

Body

application/json
model
string
required

Model slug or identifier

Example:

"flux-1-1-pro"

input
object
required

Input parameters for the prediction

Example:
{
"prompt": "A beautiful sunset over the ocean with vibrant colors",
"aspect_ratio": "16:9"
}
version
string
deprecated

Deprecated. This field is ignored. Kept for backwards compatibility.

Example:

"0.0.1"

webhook_url
string<uri>

Optional webhook URL to receive prediction result asynchronously

Example:

"https://your-app.com/webhook"

webhook_secret
string

Optional secret used to sign webhook requests

Example:

"your-secret-key"

Response

Prediction created successfully

status
string

Status of the prediction creation request

Example:

"success"

message
string

Human-readable message about the prediction creation

Example:

"Prediction created successfully"

predictionID
string

Unique prediction identifier

Example:

"abc123-def456-ghi789"

Last modified on May 28, 2026