Set up data manually
In this section, you create the required identity namespaces and define the Luma sample data structure by creating the schemas.
Step 1: Create identity namespaces
In this step, you create identity namespaces for the Luma custom identity fields named lumaLoyaltyId
, lumaCrmId
, and lumaProductSKU
. Identity namespaces play a critical role in building real-time customer profiles, as two matching values in the same namespace allow two data sources to form an identity graph.
Begin by creating a namespace for the Luma Loyalty ID schema:
-
In the Journey Optimizer user interface, go to Customer > Identities in the left navigation.
-
Select Create identity namespace.
-
Provide the following details:
table 0-row-3 1-row-3 Display Name Identity Symbol Type Luma Loyalty ID
lumaLoyaltyId
Cross-device ID -
Select Create.
-
Create two more namespaces following the same steps:
table 0-row-3 1-row-3 2-row-3 Display Name Identity Symbol Type Luma CRM ID
lumaCrmId
Cross-device ID Luma Product SKU
lumaProductSKU
Non-people identifier
Step 2: Create schemas
In this step, you define the structure of the sample data by creating six schemas:
Create Luma Loyalty Schema create-luma-loyalty-schema
This section describes how to create the Luma Loyalty schema and configure field groups.
Create the schema
-
Go to DATA MANAGEMENT > Schemas in the left navigation.
-
Select Create Schema on the top right.
-
From the drop-down menu, select XDM Individual Profile.
You select this option because you are modeling attributes of an individual customer (points, status, and so on).
Add existing field groups
Next, you are prompted to add field groups to the schema, using groups. You must add existing field groups and create a field group.
-
On the Schema page, if the Field groups modal did not automatically open, select Add.
-
On the Add Field groups page, enable the following field groups:
-
Demographic Details for basic customer data like name and birth date.
-
Personal Contact Details for basic contact details like email address and phone number.
-
Loyalty Details for the loyalty details such as points, joined date, or status. The loyalty field group is far down the list, so it is easiest to search for it.
-
-
Select Add field group to add all three field groups to the schema.
-
Select the top node of the schema.
-
Enter
Luma Loyalty Schema
as the Display name.
Create a field group create-field-group
To help ensure consistency across the schemas, ÃÛ¶¹ÊÓƵ recommends managing all system identifiers in a single group:
-
From the Composition section under Field groups, select Add.
-
Select Create new field group.
-
Add
Luma Identity Profile Field Group
as the Display name. -
Add
system identifiers for XDM Individual Profile class
as the Description. -
Select Add field groups.
Add fields to the new field group
The new, empty field group is added to your schema. Using the + buttons, you can add new fields to any location in the hierarchy. In this case, you must add fields at the root level:
-
Select + next to the name of the schema.
This step adds a field under your tenant id namespace, to manage conflicts between your custom fields and any standard fields.
-
In the Field properties sidebar, add the details of the new field:
-
Field name:
systemIdentifier
-
Display name:
System Identifier
-
Type: Object
-
Assign field group: Luma identifiers
-
-
Select Apply.
Add two fields under the
systemIdentifier
object:table 0-row-3 1-row-3 2-row-3 Fieldname Display Name Type loyaltyId
Loyalty Id
String crmId
CRM Id
String
Set identities
You now have the namespace and the Luma Loyalty schema configured. Before you can ingest data, you must label the identity fields. Each schema used with Real-time Customer Profile is required to have a primary identity specified and each record ingested must have a value for that field.
-
Set the primary Identity:
From the Luma Loyalty Schema:
-
Select the Luma Identity Profile Field Group.
-
Select the loyaltyId field.
-
In the Field properties, enable the Identity box.
-
Enable the Primary Identity box.
-
Select the
Luma Loyalty Id
namespace from Identity namespaces dropdown menu. -
Select Apply.
-
-
Set a secondary identity:
From the Luma Loyalty Schema:
-
Select the Luma Identity Profile Field Group.
-
Select the
crmId
field. -
In the Field properties, enable the Identity box.
-
Select the
Luma CRM Id
namespace from Identity namespaces dropdown. -
Select Apply.
-
Enable for profile and save the schema
-
Select the top node of the schema.
-
In the Field properties, enable Profile.
The schema should look like this:
-
Select Save.
Create Luma Product Catalog Schema create-luma-product-catalog-schema
-
Go to DATA MANAGEMENT > Schemas in the left navigation.
-
Select Create Schema (top right).
-
To create a class, select Browse all schema types from the drop-down menu.
-
Select Create new class.
-
Add the display name:
Luma Product Catalog Class
. -
Assign class.
-
Create a Field group:
- Display name:
Luma Product Catalog Field Group
- Display name:
-
Add the following field to the Luma Product Catalog Field Group.
-
Field name:
product
-
Display name:
Product
-
Type: Object
-
Field group: Luma Product Catalog Field Group
-
-
Select Apply.
-
Add the following fields to the Product object:
table 0-row-3 1-row-3 2-row-3 3-row-3 4-row-3 5-row-3 6-row-3 7-row-3 8-row-3 9-row-3 10-row-3 Fieldname Display Name Type sku
Product SKU
String name
Product Name
String category
Product Category
String color
Product Color
String size
Product Size
String price
Product Price
Double description
Product Description
String imageUrl
Product Image URL
String stockQuantity
Product Stock Quantity
String url
Product URL
String -
Set the SKU as primary identity.
-
Add the Display name
Luma Product Catalog Field Group
to the field group. -
Select Save.
Create Luma Product Inventory Event Schema create-luma-product-inventory-event-schema
-
Go to DATA MANAGEMENT > Schemas in the left navigation.
-
Select the Create Schema button on the top right.
-
From the dropdown menu, select Browse all schema types.
-
Select Create new class.
-
Add the display name:
Luma Business Event Class
. -
Select type: Time-series.
-
Assign class.
-
Create a field group:
- Display name:
Luma Product Inventory Event Details Field Group
- Display name:
-
Add the Display name
Luma Product Inventory Event Schema
to the schema. -
Add the following field to the Luma Product Inventory Event Details Field Group:
-
Field name:
inventoryEvent
-
Display name:
Inventory Event
-
Type: Object
-
Field group:
Luma Product Inventory Event Details Field Group
-
-
Add the following fields to the
Product Inventory Event Details
object:table 0-row-3 1-row-3 2-row-3 Fieldname Display Name Type sku
SKU
String stockEventType
Stock Event Type
String -
to set the
stockEventType
to Enum, select type:string
. -
Scroll down to the bottom of the Field properties.
-
Enable Enum.
-
Enter values (label):
restock
(Restock
). -
Select Add row.
-
Enter values (label):
outOfStock
(Out of Stock
). -
Select Apply.
-
-
Set
inventory.Event.sku
field as primary identity using the LumaProductSKU namespace. -
Select the
sku
field and define a relationship to theproduct.sku
field in the Luma Product catalog Schema Schema:-
Scroll down to the bottom of the Field properties.
-
Enable Relationship.
-
Reference schema: Luma Product Catalog Schema.
-
Reference identity namespace: LumaProductSKU.
-
-
Select Apply.
The schema should look like this:
-
-
Enable for Profile.
-
Select Save to save the schema.
Create additional schemas create-additional-schemas
Create the following additional schemas:
Luma Identity Profile Field Group
Demographic Details
Personal Contact Details
Orchestration eventID
Consumer Experience Event
AEP Web SDK ExperienceEvent
Luma Identity Profile Field Group
Demographic Details
Personal Contact Details
Profile test details
Luma Identity Profile Field Group
Commerce Details
productListItems.SKU
:Reference schema
Luma Product Catalog Schema
Reference identity namespace
lumaProductSKU
productListItems.SKU
:Reference schema
Luma Product Catalog Schema
Reference identity namespace
lumaProductSKU
systemIdentifier.crmId
systemIdentifier.crmId
systemIdentifier.LoyaltyId
Next steps
Now that you have created the data structure, you can create data sets and ingest sample data.