boolean_query parameter lets you write advanced search expressions using standard boolean operators. It is supported on both the LinkedIn search and database search endpoints.
Supported operators
| Operator | Description | Example |
|---|---|---|
AND | Both terms must match | Python AND Java |
OR | Either term can match | React OR Vue |
NOT | Exclude a term | NOT Intern |
"..." | Exact phrase match | "Software Engineer" |
( ) | Group expressions | (Python OR Java) AND NOT Angular |
Operator precedence
From highest to lowest:NOT > AND > OR. Use parentheses to override.
Examples
Find engineers with specific skills
Combine boolean query with other filters
boolean_query can be used alongside other filter fields like job_titles, companies, or location_ids. The boolean query applies to the keyword/full-text dimension while other filters apply to their respective structured fields.
Search the people database
Boolean queries also work on the database search endpoint:Common patterns
| Use case | Query |
|---|---|
| Multiple roles | "Software Engineer" OR "Backend Developer" OR "Full Stack" |
| Skill combination | (React OR Angular OR Vue) AND TypeScript |
| Exclude seniority | "Data Scientist" AND NOT (Junior OR Intern OR Entry) |
| Exact company + role | "Goldman Sachs" AND ("Vice President" OR Director) |
| Industry targeting | (FinTech OR "Financial Technology") AND "Head of Engineering" |
Syntax rules
- Operators
AND,OR,NOTmust be uppercase - Parentheses must be balanced
- Quoted phrases must have matching opening and closing
" - Operators cannot be consecutive (
AND ANDis invalid) - A query cannot start with
ANDorOR
Endpoints that support boolean queries
| Endpoint | Parameter |
|---|---|
POST /sourcing/linkedin/search | boolean_query |
POST /sourcing/database/search | boolean_query |