Skip to main content
GET
Retrieve a batch

Authorizations

x-api-key
string
header
required

Your workspace API key, leap_.... Create one at https://app.tryleap.ai/go/api, and keep it on your server.

Headers

Prefer
string

wait=N holds the request open for up to N seconds (at most 60) until the generation finishes, and Preference-Applied echoes the wait used. Most images finish inside the wait. If the run is still going when it ends, you get it back queued or running; poll it from there. Without this header the generation comes back queued at once.

Example:

"wait=60"

Path Parameters

id
string
required

The batch's ID, bat_....

Response

The batch, as it is now or when the wait ends.

Up to 50 generations priced and held together, each run on its own.

id
string
required

The batch's ID, bat_....

object
string
required
Allowed value: "batch"
data
object[]
required

Its generations, in the order you sent them.

Last modified on October 4, 2026