SkillMachine
All skills

LinkedIn Data Fetcher

Data & Research apify

Downloads LinkedIn profile, post, and company data to a dataset via Apify.

Live output preview

A plan is required to view this content

Choose a plan to access input format, sample outputs, and live previews.

View Plans →

About the skill

/linkedin-apify-fetcher — Library Skill: LinkedIn Data Fetcher (Read-Only)

Wraps HarvestAPI's 5 LinkedIn actors behind a standard agent-facing interface. No account cookie is required, and the user's LinkedIn account is not at risk.

⚠️ This skill only reads. Write operations such as sending DMs, connection requests, or writing comments require a separate skill (e.g. a linkedin-outreach-sender Phantombuster/Expandi wrapper); Apify is weak in that area.

How It's Called

Skill tool: linkedin-apify-fetcher
Input: {
  mode: "profile" | "profile_posts" | "profile_search" | "post_search" | "company_employees",
  query: <varies by mode, see below>,
  max_items?: <int, default 25>,
  // mode-specific optional parameters (see below)
  output_path?: <abs path>
}

Mode Details

Mode profile — Person profile + contact info

Actor: $APIFY_LINKEDIN_PROFILE_ACTOR (default: harvestapi/linkedin-profile-scraper) Price: $4/1K profiles (profile only) · $10/1K (with email search)

query: {
  urls?: ["https://www.linkedin.com/in/handle/", ...],
  publicIdentifiers?: ["handle1", "handle2"],     // the last segment of the URL
  profileIds?: ["..."]
}
options: {
  scraper_mode?: "short" | "full" | "email"       // default "full"
}

Apify input mapping:

{
  "profileScraperMode": "Profile details no email ($4 per 1k)",
  "urls": ["..."],
  "publicIdentifiers": ["..."]
}

Email mode: "Profile details + email search ($10 per 1k)".

Mode profile_posts — Posts of specific people

Actor: $APIFY_LINKEDIN_PROFILE_POSTS_ACTOR (default: harvestapi/linkedin-profile-posts) Price: $1.50/1K posts

query: {
  target_urls: ["https://www.linkedin.com/in/handle/", ...]   // required, 1-6 in parallel
}
options: {
  max_posts?: <int, default 20>,
  posted_limit?: "any" | "1h" | "24h" | "week" | "month" | "3months" | "6months" | "year",  // ⚠️ actor values — NO "past-" prefix (verified 2026-06-14)
  include_quote_posts?: <bool, default true>,
  include_reposts?: <bool, default false>,
  scrape_reactions?: <bool, default false>,
  max_reactions?: <int, default 0>,
  scrape_comments?: <bool, default false>,
  max_comments?: <int, default 0>
}

Apify input mapping:

{
  "targetUrls": ["..."],
  "maxPosts": 20,
  "postedLimit": "week",
  "includeQuotePosts": true,
  "includeReposts": false,
  "scrapeReactions": false,
  "scrapeComments": false
}

Mode profile_search — Filtered person search

Actor: $APIFY_LINKEDIN_PROFILE_SEARCH_ACTOR (default: harvestapi/linkedin-profile-search)

query: {
  search_query?: <string>,                         // fuzzy search
  locations?: ["Istanbul, Turkey", "Turkey"],
  current_companies?: ["Trendyol", "Hepsiburada"],
  past_companies?: [...],
  current_job_titles?: ["CEO", "Founder"],
  industries?: [<industryId>, ...],
  recently_changed_jobs?: <bool>,
  recently_posted?: <bool>,
  first_names?: [...],
  last_names?: [...]
}
options: {
  max_items?: <int, default 25>,
  scraper_mode?: "short" | "full" | "email"        // default "short" (cheap)
}

Apify input mapping → passes directly to the searchQuery, locations, currentCompanies, currentJobTitles, industryIds fields in the schema.

Mode post_search — Keyword post search (viral detection)

Actor: $APIFY_LINKEDIN_POST_SEARCH_ACTOR (default: harvestapi/linkedin-post-search)

query: {
  search_queries: ["AI startup", "yapay zeka KOBİ"],   // required
  author_urls?: [...],                                  // from specific authors
  authors_companies?: [...],
  content_type?: "any" | "videos" | "images" | "documents" | "articles",
  author_keywords?: <string>
}
options: {
  max_posts?: <int, default 25>,
  posted_limit?: "any" | "1h" | "24h" | "week" | "month" | "3months" | "6months" | "year",  // ⚠️ actor values — NO "past-" prefix
  sort_by?: "relevance" | "date_posted",
  scrape_reactions?: <bool>,
  scrape_comments?: <bool>
}

Apify input mapping → searchQueries, maxPosts, sortBy, authorUrls, contentType.

Mode company_employees — Company employees

Actor: $APIFY_LINKEDIN_COMPANY_EMPLOYEES_ACTOR (default: harvestapi/linkedin-company-employees)

query: {
  companies: ["Trendyol", "https://www.linkedin.com/company/getir/"],   // required
  search_query?: <fuzzy>,
  job_titles?: ["Engineer", "Product Manager"],
  locations?: [...],
  industries?: [...]
}
options: {
  max_items?: <int, default 25>,
  max_items_per_company?: <int, default 25>,
  scraper_mode?: "short" | "full" | "email"
}

Credential & Prerequisites

set -a; source ~/.claude/.env; set +a
[ -z "$APIFY_API_TOKEN" ] && { echo "FAIL: APIFY_API_TOKEN missing"; exit 1; }
which apify || brew install apify-cli
[ -f ~/.apify/auth.json ] || apify login -t "$APIFY_API_TOKEN"

Flow

1. Input Validation

  • mode required, must be in the list
  • Mode-specific required fields:
    • profile → ≥1 of urls/publicIdentifiers/profileIds
    • profile_posts → target_urls (≥1)
    • post_search → search_queries (≥1)
    • company_employees → companies (≥1)
  • max_items clamped to 1-1000

2. Actor Selection (env-driven)

case "$mode" in
  profile)             ACTOR="$APIFY_LINKEDIN_PROFILE_ACTOR" ;;
  profile_posts)       ACTOR="$APIFY_LINKEDIN_PROFILE_POSTS_ACTOR" ;;
  profile_search)      ACTOR="$APIFY_LINKEDIN_PROFILE_SEARCH_ACTOR" ;;
  post_search)         ACTOR="$APIFY_LINKEDIN_POST_SEARCH_ACTOR" ;;
  company_employees)   ACTOR="$APIFY_LINKEDIN_COMPANY_EMPLOYEES_ACTOR" ;;
esac

3. Payload Build

Generate the input JSON per mode. scraper_modeprofileScraperMode mapping:

Skill inputApify input string
"short""Short ($2 per 1k)"
"full""Profile details no email ($4 per 1k)"
"email""Profile details + email search ($10 per 1k)"

4. Call (file-based, hung-pipe-safe)

INPUT_FILE=$(mktemp -t apify-linkedin-in.XXXXXX.json)
OUTPUT_FILE=${output_path:-$(mktemp -t apify-linkedin-out.X

How do I use this skill?

You don't "run" a skill — after installing it you just tell the agent your task (e.g. ask for the relevant job), and the skill kicks in by itself when its description matches.

Upload the linkedin-apify-fetcher.zip you downloaded as-is — no packaging needed, the format is already correct (folder at root).

  1. Open Settings → Customize → Skills
  2. Upload → select the linkedin-apify-fetcher.zip you downloaded
  3. Claude reads SKILL.md; the name + description appear. Ready ✅

Scripts run in Anthropic's code-execution environment (sandbox) — not on your machine.