Filter reference
Select fields and operators, combine conditions, and check filter limits.
Overview
Filters combine conditions in groups. Each condition names a field, an operator, and usually a value. Examples include “Tags is any of champion” and “Last activity in the last 30 days”.
Members and segments use the same filter definitions. The same filter therefore selects the same people in both locations.
Datum validates fields, operators, and value types in the preview and when you save. The builder outlines the invalid condition and shows the problem under it, and Save stays disabled until you change the filter. Unsupported fields, such as revenue, funding, technology stack, industry, and sentiment, do not appear.
Basics
Groups
The top of the builder has two sections. Who they are holds contact and organization fields, and What they’ve done holds activity fields. Each section has its own + Add button. Choose all, any or none at the top to combine them.
Each nested group specifies how to combine its conditions:
| In the builder | In JSON | Means |
|---|---|---|
| Match all of these | all |
Every condition holds |
| Match any of these | any |
At least one holds |
| Match none of these | not around any |
None of them hold |
Select + Group (any of / none of) to nest a group. Inside a nested group, + Condition lists contact, organization and activity fields together.
Limits
| Limit | Detail |
|---|---|
| Four levels | Includes the top group and lowest condition. Match none uses two levels: not around any. |
| 50 conditions | Applies to the complete filter. The top group displays the count. |
| 200 values | Applies to each is any of or is none of list. |
| 3,650 days | Limits each relative date window to ten years. |
| Ten referenced segments | Includes every segment in a reference chain. A chain cannot refer back to its own segment. |
The builder displays each group’s depth.
Operators
The builder displays operator labels. CLI and agent requests use JSON names.
| In the builder | In JSON | Takes |
|---|---|---|
| is, is not | is, is_not |
Text, or true and false on a yes/no field |
| contains, does not contain, starts with | contains, not_contains, starts_with |
Text |
| is empty, is not empty | is_empty, is_not_empty |
Nothing |
| is any of, is none of | any_of, none_of |
A list of 1 to 200 values |
| is, is not, is more than, is at least, is less than, is at most | eq, ne, gt, gte, lt, lte |
A number |
| is between | between |
Two numbers, [from, to] |
| is before, is after | before, after |
A date and time |
| in the last, not in the last, in the next | within_last, not_within_last, within_next |
A number of days, {"days": 30} |
Text comparisons ignore capitalization.
Negative conditions exclude matching values. For example, “Organization name is not Acme” includes people without an organization.
before means strictly earlier than the specified time. after includes the specified time and later times.
is empty means no value exists. On a boolean field, it differs from is false, which requires a recorded false value.
Relative windows move with the current time. “Last activity in the last 30 days” always refers to the current 30-day period. Hourly evaluation removes members whose activity falls outside it.
Fields
The pickers list fields within the following groups. Workspace custom fields also appear under Contacts.
Contacts
| Field | In the builder | Type | Operators | What it means |
|---|---|---|---|---|
contact.last_visited |
Last observed community visit | date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
The latest observed visit date across collecting communities. Missing presence means unknown activity, not confirmed absence. |
contact.visited_days_30d |
Observed visit days (30 days) | number | eq, ne, gt, gte, lt, lte, between |
Distinct observed visit days across today and the preceding 29 days. This is a minimum observed count. |
contact.search |
Search | text | contains |
Searches names, handles, companies, and emails like the search box. |
contact.name |
Name | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The member profile name. |
contact.handle |
Handle | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The member profile handle. |
contact.title |
Title | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The job title that a source reports. Datum never estimates titles. |
contact.company |
Company | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The company value from a profile. Organization fields describe calculated associations. |
contact.bio |
Bio | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The bio that a source publishes. |
contact.location_city |
City | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The city that a source reports. |
contact.location_country |
Country | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The country that a source reports. |
contact.email_domain |
Email domain | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The domain of any source-verified address across the member’s accounts. Unverified addresses do not qualify. |
contact.has_notes |
Has notes | boolean | is |
Whether the member has at least one note. |
contact.has_email |
Has an email address | boolean | is |
Whether an account contains any address, verified or unverified. Standard Slack exports provide none. |
contact.has_organisation |
Has an organization | boolean | is |
Whether the member has a calculated organization association. |
contact.is_team |
Is team | boolean | is |
Staff classification through a verified team-domain address or the reserved team tag. |
contact.sources |
Sources | enum | any_of, none_of |
Sources with an account for the member. Supported values: self, github, slack, discourse, vanilla, bevy, gainsight-cc, gradual, bettermode, circle, flarum, verint, dev, stackoverflow, meetup, luma, discord, generic, csv, enrichment. |
contact.identity_count |
Accounts | number | eq, ne, gt, gte, lt, lte, between |
The number of linked source accounts. |
contact.first_seen |
First seen | date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
The earliest first-seen date across accounts. |
contact.last_seen |
Last seen | date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
The latest profile observation or activity timestamp across accounts, including reactions and joins. It excludes presence. Use contact.last_visited for visits. |
contact.tags |
Tags | list | any_of, none_of, is_empty |
Member tags, identified by name. Tags do not affect matching. |
contact.segments |
Segments | list | any_of, none_of |
Membership of another segment, identified by name. Includes filter and manual membership. |
contact.custom.<field> |
Custom field | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
A custom field, identified by name or key. Its actual type determines its operators. |
Activity
| Field | In the builder | Type | Operators | What it means |
|---|---|---|---|---|
activity.count |
Activity count | number | eq, ne, gt, gte, lt, lte, between |
The number of events that match the required where condition. |
activity.first_at |
First activity | date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
The earliest matching event time. where is optional. |
activity.last_at |
Last activity | date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
The latest matching event time. where is optional. |
activity.title |
Activity title | text | contains, not_contains |
A source-published thread title, such as a pull request or forum topic title. It never searches message text. |
Organizations
| Field | In the builder | Type | Operators | What it means |
|---|---|---|---|---|
organisation.name |
Organization name | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
Membership of an organization with the specified name. |
organisation.domain |
Organization domain | text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
The email domain that defines the organization. |
organisation.key |
Organization | list | any_of, none_of |
An organization key, such as domain:acme.io or github:acme. Keys distinguish domains from GitHub organizations with similar names. |
organisation.kind |
Organization kind | enum | any_of, none_of |
The association method: email_domain or github_org. |
organisation.member_count |
Organization size | number | eq, ne, gt, gte, lt, lte, between |
Associated community members, rather than total employees. |
organisation.tags |
Organization tags | list | any_of, none_of |
Organization tags from the shared tag list. |
organisation.first_seen |
Organization first seen | date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
The earliest appearance of an associated person. |
organisation.last_seen |
Organization last seen | date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
The latest observation of an associated person. |
organisation.employees |
Employees | number | eq, ne, gt, gte, lt, lte, between, is_empty, is_not_empty |
Headcount from a connected enrichment provider. Without enrichment data, the field remains empty. |
What an activity condition counts
An activity condition’s where selects which events to evaluate. Activity count requires where. The other three activity fields allow it optionally.
The builder displays these controls below the condition:
| In the builder | In JSON | Means |
|---|---|---|
| any source | source |
One source, such as github or luma |
| any type | types |
Source event types, such as pr, issue, message, or event_attended. Comparisons ignore capitalization. |
| any channel | channel |
A Slack channel, forum category, or repository. #support and support match the same channel. |
| in the last N days | within_last_days |
The preceding number of days |
| contributions only | is_contribution |
Excludes membership and account lifecycle events but includes reactions. Combine first activity with both period boundaries to select Home’s newcomers. false, which selects only lifecycle events, is available from the CLI and API. |
| still needs a reply | needs_reply |
Thread-opening questions after the reply window, with no subsequent activity |
Event types must match the source’s identifiers. GitHub uses pr for pull requests. pull_request therefore matches no GitHub events.
Inspect the Activity feed’s Type menu for your sources’ identifiers.
Custom fields by type
A custom field’s type determines its operators:
| Value type | Treated as | Operators |
|---|---|---|
int, number |
number | eq, ne, gt, gte, lt, lte, between, is_empty, is_not_empty |
date |
date | before, after, within_last, not_within_last, within_next, is_empty, is_not_empty |
boolean |
yes/no | is, is_empty, is_not_empty |
string, url, enum |
text | is, is_not, contains, not_contains, starts_with, is_empty, is_not_empty |
Examples
This filter selects non-team members with a GitHub pull request within 30 days:
{
"all": [
{ "field": "contact.is_team", "op": "is", "value": false },
{ "field": "activity.count", "op": "gte", "value": 1,
"where": { "source": "github", "types": ["pr"], "within_last_days": 30 } }
]
}
This filter selects champions without observations in 90 days, excluding current Speakers members:
{
"all": [
{ "field": "contact.tags", "op": "any_of", "value": ["champion"] },
{ "field": "contact.last_seen", "op": "not_within_last", "value": { "days": 90 } },
{ "field": "contact.segments", "op": "none_of", "value": ["Speakers"] }
]
}
From your terminal or agent
Read the available field list. Preview the filter before saving it. The preview uses the same selection as the saved segment.
ocmgr segments fields --group activity --json
ocmgr segments preview --json --filter '{"field":"contact.tags","op":"any_of","value":["champion"]}'{ "name": "list_segment_fields", "arguments": { "group": "activity" } }
{ "name": "preview_segment", "arguments": { "filter": { "field": "contact.tags", "op": "any_of", "value": ["champion"] } } }curl -X POST "$OCMGR_URL/v1/segments/preview" -H "Authorization: Bearer $OCMGR_API_KEY" \
-H 'content-type: application/json' \
-d '{"filter":{"field":"contact.tags","op":"any_of","value":["champion"]}}'The field list includes custom fields with their actual types. CLI and API validation errors identify the location, such as all[1].op.
See list_segment_fields and preview_segment.
FAQ
Can I filter on what someone said?
No. Datum does not retain message text. Activity title searches published thread titles only.
Why does Employees match nobody?
Only a connected enrichment provider supplies headcount. Without that data, Employees is empty selects organizations without a value.
What's the difference between Company and Organization name?
Company contains a value from a person’s profile. Organization name identifies an organization that Datum calculates from work email domains or GitHub memberships.
See Organizations.
I renamed a tag. Do my filters break?
No. Filters reference the tag’s identity. They continue to work and display its new name.
“Seen” uses the latest profile observation or activity timestamp across accounts. It includes reactions and joins but excludes presence-only visits. Use contact.last_visited or presence filters for visits.
activity.* fields evaluate events selected by where, including reactions where applicable. Select specific event types when you need member-initiated contributions.
Past date windows include values from now minus the number of days through now. Future values do not match within_last. Use within_next for values from now through the next number of days. not_within_last selects values outside the past window. It does not select people without a date. Use is_empty to select missing dates.
Sign-ups (signed_up) and sign-ins (signed_in) are account lifecycle events, so Contributions only excludes them. Reactions remain contributions. The field catalogue lists observed lifecycle types under activityTypes[].lifecycleTypes.