Update Data Policy
Update the name or description of a data policy via PATCH: partial semantics, empty string clears, and metadata changes never touch captured run snapshots.
Update the metadata of an existing data policy: its name, its description, or both. This endpoint changes policy-level metadata only; the transformation logic lives on the policy's versions and is authored separately. Resolution runs that already captured a policy snapshot are never affected by metadata changes.
This is a PATCH endpoint: include only the properties you want to change and omitted properties keep their current values. Sending an empty body is a no-op that returns the current policy with its fields and rules inlined. To clear a description, send an empty string — the API distinguishes an omitted property (keep the current value) from an empty one (overwrite), and null is rejected by validation. The same limits as creation apply: name 1-255 characters, description up to 2,000.
status is not writable here: it advances through the policy lifecycle as versions are authored and finalized, and metadata updates never touch it. Nor can this endpoint modify fields or rules — a policy's transformation logic is versioned and edited through the policy editor, which forks a new draft version rather than mutating history. This separation keeps PATCH safe to call from automation: nothing a metadata update does can change what a pipeline executes.
/v1/data-policies/{id}Path parameters
Body parameters
Request body
{
"name": "Invoice Normalization v2",
"description": "Updated: added VAT normalization rules"
}Response
Response fields
curl
curl -s -X PATCH https://api.talonic.com/v1/data-policies/p1a2b3c4-e5f6-7890-abcd-ef1234567890 \
-H "Authorization: Bearer tlnc_your_api_key" \
-H "Content-Type: application/json" \
-d '{"name":"Invoice Normalization v2"}'Response
{
"id": "p1a2b3c4-e5f6-7890-abcd-ef1234567890",
"name": "Invoice Normalization v2",
"description": "Updated: added VAT normalization rules",
"status": "published",
"created_at": "2024-10-01T09:00:00.000Z",
"updated_at": "2024-10-20T08:15: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
Note the response-shape difference between the two paths: an update that changes at least one property returns the policy header (with links), while an empty body falls through to the full GET read and returns the header with fields and rules inlined. If your client parses the response, branch on the presence of fields — or simply follow links.self after updating when you need the complete view.