Audience selection

Objects that help you select and target an audience.

Atomic selector

Atomic selectors are the simplest way to identify a single device, i.e., app or browser installation, or a group of devices. These selectors are either a unique identifier for the device such as a Channel ID or metadata that maps to the device (or multiple devices) such as a tag.

Jump to examples ↓

One of
  • string

    The simplest selector, which targets the entire audience.

  • Tag selector object

    A tag is an arbitrary bit of metadata used for targeting devices. A tag specifier may or may not have an associated group declaration, indicating a tag group the tag belongs to, for example, {"tag": "silver-member", "group": "loyalty"}. If no tag group is specified, the default device group is used.

    OBJECT PROPERTIES
    • group string
    • tag objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • Segment selector object

    The Segment ID.

    OBJECT PROPERTIES
    • segment objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • Channel selector object

    The unique channel identifier used to target an open channel device or web device, i.e., web browser.

    OBJECT PROPERTIES
    • channel objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • Named User selector object

    A named_user is an alternate, non-unique name, mapped to a user profile in a different database, e.g., CRM, that can be used to target devices associated with that profile.

    OBJECT PROPERTIES
    • named_user objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • Fire OS channel selector object

    The unique channel identifier used to target a Fire OS device.

    OBJECT PROPERTIES
    • amazon_channel objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • Android channel selector object

    The unique channel identifier used to target an Android device.

    OBJECT PROPERTIES
    • android_channel objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • Open channel selector object

    The unique channel identifier used to target a device on an open platform.

    OBJECT PROPERTIES
    • open_channel objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • string

    A long or short code the app is configured to send from. For example, 12345.

  • SMS ID selector object

    Selects a single SMS device. The msisdn must be opted_in to receive notifications.

    OBJECT PROPERTIES
    • msisdn stringREQUIRED

      The recipient phone number.

    • sender stringREQUIRED

      The sender that the app is configured to send SMS messages from.

  • Static list selector object

    A static_list is a subset of your audience defined by a CSV file containing Channel IDs or Named Users.

    OBJECT PROPERTIES
    • static_list objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • Subscription List selector object

    An single instance or array of subscription list IDs.

    OBJECT PROPERTIES
    • subscription_list objectREQUIRED
      One of
      • string
      • array<ref>
  • An attribute object with a TEXT schema type. Evaluates for the inclusion or exclusion of a text (string) attribute on a channel or Named User.

  • An attribute object with a NUMBER schema type. Performs value comparisons based on the number value for an attribute on a channel or Named User.

  • An attribute object with a DATE schema type. Performs absolute date comparisons for ISO-formatted date values or a relative date comparisons given an integer value and precision, e.g., days, months. Use a date attribute to target a channel or Named User based on the date values.

  • An attribute object with a JSON schema type. Performs value comparisons based on the JSON value for an attribute on a channel or Named User.

  • Alias selector object

    A legacy mechanism used for mapping devices to a customer ID, e.g., a CRM identifier. Superseded by named_user.

    OBJECT PROPERTIES
    • alias objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • APID selector object

    A legacy identifier for targeting Android and Windows devices, superseded by android_channel.

    OBJECT PROPERTIES
    • apid objectREQUIRED
      One of
      • string
      • array<string>

        Min items: 1, Max items: 100

  • The activity object defines the target audience based on lifecycle actions or Custom Event activity, using comparison operators on activity count and recency. Optionally include a where object, which filters for specific activity values.

    In the example to the right, the target audience is users who have opened your app from a notification from the “neowise” campaign at least twice, 3 days ago.

  • string

    A special selector used in Pipelines to indicate that the audience of the push is composed of the device or devices that activated the trigger. See Pipeline objects for more information.

Used in:

Examples

Example audience selection by tag

{
   "audience": {
      "tag": "sfGiants",
      "group": "favorite_teams"
   }
}

Example SMS channel audience

{
    "audience" : {
        "sms_id" :  {
            "sender" : "12345",
            "msisdn" : "15552243311"
        }
    }
}

Example audience segment

{
    "audience" : {
        "segment" : "<segment-id>"
    }
}

Example audience of Named Users

{
   "audience" : {
      "named_user" : "user-id-54320"
   }
}

Example audience of static list

{
   "audience" : {
      "static_list" : "name_of_list"
   }
}

Audience selector (max 100)

An audience selector forms the expression that determines the set of channels to target.

One of
  • Compound selectors combine boolean operators (AND, OR, or NOT) with atomic or nested compound selectors.

  • Atomic selectors are the simplest way to identify a single device, i.e., app or browser installation, or a group of devices. These selectors are either a unique identifier for the device such as a Channel ID or metadata that maps to the device (or multiple devices) such as a tag.

Used in:

Audience selector (max 1000)

An audience selector forms the expression that determines the set of channels to target.

One of
  • Compound selectors combine boolean operators (AND, OR, or NOT) with atomic or nested compound selectors.

  • Atomic selectors are the simplest way to identify a single device, i.e., app or browser installation, or a group of devices. These selectors are either a unique identifier for the device such as a Channel ID or metadata that maps to the device (or multiple devices) such as a tag.

Used in:

Compound selector

Compound selectors combine boolean operators (AND, OR, or NOT) with atomic or nested compound selectors.

Jump to examples ↓

One of
  • AND selector object

    AND selector

    OBJECT PROPERTIES
    • AND array
  • OR Selector object

    OR selector

    OBJECT PROPERTIES
    • OR array
  • NOT Selector object

    NOT selector

    OBJECT PROPERTIES
    • NOT object
      One of
      • Compound selectors combine boolean operators (AND, OR, or NOT) with atomic or nested compound selectors.

      • Atomic selectors are the simplest way to identify a single device, i.e., app or browser installation, or a group of devices. These selectors are either a unique identifier for the device such as a Channel ID or metadata that maps to the device (or multiple devices) such as a tag.

Used in:

Examples

Example with implicit `OR`

{
   "audience" : {
      "tag" : ["apples", "oranges", "bananas"]
   }
}

Example with nested selectors

{
   "audience": {
      "AND": [
         {"OR": [
            {"tag": "sports"},
            {"tag": "entertainment"}
         ]},
         {"tag": "language_en"}
      ]
   }
}

Example `NOT` selector

{
   "audience": {
      "AND": [
         { "tag": "Federer fan" },
         { "NOT":
            { "tag": "Messi fan" }
         }
      ]
   }
}