Skip to main content
Every fal.api.* operation is listed below with parameter shapes and return types from the plugin Zod schemas.
New to Corsair? See API access, authentication, and error handling.

Account

billing

account.billing The account’s credit balance (needs a key with billing read access) Risk: read
Input: empty object Needs a fal key with billing read access (the BILLING, READONLY or FULL preset); other keys get 403. Output

Files

upload

files.upload Upload a file to fal storage and get a public URL to pass as a model input Risk: write
Input Output

Models

estimateCost

models.estimateCost Estimate what a number of calls or output units will cost Risk: read
Input
Output

pricing

models.pricing Unit price of fal models (per image, megapixel, second…) Risk: read
Input Output

run

models.run Run a model and wait up to waitSeconds (default 10) for its output; spends fal credits. SUCCEEDED and FAILED are final. IN_QUEUE or IN_PROGRESS is a job to follow with queue.status; video, audio and training usually take longer than the wait. Risk: write
Input Goes through fal’s queue, so a run that outlasts waitSeconds is not lost. It answers with the same fields as queue.status. SUCCEEDED and FAILED are final; only IN_QUEUE or IN_PROGRESS need following, with queue.status({ responseUrl }). Output

models.search Find fal models by text, category or endpoint id; includeOpenApi returns their input and output fields Risk: read
Input Output

Queue

cancel

queue.cancel Cancel a queued request: removed if still waiting, asked to stop if running Risk: write
Input Pass endpointId and requestId, or the responseUrl that queue.submit returned. A request that already finished answers ALREADY_COMPLETED instead of an error. Output

result

queue.result The output of a completed queued request Risk: read
Input Pass endpointId and requestId, or the responseUrl that queue.submit returned. Errors with the model’s own error (422 for bad input) when the request failed. Output: Record<string, any>

status

queue.status Where a queued request stands. Once done it returns state SUCCEEDED with the output, or FAILED with the error. Risk: read
Input Pass endpointId and requestId, or the responseUrl that queue.submit returned. fal marks failed requests COMPLETED as well, so once it does this reads the result and answers state SUCCEEDED with output, or FAILED with error. Output

submit

queue.submit Queue a model run (image, video, audio, 3D…) and get a request id back at once; spends fal credits. Follow it with queue.status until state is SUCCEEDED or FAILED, or pass webhookUrl. Risk: write
Input Output

Requests

deletePayloads

requests.deletePayloads Delete a request’s stored input and output payloads and the files it generated on fal’s CDN (files it took as input stay) Risk: destructive · Irreversible
Input Needs a full-access fal key; inference-only keys get 403. Deletes the request’s stored input and output payloads and the files it generated, for good. Files the request took as input (uploads, shared URLs) stay on fal’s CDN. A file fal could not delete comes back with a non-null exception in cdn_delete_results rather than an error, so check each entry. Output

list

requests.list Past requests to given endpoints, with timing and status; optionally their inputs and outputs Risk: read
Input Output

Usage

billingEvents

usage.billingEvents Billed requests one by one, with their cost Risk: read
Input Needs a fal key with billing read access (the BILLING, READONLY or FULL preset); other keys get 403. Output

get

usage.get Usage and cost by endpoint over a date range Risk: read
Input Needs a fal key with billing read access (the BILLING, READONLY or FULL preset); other keys get 403. Output