Form Fields
Form fields mostly have the same data structure such as the basic name
type
label
and required
keys. But still differentiate in some ways.
This page documents all possible keys they can have, each input is also individually documented.
Data
Key | Type(s) | Optional | Description |
---|---|---|---|
name | string |
The form field name, this value must be used as the input's name key |
|
type | string |
Different types of form fields | |
label | string |
The label for the form field | |
required | boolean |
Indicates if the field is required for validation | |
on_value | string |
optional | Determines when a conditional field should be displayed |
options | array |
optional | Collection of options used by some field types. Only available when applicable |
conditional | array |
optional | Collection of conditional fields that must be shown if a field value matches the on_value value. Only available when conditional fields should be shown |
Example
{
"data": [
{
"title": "Persoonlijke gegevens",
"description": null,
"fields": [
{
"name": "CFIRSTNAME",
"type": "text",
"label": "Voornaam",
"required": true,
},
{
"name": "CCOUNTRY",
"type": "select",
"label": "Land",
"required": false,
"options": [
{
"name": "CCOUNTRY",
"value": "CNATIONALITY1",
"label": "Belgiƫ"
},
{
"name": "CCOUNTRY",
"value": "CNATIONALITY2",
"label": "Afghanistan"
},
...
],
"conditional": [
{
"name": "CGERMANKEEP",
"type": "checkbox",
"label": "Behoud mijn gegevens na afronden sollicitatie.",
"required": false,
"on_value": "CNATIONALITY81",
"options": [
{
"name": "CGERMANKEEP",
"value": "1",
"label": "Behoud mijn gegevens na afronden sollicitatie."
}
]
}
]
},
...
]
},
...
]
}