Skip to main content
POST /api/workflows/{workflow_id}/run executes every step of a Workflow in sequence. Inputs flow into the first step and each subsequent step can reference the output of the one before it. The response includes the overall run status, final outputs, credits charged, and a result object for every step.

Endpoint

Replace {workflow_id} with the UUID of the Workflow to run. Workflow IDs are plain UUIDs — find them on the Workflows page in the dashboard or via GET /api/workflows.

Authentication

This endpoint requires a session token. Pass your JWT in the Authorization header:

Request Body

object
default:"{}"
A key-value map of input parameters to pass into the first step of the Workflow. Use {{inputs.field_name}} syntax inside your step configs to reference these values. Pass an empty object or omit this field entirely if the first step takes no parameters.

Example Request

Response

A successful request returns HTTP 200 with the run result.

Top-Level Fields

string
Unique identifier for this Workflow run (plain UUID).
string
The UUID of the Workflow that was executed.
string
Overall run status. One of completed, failed, or waiting_for_human (when a Human-in-the-Loop step is pending review).
object | null
The inputs that were passed into the first step.
any | null
The output produced by the final step of the Workflow. null if the run failed before completing.
string | null
Error message if the run failed, otherwise null.
float
Total credits consumed across all steps in this run.
integer | null
Total wall-clock execution time in milliseconds.
string | null
ISO 8601 UTC timestamp of when execution began.
string | null
ISO 8601 UTC timestamp of when the run finished.
string
ISO 8601 UTC timestamp of when the run record was created.
array
Ordered array of result objects, one per step.

Example Response

Error Handling