Use LinkedIn People Finder by Role, Seniority & Network with Python
Search LinkedIn people with structured filters for company, school, seniority, job function, years of experience, industry, and connection degree, using your own LinkedIn session.
1. Choose the data you need
Review the published README for supported collection modes, examples, and limits. The recipe below uses the current published input definition.
2. Prepare a source-based input
This JSON contains published prefills and required-field defaults. Review every value for your task before running it; it is not a promise of successful collection.
The published schema does not supply an example for these required fields: cookie. Supply them using the reference documentation before execution.
{
"maxResults": 25,
"searchQuery": "software engineer"
}
Download input.example.json and save your reviewed copy as input.json.
| Field | Type | Required | Description |
|---|---|---|---|
searchQuery | string | required | Search keywords for finding people on LinkedIn. Examples: 'software engineer', 'John Smith', 'product manager Google' |
keywords | string | optional | Optional companion to Search Query. When both are set, they are combined with a space. Use this to keep a primary role in Search Query and add modifiers (industry buzzwords, tools) here. |
cookie | string | required | Your LinkedIn session cookie. Accepts either: (1) the li_at value from browser DevTools → Application → Cookies, or (2) full cookies JSON array exported from an extension like EditThisCookie. |
location | string | optional | Filter results by location (city, state, or country). Example: 'San Francisco Bay Area', 'New York', 'United Kingdom' |
currentCompany | string | optional | Filter by current company. Accepts a company name (e.g. 'Google') or a LinkedIn fsd_company URN/numeric ID. URN format produces the strict structured currentCompany filter; plain names are added to keywords. |
pastCompany | string | optional | Filter by past company. Accepts a company name or a LinkedIn fsd_company URN/numeric ID. |
school | string | optional | Filter by school or university attended. Accepts a school name or a LinkedIn fsd_school URN/numeric ID. Example: 'Stanford University', 'MIT', or '12345'. |
firstNameKeyword | string | optional | Filter by first name token. Adds a strict firstName filter to the search. |
lastNameKeyword | string | optional | Filter by last name token. Adds a strict lastName filter to the search. |
titleKeyword | string | optional | Filter by current job title keyword (e.g. 'Director of Engineering', 'CTO'). Different from Industry / Job Function — this is the free-text title. |
serviceCategory | string | optional | Filter by LinkedIn Services Marketplace category (e.g. 'Web Development', 'Marketing Strategy'). |
companyHeadcount | array | optional | Filter by employer company size. A=Self-employed, B=1-10, C=11-50, D=51-200, E=201-500, F=501-1,000, G=1,001-5,000, H=5,001-10,000, I=10,001+. |
followerOf | string | optional | Filter to people who follow a specific company. Accepts an fsd_company URN or numeric company ID. |
geoUrn | string | optional | Precise location filter using a LinkedIn geo URN or numeric geo ID (e.g. '103644278' for the United States). Use this for strict geographic filtering instead of the free-text Location field. |
connectionDegree | string | optional | Filter by connection degree to your account. |
industry | string | optional | Filter results by industry. Applied to both Voyager filters and the HTML search URL. |
seniorityLevel | string | optional | Filter results by seniority level. |
yearsOfExperience | string | optional | Filter results by years of total professional experience. 1=Less than 1 year, 2=1-2 years, 3=3-5 years, 4=6-10 years, 5=11-15 years, 6=16+ years. |
jobFunction | string | optional | Filter results by job function / department. |
openTo | array | optional | Filter people by what they are open to. Select one or more options. HIRING = open to hiring, GETTING_HIRED = open to new jobs, PROVIDING_SERVICES = open to providing freelance/consulting services, JOINING_A_NONPROFIT = open to joining a nonprofit. |
profileLanguages | array | optional | Filter by the language(s) the person's LinkedIn profile is written in. Use ISO 639-1 codes, e.g. ["en", "es", "fr", "de", "zh", "ar", "pt"]. |
contactOf | string | optional | Filter to show people who are connections of the specified LinkedIn member. Provide the member's URN (e.g. 'urn:li:member:123456') or numeric profile ID. |
talksAbout | string | optional | Filter to people who talk about the specified keyword or topic in their profile. This is appended to the search keywords. |
maxResults | integer | optional | Maximum number of profiles to return. |
proxyConfiguration | object | optional | Optional Apify proxy configuration. |
3. Start an Actor run
Set APIFY_TOKEN in your environment. Python 3.10 or newer is sufficient; this recipe uses no third-party packages.
Execution may incur charges. Review current pricing on Apify. The request asks for a 120-second timeout and a charge limit; these settings are subject to Apify’s pricing and do not guarantee an all-inclusive spending cap.
import json
import os
import urllib.request
# Save the schema-derived example as input.json; review and edit it first.
with open("input.json", encoding="utf-8") as stream:
actor_input = json.load(stream)
token = os.environ["APIFY_TOKEN"]
request = urllib.request.Request(
"https://api.apify.com/v2/acts/M7DHH5XpX0Xay3eLy/runs?timeout=120&maxTotalChargeUsd=0.50",
data=json.dumps(actor_input).encode("utf-8"),
headers={"Authorization": "Bearer " + token, "Content-Type": "application/json"},
method="POST",
)
# This starts a potentially billable run. Do not automatically retry this POST.
with urllib.request.urlopen(request, timeout=40) as response:
run = json.load(response)["data"]
print("Run ID:", run["id"])
print("Status:", run["status"])
# Inspect and download results in Apify Console once the run succeeds.
4. Inspect the actual results
Open the run in Apify Console and wait for a successful completion. Use the published output schema to locate results and the dataset schema to understand declared views. Missing or optional record fields must not be treated as guaranteed values.
LinkedIn profiles matching a structured people search, with name, headline, current company, seniority-related badges, and profile URL.
Questions before you run
Which inputs are required?
The published required fields are searchQuery, cookie
What does this guide verify?
The fields, prefills, and schema links are rendered from the published build. This is a usage recipe, not a paid live extraction test. Source availability and collection results can vary.
What if the run request times out?
Check Apify Console before retrying. The first request may already have created a run. Do not automatically repeat a run-creation POST.
Generated from source build CrEkFHlcagPwfg7e7 and its README and schemas. Source changes regenerate this guide; no third-party editorial claims are inferred.