Custom Tables
Before being able to segment users or incorporate them into journeys, it’s essential to define our tables first. Each table definition is fully customizable, with the exception of the User table. Every client is required to have a table named user
, which is predetermined as the default main table in the definition process.
User Table
The ‘user’ table contains some mandatory fields, crucial for the system’s capability to dispatch emails, SMS messages, and push notifications.
Required Properties
{
id: string | number;
marketingPreferences: object;
systemPreferences: object;
}
Both Marketing Preferences and System Preferences are mandatory objects, each encompassing the following attributes:
marketingPreferences: {
email: boolean,
phone: boolean
}
systemPreferences: {
email: boolean,
phone: boolean
}
You’re at liberty to augment and personalize all additional properties of the user table as per your prerequisites.
Note that all dates are formatted to be unix timestamp.
Other Tables
The creation and customization of all other tables are under your discretion. However, it’s imperative for every table to incorporate an id field, serving as the identifier of the entity within your system.
Creating Table Definitions
- Navigate to Database > Table Definitions on the Back Office platform.
- The Table Definitions screen allows the addition and modification of new definitions within the Table Definition Canvas.
- Initiate the table creation process by selecting a pre-existing table on the canvas, followed by clicking the ‘Add Table’ button.
- Post creation, you can incorporate new attributes, associate the table with a parent table, and determine which attributes will serve as the foreign key of the parent table.
Editing Table Definitions
To amend an existing table:
- Select it on the canvas; this action renders its attributes editable.
- Alter the parent table by effortlessly dragging the parent’s end of a node to another intended parent.
Note: Refrain from modifying table definitions post the synchronization of databases; doing so necessitates redoing the entire database sync from scratch.