{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/signicat/main/json-schema/signicat-paged-collection-1-schema.json",
  "title": "PagedCollection`1",
  "x-generated": "2026-10-18",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/signicat-ongoing-monitoring-person-openapi.yml#/components/schemas/PagedCollection`1",
  "type": "object",
  "properties": {
    "offset": {
      "type": "integer",
      "description": "The offset of the current page.",
      "format": "int32"
    },
    "limit": {
      "type": "integer",
      "description": "The limit of the current paging options.",
      "format": "int32"
    },
    "size": {
      "type": "integer",
      "description": "The total size of the collection (irrespective of any paging options).",
      "format": "int64"
    },
    "links": {
      "$ref": "#/$defs/Links"
    },
    "data": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/PersonChanges"
      }
    }
  },
  "additionalProperties": false,
  "$defs": {
    "Links": {
      "type": "object",
      "properties": {
        "next": {
          "type": [
            "string",
            "null"
          ],
          "description": "Url of the next page"
        },
        "previous": {
          "type": [
            "string",
            "null"
          ],
          "description": "Url of the previous page"
        },
        "first": {
          "type": [
            "string",
            "null"
          ],
          "description": "Url of the first page"
        }
      },
      "additionalProperties": false
    },
    "MonitorPersonChange": {
      "type": "object",
      "properties": {
        "firstName": {
          "type": [
            "string",
            "null"
          ],
          "description": "The person's new first name."
        },
        "lastName": {
          "type": [
            "string",
            "null"
          ],
          "description": "The person's new last name."
        },
        "middleName": {
          "type": [
            "string",
            "null"
          ],
          "description": "The person's new middle name, if available."
        },
        "dateOfBirth": {
          "type": [
            "string",
            "null"
          ],
          "description": "The person's new date of birth, if available.",
          "format": "yyyy-MM-dd"
        },
        "nationalIdentityNumber": {
          "type": [
            "string",
            "null"
          ],
          "description": "The person's new national identity number, if available."
        },
        "address": {
          "$ref": "#/$defs/PersonAddress"
        },
        "isAddressProtected": {
          "type": [
            "boolean",
            "null"
          ],
          "description": "Whether the person's address is protected"
        },
        "isProtected": {
          "type": [
            "boolean",
            "null"
          ],
          "description": "Whether the person's information is protected"
        },
        "screening": {
          "$ref": "#/$defs/PersonScreening"
        },
        "dateOfDeath": {
          "type": [
            "string",
            "null"
          ],
          "description": "The person's new date of death, if available.",
          "format": "yyyy-MM-dd"
        }
      },
      "additionalProperties": false,
      "description": "Relevant person changes. Only changed fields contain data."
    },
    "MonitorPersonStatus": {
      "enum": [
        "unknown",
        "ok",
        "invalid"
      ],
      "type": "string",
      "description": "Status of the person"
    },
    "PersonAddress": {
      "type": "object",
      "properties": {
        "address": {
          "maxLength": 400,
          "minLength": 1,
          "type": [
            "string",
            "null"
          ],
          "description": "Address line."
        },
        "zipCode": {
          "maxLength": 20,
          "minLength": 1,
          "type": [
            "string",
            "null"
          ],
          "description": "Zip code / Postal code."
        },
        "city": {
          "maxLength": 200,
          "minLength": 1,
          "type": [
            "string",
            "null"
          ],
          "description": "City."
        },
        "country": {
          "maxLength": 3,
          "minLength": 2,
          "type": [
            "string",
            "null"
          ],
          "description": "Country (ISO 3166-1 alpha-2)."
        }
      },
      "additionalProperties": false,
      "description": "The person's address"
    },
    "PersonChanges": {
      "type": "object",
      "properties": {
        "changeId": {
          "type": "integer",
          "description": "Sequential ID of the change.",
          "format": "int32"
        },
        "status": {
          "$ref": "#/$defs/MonitorPersonStatus"
        },
        "source": {
          "$ref": "#/$defs/Source"
        },
        "changeDetected": {
          "type": "string",
          "description": "Date and time when the change was detected.",
          "format": "date-time"
        },
        "referenceKey": {
          "maxLength": 100,
          "minLength": 1,
          "type": [
            "string",
            "null"
          ],
          "description": "Person's reference key."
        },
        "changes": {
          "$ref": "#/$defs/MonitorPersonChange"
        }
      },
      "additionalProperties": false,
      "description": ""
    },
    "PersonScreening": {
      "type": "object",
      "properties": {
        "riskLevel": {
          "maximum": 5,
          "minimum": 1,
          "type": [
            "integer",
            "null"
          ],
          "format": "int32"
        },
        "listType": {
          "maxLength": 200,
          "minLength": 1,
          "type": [
            "string",
            "null"
          ]
        },
        "source": {
          "maxLength": 200,
          "minLength": 1,
          "type": [
            "string",
            "null"
          ]
        }
      },
      "additionalProperties": false,
      "description": "Attribute providing information about the Screening status of the person"
    },
    "Source": {
      "enum": [
        "nationalRegistry",
        "trapets"
      ],
      "type": "string",
      "description": "What kind of sources to use for monitoring"
    }
  }
}