The data model
Customer context starts with a model of the business. To select customers who bought twice this month, maxclicks needs customer records, purchase records and the fields that connect them. Define that model and supply the data once, then reuse it across audiences, email and journeys.
Three words carry the whole thing:
- A schema is a kind of record: Customer, Product, PurchaseCompleted.
- An attribute is a field on that schema: email, price, order total.
- A record is one entry: one customer, one product, one purchase.
A schema is a form, an attribute is a question on the form, and a record is one filled-out copy.
Decide what kind of thing you are describing
Every schema is one of three types, and the type is fixed once you create it.
| Type | Use it for | Examples |
|---|---|---|
| Contact | People you can email | Customer, Subscriber, Student |
| Object | Things you track but never email | Product, Order, Company |
| Event | Something that happened at a point in time | PurchaseCompleted, CartAbandoned |
Contacts and objects are records you create, update, and keep. Events are different: they arrive from your systems, you never edit them, and each one can start a workflow.
Start with one contact schema. Add objects for the state your messages need and business events for occurrences your journeys use. The Events area also supports typed collected events from browser or server sources, including observations that build customer measures without triggering an email for every occurrence.
Where you set this up
- Contact and object schemas live in Settings, under Schemas.
- Event schemas live in Settings, under Events.
- The records themselves get their own page under Records in the top navigation, one entry per contact or object schema.
From a record page, the icons beside the title jump straight to Schema settings and Manage attributes for that schema.
Fields you fill in, and fields maxclicks works out
There are three useful ways to supply a field:
| Value source | Renewal-campaign example | When it changes |
|---|---|---|
| Stored | Subscription renewal date supplied by your billing system | A record write; a missing-value policy can fill a new record |
| Evaluated | The subscription matching this customer's subscription ID | When a consumer requests the relationship |
| Computed | Customer activity count in the last 30 days | A scheduled background calculation publishes a result |
Evaluated and computed fields both require expansion for email data, but they have different freshness. A computed count with no qualifying history is empty, not zero. A delayed calculation can retain an old published value. A live relationship can only see records already supplied to maxclicks.
Do not add every possible field before your first campaign. Write down the actual message and audience rule, then identify the facts, joins and missing-value behavior needed to support them.
Get the shape right before you load data
maxclicks validates supported record fields against their schema. Unknown custom fields can be omitted, and the standard CSV importer converts some cell types before validation. Declare the fields first, then test a small set of records and inspect the values that actually arrived. A successful write proves acceptance of that input, not that the source mapped every intended field correctly.
Two decisions are permanent. An attribute's key and its type cannot be changed after you create it, and a schema's type cannot be changed at all. There is no migration tool that rewrites existing records, so it is worth five minutes of thought before you create a field you will fill a million times.
One more rule to know early: once you create your first contact schema, your space always keeps at least one. You cannot delete the last one.
The rest of this lesson
Five short pages, in the order you will need them:
- Understanding schemas: create one, and see the fields you get for free.
- Understanding attributes: add your own fields and pick their types.
- Understanding records: get records in without creating duplicates.
- Understanding events: the records you fire instead of edit.
- Connecting records: link contacts to everything else.
Next
Start with the foundation: how to create a schema and the fields it comes with.
Understanding schemas