SUPPORT.TWILIO.COM END OF LIFE NOTICE: This site, support.twilio.com, is scheduled to go End of Life on February 27, 2024. All Twilio Support content has been migrated to help.twilio.com, where you can continue to find helpful Support articles, API docs, and Twilio blog content, and escalate your issues to our Support team. We encourage you to update your bookmarks and begin using the new site today for all your Twilio Support needs.

How to Remove or Nullify Custom Trait Keys from Segment Unify Profiles

Objective

This article explains how to remove or nullify legacy custom trait keys from user profiles in Segment Unify. If you have trait keys that remain visible in Profile Explorer after sending null values, this guide will help you use both the Identify API and Reverse ETL mapping to ensure those keys are properly nullified. By sending an Identify event with the custom trait value set to null, you can remove the trait from the user's profile in the UI. This does not delete the trait's schema from our database but removes the trait from the user's Unify profile.

 

Product

Twilio Segment

 

Environment

Segment Console

 

User Account Permission/Role(s) Required 

Workspace admin or a user with permissions to manage Reverse ETL mappings and send Identify calls.

 

Procedure 

To remove or nullify custom trait keys from Segment Unify profiles, follow these steps:

Option 1: Using a Script (Recommended for Large Scale)

  1. Query your data warehouse or use the Profile API to pull a list of the userId values for all users who have the stale traits.

  2. Write a script to programmatically fire Identify calls for those specific userIds.

  3. In the Identify call payload, pass null as the value for each trait you want to remove. For example:

JSON

{
  "userId": "12345",
  "traits": {
    "ab_test_group": null,
    "order_type": null
  }
}
  1. (Optional but recommended) If you are on a Business Tier plan, use Schema Controls to explicitly block these stale traits from being accidentally ingested again. Navigate to your Source, select the Schema tab, click on Identify, and toggle off the specific traits you no longer want to capture. Note that blocking a trait only stops future data from being collected; it does not delete the historical data.

  • Note: This does not delete the trait's schema from Segment's database, but it does remove the trait from the user's Unify profile.

Option 2: Set NULL in Reverse ETL Mapping

  1. In the Segment Console, navigate to your Reverse ETL mapping for the relevant source and destination.
  2. For each custom trait key you want to remove, set the static value to NULL. Ensure that the Sync null values toggle setting is enabled.
  3. Save the mapping.
  4. Send a test record to verify the mapping works as expected.
  5. Initiate a manual Sync to apply the changes to all affected profiles.

Option 3: Using the Profiles CSV Uploader

You can also use the Profiles CSV Uploader to update user traits in bulk.

  1. Navigate to Unify > Profile explorer or Engage > Audiences > Profile explorer.

  2. Click +Add Profiles.

  3. Click Download Template to download a CSV template with identifier columns from your identity resolution configuration.

  4. Fill out the CSV file with the identifiers (such as userId) of the affected users.

  5. Add columns for the custom traits you want to remove, and set the values to null to clear the data.

  6. Upload your CSV file to process the updates.

Note:
Currently, Segment does not support complete backend deletion of trait keys. Nullifying the trait is the only supported method, and the key may remain visible in Profile Explorer with a null value.

 

 

 

Have more questions? Submit a request
Powered by Zendesk