v1

latestOpenAPI 3.1.1Proprietary2026-07-2687313591.4 KB
Persons

Get metadata on Person Fields

Returns metadata on non-list-specific Person Fields.

Use the returned Field IDs to request field data from the GET /v2/persons and GET /v2/persons/{id} endpoints.

You can filter Fields using the filter query parameter. The filter parameter is a string that you can specify conditions based on the following properties.

Property NameTypeAllowed OperatorsExamples
nametext=, =~name="Location", name=~loc

Use the includes query parameter to add optional metadata to each Field in the response. Pass includes more than once to request multiple values.

ValueAdds to each Field
filterabilityHow the field can be used in filter expressions on GET /v2/persons and POST /v2/persons/search
sortabilityHow the field can be used in sort expressions on those endpoints

Example: GET /v2/persons/fields?includes=filterability&includes=sortability

get/v2/persons/fields

Query parameters

cursorstring

Cursor for the next or previous page

limitinteger
Example:100

Number of items to include in the page

filterstring

Filter options

includesstring[]

Additional properties to include in the response

Response

OK

Example response

{
  "data": [
    {
      "id": "affinity-data-location",
      "name": "Location",
      "type": "enriched",
      "enrichmentSource": "affinity-data",
      "valueType": "location",
      "createdAt": "2024-03-07T20:21:42Z",
      "filterability": {
        "operators": [
          {
            "id": "is-any-of",
            "name": "Is any of"
          }
        ]
      },
      "sortability": {
        "attributes": [
          {
            "id": "date-of-activity",
            "name": "Date of Activity",
            "valueType": "date"
          }
        ]
      }
    }
  ],
  "pagination": {
    "prevUrl": "https://api.affinity.co/v2/foo?cursor=ICAgICAgYmVmb3JlOjo6Nw",
    "nextUrl": "https://api.affinity.co/v2/foo?cursor=ICAgICAgIGFmdGVyOjo6NA"
  }
}