Skip to main content
POST
Flows - Run a flow

Authorizations

x-magnific-api-key
string
header
required

Your Magnific API key. Required for authentication. Learn how to obtain an API key

Path Parameters

flow-id
string
required

Short unique identifier (sqid) of the flow to execute. Discover flow identifiers via GET /v1/ai/flows.

Example:

"uqzQLDr2Aw"

Body

application/json
inputs
object
required

Map of input identifier to value. Use each input's api_key (recommended) or its id (UUID, legacy) as the key — both are accepted.

Value types by input type:

  • creation (image/media): URL string, base64-encoded string, or existing creation sqid
  • text: Plain text string
  • number: Numeric value
  • select: Value from allowed options
webhook
string<uri>

Optional callback URL that receives status notifications during execution. The webhook receives POST requests with the event payload (see webhook event schema). Events are sent when the run starts (initialized) and when it finishes (finished or failed).

Example:

"https://www.example.com/webhook"

Response

Accepted - Flow execution started. Use the webhook to receive results.

status
enum<string>
required

Current execution status.

Available options:
running
Example:

"running"

workflow_run_identifier
string
required

Unique identifier for this flow execution run. Matches the run_id in webhook events.

Example:

"vCrK3Aa47y"