API

Definitions

In any system, there are certain phrases and principles that need to be defined to make sure that everybody is talking about the same thing.
This is specially important for the data being sent and received: both sender and recipient have to agree on certain formats to make sure the data is handled at both ends.

In the structures and examples a number of prhases are used to describe the data like 'String', 'Integer number', etc.
All these types of data have their own specific format and are described in the table you find below.

Definitions for json structures

PhraseMeaningOur (regex) mask
StringAnything that could be typed on a keyboard, including: valid UTF-8 tekst, base64 encoded information, etc./.*/
Key (UUID format)A valid UUID format: 00000000-0000-0000-0000-000000000000 where any 0 can be a number or (capital) ASCII character/^[0-9A-Z]{8}-[0-9A-Z]{4}-[0-9A-Z]{4}-[0-9A-Z]{4}-[0-9A-Z]{12}$/
Integer numberA valid integer number. Any maximum or minimum is defined in the option. /^[\-0-9]+$/
Real numberA valid decimal number. The decimal point is a . not a comma. Any maximum or minimum is defined in the option./^[\-0-9\.]+$/
BooleanA JSON true or false/^true|false$/
DateA valid dateYYYY-MM-DD
DateTimeA valid date and timeYYYY-MM-DD HH:MM:SS
DateTime RFC3339This is a standard date and time notation taking timezones into account. All newly created and updated endpoints will move to this format (while ofcourse retaining the old fields for backward compatibility)YYYY-MM-DDTHH:MM:SS(Z|Txxx)
E-mailA valid email addressAny valid email address at least having the format name@domain.tld
urlvalid http urlAny valid URL
priceThe same as a 'Real number', but rounded off to 2 decimals./^[0-9]+\.[0-9]+$/
CountryA valid ISO3 country name, lists are available online (for example NLD)./^[A-Z]{3}$/
Timezonevalid timezone name (for example: Europe/Amsterdam)/^[a-zA-z]_\/[a-zA-Z]+$/
HEX stringA special kind of string, containting hexadecimal numbers/^[0-9A-F\_]+$/
SublistA JSON object that has named items.example: { 'item1' => 'value1', 'item2' => 'value2' }, the values might be an array or sublist.
Array of single valuesMust be able to be evaluated as a JSON array, and each array item must be a simple value (anything of the above, but not another array, object list or sublist).example: ["value1","value2","value3"...]
Array of objectsA valid JSON array with valid JSON objects.Must be able to be evaluated as a JSON array. Each item is a sublist as defined above.
ID list of objectsBasically the same as a Sublist, but the difference is that each entry is a 'key' or 'id' with an array or sublist object attached to it.example: {"1":{"name":"test","field":"value"},"2":{"name":"test2","field":"value"} ...}