Amplitude

Overview

Amplitude is a product analytics service that tracks user events and builds rich cross-sectional and longitudinal profiles. It primarily sources users and events from websites and mobile apps. Amplitude provides a powerful UI enabling you to create "cohorts" of users based on event histories.

Integrating Lytics with Amplitude provides cross-channel profile resolution, expedited marketing activation, and Journey Orchestration. Lytics can import the cohorts and events stored in Amplitude, enabling users to further refine targeting logic.

Authorization

If you haven't already done so, you will need to setup an Amplitude account before you begin the process described below. Follow the instructions on setting up an account and starting a new project. Each project has its own unique API key and secret, which you will need to authorize this integration.

If you are new to creating authorizations in Lytics, see the Authorizations documentation for more information.

  1. Select Amplitude from the list of providers.
  2. Select the Amplitude API Key method for authorization.
  3. In the Label text box, enter a name for the authorization
  4. (optional) In the Description text box, enter a description for this authorization
  5. In the API Key field, enter your Amplitude API username.
  6. In the API Secret field, enter your Amplitude API password.
  7. Click Save Authorization.
    Amplitude Auth

Import Cohorts

Importing cohorts from Amplitude results in new and/or updates to existing user profiles in your Lytics account containing fields from Amplitude. Once imported, Lytics can use this Amplitude data to inform its ML-based enrichments, and this data enables you to target your multi-channel campaigns orchestrated by Lytics.

Integration Details

  • Implementation Type: Server-side Integration.
  • Implementation Technique: REST API Integration.
  • Frequency: Batch Integration one-time or daily continuous updates where the time of day can be configured.
  • Resulting Data: Full user profiles from Amplitude for selected Cohorts.

This integration utilizes the Amplitude Behavioral Cohorts API to retrieve data. On each run of the job, it will request a list of cohorts, and for each cohort selected by the user during the configuration step, it will:

  1. Request a single cohort for download.
  2. Poll the request status for completion.
  3. Once completed, download the cohort file.
  4. Ingest the data from the cohort file into the Lytics data stream amplitude_cohorts.

Fields

The following fields are included in the default mapping of the amplitude_cohorts stream:

Source FieldLytics User FieldDescriptionType
citycityAmplitude Citystring
regionregion, stateAmplitude Region/Statestring
countrycountryAmplitude Countrystring
deviceamplitude_deviceAmplitude Devicestring
device_typeamplitude_device_typeAmplitude Device Typestring
languageamplitude_languageAmplitude Languagestring
carrieramplitude_carrierAmplitude Carrierstring
platformamplitude_platformAmplitude Platformstring
last_computedamplitude_last_computedAmplitude Cohort Last Computeddate
dmaamplitude_dmaAmplitude DMAstring
libraryamplitude_libraryAmplitude Libratystring
start_versionamplitude_start_versionAmplitude Start Versionstring
versionamplitude_versionAmplitude Versionstring
osamplitude_osAmplitude OSstring
cohort_idamplitude_cohort_idsAmplitude Cohort IDsmap[string]bool
cohort_nameamplitude_cohort_namesAmplitude Cohort Namesmap[string]bool
user_idamplitude_user_id unique idAmplitude User IDstring
amplitude_idamplitude_id unique idAmplitude IDstring

Configuration

Follow these steps to set up and configure an import job for Amplitude in the Lytics platform. If you are new to creating jobs in Lytics, see the Data Sourcesdocumentation for more information.

  1. Select Amplitude from the list of providers.

  2. Select the Import Cohorts job type from the list.

  3. Select the Authorization you would like to use or create a new one.

  4. Enter a Label to identify this job you are creating in Lytics.

  5. (Optional) Enter a Description for further context on your job.

  6. Complete the configuration steps for your job.
    Amplitude Cohort Import Config

  7. (Optional) From the Amplitude ID Field input, select the field name that contains the user's Amplitude ID. If left blank, cohorts will only be added to profiles.

  8. (Optional) From the Amplitude Cohort Names Field input, select the field name that contains the user's cohort membership. If left blank, cohorts will only be added to profiles.

  9. (Optional) From the Cohorts input, select select the cohorts you want to import. If left blank, all cohorts will be imported.

  10. (Optional) Select the Keep Updated checkbox, to import cohorts daily.

  11. (Optional) From the Time of Day input, select time of day to start import.

  12. (Optional) From the Timezone input, select timezone for time of day.

  13. Click Start Import.

Import Events

Importing events from Amplitude enables you to refine audience definitions within Lytics. Beyond just basic event triggers, Lytics can apply its ML-powered Behavioral Scores and Content Affinities to enhance user profiles.

Integration Details

  • Implementation Type: Server-side Integration.
  • Implementation Technique: REST API Integration.
  • Frequency: Batch Integration one-time or daily continuous updates.
  • Resulting Data: User Fields and Raw Event Data (see additional fields).

This integration utilizes the Amplitude Export API to retrieve event data. On each run of the job, it will:

  1. Request an export of zipped event data in a JSON format.

    NOTE: If the user opted to backfill events, on the first run of the job it will request all events from the time frame selected by the user. Otherwise the import requests a file of all events between the current and previous run.
  2. Ingest the data from the JSON files into the Lytics data stream amplitude_events.

Fields

The following fields are included in the default mapping from the amplitude_events stream:

Source FieldLytics User FieldDescriptionType
event_typeamplitude_eventsAmplitude Event Countmap[string]int
schemaamplitude_schemaAmplitude Schemaint
event_timeamplitude_event_timeAmplitude Event Timedate
server_upload_timeamplitude_server_upload_timeAmplitude Server Upload Timedate
cityamplitude_cityAmplitude Citystring
appamplitude_appAmplitude Appint
device_carrieramplitude_device_carrierAmplitude Device Carrierstring
platformamplitude_platformAmplitude Platformstring
os_versionamplitude_os_versionAmplitude OS Versionstring
user_creation_timeamplitude_user_creation_timeAmplitude User Creation Timedate
payingamplitude_payingAmplitude Payingboolean
dmaamplitude_dmaAmplitude DMAstring
group_properties.*amplitude_group_propertiesAmplitude Group Propertiesmap[string]string
user_properties.*amplitude_user_propertiesAmplitude User Propertiesmap[string]string
event_properties.*amplitude_event_propertiesAmplitude Event Propertiesmap[string]string
client_upload_timeamplitude_client_upload_timeAmplitude Client Upload Timedate
insert_idamplitude_insert_idAmplitude Insert IDstring
event_typeamplitude_event_typeAmplitude Event Typestring
libraryamplitude_libraryAmplitude Librarystring
amplitude_attribution_idsamplitude_attribution_idsAmplitude Attribution IDsstring
device_typeamplitude_device_typeAmplitude Device Typestring
device_manufactureramplitude_device_manufacturerAmplitude Device Manufacturerstring
location_lngamplitude_location_lngAmplitude Location lngfloat
event_idamplitude_event_idAmplitude Event IDint
location_latamplitude_location_latAmplitude Location latfloat
os_nameamplitude_os_nameAmplitude OS Namestring
amplitude_event_typeamplitude_event_typeAmplitude Event Typestring
device_brandamplitude_device_brandAmplitude Device Brandstring
dataamplitude_dataAmplitude Datastring
device_idamplitude_device_idAmplitude Device IDstring
languageamplitude_languageAmplitude Languagestring
device_modelamplitude_device_modelAmplitude Device Modelstring
countrycountryAmplitude Countrystring
regionregion, stateAmplitude Region/Statestring
is_attribution_eventamplitude_is_attribution_eventAmplitude Is Attrivbution Eventboolean
session_idamplitude_session_idAmplitude Session IDstring
device_familyamplitude_device_familyAmpitude Device IDstring
sample_rateamplitude_sample_rateAmplitude Sample Ratestring
client_event_timeamplitude_client_event_timeAmplitude Client Event Timedate
idfaamplitude_idfaAmplitdue Idfastring
adidamplitude_adidAmplitude Adidstring
user_idamplitude_user_id unique idAmplitude User IDstring
amplitude_idamplitude_id unique idAmplitude Amplitude IDstring

Additional fields

The following fields are not included in the default mapping, reach out to the customer support team to add them to the mappings for your account.

Source FieldLytics User FieldDescriptionType
server_received_timeamplitude_server_received_timeAmplitude Server Received Timedate
processed_timeamplitude_processed_timeAmplitude Processed Timedate
version_nameamplitude_version_nameAmplitude Version Namestring
start_versionamplitude_start_versionAmplitude Start Versionstring
uuidamplitude_uuidAmplitude UUIDstring
ip_addressamplitude_ip_addressAmplitude IP Addressstring

Configuration

Follow these steps to set up and configure an import job for Amplitude in the Lytics platform. If you are new to creating jobs in Lytics, see the Data Sourcesdocumentation for more information.

  1. Select Amplitude from the list of providers.
  2. Select the Import Activity Data job type from the list.
  3. Select the Authorization you would like to use or create a new one.
  4. Enter a Label to identify this job you are creating in Lytics.
  5. (Optional) Enter a Description for further context on your job.
  6. Complete the configuration steps for your job.
    image
  7. In the Backfill Days numeric field, enter how many days in the past do you want to import events (default is 90 days). Select 0 if you want to start from now on.
  8. (Optional) Toggle Show Advanced Options. Select the Keep Updated checkbox to import events hourly.
  9. Click Start Import.