Filter Group Structure
A filter group combines conditions with a logical operator.Condition Types
Each condition object must include acondition_type field that determines which fields and operators are valid.
Requests use the snake_case key
condition_type. In API responses, condition objects are serialized with camelCase keys — conditionType, and (always present) listId. Optional keys joinOperator, secondaryOperator, secondaryValue, and secondaryUnit appear only when set.1. Time Conditions
Filter contacts by time-based fields using relative or absolute time windows.
Valid Operators:
Valid Units:
days, hours, minutes
The
exists and not_exists operators do not require value or unit. All other operators require both.2. Count Conditions
Filter contacts by numeric count fields such as send count, click count, or conversion count.
Valid Operators:
3. Custom Field Conditions
Filter contacts by any custom field stored on the contact record. Custom fields are arbitrary key-value pairs you define when creating or updating contacts.4. Carrier Conditions
Filter contacts by their mobile carrier.carrier
Valid Operators:
5. Timezone Conditions
Filter contacts by their timezone.timezone
Valid Operators:
Timezone values use the IANA timezone database format (e.g.,
America/New_York, US/Pacific, Europe/London).
6. Revenue Conditions
Filter contacts by revenue data.
Valid Operators:
7. Phone Numbers Conditions
Filter contacts by matching against an explicit list of phone numbers.field value is not used for matching, but field must be present (any non-empty string).
Valid Operators:
value must be a non-empty array of phone numbers. An empty or missing list is rejected with missing_phone_numbers_value.
Nesting Groups
Groups can be nested to create complex boolean logic. Each nested group has its ownoperator and set of conditions.
Example: Find contacts who were sent a message AND clicked within 30 days, AND whose carrier is either T-Mobile OR AT&T.
Validation Error Codes
If your filter is malformed, the API returns a400 response with one of the following error codes:
Next Steps
Creating Audiences
Build audience segments in the UI
Create Audience
Create an audience via the API