Skip to main content
Use these endpoints to answer which folder triggered a run, where ingestion failed, how many tiles finished, which tasks need credits, and whether a notification was delivered. The API returns persisted evidence; missing evidence is unknown.

Give your dashboard a read-only key

In the editor’s API key settings, enable Restricted and set Agents, Agent runs, and Triggers to Read. Leave the other entities at None. See API key permissions for the complete scope list and error contract. Send Authorization: Bearer mk_your_api_key on each request. Start with GET /whoami and inspect scopes. Set X-Workspace-Id to your workspace UUID when observing one workspace. Keys belong to an organization; a workspace header narrows that access. Public API access also requires an eligible paid plan.

Trace a folder to its run

  1. List storage triggers. Save each trigger’s id, agent_id, provider, root configuration, and selected_folder_display_path.
  2. List watched folders for a trigger. watcher.folder_id identifies the provider folder. Check is_active, watcher status, last_error, and deleted_at. Inactive and deleted watcher records are included unless you filter them.
  3. List ingestion events. Events with errors may have no batch or run yet. Use batch_ids for exact batch links; do not match events to runs by timestamps or filenames.
  4. List storage batches with trigger_id and optionally folder_id. agent_state_id is the run ID. Inspect stage, last_error, error_message, and the authorized run snapshot. Batch items link a batch back to its input events.
  5. Read run progress using that run ID. Whole-run node_status_counts and completed_node_percent accompany a page of runtime tiles. Fetch tasks for complete task evidence.
  6. Read notification configurations for current settings and delivery receipts for actual sending, delivered, failed, or skipped evidence. Configuration alone does not establish delivery.

IDs and values

Use List Pipeline Runs for lightweight run discovery at scale. It avoids graph/input/output expansion and supports cursor paging and run-row update watermarks. For an existing run search, List All Agent Runs, List Agent Runs, and List Trigger Runs accept folder_id, batch_id, batch_key, storage_trigger_id, and production_id. These match persisted triggered_by metadata; not every run has those fields.

Poll without losing updates

Every new list endpoint accepts limit (default 25, maximum 100) and an opaque cursor. Preserve filters and pass next_cursor verbatim until it is null. Do not construct cursors. Each progress/configuration page counts tiles; a progress tile embeds at most five recent tasks. Whole-run totals are independent of the page. For an initial history load, paginate a bounded from/to creation-time window. For subsequent polls:
  1. Record the poll start time. Start without a cursor, using the previous updated_from watermark with a short overlap.
  2. Fetch every page with identical filters. Upsert each record by its stable ID.
  3. After every page succeeds, advance the watermark to the poll start time. Keep the previous watermark if any page fails.
Results are not a transaction snapshot. Creation order stays stable, but updates can happen while paging; overlapping polls and ID-based deduplication handle those changes. updated_from filters the listed resource’s update time. Folder results use the later of the subscription and watcher update time. Progress filters tile updates, while tasks filter task updates: poll the tasks endpoint as well when task changes matter. Batch items have no update watermark and reject updated_from; load them when a batch is discovered or changes. Keep trigger/folder configuration cached, poll active runs more often than completed history, use source and time filters, and limit simultaneous requests. Avoid polling every historical run on every dashboard refresh. A completed run can be refreshed less frequently; treat status values as extensible strings.

Instructions for an AI agent

You can give an agent this procedure along with the OpenAPI contract:

Handle errors by meaning

See each endpoint reference for request examples, actual response fields, and example values.