Skip to main content

Get Data Policy

Retrieve a data policy by ID with its fields and rules inlined. Returns the full policy configuration needed to understand transformation behavior.

Retrieve the complete details of a specific data policy, including its fields and rules inlined in the response. This provides a single-call view of the entire policy configuration, which is useful for auditing transformation logic or debugging resolution results.

The inlined fields define the output contract: which field keys the policy declares and their expected types. The inlined rules define the transformation logic: lookup tables, direct mappings, Lua scripts, and computed fields. Rules are executed in topological order based on their declared dependencies.

GET/v1/data-policies/{id}

Response

Response fields

idstringData policy UUID.
namestringPolicy name.
descriptionstring | nullPolicy description.
versionintegerCurrent version number.
fieldsarrayArray of declared output field objects.
rulesarrayArray of transformation rule objects.
created_atstringISO 8601 creation timestamp.
updated_atstringISO 8601 last update timestamp.

curl

Response

{
  "id": "p1a2b3c4-e5f6-7890-abcd-ef1234567890",
  "name": "Invoice Normalization",
  "description": "Standardize currency codes, country names, and date formats",
  "version": 3,
  "fields": [
    { "field_key": "country_code", "type": "string" },
    { "field_key": "currency", "type": "string" }
  ],
  "rules": [
    {
      "id": "r1a2b3c4-0001",
      "field_key": "country_code",
      "rule_type": "lookup",
      "config": { "table": "country_codes", "source_field": "country" }
    }
  ],
  "created_at": "2024-10-01T09:00:00.000Z",
  "updated_at": "2024-10-15T11:30:00.000Z"
}

Errors

Error responses

401unauthorizedMissing or invalid API key.
404not_foundData policy not found or does not belong to your organization.
429rate_limitedToo many requests. Retry after the period indicated in the Retry-After header.