Manage data mappings

This article explains how to manage data mappings.

Add a variable mapping

Vendor tag parameters (also called destinations) are built into the Data Mappings configuration screen for the tag. This is where you add and manage data mappings.

To create a variable mapping:

  1. Expand a tag to view the details for that tag.
  2. Under Mapped Variables, click Edit.
  3. Select a data layer variable from the Variables drop-down or click + Add Variable to use a new one.
    Add Variable or Use Custom Value
  4. Click + Select Destination.
    The mapping dialog displays the supported vendor parameters.
  5. Browse the categories of vendor parameters in the left panel and check the box next to the desired destination.
  6. Click Done.

The new data mapping appears.

Map Additonal Variables

Repeat Steps 2 through 6 to map additional variables.

When done, click Apply.

Add an event mapping

Use an event mapping to associate your event names with the vendor’s event names and corresponding tracking. First, select your event variable (typically tealium_event), then enter the event name from your data layer, then select the corresponding vendor event to trigger.

Event Triggers

Use the following steps to map an event:

  1. Expand a tag to view the details for that tag.
  2. Under Mapped Variables, click Edit.
  3. Select the event variable to map.
  4. Click + Select Destination.
  5. Under Category, find the Events section.
  6. ln the Trigger field, enter the event name from your data layer.
  7. In the Event drop-down, select the vendor’s event to trigger.
  8. Click + Add. Repeat these steps to map multiple events.
  9. Click Apply.

Event mappings appear in the data mappings list in the format of EVENT_NAME:VENDOR_EVENT. For example, if you mapped the cart_add event to the vendor’s event addToCart, the mapping appears as cart_add:addToCart.

Mapped Event Triggers

Add a custom value mapping

To create a data mapping that uses a custom (static) value instead of a data layer variable:

  1. Expand a tag to view the details for that tag.
  2. Under Mapped Variables, click Edit.
  3. Expand the Variables drop-down list or click Use Custom Value.
    Add Variable Using Custom Value
  4. Click Select Destination.
    The mapping dialog displays the supported vendor parameters.
  5. Select the type of value to set and enter a value.
    • Text: a simple text value.
    • JS Code: a native JavaScript value, such as a number, boolean, array, object, or an inline function.
      Add Custom Destination Text or JSCode
  6. Click Close.

The mapped variable appears. Repeat these steps to map additional custom values.

When done, click Apply.

Add a custom data mapping

While the built-in destinations cover most of your mapping needs, you can optionally define a custom data mapping to send data to a vendor parameter that you name.

Use the following steps to create a custom data mapping:

  1. Expand a tag to view the details for that tag.
  2. Under Mapped Variables, click Edit.
  3. Select a data layer variable from the Variables drop-down or click + Add Variable to use a new one.
  4. Click + Add Custom Destination in the top panel or in the lower left panel.
  5. Enter a name for the custom variable.
  6. Click OK in the top panel or + Add if you used the bottom panel option.
    Two Options to Add Custom Destination

Repeat the steps to add more custom mappings. When complete, click Done. The custom mapping appears in the Data Mappings tab.

Mapping an AudienceStream attribute

AudienceStream attributes are enriched attributes about your visitors that are sent back to your website for use with personalization.

The following requirements must be in place to map an AudienceStream attribute:

  • Data Layer Enrichment
    Your profile must be populated by attributes from the matching AudienceStream profile. Those attributes are made available as data mappings in the variables drop-down menu. They are organized by attribute types and are labeled as AudienceStream variables.
    Learn more about data layer enrichment.

  • AudienceStream Capable Tags
    Tags marked as AudienceStream Capable in the tag marketplace can map attributes from AudienceStream to the tag’s destinations. Look for this label in the tips panel when adding a tag. You can optionally filter your tag search results by clicking AudienceStream Capable in the left panel.

    Filter AudienceStream Capable Tags

Edit a mapping

Use the following steps to edit a destination for a mapped variable:

  1. Expand a tag to view the details for that tag.
  2. Under Mapped Variables, click Edit.
  3. Click Edit next to the mapping you want to modify.
    The mapping dialog displays.
    Edit Mapping Configuration
  4. Edit any of the following:
    • Change the destination name
    • Map to another destination
    • Remove the destination
  5. Click Done.
  6. Repeat to edit more mappings.
  7. When complete, click Apply.

Edit a custom data mapping

Use the following steps to edit the destination variable:

  1. Expand a tag to view the details for that tag.
  2. Under Mapped Variables, click Edit.
  3. Click the destination variable name in the top panel.
    Edit Variable Name Step 1
    The name becomes a text field.
  4. Enter the new name.
    Change Variable Name Step 2
  5. Click OK to apply the changes.
  6. When complete, click Done.

Reorder mappings

You can drag and drop data mappings in your preferred order. This is helpful if you want to order your mappings alphabetically for better organization.

Order of mapping is important when two or more data layer variables are mapped to the same vendor destination. In this case, the last mapping takes precedence.

Delete a mapping

Use the following steps to delete a mapping:

  1. Expand a tag to view the details for that tag.
  2. Under Mapped Variables, click Edit.
  3. Click the trash icon next to the mapping you want to remove.
    Drop Active Mapping Trash
  4. Click Apply to confirm.

No warning or confirmation message appears. The deleted mapping cannot be restored.


 

Was this page helpful?

This page was last updated: January 7, 2023