Skip to main content

Create Data Product from Pipeline

Produce a data product from a finished pipeline run and rebuild its review queue. The data product is where extracted rows are read and holdback is enforced.

POST /v1/pipelines/{id}/data-product produces a data product from a finished pipeline run. The data product is the read surface for the run's extracted rows: you read its rows, generate a share token, and export CSV through the data-products endpoints. It is also where per-cell review holdback lives. Fields a blocking gate parked for review surface with status only, with the value withheld, until a reviewer resolves them.

A pipeline is effectively one-to-one with its data product. Calling this endpoint again reactivates the existing product rather than minting a duplicate, and in either case it rebuilds the review queue from the run's stored validation verdicts. The run must have at least one completed (or partial) document; a run with nothing processed yet is rejected with 400. Preview runs cannot produce data products.

Timing matters: a run whose per-document counters have settled can still be finalizing — the pipeline-scoped tail (assembly, post-assembly resolution and validation) is still mutating the output the product would capture. Creating the product during that window is rejected with 400 telling you to wait; poll GET /v1/pipelines/{id}/progress until status is completed first, so the product captures the fully assembled, validated row. An active blocking Business Rule hold on the run likewise blocks creation until it is reviewed or overridden.

The response carries the created (or reactivated) data product and its auto-generated share token. Pass an optional name to label the product; it defaults to the run name plus a suffix. Once created, use the returned dataProduct.id with the data-products endpoints to read rows and the share token for the public delivery surface. This endpoint requires an API key with the write scope.

Creating a data product rebuilds the run's review queue from stored verdicts. The queue rebuild is best-effort: the product is already created even if the rebuild step encounters an error.
POST/v1/pipelines/{id}/data-product

Body parameters

namestringOptional data product name (max 200 characters). Defaults to the run name plus a suffix.

Request

curl -X POST https://api.talonic.com/v1/pipelines/a1b2c3d4-e5f6-7890-abcd-ef1234567890/data-product \
  -H "Authorization: Bearer $TALONIC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Lease Agreements September" }'

Response

Response fields

dataProductobjectThe created or reactivated data product.
dataProduct.idstringData product UUID. Use this with the data-products endpoints.
dataProduct.namestringData product name.
dataProduct.pipeline_idstringThe pipeline run this product was built from.
dataProduct.statusstringProduct status (active).
shareTokenobjectAuto-generated share token for the public delivery surface.
shareToken.tokenstringOpaque share token string.

Response

{
  "dataProduct": {
    "id": "dp_uuid_1",
    "name": "Lease Agreement — Data Product",
    "pipeline_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "status": "active"
  },
  "shareToken": {
    "data_product_id": "dp_uuid_1",
    "token": "shr_8f2c1a9b3d7e4f60"
  }
}

Errors

Error responses

400bad_requestThe run has no completed documents, it is a preview run (previews cannot produce data products), or it is still finalizing — wait for status completed.
401unauthorizedMissing or invalid API key.
404not_foundNo pipeline with this ID exists for your organization.
409BUSINESS_RULE_RUN_HOLD_ACTIVE / BUSINESS_RULE_RUN_GOVERNANCE_PENDINGAn active run-level Business Rule hold blocks delivery, or blocking run-level rules have not finished evaluating. The body lists the holds; review or override them, then retry.
429rate_limitedToo many requests. Retry after the period indicated in the Retry-After header.

Frequently asked questions

What happens if a data product already exists for this run?+
The existing product is reactivated rather than duplicated, since a pipeline is one-to-one with its data product. The review queue is rebuilt from stored verdicts in both cases.
Why can't I produce a data product from my run?+
Three common reasons: the run has no completed documents yet, it is a preview run (sample-anchored previews never reach delivered output), or it is still finalizing while the post-assembly tail runs. Poll GET /v1/pipelines/{id}/progress until status is completed, then retry.
How do I read the rows?+
Use the returned `dataProduct.id` with the data-products endpoints to read rows, and the share token for the public delivery surface. Fields held for review surface with status only until resolved. For poll-able JSON without creating a product at all, use GET /v1/pipelines/{id}/results instead.
Do I need a data product if I only want JSON rows?+
No. GET /v1/pipelines/{id}/results serves the same governed row read directly — no product, no share token. Create the data product when you need the CSV export, the public share surface, or delivery bindings on the product.