nexqdata/ docs

Pipelines

Run agents in a fixed order, as one run.

A pipeline runs its agents one after another. Each stage starts only when the previous stage succeeds; if a stage fails, the chain stops there, so nothing downstream runs on a broken result.

Stages don't pass data to each other

Each stage runs with its agent's default inputs. A pipeline sequences agents; it doesn't feed one stage's output into the next stage's inputs.

List pipelines

GET/api/pipelines
GET/api/pipelines/{id}

One pipeline, with its steps in order. Each step has its sortOrder, scraperAgentId, and externalAgentId.

FieldMeaning
isActivefalse when the pipeline is disabled and can't be run.
stepCount, stepsThe agents in the chain, in order.
activeRunCountRuns of this pipeline still in progress.
lastRunStatus, lastRunAtThe latest run's status and when it started. null if it has never run.
canManageWhether you can edit or delete it — true for pipelines you created.

Run a pipeline

POST/api/pipelines/{pipelineId}/run
curl -X POST "$NEXQDATA_API/api/pipelines/$PIPELINE_ID/run" \
  -H "X-Api-Key: $NEXQDATA_API_KEY"
200 OK
{
  "success": true,
  "message": "Pipeline started — running 4 agents in order.",
  "data": {
    "pipelineRunId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "stepCount": 4
  }
}

You get 403 FORBIDDEN if the pipeline includes an agent that isn't assigned to you.

Follow a pipeline run

GET/api/pipelines/runs/{pipelineRunId}
FieldMeaning
statusRunning, Completed, or Failed.
currentStepIndex, stepCountWhich stage is running, out of how many.
startedAt, finishedAtWhen the run started and ended.
stepsOne entry per stage, with its status, error, and the agentJobHistoryId it started.

Each stage reports Pending, Running, Succeeded, Failed, or Skipped (for stages after a failure).

List pipeline runs

GET/api/pipelines/runs

Your past pipeline runs, newest first. This list is paged by page number.

Query parameterDefaultDescription
pipelineIdOnly this pipeline's runs.
statusallRunning, Completed, or Failed.
qMatches the pipeline name or the run id.
from, toOnly runs started in this date range.
page, pageSize1, 25pageSize up to 100.

The response has items, total, and metricstotal, completed, inProgress, and issues across all your pipeline runs.

Download the results

GET/api/pipelines/runs/{pipelineRunId}/export

One zip containing every stage's output.

Create and manage pipelines

You can build pipelines from the agents assigned to you, and edit or delete the pipelines you created. Pipelines set up for you by NexqData can be run but not changed — for those, canManage is false and edits return 404.

POST/api/pipelines
Request body
{
  "name": "Licence check, then court records",
  "description": "Stops if the licence lookup fails.",
  "agentIds": [
    "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "3fa85f64-5717-4562-b3fc-2c963f66afa7"
  ]
}

agentIds are agent ids (GUIDs), in the order the stages run. A pipeline can have up to 25 stages, and each agent can appear only once. Breaking either rule, or including an agent that isn't assigned to you, returns 400.

EndpointDoes
PUT /api/pipelines/{id}Change name or description, or disable the pipeline with isActive: false. Fields you leave out stay as they are.
PUT /api/pipelines/{id}/stepsReplace the chain with { "agentIds": [...] }, in order.
DELETE /api/pipelines/{id}Delete the pipeline. Its past runs are kept.
DELETE /api/pipelines/runs/{pipelineRunId}Delete one of your pipeline runs, with its jobs and run history.

Deleting a run is permanent

Deleting a pipeline run removes its jobs and run history, and it can't be undone.

On this page