Skip to main content

Structuring your JSON Definition File

Description of information constituting the Definition File

To create a Custom Table of your Data Model, it will be necessary to define its structure through a JSON file.

This JSON file must contain a wide range of information. Some of these pieces of information are mandatory, others are optional. Moreover, they might have to follow specific criteria, either for their type or for possible values.

Parameters used to define the identity of your table (display and technical name, entity,...) can be specified directly, while parameters defining the behavior of your table will be structured as arrays.

The table below provides comprehensive explanations about the various parameters constituting your JSON file.

Illustration of a complete JSON file

The file below provides an illustration of the format taken by a file containing every possible parameter, alongside the expected values.

Visual illustration of a JSON definition file

{
"id"("string",
"optional)":" ",
"businessKey""(string)":" ",
"technicalName""(string)":" ",
"userName""(string",
"optional)":" ",
"prettyNameExpression""(string",
"optional)":" ",
"entityName""(string)":" ",
"capabilityDTOs""(Array"[
"Capability"
],
"optional)":[
{
"name""(string)":" 'LookupTable' , 'EventGeneratedTable', 'Interaction' ,
'ProfileData', 'MultipleTargetingAllowed' "
}
],
"defaultFetchingParameters""(Array"[
"FetchingParameters"
],
"optional)":[
{
"keyAttribute""(string",
"optional)":" ",
"ascending""(boolean",
"optional)":,
"sortingKey""(string",
"optional)":" ",
"maxNumberOfRecords""(long",
"optional)":
}
],
"emails""(Array"[
"string"
],
"optional)":"fields""(Array"[
"PropertyWithInfoDTO"
],
"optional)":[
{
"cacheIndexed""(boolean",
"optional)":,
"columnName""(string)":,
"type""(string)":"STRING",
"INTEGER",
"BOOLEAN",
"DATE",
"TIMESTAMP",
"NUMERIC",
"LONG""extended""(boolean",
"optional)":,
"fieldName""(string)":" ",
"indexed""(boolean",
"optional)":,
"objectType""(string)":"SIMPLE",
"required""(boolean",
"optional)":,
"unique""(boolean",
"optional)":,
"userName""(string",
"optional)":" ",
"possibleValues":"(Array"[
"String"
]")":"description""(string",
"optional)":" ",
"valueDisplayer""(ValueDisplayerDTO",
"optional)":,
{
"displayerType":"CivilState",
"PersonTitle",
"Gender",
"Country",
"Language"
},
"typeValidator""(AdvancedTypeValidator",
"optional)":{
"objectType":"EMAIL_ADDRESS",
"SEX",
"COUNTRY",
"LANGUAGE",
"PHONE_NUMBER",
"CIVIL_STATE",
"PERSON_TITLE",
"STRING_LENGTH""minCharacters""(long",
"optional)":,
"maxCharacters""(long",
"optional)"::
}
}
],
"layout""(Layout",
"optional)":{
"details""(Details",
"optional)":{
"sections""(Array"[
"Section"
],
"optional)":[
{
"fields""(Array"[
"string"
],
"optional)":" ",
"name""(string)":" "
}
]

Field types

Depending on their types, the fields must follow specific constraints:

  • STRING: string of characters [a-z, A-Z, 0-9]
    • the default max number of characters for a STRING type is 255. It can be modified with a "typeValidator" parameter (see table above)
  • INTEGER:
    • this type is depreciated but remains allowed in a table definition. It will be automatically transformed in type LONG
    • no space, dot or comma
    • maximum value: 2147483647
    • minimum value: -2147483647
  • LONG:
    • maximum value: 9223372036854775808
    • minimum value: -9223372036854775808
    • no space, dot or comma
  • BOOLEAN: match one of the following values “true” or “false”
  • DATE: string of characters matching one of the following formats:
    • YYYYMMDD
    • YYYY-MM-DD
    • dd/MM/yyyy
  • TIMESTAMP: string of characters matching one of the following formats:
    • YYYYMMDD *
    • YYYY-MM-DD *
    • dd/MM/yyyy *
    • YYYYMMDDhhmmss
    • YYYY-MM-DD hh:mm:ss
    • dd/MM/yyyy HH:mm:ss
    • MM/dd/yyyy hh:mm:ss AM|PM

If no values are specified for "hhmmss", the values "00:00:00" will be added

  • NUMERIC:
    • separator must be '.'
    • no character amount limit
Good to know

In addition to general types, there are advanced types for specific fields, in order to ensure their format to match the format expected by Actito.

These are the following types: "EMAIL_ADDRESS","SEX","COUNTRY","LANGUAGE","PHONE_NUMBER","CIVIL_STATE". The syntax required for theses types is detailed in the "Using Predefined Attributes" page.

To make sure that fields of your table match one of these types, you will have to specify it in the "objectType" parameter.