Skip to main content
Running an app is asynchronous: you start a run and get a runId back immediately, then poll until the run completes. This page walks through the whole flow. All examples assume you’ve set FLOWY_API and FLOWY_KEY from Authentication.
1

Find the app you want to run

List the apps in your workspace and grab an app’s id.
curl "$FLOWY_API/apps" -H "Authorization: Bearer $FLOWY_KEY"
{ "data": [
  { "id": "507f1f77bcf86cd799439011", "title": "Headshot generator",
    "published": true, "runCount": 42 }
] }
2

Look up the app's inputs

Fetch the app to see which inputs it expects. Each input’s nodeId is the key you’ll send in the run request.
curl "$FLOWY_API/apps/APP_ID" -H "Authorization: Bearer $FLOWY_KEY"
{ "data": {
  "id": "APP_ID", "title": "Headshot generator",
  "inputs": [
    { "nodeId": "node_1", "label": "Your photo", "kind": "image_url", "required": true },
    { "nodeId": "node_2", "label": "Style", "kind": "text", "required": false }
  ],
  "outputs": [ { "nodeId": "node_9", "label": "Headshot", "outputType": "image" } ]
} }
3

Start the run

POST to the app’s runs endpoint with an inputs map of nodeId → value. Text inputs take a string; media inputs take a URL. You get a runId back right away.
curl -X POST "$FLOWY_API/apps/APP_ID/runs" \
  -H "Authorization: Bearer $FLOWY_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "inputs": {
      "node_1": "https://example.com/me.jpg",
      "node_2": "studio lighting, neutral background"
    }
  }'
{ "data": { "runId": "64c3f2a1e8b9c0d1f2e3a4b5", "status": "queued" } }
4

Poll until it's done

Poll the run every couple of seconds until status is completed or failed. Output media URLs are signed and ready to download.
curl "$FLOWY_API/runs/RUN_ID" -H "Authorization: Bearer $FLOWY_KEY"
{ "data": {
  "runId": "RUN_ID", "appId": "APP_ID", "status": "completed",
  "outputs": [
    { "nodeId": "node_9", "kind": "image", "url": "https://cdn.flowy…/headshot.png" }
  ]
} }
Output URLs are signed and expire. Download or copy the asset to your own storage soon after the run completes rather than storing the URL long‑term.