Check run status

The /run-data endpoint returns the current status of an automation and any data it wrote out (for example, rows added to a Google Sheet, or values returned from a custom JavaScript step). Identify the run by the automation's name, the same string you pass to /trigger. Poll this endpoint after triggering to know when the run is finished.

Request


POST /api/v3/run-data
ParameterTypeRequiredDescription
keystringYesYour API key. See Authentication.
namestringYesExact name of the automation, as it appears in the Dashboard. Case-sensitive and whitespace-sensitive. Same string you pass to /trigger.

Request payload

{
  "key": "<API_KEY>",
  "name": "<AUTOMATION_NAME>"
}

Response


{
  "status": "Success",
  "data": {
    "google-sheet-data": [
      ["A1", "B1", "C1"],
      ["A2", "B2", "C2"]
    ]
  }
}
FieldTypeDescription
statusstringOne of Running, Success, or Failure.
dataobjectData the automation wrote out, keyed by the token name of each Google Sheet (or other writer step). Each value is a 2D array of [row][col].

Status values

ValueMeaning
RunningThe run is in the queue or actively executing.
SuccessThe run completed without errors. The data field contains any output.
FailureThe run hit an error and stopped. Check the run report in the Dashboard for details.

Example


curl -X POST https://lar.axiom.ai/api/v3/run-data \
  -H "Content-Type: application/json" \
  -d '{
    "key": "your-api-key-here",
    "name": "My First Automation"
  }'

A typical polling loop:

async function waitForRun(name, key) {
  while (true) {
    const res = await fetch("https://lar.axiom.ai/api/v3/run-data", {
      method: "POST",
      headers: { "Content-Type": "application/json" },
      body: JSON.stringify({ key, name }),
    });
    const result = await res.json();

    if (result.status === "Success") return result.data;
    if (result.status === "Failure") throw new Error("Run failed");

    await new Promise(r => setTimeout(r, 10_000)); // poll every 10s
  }
}

Polling cadence


Poll every 5 to 15 seconds for most automations. Faster polling won't make the run finish any quicker, and may trip rate limits. For long-running automations (those that take more than a few minutes), increase the interval to 30 seconds or use exponential backoff: start at 5 seconds, double each time, cap at 60.

When there's no completion webhook


The API doesn't push a notification when a run finishes; polling /run-data is the only way to detect completion from outside. If you want a push-style notification, add a Trigger webhook step inside the automation itself. The automation will POST to your URL when it reaches that step, which you can place at the end of the flow to get a "done" signal.

Notes


  • /run-data returns the status of the most recent run of an automation with the given name. To see runs further back in history, use /run-reports.
  • The data object is keyed by the token name of each writer step (most commonly a Google Sheet token). One automation can write to several sheets, in which case data has several keys. Each value is the 2D [row][col] content of that sheet.
  • An automation that doesn't write any data returns data as an empty object.
  • A run that's been queued reports Running, the same as a run that's actively executing. There's no separate Queued state today. See Queue and concurrency for ways to tell the two apart.
  • Names are matched exactly. Case and whitespace must match the Dashboard.