About file import
This article describes how to import CSV files as a data source, allowing you to enrich offline data and make it actionable within the Customer Data Hub.
- Tealium AudienceStream CDP OR
- Tealium EventStream API Hub
To be successfully imported, you must format your CSV files correctly. For information on file and data formats, see Prepare a CSV file for import.
How It Works
Use the Tealium server to connect to a file service (such as an Amazon S3 bucket), read the file, and import the data. Each imported row is processed as an event. After importing, the data can then be enriched, stitched to existing visitor profiles, and sent to other vendors.
There are two steps in setting up a file import as a data source:
Column mapping and file transfer service configuration
To set up a file import data source, map columns from your CSV file to event attributes in Tealium and select a file transfer service.
To assist with column mapping, upload a sample CSV file with your column labels and up to 1,000 rows of data.
Upload files to your file transfer service
After you set up your data source, upload your CSV files to your file service. File uploading is done outside of Tealium.
Step 1: CSV column mapping and file transfer service configuration
The column mapping configuration determines the event attributes that correspond to each column in the CSV file. The column names are often different from the attribute names in the Customer Data Hub, so this mapping ensures that the data is imported properly. For example, a CSV file might have a column named
postalCode, but the matching event attribute is named
customer_zip, so you need to map these columns to associate them.
Mappings can be configured based on an existing event specification or as a custom event.
Event specification mapping
Each row of the CSV file is processed as an event. When you select an event specification mapping, event attributes are pre-selected in the Column Mapping table. Each row is processed as an event of the selected specification, for example
tealium_event = "purchase".
If you select a custom event mapping, specify the event attribute that corresponds to each CSV column. Each row is processed as an event with the following event identifier:
tealium_event = "imported"
Visitor ID mapping
To ensure your imported data is stitched with other sources, such as web, mobile or HTTP API, ensure that every row in a file import source file has a column with a unique visitor ID. You can then map the visitor ID column and corresponding event attribute to a visitor ID attribute (a unique attribute type for visitor identification in AudienceStream). The value in the mapped event attribute is assigned to the
tealium_visitor_id attribute and matched directly to any existing visitor profiles.
For more information about Visitor ID Mapping in AudienceStream, see Visitor Identification using File Import Data Source.
File transfer service
The file transfer service is a secure location where you upload the files to be imported. Tealium supports the following file transfer services:
- Amazon S3 (Tealium bucket or your own bucket) - Tealium uses VPC endpoints to access Tealium S3 buckets directly through the AWS network. Use IAM credentials to allow Tealium access to your own bucket via our VPC Internet Gateway.
- Microsoft Azure File/Blob Storage
- FTP/SFTP - Supports the following authentication methods:
- Upload Private Key File
- Generate Key Pair
Step 2: Upload your files to a file transfer service
After you complete your file import data source configuration, upload files to the file service you have selected.
Tealium uses the following order of operations to import files:
- Check for new files
The system checks the file transfer service for new files every 10 minutes.
- Copy new files
When a new file is detected, it is copied from the file transfer location and processed in the Customer Data Hub.
- Match Filename Prefix to File Import data source
The prefix of the filename is used to identify which file import data source to use when importing the data in the file.
- Process files
The header line is read to identify the attributes being imported. After reading the header line, the following processing is performed:
Visitor lookup — The visitor ID is used to look up the visitor record in AudienceStream. If an existing visitor record is not found, a new one is created.
Grouping rows with the same visitor ID decreases the import time.
Attribute enrichment - The visitor record is enriched according to the attributes imported and the existing enrichments in your account.
Thank you for your feedback!
This page was last updated: March 6, 2023