Create Data Policy
Create a data policy: a named container for field transformation rules, lookup cascades, and normalization logic applied during resolution. Write scope.
Create a new data policy: a named, versioned container for the transformation rules and output fields that normalize your extracted values. The policy starts empty with status draft. After creation, define its output contract and transformation logic; the policy only does useful work once it has at least one field and one rule.
Choose a name descriptive enough to distinguish the policy from others in the workspace, and use the optional description to document what the policy targets: the document types it applies to and the normalization strategies it employs. Both help later when a pipeline builder picks policies for a Resolve stage.
/v1/data-policiesBody parameters
Request body
{
"name": "Invoice Normalization",
"description": "Standardize currency codes, country names, and date formats"
}Response
Response fields (201 Created)
curl
Response (201 Created)
{
"id": "p1a2b3c4-e5f6-7890-abcd-ef1234567890",
"name": "Invoice Normalization",
"description": "Standardize currency codes, country names, and date formats",
"status": "draft",
"created_at": "2024-10-01T09:00:00.000Z",
"updated_at": "2024-10-01T09:00:00.000Z",
"links": {
"self": "/v1/data-policies/p1a2b3c4-e5f6-7890-abcd-ef1234567890",
"versions": "/v1/data-policies/p1a2b3c4-e5f6-7890-abcd-ef1234567890/versions",
"fields": "/v1/data-policies/p1a2b3c4-e5f6-7890-abcd-ef1234567890/fields",
"rules": "/v1/data-policies/p1a2b3c4-e5f6-7890-abcd-ef1234567890/rules"
}
}Errors
Error responses