Skip to main content

Value Clusters

Group held review items by their current value: distinct values with counts and member items, the data behind identical-value cluster bulk approval.

The value-clusters endpoint groups held review items by their current value. When a single field is held across many documents with the same value, those items form one cluster you can review once and approve together. This is the data behind a "approve all 40 documents where vendor_name is Meridian Energy AG" action: one human decision instead of forty.

Filter to the set you want to cluster, typically a single field_key, optionally scoped by pipeline_id, schema_id, document_id, stage_id, trigger, reason, assignee, or age. Each returned cluster carries the distinct value, a count, and its member items (the document + field-key pairs), which you can hand straight to POST /v1/field-reviews/bulk-resolve.

Pair value clusters with bulk-resolve: cluster a field's held values, then bulk-approve the clusters you trust and inspect only the outliers.
GET/v1/field-reviews/value-clusters

Query parameters

field_keystringCluster a single field (the common case).
pipeline_idstringScope to one pipeline.
schema_idstringScope to one schema.
document_idstringScope to one pipeline document.
stage_idstringScope to one validation stage.
triggerstringgate | declarative.
reasonstringRestrict to one reason bucket.
assigneestringme | unassigned.
older_than_hoursintegerOnly items requested before this many hours ago.
include_heldbooleanInclude hold-routed items (default false).

curl

Response

Response fields

totalintegerTotal held items in the filtered scope.
clusters[].valuestring | nullThe distinct current value shared by the cluster; null groups empty values.
clusters[].countintegerNumber of held items with this value.
clusters[].itemsobject[]Member items ({ pipelineDocumentId, fieldKey }) for bulk-resolve, capped at 1,000 per cluster.

Response

{
  "total": 4,
  "clusters": [
    {
      "value": "EUR",
      "count": 3,
      "items": [
        { "pipelineDocumentId": "pd_uuid_1", "fieldKey": "currency" },
        { "pipelineDocumentId": "pd_uuid_2", "fieldKey": "currency" },
        { "pipelineDocumentId": "pd_uuid_3", "fieldKey": "currency" }
      ]
    },
    {
      "value": "EUR ",
      "count": 1,
      "items": [
        { "pipelineDocumentId": "pd_uuid_4", "fieldKey": "currency" }
      ]
    }
  ]
}