Instead of a data type, the format of an AFD attribute can also be based on a codelist. With a codelist, the number of permitted values of an attribute can be limited further than in the case, a generic data type is used. For example, the attribute tripPurpose
is of the ADNDRS
type (“Purpose of the trip”). The possible values of tripPurpose
are therefore limited to six values, namely the six codes of the codelist. Each code has a corresponding description, which can be found in AFD 2.0 Online.
In AFD 2.0 Online you can find a complete and up-to-date overview of all codelists. More documentation on the use of SIVI AFS is available in chapter Where to find elements of SIVI AFS.
Example codelist
List | Code | Description |
---|---|---|
ADNDRS | Purpose of the trip | |
1 | Commercieel | |
2 | Stage / studie | |
3 | Vakantie / rondreis | |
4 | Administratief / toezichthouder | |
5 | Au pair | |
99 | Anders |
Example usage
"tripPurpose": "2"
External codelists
AFD attributes may also refer to an external codelist, not maintained by SIVI. In such cases, the name of the codelist does not start with the prefix ‘ADN-‘ nor ‘AFD-‘, but with the (3 letter abbreviation) of the issuing party. An example is the ISOLAN codelist (“ISO country table”) issued by the International Organization for Standardization (ISO).
Adding codelists and/or code values to the data catalog
Insurers and intermediaries affiliated with SIVI, and suppliers cooperating with SIVI (suppliers authorized to use AFD), can submit a formal request to SIVI for adding a codelist to AFD, or adding (one or more) code values to an existing codelist. Requests can be made with the form ‘Aanvraag uitbreiding AFD 2.0’.
Defining codelist subsets with Schemas
For these restrictions, AFD-definitions can be used within the context of SIVI AFS (see also the chapter on the AFD-definition Standard). The following is an example of such a restriction in JSON Schema, and a matching sample message that validates against this Schema. The example shows the Schema of an AFD-definition which restricts the allowed values of the ‘businessLine’-attribute to five possibilities (instead of the entire ADNBRA codelist).
Example JSON Schema:
…{
"policy": {
"type": "object",
"additionalProperties": false,
"properties": {
"entityType": {
"description": "Unique identification of an entity. (NL: De unieke identificatie van een entiteit.)",
"type": "string",
"const": "policyDetails"
},
"businessLine": {
"description": "Business line (NL: ADN branchecode)",
"codelistName": "ADNBRA",
"type": "string",
"oneOf": [
{
"const": "010"
},
{
"const": "011"
},
{
"const": "012"
},
{
"const": "013"
},
{
"const": "014"
}
]
},
"required": [
"entityType",
"businessLine"
]
}…
Example JSON message that complies with the Schema above:
{
"policy": [ {
"entityType": "policyDetails",
"businessLine": "010"
} ]
}
Post your comment on this topic.