Open the Schemas workspace
The Schemas workspace in the Platform UI provides a visualization of the Schema Library, allowing you to view manage the schemas available for your organization. The workspace also includes the Schema Editor, the canvas on which you can compose a schema throughout this tutorial.
After logging into Experience Platform, select Schemas in the left navigation to open the Schemas workspace. The Browse tab displays a list of schemas (a representation of the Schema Library) for you to view and customize. The list includes the name, type, class, and behavior (record or time-series) on which the schema is based, as well as the date and time the schema was last modified.
See the guide on exploring existing XDM resources in the UI for more information.
Create and name a schema
To begin composing a schema, select Create schema in the top-right corner of the Schemas workspace.
The Create a schema dialog appears. In this dialog, you can choose to either manually create a schema by adding fields and field groups, or you can upload a CSV file and use ML algorithms to generate a schema. Select a schema creation workflow from the dialog.
Beta Manual or ML-assisted schema creation
To learn how you can use a ML algorithm to recommend a schema structure based on an uploaded file, see the machine learning-assisted schema creation guide. This UI guide focusses on the manual creation workflow.
Choose a base class
The Create schema workflow appears. Next, choose a base class for the schema. You can choose between the core classes of XDM Individual Profile and XDM ExperienceEvent, or Other if these classes do not suit your purposes. The Other classes option allows you to either create a new class or choose from other pre-existing classes.
See the XDM individual profile and XDM ExperienceEvent documentation for more information on these classes. For the purposes of this tutorial, select XDM Individual Profile followed by Next.
Name and review
After you have selected a class, the Name and review section appears. In this section, you provide a name and description to identify your schema. There are several important considerations to make when deciding on a name for your schema:
- Schema names should be short and descriptive so that the schema can be easily found later.
- Schema names must be unique, meaning it should also be specific enough that it will not be reused in the future. For example, if your organization had separate loyalty programs for different brands, it would be wise to name your schema “Brand A Loyalty Members” to make it easy to distinguish from other loyalty-related schemas you might define later.
- You can also use the schema description to provide any additional contextual information regarding the schema.
This tutorial composes a schema to ingest data related to the members of a loyalty program, and therefore the schema is named “Loyalty Members”.
The schema’s base structure (provided by the class) is shown in the canvas for you to review and verify your selected class and schema structure.
Enter a human-friendly Schema display name in the text field. Next, enter a suitable description to help identify your schema. When you have reviewed your schema structure and are happy with your settings, select Finish to create your schema.
Compose your schema
The Schema Editor appears. This is the canvas upon which you will compose your schema. The self-titled schema is automatically created in the Structure section of the canvas when you arrive in the editor, along with the standard fields included in the base class that you selected. The assigned class for the schema is also listed under Class in Composition section.
Add a field group
You can now begin to add fields to your schema by adding field groups. A field group is a group of one or more fields that are often used together to describe a particular concept. This tutorial uses field groups to describe the members of the loyalty program and capture key information such as name, birthday, phone number, address, and more.
To add a field group, select Add in the Field groups sub-section.
A new dialog appears, displaying a list of available field groups. Each field group is only intended for use with a specific class, therefore the dialog only lists field groups that are compatible with the class you selected (in this case, the XDM Individual Profile class). If you are using a standard XDM class, the list of field groups will be intelligently sorted based on usage popularity.
You can select one of the filters in the left rail to narrow down the list of standard field groups to specific industries like retail, financial services, and healthcare.
Selecting a field group from the list causes it to appear in the right rail. You can select multiple field groups if desired, adding each one to the list in the right rail before confirming. In addition, an icon appears on the right side of the currently selected field group which allows you to preview the structure of the fields it provides.
When previewing a field group, a detailed description of the field group’s schema is provided in the right rail. You can also navigate through the field group’s fields in the provided canvas. As you select different fields, the right rail updates to show details about the field in question. Select Back when you are finished previewing to return to the field group selection dialog.
For this tutorial, select the Demographic Details field group, then select Add field group.
The schema canvas reappears. The Field groups section now lists “Demographic Details” and the Structure section includes the fields contributed by the field group. You can select the field group’s name under the Field groups section to highlight the specific fields it provides within the canvas.


This field group contributes several fields under the top-level name person
with the data type “Person”. This group of fields describes information about an individual, including name, birth date, and gender.
Notice that the name
field has a data type of “Full name”, meaning it too describes a common concept and contains name-related sub-fields such as first name, last name, courtesy title, and suffix.
Select the different fields within the canvas to reveal any additional fields they contribute to the schema structure.
Add more field groups
You can now repeat the same steps to add another field group. When you view the Add field group dialog this time, notice that the “Demographic Details” field group has been greyed out and the checkbox next to it cannot be selected. This prevents you from accidentally duplicating field groups that you have already included in the current schema.
For this tutorial, select the standard field groups Personal Contact Details and Loyalty Details from the list, then select Add field groups to add them to the schema.
The canvas reappears with the added field groups listed under Field groups in the Composition section, and their composite fields added to the schema structure.
Define a custom field group
The Loyalty Members schema is meant to capture data related to the members of a loyalty program, and the standard Loyalty Details field group that you added to the schema provides most of these, including the program type, points, join date, and more.
However, there may be a scenario where you want to include additional custom fields not covered by standard field groups in order to achieve your use cases. In the case of adding custom loyalty fields, you have two options:
- Create a new custom field group to capture these fields. This is the method that will be covered in this tutorial.
- Extend the standard Loyalty Details field group with custom fields. This causes Loyalty Details to be converted to a custom field group, and the original standard field group will no longer be available. See the Schemas UI guide for more information on adding custom fields to the structure of standard field groups.
To create a new field group, select Add in the Field groups sub-section like before, but this time select Create New Field group near the top of the dialog that appears. You are then asked to provide a display name and description for the new field group. For this tutorial, name the new field group “Custom Loyalty Details”, then select Add field groups.
“Custom Loyalty Details” should now appear under Field groups on the left side of the canvas, but there are no fields associated with it yet and therefore no new fields appear under Structure.
Add fields to the field group
Now that you have created the “Custom Loyalty Details” field group, it is time to define the fields that the field group will contribute to the schema.
To begin, select the plus (+) icon next to the name of the schema in the canvas.
An “Untitled Field” placeholder appears in the canvas, and the right rail updates to reveal configuration options for the field.
In this scenario, the schema needs to have an object-type field that describes the person’s current loyalty tier in detail. Using the controls in the right rail, start creating a loyaltyTier
field with type “Object” that will be used to hold your related fields.
Under Assign to, you must select a field group to assign the field to. Remember that all schema fields belong to either a class or a field group, and since this schema uses a standard class, your only option is to select a field group. Start typing in the name “Custom Loyalty Details”, then select the field group from the list.
When finished, select Apply.
The changes are applied and the newly created loyaltyTier
object appears. Since this is a custom field, it is automatically nested within an object namespaced to your organization’s tenant ID, preceded by an underscore (_tenantId
in this example).
Select the plus (+) icon next to the loyaltyTier
object to start adding sub-fields. A new field placeholder appears and the Field properties section is visible on the right side of the canvas.
Each field requires the following information:
- Field Name: The name of the field, preferably written in camelCase. No space characters are allowed. This is the name used to reference the field in code and in other downstream applications.
- Example: loyaltyLevel
- Display Name: The name of the field, written in title case. This is the name that will be displayed in the canvas when viewing or editing the schema.
- Example: Loyalty Level
- Type: The data type of the field. This includes basic scalar types and any data types defined in the Schema Registry. Examples: String, Integer, Boolean, Person, Address, Phone number, etc.
- Description: An optional description of the field should be included with a maximum of 200 characters.
The first field for the loyaltyTier
object will be a string called id
, representing the ID of the loyalty member’s current tier. The tier ID will be unique for each loyalty member, since this company sets different loyalty tier point thresholds for each customer based on different factors. Set the new field’s type to “String”, and the Field properties section becomes populated with several options for applying constraints, including default value, format, and maximum length. See the documentation on best practices for data validation fields to learn more.
Since id
will be a randomly generated freeform string, no further constraints are necessary. Select Apply to apply your changes.