Audience selection

Select an audience of passes for scheduled updates or other operations.

Atomic selector

Determines the property type you want to target. This can be tag, segment, template, pass or externalId.

Jump to examples ↓

OBJECT PROPERTIES
  • externalId string[string]

    The pass external ID. Must also include a template.

  • passId number[number]

    The pass ID.

  • segment array[string]

    The segment ID.

  • tag array[string]

    A tag is arbitrary metadata string used to identify and target passes.

  • templateId number[string]

    The template ID.

Used in:

Examples

Example atomic selector tag

{
  "audience": {
      "tag": "TZ_PST"
  }
}

Example atomic selector segment

{
  "audience": {
      "segment": "3b13666df-e5b3-4e42-8919-f8d63bd7ce2a"
  }
}

Example atomic selector template

{
  "audience": {
      "templateId": 1234
  }
}

Example atomic selector pass

{
  "audience": {
      "passId": 1234
  }
}

Example atomic selector external ID

{
  "audience": {
    "and": [
      { "externalId": "test_ext_id" },
      { "templateId": "12345" }
    ]
  }
}

Audience selector

Determines the passes you want to target.

Jump to examples ↓

One of
  • Compound selectors combine boolean operators (AND, OR, or NOT) with atomic or nested compound selectors. The syntax can be either implicit, using an array of values associated with an atomic selector, or explicit, employing a boolean operator followed by an array of atomic expression objects.

  • Determines the property type you want to target. This can be tag, segment, template, pass or externalId.

  • string

    All passes.

Used in:

Examples

Example pass objects tagged for baseball or basketball and in time zone PST

{
  "audience": {
      "AND": [
        {
            "OR": [
              {
                  "tag": "baseball"
              },
              {
                  "tag": "basketball"
              }
            ]
        },
        {
            "tag": "TZ_PST"
        }
      ]
  }              
}

Example pass objects tagged for time zone ET and not for time zone PST

{
  "audience": {
      "AND": [
        {
            "tag": "TZ_ET"
        },
        {
            "NOT": {
              "tag": "TZ_PST"
            }
        }
      ]
  }              
}

Compound selector

Compound selectors combine boolean operators (AND, OR, or NOT) with atomic or nested compound selectors. The syntax can be either implicit, using an array of values associated with an atomic selector, or explicit, employing a boolean operator followed by an array of atomic expression objects.

Jump to examples ↓

One of
  • Determines the property type you want to target. This can be tag, segment, template, pass or externalId.

  • AND selector

    OBJECT PROPERTIES
    • AND array
  • OR selector

    OBJECT PROPERTIES
    • OR array
  • NOT selector

    OBJECT PROPERTIES
    • NOT array

Used in:

Examples

Example implicit OR

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

Example explicit OR

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