Define required fields in the UI

In Experience Data Model (XDM), a required field indicates that it must be supplied a valid value in order for a particular record or time-series event to be accepted during data ingestion. Common use cases for required fields include user identity information and timestamps.

IMPORTANT
Regardless of whether a schema field is required or not, Platform does not accept null or empty values for any ingested field. If there is no value for particular field in a record or event, the key for that field should be excluded from the ingestion payload.

When defining a new field in the Adobe Experience Platform user interface, you can set it as a required field by selecting the Required checkbox in the right rail. Select Apply to apply the change to the schema.

Required checkbox

If the field is a root-level attribute under the tenant ID object, its path immediately appears under Required fields in the left rail.

Root-level required field

If a required field is nested within an object that is not marked as required itself, however, then the nested field does not appear under Required fields in the left rail.

In the example below, the internalSKU field is set as required, but its parent object SKUs is not. In this case, no validation errors would occur if SKUs is excluded when ingesting data, even though the child field internalSKU is marked as required. In other words, while SKUs is optional it must contain a internalSKU field in the event that it is included.

Nested required field

If you want a nested field to always be required in a schema, you must also set all parent fields as required (with the exception of the tenant ID object).

Parent and child required fields

Next steps

This guide covered how to define a required field in the UI. See the overview on defining fields in the UI to learn how to define other XDM field types in the Schema Editor.

recommendation-more-help
62e9ffd9-1c74-4cef-8f47-0d00af32fc07