Case Anomalies
Get detector anomalies for a case: field conflicts, divergent shared keys, suspicious value reuse, and missing document types, plus open findings and template.
The anomalies endpoint is the case risk surface. It runs the case's documents through the anomaly detectors and returns what looks wrong: field_conflict (the same key carries divergent values across documents), duplicate_key_divergence, value_reuse_suspicious, and missing_document_type (the matched workflow template expects a document type the case lacks). Each anomaly carries a type, severity, title, description, the document_ids involved, and targets — the (document, field, value) tuples so you can open the offending value directly.
Alongside the detector anomalies, the response includes the case's open findings — the dangling references (a document points at an identifier that resolves to no document in your workspace, signalling a likely missing document) — and the matched workflow template. Anomalies are computed on-read from the case's live field occurrences: no AI call is made and nothing is persisted, so the result always reflects the current documents.
/v1/cases/:key/anomaliesPath parameters
Response
Response fields
Response
{
"data": [
{
"type": "field_conflict",
"severity": "warning",
"title": "Conflicting values for iban",
"description": "Documents in this case carry divergent values for the shared key iban.",
"document_ids": ["doc_uuid_1", "doc_uuid_2"],
"targets": [
{ "document_id": "doc_uuid_1", "field": "iban", "value": "DE44 5001 0517 5407 3249 31" },
{ "document_id": "doc_uuid_2", "field": "iban", "value": "DE89 3704 0044 0532 0130 00" }
]
}
],
"findings": [],
"template": {
"name": "Procurement",
"required_types": ["Purchase Order", "Invoice"],
"optional_types": ["Delivery Note"]
}
}Two complementary signals also live on the case: anomaly_count on GET /v1/cases/:key (the number of open findings) and GET /v1/cases/:key/completeness (members ÷ members + open findings). Use those for a cheap health number, and this endpoint when you need the detailed anomaly list.
Errors
Error responses