Device Tag Exports

The device tags stores arbitrary tags against a user and their device, acting as an acceleration layer for real-time targeting via personalisation tools. This document outlines the structure, delivery, and format of the device tag data export.

Requesting Access

To request access to device tag exports for your integration, please contact customer support with the following information:

  • Client ID
  • Desired destination (S3 bucket details)
  • Desired export frequency

Export Destinations

Amazon S3

Exports are delivered directly to your Amazon S3 bucket.

  • Requires: Bucket name, region, and appropriate IAM permissions.
  • This is the primary destination for all exports.

Export Types

Full Exports: Each export contains the complete dataset of all device tags, regardless of when they were last modified.


Export Scheduling

Exports can be configured to run at the following intervals:

  • Hourly: Every hour at a specified minute.
  • Daily: Once per day at a specified time (UTC).
  • Weekly: Once per week on a specified day and time (UTC).
  • Custom: Custom scheduling requirements can be met.

Data Formats

Exports are available in JSON (default) and CSV. The export is delivered as a ZIP file containing the data file. The JSON export is a list of device tag objects.


Export Sample

The devicetags export contains all device and user tag information.

Sample Export:

[
  {
    "_id": "62fcd5e16f0058187878a67c",
    "clientId": "TEST_CLIENT",
    "deviceId": "f7x3f45c-d8dd-4b3d-96f6-84ef005a92e1",
    "authId": 14967390,
    "associatedIds": [
      {
        "type": "onesignalId",
        "value": "b51b18c4-f159-416b-87d8-452cd0d752c6"
      }
    ],
    "sessionCount": 42,
    "duration": 2754,
    "language": "EN",
    "location": null,
    "country": "GB",
    "platform": "ANDROID",
    "appVersion": "1.4.7",
    "osVersion": "28",
    "lastSession": "2023-09-21T10:36:50.073Z",
    "createdAt": "2022-08-17T11:49:53.764Z",
    "updatedAt": "2024-10-11T09:36:16.177Z",
    "tags": [
      { "name": "example_tag", "value": "true", "type": "boolean" },
      { "name": "another_tag", "value": "123", "type": "number" }
    ],
    "audiences": [
      { "name": "active_user", "value": "true", "type": "boolean" }
    ]
  }
]

Field Description:

FieldTypeDescription
_idstringUnique identifier for the device record (ObjectID).
clientIdstringClient identifier.
deviceIdstringUnique identifier for the device.
authIdnumberThe authenticated user's ID (if logged in).
associatedIdsarrayAn array of objects for additional identifiers (e.g., onesignalId).
sessionCountnumberThe total number of sessions recorded for this device.
durationnumberThe total session duration in seconds.
languagestringThe device's language setting.
locationobjectDevice location data.
countrystringThe device's country.
platformstringThe device platform.
appVersionstringThe version of the client application.
osVersionstringThe version of the device's operating system.
lastSessionstringTimestamp of the last recorded session.
createdAtstringTimestamp when the device record was created.
updatedAtstringTimestamp of the last modification to the record.
tagsarrayAn array of tag objects applied to the device. Each object contains name (string), value (any), and type (string).
audiencesarrayAn array of tag objects representing audience membership. Each object contains name (string), value (any), and type (string).