Skip to navigation

Search conditions

The conditions query parameter of the search endpoints, every field with its operators and value

The search endpoints take their filters in one query parameter, conditions: a JSON array of conditions, URL-encoded. Every condition must hold.

[
{"field": "siteId", "operator": "equals", "value": "efcb8b3f-5994-4649-b3c0-802dd10ac489"},
{"field": "ingestedAt", "operator": "between", "value": ["2026-10-01T00:00:00Z", "2026-10-08T00:00:00Z"]}
]
  • A condition is an object with exactly three keys: field, operator and value.
  • At most 30 conditions, and the whole parameter at most 4,096 characters.
  • A string value holding commas is several values: "TX,CA" matches Texas or California for equals, and excludes both for not_equals.
  • A field the root does not have, an operator the field does not allow, or a value of the wrong shape is refused with INVALID_ARGUMENT, naming the condition (conditions[1].value).

Operators

OperatorMatches whenValue
equalsthe field is the valueone string, number or boolean; a comma-separated string matches any of its parts
not_equalsthe field is not the valueone string, number or boolean; a comma-separated string excludes every part
containsthe field’s text contains the valueone string; a comma-separated string matches any of its parts
does_not_containthe field’s text does not contain the valueone string; a comma-separated string excludes every part
starts_withthe field’s text starts with the valueone string
ends_withthe field’s text ends with the valueone string
contains_wordthe field’s text contains the value as a whole wordone string
match_phrasethe field’s text contains the value as a phrase, its words in orderone string
inthe field is one of the valuesan array of at most 500 strings or numbers, or a comma-separated string
not_inthe field is none of the valuesan array of at most 500 strings or numbers, or a comma-separated string
gtthe field is greater than the valueone number, or one date for a date field
gtethe field is the value or greaterone number, or one date for a date field
ltthe field is less than the valueone number, or one date for a date field
ltethe field is the value or lessone number, or one date for a date field
betweenthe field is within the two boundsan array of exactly two numbers or dates, or one string "low,high"
between_stringthe field is within the two boundsone string "low,high"
existsthe field has a valueignored
not_existsthe field has no valueignored
array_containsthe field, a list, holds the valueone string

Value kinds

Each field takes values of one kind.

KindWhat the value looks like
texta string, matched on its words
keyworda string matched exactly, such as an id, a code or a state
numbera JSON number, or a string in plain numeric form ("5000", "-1.5"): no thousands separators, currency signs or empty strings
datea date or date-time in ISO 8601 ("2026-10-01", "2026-10-01T00:00:00Z"), or epoch milliseconds as a number
booltrue or false, as a boolean or as a string
opaquea string in the form the endpoint’s description gives (a beacon id, a territory id, a list of shapes)

Visits

GET /v4/visits/search. Exactly one siteId condition is required: a search is scoped to one of the team’s sites. Names on one row are aliases of the same field.

FieldOperatorsValue
geo.subdivisions.isoCodeequalskeyword
ingestedAtequals, gt, gte, lt, lte, between, between_stringdate
siteIdequalskeyword

Institutions

GET /v4/institutions/search. beaconIds (in, beacon ids) with radiusMiles (equals, a number) selects the institutions of the team’s beacons, or those within the miles of them. Names on one row are aliases of the same field.

FieldOperatorsValue
access, schoolAccessequalstext
addresscontainstext
agencyRevTotal, districtRevTotal, fsclRevTotal, revenueTotalgt, lt, betweennumber
beaconIdsinopaque
charterLeaequals, not_equalstext
cityequals, containstext
countyIdequalstext
dsIdNces, ncesIdequalsopaque
faxequals, not_equals, contains, does_not_contain, existstext
fulltextcontainsopaque
gradeequals, not_equalsopaque
grade1equalsbool
grade10equalsbool
grade11equalsbool
grade12equalsbool
grade13equalsbool
grade2equalsbool
grade3equalsbool
grade4equalsbool
grade5equalsbool
grade6equalsbool
grade7equalsbool
grade8equalsbool
grade9equalsbool
gradeAEequalsbool
gradeKGequalsbool
gradePKequalsbool
highestGradeequals, gtenumber
idequals, in, not_inopaque
idParentInstitutionequalstext
listequals, not_equalsopaque
locState, stateequals, not_equalskeyword
lowestGradeequals, ltenumber
modelequalstext
nameequals, contains, existstext
parentDistrictNcesIdequalstext
parentDistrictRevenuegt, lt, betweennumber
phoneequals, not_equals, contains, does_not_contain, existstext
radiusMilesequalsnumber
radiusSearch, shapesequalsopaque
religiousAffiliation, schoolReligiousAffiliationequalstext
schoolSubtypeequals, not_equalsone of REGULAR, CHARTER
staffTotal, stfTotalgt, lt, betweennumber
studentTeacherRatioequals, not_equals, gt, gte, lt, lte, betweennumber
studentsTotalgt, lt, betweennumber
subtypeequals, not_equalstext
subtypeKeywordequals, not_equalskeyword
teachersTotalequals, not_equals, gt, gte, lt, lte, betweennumber
territoryIdequals, inopaque
titleOneequals, not_equalsbool
totalDistricts, totalSchoolsgt, lt, betweennumber
typeequals, not_equalstext
websitecontains, existstext
zipequals, not_equals, does_not_contain, starts_with, ends_withtext

People

GET /v4/people/search and GET /v4/people/headcounts. Institution conditions hold on one and the same institution of a person, role conditions on one and the same role; a role exclusion holds on every role. beaconIds with radiusMiles work as on institutions. Names on one row are aliases of the same field.

FieldOperatorsValue
access, institution.accessequals, not_equalstext
accountIdequalskeyword
accountNrStudentsequals, not_equals, gt, gte, lt, lte, betweennumber
beaconIdsinopaque
countyId, institution.countyIdequals, not_equalskeyword
districtRevTotal, institution.districtRevTotalequals, not_equals, gt, gte, lt, lte, betweennumber
emailequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
emailFormatequals, not_equalstext
emailSourceequals, not_equalstext
emailTypeequals, not_equalstext
emailVerificationStatusequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, not_in, exists, not_existstext
firstNameequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
fulltextcontainsopaque
grade, institution.gradeequals, not_equalsopaque
idequals, inopaque
institution.id, institutionIdequalskeyword
institution.model, modelequals, not_equalskeyword
institution.name, institutionNameequals, containstext
institution.ncesId, institutions.nces_id, ncesIdequals, not_equalsopaque
institution.radiusSearch, institution.shapes, radiusSearch, shapesequalsopaque
institution.religiousAffiliation, religiousAffiliationequalskeyword
institution.schoolGrade, schoolGradeequals, not_equalsopaque
institution.state, stateequals, not_equalskeyword
institution.stfTotal, stfTotalequals, not_equals, gt, gte, lt, lte, betweennumber
institution.studentTchrRatioequals, not_equals, gt, gte, lt, lte, betweennumber
institution.studentsTotal, studentsTotalequals, not_equals, gt, gte, lt, lte, betweennumber
institution.subtype, subtypeequals, not_equalskeyword
institution.territoryId, territoryIdequals, inopaque
institution.titleOne, titleOneequals, not_equalsbool
institution.type, institutionType, typeequals, not_equalsopaque
institution.zip, zipequals, not_equals, starts_with, ends_withkeyword
labelsin, not_inkeyword
lastNameequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
lastSeenequals, not_equalsopaque
nameequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
phoneequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
phoneUniquenessequals, not_equalstext
priorityequals, not_equals, gt, gte, lt, lte, betweennumber
radiusMilesequalsnumber
role.area, titleAreaequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
role.confidenceequals, not_equals, gt, gte, lt, lte, betweennumber
role.decisionLevelequals, not_equals, inkeyword
role.functionalGroupequals, not_equals, inkeyword
role.marketThemesequals, not_equals, in, not_inkeyword
role.modifier, titleModifierequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
role.role, titleRoleequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
role.statusequals, not_equals, in, not_inkeyword
sourceAndAgein, not_inopaque
tagequals, not_equalsopaque
titleequals, not_equals, contains, does_not_contain, starts_with, ends_with, contains_word, exists, not_existstext
titleRankequals, not_equals, gt, gte, lt, lte, betweennumber