Search, Company Pages And Raw Data
LinkedIn's classic search for people, posts and jobs, the ids its filters take, company pages and their employees, and the raw route for reads.
Everything here reads LinkedIn as the connected account, with Unipile's paths, bodies and answers. The company search itself (category: companies) is on Company Search.
Search People#
curl -sS -X POST "https://direct.lempile.com/api/v1/linkedin/search?account_id=$ACCOUNT_ID&limit=10" \
-H "X-API-KEY: $DIRECT_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "api": "classic", "category": "people", "keywords": "founder", "network_distance": [2], "location": ["105015875"], "company": ["1035"] }'{
"object": "LinkedinSearch",
"items": [
{
"object": "SearchResult",
"type": "PEOPLE",
"id": "ACoAAApeoplesearch01",
"public_identifier": "ada-founder",
"public_profile_url": "https://www.linkedin.com/in/ada-founder",
"profile_url": "https://www.linkedin.com/in/ACoAAApeoplesearch01",
"profile_picture_url": "https://media.licdn.com/dms/image/...",
"profile_picture_url_large": "https://media.licdn.com/dms/image/...",
"member_urn": "urn:li:member:1001",
"name": "Ada Founder",
"network_distance": "DISTANCE_2",
"location": "Paris, Île-de-France, France",
"industry": null,
"headline": "Founder at Example"
}
],
"config": { "params": { "api": "classic", "category": "people", "keywords": "founder", "network_distance": [2], "location": ["105015875"], "company": ["1035"] } },
"paging": { "start": 0, "page_count": 10, "total_count": 1240 },
"cursor": "<cursor>"
}- Filters, as Unipile's:
keywords,industry,location,profile_language,network_distance(1, 2, 3),company(current),past_company,school,service,connections_of,followers_of,open_to(proBono,boardMember) andadvanced_keywords(first_name,last_name,title,company,school). Ids are LinkedIn's (digits), fromGET /linkedin/search/parametersbelow;connections_ofandfollowers_oftake members' provider ids. idis the member's provider id (ACo…), whatGET /users/{identifier},POST /users/inviteandPOST /chatstake.- LinkedIn answers 10 people a call;
limitup to 100 reads up to 10 pages. Thecursorkeeps the filters: send it back alone ({"cursor": "<cursor>"}, or?cursor=). - A company's employees:
{"category": "people", "company": ["1035"]}.
Search Posts#
curl -sS -X POST "https://direct.lempile.com/api/v1/linkedin/search?account_id=$ACCOUNT_ID" \
-H "X-API-KEY: $DIRECT_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "api": "classic", "category": "posts", "keywords": "outbound", "sort_by": "date", "date_posted": "past_week" }'Each item is a SearchResult of type: "POST": the post's id (its activity id, what GET /posts/{post_id}, its comments and reactions take), social_id, share_url, text, date, parsed_datetime, the counters, author, permissions, is_repost (and reposted_by). Filters: sort_by (relevance, date), date_posted (past_day, past_week, past_month), content_type, posted_by (member, company, me, first_connections, people_you_follow), mentioning (member, company), author (industry, company, keywords). As on Unipile, 3 posts by default and 49 at most a page.
Search Jobs#
curl -sS -X POST "https://direct.lempile.com/api/v1/linkedin/search?account_id=$ACCOUNT_ID&limit=25" \
-H "X-API-KEY: $DIRECT_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "api": "classic", "category": "jobs", "keywords": "sales", "region": "105015875", "presence": ["remote"], "date_posted": 7 }'Each item is a SearchResult of type: "JOB" (id, title, location, posted_at, url, promoted, easy_apply, company). Filters: sort_by, date_posted (days), region, location, location_within_area, industry, seniority, function, role, job_type, company, presence, easy_apply, has_verifications, under_10_applicants, in_your_network, fair_chance_employer. benefits, commitments and minimum_salary answer 501 for now. 25 jobs a LinkedIn call, 50 at most a page.
By A LinkedIn Search Address#
Unipile's {"url": "…"} body: a LinkedIn search page's address (people, content, companies or jobs), read as the matching body.
curl -sS -X POST "https://direct.lempile.com/api/v1/linkedin/search?account_id=$ACCOUNT_ID" \
-H "X-API-KEY: $DIRECT_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "url": "https://www.linkedin.com/search/results/people/?keywords=cto&network=%5B%22S%22%5D" }'Sales Navigator and Recruiter (api: "sales_navigator", api: "recruiter", or their addresses) answer 403 errors/feature_not_subscribed: Direct serves LinkedIn's classic API.
Search Parameters#
The ids the filters take, from LinkedIn's own typeahead (one call):
curl -sS "https://direct.lempile.com/api/v1/linkedin/search/parameters?account_id=$ACCOUNT_ID&type=LOCATION&keywords=paris" \
-H "X-API-KEY: $DIRECT_API_KEY"{
"object": "LinkedinSearchParametersList",
"items": [{ "object": "LinkedinSearchParameter", "id": "105015875", "title": "Paris, Île-de-France, France" }],
"paging": { "page_count": 1 }
}type: LOCATION, REGION, PEOPLE, CONNECTIONS (ids are provider ids), COMPANY, SCHOOL, INDUSTRY, JOB_TITLE (the jobs search's role) or SKILL. Other classic types answer 501; Sales Navigator and Recruiter types answer 403 errors/feature_not_subscribed.
A Company Page#
curl -sS "https://direct.lempile.com/api/v1/linkedin/company/example-co?account_id=$ACCOUNT_ID" \
-H "X-API-KEY: $DIRECT_API_KEY"{
"object": "CompanyProfile",
"id": "1035",
"name": "Example Co",
"description": "We make outbound simple.",
"entity_urn": "urn:li:fsd_company:1035",
"public_identifier": "example-co",
"profile_url": "https://www.linkedin.com/company/example-co/",
"tagline": "Grow better",
"followers_count": 5400,
"is_following": true,
"is_employee": false,
"hashtags": [{ "title": "#outbound" }],
"messaging": { "is_enabled": false },
"claimed": true,
"viewer_permissions": { "canReadAdminDashboard": false },
"organization_type": "PRIVATELY_HELD",
"locations": [{ "is_headquarter": true, "country": "US", "city": "Boston", "street": ["1 Main St"], "postalCode": "02110", "area": "MA" }],
"industry": ["Software Development"],
"employee_count": 120,
"employee_count_range": { "from": 51, "to": 200 },
"website": "https://example.com",
"foundation_date": "2015"
}{identifier}: the public identifier, the id, a urn or the page's link. One LinkedIn call.viewer_permissionsare alltruefor the page's admins and allfalseotherwise (LinkedIn's answer names admin only).messaging.is_enabledis alwaysfalse, andinsightsandcrunchbase_fundingaren't answered.- Its employees: search people with
company: ["<id>"](above). Its posts:GET /users/{id}/posts?is_company=true(Posts).
Raw Data (Reads)#
Unipile's raw route, for a LinkedIn read Direct has no route for yet: a GET of one of LinkedIn's API addresses, with the account's own session, paced and counted like every read.
curl -sS -X POST "https://direct.lempile.com/api/v1/linkedin" \
-H "X-API-KEY: $DIRECT_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "account_id": "'"$ACCOUNT_ID"'", "request_url": "https://www.linkedin.com/voyager/api/me" }'{ "object": "LinkedinRawData", "data": { "data": { "plainId": 1 }, "included": [] } }request_urlis onhttps://www.linkedin.com/voyager/api/(or that path);query_paramsare added to it (encoding: falseadds them as given).headersandbodyare ignored.- Any other
method, or anaction=address, answers501: writes go through Direct's own routes, each checked first and tried with?dry_run=true. - Unipile's Sales Navigator and Recruiter routes (
/linkedin/projects,/linkedin/contracts,/linkedin/user/{user_id},/linkedin/recruiter/sessions/…) answer403errors/feature_not_subscribed.
Was this page helpful?