Skip to main content

Tenant Segments

Introduction

Tenant Segments allow you to group users based on specific criteria or conditions. These segments are used to target communications and automations to specific groups of users. Segments are dynamic, meaning users automatically enter or leave segments as they meet or no longer meet the defined conditions. Please see the API Reference here for more information.

Structure

A tenant segment consists of:
  • Status: Can be either active or deactivated
  • Business ID: Links the segment to a specific tenant
  • Name: A descriptive name for the segment
  • Description: Detailed description of the segment’s purpose
  • Conditions: Array of conditions that define segment membership. See Segment Conditions for more information.

Segment Conditions

Available Fields

Currently supported fields for conditions include both built-in fields and custom fields:

Built-in Fields

These fields are available out of the box for all platforms:
  • user_id: The unique identifier of the user
  • email: The user’s email address
  • phone: The user’s phone number
  • first_name: The user’s first name
  • last_name: The user’s last name

Custom Fields

Custom fields can be exposed through the fields_to_expose configuration in your partner resource schema definitions. This allows you to:
  • Define custom fields from your data schema
  • Specify JSON paths to access nested data structures
  • Control field exposure for segments, merge fields, or both
  • Add business-specific fields like loyalty points, purchase history, location data, etc.
Custom fields are configured through the fields_to_expose property in your partner resource schema definitions. Each field specifies a name, description, JSON path, and exposure settings to control where the field is available.For help configuring custom fields, please reach out to [email protected].

Operators

The following operators are available for conditions:
  • equals: Exact match
  • not_equals: Inverse match
  • greater_than: Numeric comparison (>)
  • less_than: Numeric comparison (<)

Condition Structure

Each condition consists of:
{
  "field": "user_id",
  "operator": "equals",
  "value": ["123"]
}

Usage in Automations

Segments are primarily used in automations to:
  1. Include Users: Define the target audience for communications
  2. Exclude Users: Specify users who should not receive communications
See Automations for more information on where segments are used.