Overview
Import event feature allows you to import events from a CSV file into your MoEngage account. This feature supports several uses, such as:
- Historical Data Import- As a marketer, you can import historical event data into MoEngage to analyze your customers' past behaviour and trends.
- Event Data Migration- During a platform migration, you can import events through CSV to ensure a smooth transition of historical event data, ensuring continuity in analysis and campaign management.
- Batch Upload- Importing events through CSV allows users to upload a large volume of events in a single batch, saving time and effort. This is useful when updating or populating a large number of events in the MoEngage platform.
Import Event Using CSV
Perform the following steps to import event data using a CSV file:
- Log in to the MoEngage dashboard.
- Navigate to Data > Data Imports.
- On the Data Imports page, under the Event tab, click Import >Events.
- On the Import Events dialog box, click Upload CSV. You can also import events using SFTP and S3.
- Click Continue.
The following step-by-step process outlines how events can be imported using CSV into the MoEngage platform.
Step 1: Source and Format
Enter the following details related to the source and format of the CSV file in Step 1.
info |
Information A CSV file can only upload one event at a time, so it is impossible to use one CSV file to upload multiple events. |
- Import name- Enter a name for your import.
-
Select event- Select the event you want to upload using the CSV file. If the event you are searching for is not listed in the drop-down, click Create new event from the drop-down.
- On the Create new event dialog box, enter the Event name and click Create.
-
Select file- You can either drag and drop a CSV file or upload a CSV file from the computer. You can also Download a sample file to view a sample event file that clearly explains the data format expected in the CSV File. Note that CSV files less than 150 MB are supported.
info Information
When you upload an event CSV file, the column represents the event attributes.
- File preview- Click the Preview file to preview the CSV file you uploaded. You can preview the first five rows of the event CSV file.
- Click Next. This takes you to the next step.
Step 2: Import Configuration and Action
This step involves mapping event attributes in MoEngage to event attribute columns in the CSV file.
Required Mapping
This is a mandatory mapping that should be performed. Under the Attribute name, you can view the event attributes of Moengage, such as User Identifier and Event time. These attributes should be mandatorily mapped to the events attributes column in the CSV file listed under Map Column. You can select the column names of the uploaded CSV file from the drop-down menu under the Map column.
While mapping the Event time, make sure to select the date, time format and time zone.
Map Columns
After successfully mapping the mandatory fields mentioned above, you need to map the remaining events attribute columns in the CSV file to the event attributes of MoEngage.
The event attributes columns of the CSV file are listed under the Column name, and this is to be mapped to the event attributes of MoEngage under the Map column to attribute.
Perform the following steps to map columns:
- You can either select the event attributes of MoEngage from the Select attribute drop-down or click Create new attribute, if the attribute is not listed in the drop-down.
- On the Create new attribute dialog box, enter the Attribute name, Data type and click Create.
- On the Create new attribute dialog box, enter the Attribute name, Data type and click Create.
- Select the Data type of each attribute while mapping.
- Select the Skip column if you want to skip any columns from mapping. Note that the mandatory fields already mapped are disabled under Map Columns.
Send Import Status
After the event data is imported to MoEngage, you can send the import status to 10 email ids. Select the Email id from the drop down to which you want to send the status and click Next.
Step 3: Scheduling
In this step, you need to define when to import the files. MoEngage supports the following types of imports:
-
As soon as possible: The file will start importing as soon as you click Schedule Import.
-
At specific date and time: You can choose to run the import based on your selected Start date and Start time. You can also select the Time zone.
After scheduling, click Schedule Import. The event data now gets imported to MoEngage.
View Imported Event Data
The imported event data gets listed under Data > Data Imports >Events. Click Actions () to View or Duplicate the event data.
- Click View to view the imported event details. Click Actions () to Export file to your email id.
- Click Duplicate to duplicate an event with the same event name, and then you can upload the CSV file for it.
The imported event data has the following import status:
- Successful- This is displayed when the event import is successful.
- Processing- This is displayed when the event import is still in the processing state after being imported.
- Archived- This is displayed when the imported event is archived.
- Failed- This is displayed when the event import is failed.
Supported Data Types, Event Attributes Types and Datatime Formats in Event Data
Supported data types
The following data types are supported for column values in the file:
- String
- Numeric
- Boolean
- Datetime
- Array (String, Double, Float, Int)
Supported Event Attribute Types
Type | Description | Value in Manifest |
---|---|---|
String | Any string value. Examples of acceptable values are ABC, ABC XYZ, ABC123, and so on. | "type": "string" |
Double | Any decimal value. Examples of acceptable values are 3.14159, 241.23, -123.1 | "type": "double" |
Boolean | Examples of acceptable values are true, false | "type": "bool" |
Date Time | Any date time value. The supported formats are covered in the next table.Example of acceptable values are 2019/02/22 17:54:14.933 | "type": "datetime" |
Supported Datetime Formats
Date and Time Format | Examples |
---|---|
“datetime_format”: "YYYY-MM-DD" |
|
“datetime_format”: "YYYY/MM/DD" |
|
“datetime_format”: "DD/MM/YYYY" |
|
“datetime_format”: "DD-MM-YYYY" |
|
“datetime_format”: "DD-MM-YYYY hh:mm:ss" |
|
“datetime_format”: "DD/MM/YYYY hh:mm:ss" |
|
“datetime_format”: "YYYY-MM-DD hh:mm:ss" |
|
“datetime_format”: "YYYY/MM/DD hh:mm:ss" |
|
“datetime_format”: "DD-MM-YYYYThh:mm:ss.s" |
|
“datetime_format”: "DD/MM/YYYYThh:mm:ss.s" |
|
“datetime_format”: "DD-MM-YYYYThh:mm:ssTZD" |
|
“datetime_format”: "DD/MM/YYYYThh:mm:ssTZD" |
|
“datetime_format”: "YYYY-MM-DD hh:mm:ss.s" |
|
“datetime_format”: "YYYY/MM/DD hh:mm:ss.s" |
|
“datetime_format”: "YYYY-MM-DDThh:mm:ssTZD" |
|
“datetime_format”: "YYYY/MM/DDThh:mm:ssTZD" |
|
“datetime_format”: "YYYY-MM-DDThh:mm:ss.sTZD" |
|
“datetime_format”: "YYYY/MM/DDThh:mm:ss.sTZD" |
|
Language Support
You can import data in any language as long as you are using UTF-8 decodable characters.
Empty values
If your file contains empty values then these would still be imported into MoEngage. In this case, we will create/update event attribute where the value would be empty.
What is not supported currently?
- Attribute Type list and other complex types (JSON, dictionaries, etc.).
- Newline character formats other than "\n" - .The only newline character currently supported for the .csv files is "\n".Other formats like "Ctrl+M" or "\r" are not supported.
- If your file contains less than 5 rows, then you may face errors during file import. Make sure to add some dummy rows to import in this case.