Skip to main content

List Data Policy Fields

List the declared output fields of a data policy: the field keys and types the policy emits in resolution results. Undeclared values are discarded.

List the declared output fields of a data policy. Fields define the output contract: the set of field keys the policy executor emits in resolution results. Only declared fields appear in the final output; any intermediate values computed by rules but not declared as fields are treated as temporary variables and discarded.

Each field carries its field_key (the output column name), a field_type, and a source describing where the field came from. The declared field list is what the resolution pipeline validates output against and what the results UI uses to decide which columns to display.

GET/v1/data-policies/{id}/fields

Path parameters

id*uuidData policy UUID.

Response

Response fields

dataarrayArray of field definition objects.
data[].idstringField row UUID.
data[].field_keystringOutput field key name.
data[].field_typestringDeclared value type (e.g. string, number, date).
data[].sourcestring | nullWhere the field originates.
data[].created_atstringISO 8601 creation timestamp.
links.selfstringURL to this field list.
links.policystringURL to the parent policy.

curl

Response

{
  "data": [
    {
      "id": "f1a2b3c4-0001",
      "field_key": "country_code",
      "field_type": "string",
      "source": "policy",
      "created_at": "2024-10-01T09:05:00.000Z"
    },
    {
      "id": "f1a2b3c4-0002",
      "field_key": "currency",
      "field_type": "string",
      "source": "policy",
      "created_at": "2024-10-01T09:06:00.000Z"
    }
  ],
  "links": {
    "self": "/v1/data-policies/p1a2b3c4-e5f6-7890-abcd-ef1234567890/fields",
    "policy": "/v1/data-policies/p1a2b3c4-e5f6-7890-abcd-ef1234567890"
  }
}

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.
The declared field list is the policy's output contract. Values written by rules to undeclared keys are treated as temp variables and suppressed from results; flip pipeline.resolution.emit_undeclared_cells only for debugging.