audience_​segmentation

Version: v2025-01-13Includes use: No

Behavior name: Audience Segmentation Cloudlet

Allows you to divide your users into different segments based on a persistent cookie. You can configure rules using either the Cloudlets Policy Manager application or the Cloudlets API.

Default behavior

These samples reflect the behavior's default settings. You can use these as is in your configurations or make adjustments based on the behavior's available options.

data "akamai_property_rules_builder" "audience_segmentation" {
  rules_v2025_02_18 {
    name     = "Audience Segmentation Cloudlet"
    comments = "Divide your users into different segments based on a persistent cookie."
    behavior {
      audience_segmentation {
        enabled                             = true
        is_shared_policy                    = false
        cloudlet_policy                     = ""
        label                               = ""
        segment_tracking_method             = "NONE"
        population_cookie_type              = "ON_BROWSER_CLOSE"
        specify_population_cookie_domain    = false
        population_cookie_automatic_salt    = true
        population_cookie_include_rule_name = false
      }
    }
  }
}
"behaviors": [
  {
    "name": "audienceSegmentation",
    "options": {
      "enabled": true,
      "isSharedPolicy": false,
      "cloudletPolicy": "",
      "label": "",
      "segmentTrackingMethod": "NONE",
      "populationCookieType": "ON_BROWSER_CLOSE",
      "specifyPopulationCookieDomain": false,
      "populationCookieAutomaticSalt": true,
      "populationCookieIncludeRulename": false
    }
  }
]

Options

Option Description
enabled
Enables the Audience Segmentation cloudlet feature.
is_shared_policy
Whether you want to use a shared policy for a Cloudlet. Learn more about shared policies and how to create them in Cloudlets Policy Manager.
cloudlet_policy
Identifies the Cloudlet policy. Contains:
  • id. The cloudlet policy's ID.
  • name. The cloudlet policy's name.
cloudlet_shared_policy
This identifies the Cloudlet shared policy to use with this behavior. You can list available shared policies with the Cloudlets API.
label
Specifies a suffix to append to the cookie name. This helps distinguish this audience segmentation policy from any others within the same property.
segment_tracking_method
Specifies the method to pass segment information to the origin. The Cloudlet passes the rule applied to a given request location. Value is one of:
  • IN_COOKIE_HEADER
  • IN_CUSTOM_HEADER
  • IN_QUERY_PARAM
  • NONE
segment_tracking_query_param
This query parameter specifies the name of the segmentation rule.
segment_tracking_cookie_name
This cookie name specifies the name of the segmentation rule.
segment_tracking_custom_header
This custom HTTP header specifies the name of the segmentation rule.
population_cookie_type
Specifies when the segmentation cookie expires. Value is one of:
  • NEVER. Never expire.
  • ON_BROWSER_CLOSE. Expire at end of browser session.
  • DURATION. Specify a delay.
population_duration
Specifies the lifetime of the segmentation cookie.
population_refresh
If disabled, sets the expiration time only if the cookie is not yet present in the request.
specify_population_cookie_domain
Whether to specify a cookie domain with the population cookie. It tells the browser to which domain to send the cookie.
population_cookie_domain
Specifies the domain to track the population cookie.
population_cookie_automatic_salt
Whether to assign a salt value automatically to the cookie to prevent manipulation by the user. You should not enable if sharing the population cookie across more than one property.
population_cookie_salt
Specifies the cookie's salt value. Use this option to share the cookie across many properties.
population_cookie_include_rule_name
When enabled, includes in the session cookie the name of the rule in which this behavior appears.