agentleFS
Linked-APILinked-API/linkedin-skills/linkedin/SKILL.md

linkedin

Skill114 starsChanged 6 months agoMITView on GitHub

General-purpose LinkedIn automation – fetch profiles, search people and companies, send messages, manage connections, create posts, and more. Use when the user wants to interact with LinkedIn.

  • Installs packages

30 other projects use a version of this, 2 of them edited.

Adopted by

Most recently taken up by

Used with

Projects with it also use tiktok, instagram and 5 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • 0-shivSkill

    tiktok

    TikTok Ads management skill -- audits campaigns, scores creatives, optimizes Spark Ads, Shop campaigns, targeting, bidding, pixel tracking, and generates reports. CPM 50-70% cheaper than Meta.

    Also in 4 projects that use this

  • refly-aiSkill

    instagram

    Integrate with Instagram for social media. Use when you need to: (1) post content to Instagram, (2) manage media and insights, or (3) automate Instagram publishing workflows.

    Also in 5 projects that use this

  • ReScienceLabSkill

    reddit

    Search and retrieve content from Reddit. Get posts, comments, subreddit info, and user profiles via the public JSON API. Use when user mentions Reddit, a subreddit, or r/ links.

    Also in 7 projects that use this

  • KamalikaPoddarSkill

    competitor-intel

    Invoke this skill when the user wants to run competitor analysis, monitor competitor signals, generate a weekly intel brief, understand what users are saying about competitors, decode competitor job postings or strategic moves, or build a competitor intelligence system. Triggers on: 'competitor analysis', 'what are [competitor] users saying', 'weekly intel brief', 'what signals should I watch', 'what is [competitor] doing', 'analyse these reviews/tweets/job posts', 'what should we do about [competitor move]', or any request to understand and act on competitive landscape signals. Works across any industry — fintech, gaming, streaming, SaaS, e-commerce. Uses five specialist subagents (industry context, user psychology, signal collector, pattern detector, action recommender) routed by an orchestrator.

    Also in 3 projects that use this

  • anshul-garg27Skill

    newsletter

    Create engaging email newsletters with subject lines, sections, and CTAs for Substack, Beehiiv, ConvertKit, or plain email

    Also in 3 projects that use this

  • refly-aiSkill

    youtube

    Integrate with YouTube for video management. Use when you need to: (1) upload videos to YouTube, (2) manage channel content, or (3) retrieve video analytics and insights.

    Also in 4 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

17 rules. 0 are common, 7 are distinctive, and 10 are very specific to this project.

  • 0

    Common

    Most of the 23 edited versions we read keep these.

  • 7

    Distinctive

    This author's own choices. Worth a look.

  • 10

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If linkedin is not available, install it:

    line 12
  2. Distinctive:

    If a command fails with exit code 2 (authentication error), ask the user to set up their account:

    line 20
  3. Very specific:

    Always use --json and -q for machine-readable output:

    line 34
  4. Very specific:

    When using this skill, run every linkedin ...

    line 40
  5. Distinctive:

    Only request additional data when needed – each flag increases execution time.

    line 102
  6. Very specific:

    Use --skill for one exact skill name.

    line 124
  7. Very specific:

    Use repeatable --pattern to select skills matching any of the patterns.

    line 125
  8. Very specific:

    Use --all only when the user wants every skill endorsed.

    line 126
  9. Very specific:

    Read events with an advancing --since – the detectedAt of the newest event you already have – and handle each event once by its id, …

    line 298
  10. Very specific:

    Always pass --since: without it every event of the last 90 days comes back, which can be very large.

    line 305
  11. Very specific:

    Prefer linkedin inbox get --person <url> --type nv to read Sales Navigator messages.

    line 657
  12. Distinctive:

    Check workflow status or wait for completion:

    line 774
  13. Distinctive:

    Read what is new in Linked API.

    line 785
  14. Distinctive:

    Sequential execution: All operations for an account run one at a time.

    line 806
  15. Distinctive:

    Timestamps in UTC: All dates and times are in UTC.

    line 808
  16. Distinctive:

    Single quotes for text arguments: Use single quotes around message text, post text, and comments to avoid shell interpretation issues with …

    line 809
  17. Very specific:

    URL normalization: All LinkedIn URLs in responses are normalized to https://www.linkedin.com/...

    line 811

“Common” is measured: kept by at least 6 in 10 of the 23 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

LinkedIn Skill

You have access to linkedin – a CLI tool for LinkedIn automation. Use it to fetch profiles, search people and companies, send messages, manage connections, create posts, react, comment, and more.

Each command sends a request to Linked API, which runs a real cloud browser to perform the action on LinkedIn. Operations are not instant – expect 30 seconds to several minutes depending on complexity.

If linkedin is not available, install it:

npm install -g @linkedapi/linkedin-cli

Authentication

If a command fails with exit code 2 (authentication error), ask the user to set up their account:

  1. Go to app.linkedapi.io and sign up or log in
  2. Connect their LinkedIn account
  3. Copy the Linked API Token and Identification Token from the dashboard

Once the user provides the tokens, run:

linkedin setup --linked-api-token=TOKEN --identification-token=TOKEN

Global Flags

Always use --json and -q for machine-readable output:

LINKEDAPI_CLIENT=skill:linkedin linkedin <command> --json -q

When using this skill, run every linkedin ... example below with the LINKEDAPI_CLIENT=skill:linkedin prefix so Linked API can attribute usage to the skill.

FlagDescription
--jsonStructured JSON output
--quiet / -qSuppress stderr progress messages
--fields name,url,...Select specific fields in output
--no-colorDisable colors
--account "Name"Use a specific account for this command

List Flags

Flags described below as comma-separated split their value on every comma. When any value contains a comma itself – a location such as Chicago, Illinois, an industry such as Technology, Information and Internet, a company such as Example Co., Ltd. – pass the whole list as a JSON array instead, or the value is silently split into separate filters. The JSON form needs linkedin-cli 1.2.24 or newer (linkedin --version; update with npm install -g @linkedapi/linkedin-cli):

linkedin person search --term "designer" --locations '["Chicago, Illinois","London, United Kingdom"]' --json -q

Output Format

Success:

{"success": true, "data": {"name": "John Doe", "headline": "Engineer"}}

Error:

{"success": false, "error": {"type": "personNotFound", "message": "Person not found"}}

Exit code 0 means the API call succeeded – always check the success field for the action outcome. Non-zero exit codes indicate infrastructure errors:

Exit CodeMeaning
0Success (check success field – action may have returned an error like "person not found")
1General/unexpected error
2Missing or invalid tokens
3Subscription/plan required
4LinkedIn account issue
5Invalid arguments
6Rate limited
7Network error
8Workflow timeout (workflowId returned for recovery)

Commands

Fetch a Person Profile

linkedin person fetch <url> [flags] --json -q

Optional flags to include additional data:

  • --experience – work history
  • --education – education history
  • --skills – skills list
  • --languages – languages
  • --posts – recent posts (with --posts-limit N, --posts-since TIMESTAMP)
  • --comments – recent comments (with --comments-limit N, --comments-since TIMESTAMP)
  • --reactions – recent reactions (with --reactions-limit N, --reactions-since TIMESTAMP)

Only request additional data when needed – each flag increases execution time.

# Basic profile
linkedin person fetch https://www.linkedin.com/in/username --json -q

# With experience and education
linkedin person fetch https://www.linkedin.com/in/username --experience --education --json -q

# With last 5 posts
linkedin person fetch https://www.linkedin.com/in/username --posts --posts-limit 5 --json -q

Endorse a Person's Skills

linkedin person endorse <url> --skill 'Project Management' --json -q
linkedin person endorse <url> --pattern manage --pattern '^scrum$' --json -q
linkedin person endorse <url> --all --json -q

Choose exactly one of --skill, --pattern or --all:

  • Use --skill for one exact skill name; letter case and extra spaces are ignored.
  • Use repeatable --pattern to select skills matching any of the patterns. Patterns use RE2, are case-insensitive and match anywhere in the name. Anchor with ^…$ to match a whole name. Provide 1-20 patterns, each 1-200 characters; lookaround and backreferences are unsupported.
  • Use --all only when the user wants every skill endorsed. It omits the patterns parameter; never send an empty patterns array.

Skill names are in the profile owner's language, regardless of your own LinkedIn language. Fetch the profile with --skills first when you need to discover the names; a German profile may list Projektmanagement rather than Project Management.

Only 1st-degree connections can receive endorsements. An already-endorsed skill stays endorsed and counts as success. Each successful endorsement, including an existing one, counts toward the account's stEndorsements limit. With --pattern or --all, check every item's success and error.type in data: a failed skill does not stop the others, and limitExceeded can affect only part of the result.

Search People

linkedin person search [flags] --json -q
FlagDescription
--termSearch keyword or phrase; required unless --url is given
--urlLinkedIn people search URL (linkedin.com/search/results/people/...), such as an anonymous viewer's searchUrl; overrides --term and the filters
--limitMax results
--first-nameFilter by first name
--last-nameFilter by last name
--positionFilter by job position
--locationsComma-separated locations
--industriesComma-separated industries
--current-companiesComma-separated current company names
--previous-companiesComma-separated previous company names
--schoolsComma-separated school names
--connection-degreesComma-separated connection degrees: 1st, 2nd, 3rd+
linkedin person search --term "product manager" --locations "San Francisco" --json -q
linkedin person search --term "engineer" --current-companies "Google" --limit 20 --json -q
linkedin person search --url "https://www.linkedin.com/search/results/people/?keywords=CTO" --json -q

Fetch a Company

linkedin company fetch <url> [flags] --json -q

Optional flags:

  • --employees – include employees
  • --dms – include decision makers
  • --posts – include company posts

Employee filters (require --employees):

FlagDescription
--employees-limitMax employees to retrieve
--employees-first-nameFilter by first name
--employees-last-nameFilter by last name
--employees-positionFilter by position
--employees-locationsComma-separated locations
--employees-industriesComma-separated industries
--employees-schoolsComma-separated school names
--employees-connection-degreesComma-separated connection degrees: 1st, 2nd, 3rd+
FlagDescription
--dms-limitMax decision makers to retrieve (requires --dms)
--posts-limitMax posts to retrieve (requires --posts)
--posts-sincePosts since ISO timestamp (requires --posts)
# Basic company info
linkedin company fetch https://www.linkedin.com/company/name --json -q

# With employees filtered by position
linkedin company fetch https://www.linkedin.com/company/name --employees --employees-position "Engineer" --json -q

# With decision makers and posts
linkedin company fetch https://www.linkedin.com/company/name --dms --posts --posts-limit 10 --json -q

Search Companies

linkedin company search [flags] --json -q
FlagDescription
--termSearch keyword; required unless --url is given
--urlLinkedIn companies search URL (linkedin.com/search/results/companies/...); overrides --term and the filters
--limitMax results
--sizesComma-separated sizes: 1-10, 11-50, 51-200, 201-500, 501-1000, 1001-5000, 5001-10000, 10001+
--locationsComma-separated locations
--industriesComma-separated industries
linkedin company search --term "fintech" --sizes "11-50,51-200" --json -q

Send a Message

linkedin message send <person-url> '<text>' --json -q

Text up to 1900 characters. Wrap the message in single quotes to avoid shell interpretation issues.

linkedin message send https://www.linkedin.com/in/username 'Hey, loved your latest post!' --json -q

Inbox

To read messages use inbox get. Call message get only when you need a person's earlier history, and never repeat it to check for new messages.

Enable inbox monitoring once per account, before sending messages whose replies you need – it captures only messages that arrive after it is on:

linkedin inbox sync --json -q          # standard inbox
linkedin inbox sync --nv --json -q     # Sales Navigator inbox

New messages from everyone, with an advancing --since:

linkedin inbox get --since 2024-01-15T10:30:00Z --json -q

The whole known conversation with one person, including history loaded by message get:

linkedin inbox get --person https://www.linkedin.com/in/username --json -q

With --person, the output has messages and threads. Each thread has historyComplete: if it is false and you need earlier messages, run message get <person-url> once, then inbox get --person again. A hashed person URL (personHashedUrl from a message) always matches; a public URL matches only once Linked API knows it, so prefer the hashed URL when messages show personPublicUrl: null. Message times are whole minutes: to check for a reply, pass --type of your message and --since a few minutes before it, take the earliest us message in the result (the one you sent, not a later follow-up) and count a them message that is not earlier than it; if your message is not in the result yet, the reply is not known yet.

Get Conversation

linkedin message get <person-url> [--since TIMESTAMP] --json -q

Loads the person's earlier history on the first call, which may take longer; subsequent calls are faster. Prefer linkedin inbox get --person <url> to read messages – use this only when you need history from before inbox monitoring was enabled.

linkedin message get https://www.linkedin.com/in/username --json -q
linkedin message get https://www.linkedin.com/in/username --since 2024-01-15T10:30:00Z --json -q

Signals

These commands need linkedin-cli 1.4.0 or newer, and listAlerts needs 1.4.1 or newer (linkedin --version; update with npm install -g @linkedapi/linkedin-cli).

A signal makes the account watch one thing on LinkedIn on a schedule and record each new item once as an event. When the user wants to keep track of something over time – new posts by a person or company, new posts on a topic, new comments and reactions on a post, new profile viewers, connection changes, Sales Navigator alerts about the leads and accounts in a list – create a signal instead of re-running searches or fetches: a rerun spends limits every time and returns what you have already seen, while a signal reports only what is new.

--typeTarget flagsReports
personPosts--person-urlnew posts by the person
companyPosts--company-urlnew posts by the company page
postSearch--term (repeat for up to 3 phrases), optional filters as in post search (--content-type, --posted-by, --mentioning-members, --mentioning-companies, --author-companies, --author-industries)new posts matching any phrase
postEngagement--post-url, or --my-posts for the account's own postsnew comments and reactions
profileViewersnonenew profile viewers
networknoneaccepted invitations, new connections, received invitations
listAlerts--list-id of one of the account's own Sales Navigator lists (from navigator lists)new Sales Navigator alerts about the list's leads and accounts
linkedin signal create --type personPosts --person-url https://www.linkedin.com/in/username --label lead-1042 --json -q
linkedin signal create --type postSearch --term 'user onboarding' --term 'time to value' --json -q
linkedin signal create --type postEngagement --my-posts --json -q
linkedin signal create --type listAlerts --list-id <list-id> --json -q
linkedin signal list --status active --json -q
linkedin signal pause <signal-id> --json -q     # not checked and spends nothing until resumed
linkedin signal resume <signal-id> --json -q    # its first check reports what appeared while paused
linkedin signal delete <signal-id> --json -q    # checks stop; its events stay available for 90 days

--label is your own identifier (up to 64 characters), returned with the signal and every event it produces. Creating a signal that already exists returns it. A signal's first check records a silent baseline: what is already there is not reported, except that post signals report posts published since the signal was created and listAlerts reports alerts published since then. A stopped signal cannot be resumed – delete it and create it again. signalLimitReached (exit code 5) means the account already has the maximum number of active signals of that type: pause or delete one first.

Read events with an advancing --since – the detectedAt of the newest event you already have – and handle each event once by its id, skipping ids you have already processed:

linkedin signal events --since 2026-10-12T16:40:00.000Z --json -q
linkedin signal events --since 2026-10-12T16:40:00.000Z --signal-id <signal-id> --json -q

Always pass --since: without it every event of the last 90 days comes back, which can be very large. --signal-type and --event-type narrow the result further.

A listAlerts event (alertPublished) carries alert, exactly as navigator alerts returns it, plus subjectUrn and subjectHashedUrl: the lead's or account's urn and hashedUrl as navigator lists leads and navigator lists accounts return them, so match events to list members by those. LinkedIn chooses which activity raises an alert and publishes it hours later, so this is not a record of everything the members do. Watch a list the user built: lists Sales Navigator fills on its own with people the account never saved get only occasional suggested alerts. It needs an active Sales Navigator subscription (otherwise it stops with noSalesNavigator), and very large lists are not supported yet (listTooLarge); a list that is not one of the account's own, or was deleted, stops it with targetNotFound.

What checks spend: network, profileViewers, postEngagement and listAlerts take nothing from account limits; each postSearch check spends 1 of stSearchQueries, so put the wordings of one topic into one signal as several --terms; personPosts and companyPosts open the profile or company page once, then take a few stSearchQueries a day for the whole account and an occasional visit.

Connection Management

Check connection status

linkedin connection status <url> --json -q

Send connection request

linkedin connection send <url> [--note 'text'] [--email user@example.com] --json -q

List connections

linkedin connection list [flags] --json -q
FlagDescription
--limitMax connections to return
--sinceOnly connections made since ISO timestamp (only works when no filter flags are used)
--first-nameFilter by first name
--last-nameFilter by last name
--positionFilter by job position
--locationsComma-separated locations
--industriesComma-separated industries
--current-companiesComma-separated current company names
--previous-companiesComma-separated previous company names
--schoolsComma-separated school names
linkedin connection list --limit 50 --json -q
linkedin connection list --current-companies "Google" --position "Engineer" --json -q
linkedin connection list --since 2024-01-01T00:00:00Z --json -q

List pending outgoing requests

linkedin connection pending --json -q

List incoming connection requests

Invitations that others have sent to you (received requests).

linkedin connection requests --json -q

Accept an incoming request

linkedin connection accept <url> --json -q

Ignore an incoming request

linkedin connection ignore <url> --json -q

Withdraw a pending request

linkedin connection withdraw <url> [--no-unfollow] --json -q

By default, withdrawing also unfollows the person. Use --no-unfollow to keep following.

Remove a connection

linkedin connection remove <url> --json -q

Posts

Fetch a post

linkedin post fetch <url> [flags] --json -q
FlagDescription
--commentsInclude comments
--reactionsInclude reactions
--comments-limitMax comments to retrieve (requires --comments)
--comments-sortSort order: mostRelevant or mostRecent (requires --comments)
--comments-repliesInclude replies to comments (requires --comments)
--reactions-limitMax reactions to retrieve (requires --reactions)
linkedin post fetch https://www.linkedin.com/posts/username_activity-123 --json -q

# With comments sorted by most recent, including replies
linkedin post fetch https://www.linkedin.com/posts/username_activity-123 \
  --comments --comments-sort mostRecent --comments-replies --json -q

Search posts

linkedin post search [flags] --json -q
FlagDescription
--termSearch keyword or phrase, up to 50 characters
--limitMax results to return, up to 100
--from-membersPeople whose posts to keep
--from-companiesCompanies whose posts to keep
--mentioning-membersPeople the post must mention
--mentioning-companiesCompanies the post must mention
--author-companiesCompanies the author works at

Each actor flag is a comma-separated list. An element is name or name:identifier, where the identifier is a URN or LinkedIn URL of that person or company and pins the filter to exactly them. A name alone may match a namesake. When an entry cannot be applied, the action fails with filterNotApplied; correct or remove it rather than retrying.

linkedin post search --term "ai" --from-members "Bill Gates,Example Person:urn:li:member:123456789" --json -q

Create a post

linkedin post create '<text>' [flags] --json -q
FlagDescription
--company-urlPost on behalf of a company page (requires admin access)
--attachmentsAttachment as url:type or url:type:name. Types: image, video, document. Can be specified multiple times.
--mentionOne mention, bound to @[key] in the text. Format below. Can be specified multiple times, up to 20.

Attachment limits: up to 9 images, or 1 video, or 1 document. Cannot mix types.

Mention format — write @[key] in the text, then describe that key with --mention as key:name or key:name:identifier. Everything after the second : is the identifier, so its own colons need no escaping. The identifier is optional and is one of urn:li:member:<id>, urn:li:organization:<id>, a hashed profile URL, or a hashed company URL; without it LinkedIn's first suggestion for name is used, which may not be the entity you meant. Every @[key] must have a matching --mention and vice versa, and keys cannot repeat.

linkedin post create 'Excited to share our latest update!' --json -q

# With a document
linkedin post create 'Our Q4 report' \
  --attachments "https://example.com/report.pdf:document:Q4 Report" --json -q

# Mentioning a person
linkedin post create 'Huge thanks to @[author] for the write-up!' \
  --mention "author:Example Person:urn:li:member:123456789" --json -q

# Post as a company
linkedin post create 'Company announcement' \
  --company-url https://www.linkedin.com/company/name --json -q

Repost a post

linkedin post repost <url> [flags] --json -q
FlagDescription
--textYour own commentary (up to 3000 characters). Without it the post is reposted as is.
--mentionOne mention, bound to @[key] in --text. Same format as for post create. Can be specified multiple times, up to 20.

The repost's own postUrl and postUrn come back, not those of the post you reposted. They are empty when the repost was published but LinkedIn did not return its address — do not retry, the repost is already live.

alreadyReposted is returned only when LinkedIn refuses an instant repost (one without --text). LinkedIn does not always refuse a repeat repost: a repost of your own post, or a repost with commentary, can be published again. Keep track of what you have already reposted instead of relying on this error.

linkedin post repost https://www.linkedin.com/posts/username_activity-123 --json -q

# With commentary
linkedin post repost urn:li:activity:1234567890123456789 \
  --text 'Worth reading, especially the part on onboarding.' --json -q

React to a post

linkedin post react <url> --type <reaction> [--company-url <url>] --json -q

Reaction types: like, love, support, celebrate, insightful, funny.

linkedin post react https://www.linkedin.com/posts/username_activity-123 --type like --json -q

# React on behalf of a company
linkedin post react https://www.linkedin.com/posts/username_activity-123 --type celebrate \
  --company-url https://www.linkedin.com/company/name --json -q

Comment on a post

linkedin post comment <url> '<text>' [--company-url <url>] --json -q

Text up to 1000 characters.

linkedin post comment https://www.linkedin.com/posts/username_activity-123 'Great insights!' --json -q

# Comment on behalf of a company
linkedin post comment https://www.linkedin.com/posts/username_activity-123 'Well said!' \
  --company-url https://www.linkedin.com/company/name --json -q

Statistics

# Social Selling Index
linkedin stats ssi --json -q

# Performance analytics (profile views, post impressions, search appearances)
linkedin stats performance --json -q

# API usage for a date range
linkedin stats usage --start 2024-01-01T00:00:00Z --end 2024-01-31T00:00:00Z --json -q

# Who viewed your profile
linkedin stats viewers --limit 50 --json -q

# Only views since a moment
linkedin stats viewers --since 2026-08-01T00:00:00Z --json -q

Each viewer is either identified — carrying name, publicUrl and urn (a member URN, null when LinkedIn does not expose it) — or anonymous, carrying only the description LinkedIn showed and a searchUrl you can pass to linkedin person search --url (linkedin-cli 1.2.24 or newer) to look for them. Viewers come newest first, and viewedAt is an estimate derived from the relative age LinkedIn displays.

Sales Navigator

Requires a LinkedIn Sales Navigator subscription. Person and company lookups accept public or hashed LinkedIn URLs.

Fetch person

linkedin navigator person fetch <url> --json -q

Search people

linkedin navigator person search [flags] --json -q
FlagDescription
--termSearch keyword or phrase; required unless --url is given
--urlSales Navigator people search URL (linkedin.com/sales/search/people/...); overrides --term and the filters
--limitMax results
--first-nameFilter by first name
--last-nameFilter by last name
--positionFilter by job position
--locationsComma-separated locations
--industriesComma-separated industries
--current-companiesComma-separated current company names
--previous-companiesComma-separated previous company names
--schoolsComma-separated school names
--years-of-experienceComma-separated ranges: lessThanOne, oneToTwo, threeToFive, sixToTen, moreThanTen
--connection-degreesComma-separated connection degrees: 1st, 2nd, 3rd+, groupMembers
linkedin navigator person search --term "VP Marketing" --locations "United States" --json -q
linkedin navigator person search --term "CEO" --years-of-experience "moreThanTen" --json -q

Fetch company

linkedin navigator company fetch <url> [flags] --json -q

Optional flags:

  • --employees – include employees
  • --dms – include decision makers

Employee filters (require --employees):

FlagDescription
--employees-limitMax employees to retrieve
--employees-first-nameFilter by first name
--employees-last-nameFilter by last name
--employees-positionsComma-separated positions
--employees-locationsComma-separated locations
--employees-industriesComma-separated industries
--employees-schoolsComma-separated school names
--employees-years-of-experienceComma-separated experience ranges
--employees-connection-degreesComma-separated connection degrees: 1st, 2nd, 3rd+, groupMembers
--dms-limitMax decision makers to retrieve (requires --dms)
linkedin navigator company fetch https://www.linkedin.com/sales/company/97ural --employees --dms --json -q
linkedin navigator company fetch https://www.linkedin.com/sales/company/97ural \
  --employees --employees-positions "Engineer,Designer" --employees-locations "Europe" --json -q

Search companies

linkedin navigator company search [flags] --json -q
FlagDescription
--termSearch keyword; required unless --url is given
--urlSales Navigator companies search URL (linkedin.com/sales/search/company/...); overrides --term and the filters
--limitMax results
--sizesComma-separated sizes: 1-10, 11-50, 51-200, 201-500, 501-1000, 1001-5000, 5001-10000, 10001+
--locationsComma-separated locations
--industriesComma-separated industries
--revenue-minMin annual revenue in M USD: 0, 0.5, 1, 2.5, 5, 10, 20, 50, 100, 500, 1000
--revenue-maxMax annual revenue in M USD: 0.5, 1, 2.5, 5, 10, 20, 50, 100, 500, 1000, 1000+
linkedin navigator company search --term "fintech" --sizes "11-50,51-200" --json -q
linkedin navigator company search --term "logistics" --revenue-min 10 --revenue-max 100 --locations "United States" --json -q

Send InMail

linkedin navigator message send <person-url> '<text>' --subject '<subject>' --json -q

Text up to 1900 characters. Subject up to 80 characters.

linkedin navigator message send https://www.linkedin.com/in/username \
  'Would love to chat about API integrations' --subject 'Partnership Opportunity' --json -q

Get Sales Navigator conversation

linkedin navigator message get <person-url> [--since TIMESTAMP] --json -q

Prefer linkedin inbox get --person <url> --type nv to read Sales Navigator messages; use this only when you need the person's earlier history.

Sales Navigator saved leads, accounts, lists and searches

These commands need linkedin-cli 1.2.26 or newer (linkedin --version; update with npm install -g @linkedapi/linkedin-cli).

Plus plan required. IDs are strings.

linkedin navigator alerts --limit 50 --sort latest --json -q
linkedin navigator alerts --list-id <list-id> --json -q
linkedin navigator alerts --subject '<hashed-url-or-subject-urn>' --subject '<another-identity>' --json -q
linkedin navigator person save <url> [--list-id <list-id>] --json -q
linkedin navigator person unsave <url> --json -q
linkedin navigator company save <url> [--list-id <list-id>] --json -q
linkedin navigator company unsave <url> --json -q
linkedin navigator lists --type <lead|account> --json -q
linkedin navigator lists create --type <lead|account> --name 'Prospects' [--description 'Notes'] --json -q
linkedin navigator lists delete <list-id> --json -q
linkedin navigator lists leads <list-id> [--limit 25] --json -q
linkedin navigator lists accounts <list-id> [--limit 25] --json -q
linkedin navigator person remove-from-list <url> --list-id <list-id> --json -q
linkedin navigator company remove-from-list <url> --list-id <list-id> --json -q
linkedin navigator lists rename <list-id> --name 'New name' --json -q
linkedin navigator saved-searches --type <lead|account> --json -q
linkedin navigator saved-searches create '<search-url>' --type <lead|account> [--name 'Heads of Sales'] --json -q
linkedin navigator saved-searches delete <saved-search-id> --json -q

Alerts also accept --category lead|account, --types (comma-separated or a JSON array), --since (inclusive ISO timestamp), and --exclude-suggested. --subject is repeatable: each occurrence is exactly one recognised hashed LinkedIn URL, Sales Navigator subject URN, or urn:li:member:<id> / urn:li:organization:<id> as navigator lists leads and navigator lists accounts return it in urn (these two forms need linkedin-cli 1.4.1 or newer). These identities can contain commas, so never split them or pass a JSON array. An empty subject list is unrestricted. Subjects are ORed; the other filters are ANDed. Public URL handles cannot identify subjects for this filter. --list-id requires --sort latest.

List-member limits are 1–1000 (default 25). Removing membership keeps the subject saved and in other lists; removing an absent membership succeeds. Unsave removes the saved state and all memberships. Deleting a list keeps its members saved. Rename trims its name (1–75 characters, no line breaks), returns listAlreadyExists for a duplicate and listNotRenamable for system lists. Saved searches require a copied /sales/search/people (lead) or /sales/search/company (account) URL matching --type; --name (trimmed, 1–256 characters, one line) renames the new search; without it Sales Navigator names it, e.g. by its keywords. A name already used by a saved search of the same type returns savedSearchAlreadyExists, a full catalog savedSearchLimitReached; savedSearchRenameUnconfirmed means the search was saved under Sales Navigator's name and kept. Deleted or foreign IDs return savedSearchNotFound.

Recruiter Lite

Requires a LinkedIn Recruiter Lite seat and Linked API's Plus plan. These commands need linkedin-cli 1.3.0 or newer (linkedin --version; update with npm install -g @linkedapi/linkedin-cli). Keep only one Recruiter session open for the account. Use Recruiter profile URLs (https://www.linkedin.com/talent/profile/…), never public /in/… URLs. Project IDs are strings.

linkedin recruiter person search [--term <text>] [--url <search-url>] [--limit 25] [filters] --json -q
linkedin recruiter person fetch <url> [--no-basic-info] [--recruiting-activity] --json -q
linkedin recruiter projects [--limit 25] --json -q
linkedin recruiter projects candidates <project-id> [--stage <stage>] [--limit 25] --json -q
linkedin recruiter person save <url> --project-id <project-id> --json -q
linkedin recruiter projects create --name "Project name" --json -q
linkedin recruiter projects rename <project-id> --name "New name" [--description "Description"] --json -q
linkedin recruiter projects archive <project-id> --json -q
linkedin recruiter message send <person-url> "Text" --subject "Subject" --json -q
linkedin recruiter message send --thread-id <thread-id> "Reply text" --json -q
linkedin inbox sync --rc --json -q
linkedin inbox get --type rc --json -q
linkedin inbox get --type rc --person <recruiter-url> --json -q

Search accepts a nonblank --term, filters alone, or --url copied from a Recruiter search (https://www.linkedin.com/talent/search?…). --url is exclusive with --term and every filter flag. A scope selector or false checkbox alone is not search criteria. Search, project and candidate limits are 1–1000, default 25. Candidate stage is uncontacted, contacted, replied or archived; omit it to read all stages. Fetch reads basic information by default; --no-basic-info turns it off (--basic-info turns it on). Recruiting activity defaults off; use --recruiting-activity or --no-recruiting-activity.

Filter lists are comma-separated or a JSON array of strings when a value contains commas, following List Flags above.

FlagFilter / values
--job-titles <list>jobTitles — String list
--job-titles-scope <scope>jobTitlesScope — Title/company scope below
--locations <list>locations — String list
--locations-scope <scope>locationsScope — Location scope below
--postal-code <code> and --postal-code-radius-miles <miles>postalCode — code required when postal filter is present; radius optional: 1, 5, 10, 25, 50, 100, 200
--skills <list>skills — String list
--has-passed-skill-assessment / --no-has-passed-skill-assessmenthasPassedSkillAssessment — Boolean
--companies <list>companies — String list
--companies-scope <scope>companiesScope — Title/company scope below
--current-companies <list>currentCompanies — String list
--past-companies <list>pastCompanies — String list; intentionally pastCompanies, not NV's previousCompanies
--company-sizes <list>companySizes — Company-size enum list below
--schools <list>schools — String list
--graduation-years-from <year>, --graduation-years-to <year>graduationYears — Integer range, 1900–2100; either bound or both
--industries <list>industries — String list
--job-functions <list>jobFunctions — Job-function enum list below
--seniority <list>seniority — Seniority enum list below
--years-of-experience-from <years>, --years-of-experience-to <years>yearsOfExperience — Integer range, 0–30; either bound or both; zero is preserved
--first-names <list>firstNames — String list; plural unlike NV's scalar firstName
--last-names <list>lastNames — String list; plural unlike NV's scalar lastName
--profile-languages <list>profileLanguages — LinkedIn language codes, e.g. en, es, in (Indonesian), _o (Other); never language names
--recently-joined <list>recentlyJoined — Recently-joined enum list below
--network-relationships <list>networkRelationships — 1st, 2nd, groupMembers, 3rd+
--is-military-veteran / --no-is-military-veteranisMilitaryVeteran — Boolean
--groups <list>groups — String list
--recruiting-activity-type <type>, --recruiting-activity-period <period>recruitingActivity — Type required when activity filter is present; period optional; enums below
--projects <list>projects — Project names, not project IDs
--notes <list>notes — String list
--hide-previously-viewed / --no-hide-previously-viewedhidePreviouslyViewed — Boolean

Title/company scopes: currentOrPast, current, pastNotCurrent, past. Location scopes: current, currentOrOpenToRelocate, openToRelocateOnly. Company sizes: selfEmployed, 1-10, 11-50, 51-200, 201-500, 501-1000, 1001-5000, 5001-10000, 10001+. Seniority: unpaid, training, entry, senior, manager, director, vp, cxo, partner, owner. Recently joined: 1day, 2to7days, 8to14days, 15to30days, 1to3months. Recruiting activity types: messages, notes, projects, resumes, reviews; periods: anytime, pastDay, pastWeek, pastTwoWeeks, pastThreeMonths, pastSixMonths, pastYear, pastTwoYears. Job functions use the exact choices shown by linkedin recruiter person search --help.

Boolean filter flags accept --no-… to leave the checkbox off; this is not an inverse filter. Ranges accept either bound or both and require from <= to; preserve 0 years of experience. A radius needs --postal-code; an activity period needs --recruiting-activity-type.

Project names are 1–100 characters on one line. Description allows up to 2000 characters; omit it to leave unchanged. Create sets only the name. Creation is not idempotent: after a failure, check your projects before creating again (a duplicate can only be archived). Archive keeps the project rather than deleting it.

New InMail requires a person URL, subject (1–200 characters, one line), and text (1–1900 characters). A reply uses --thread-id and text only: no person URL and no subject. Paid InMail is disabled by default. --allow-paid-credit explicitly enables it; a paid InMail credit is spent only when this flag is true. Turn on --allow-paid-credit only when the user has explicitly approved spending a paid InMail credit on this message; on inMailCreditRequired, ask the user instead of retrying with --allow-paid-credit on. Never retry a send automatically. After an unexpectedError, check the conversation before sending again.

Enable Recruiter inbox monitoring once with inbox sync --rc (exclusive with --nv). Only messages arriving after monitoring is enabled are captured. Use inbox get --type rc with an advancing --since. Recruiter messages identify the person with personRecruiterUrl; personHashedUrl, personUrn and deprecated personUrl are null. personRecruiterUrl is nullable on other types. A Recruiter profile URL works with --person. Omitting --type returns all inbox types.

For rc.doForPeople, use linkedin workflow run with a custom workflow; it has no dedicated command.

Custom Workflows

Execute a custom workflow definition from a file, stdin, or inline:

# From file
linkedin workflow run --file workflow.json --json -q

# From stdin
cat workflow.json | linkedin workflow run --json -q

# Inline
echo '{"actions":[...]}' | linkedin workflow run --json -q

Check workflow status or wait for completion:

linkedin workflow status <id> --json -q
linkedin workflow status <id> --wait --json -q

See Building Workflows for the workflow JSON schema.

Changelog

Read what is new in Linked API. Check it before telling the user that something is not supported yet – the capability may have shipped recently. No authentication is needed:

linkedin changelog --json -q                       # Every release, newest first
linkedin changelog --since 2026-10-01 --json -q    # Releases from that week on

The JSON is the changelog itself, not the usual success/data envelope: entries holds releases, each with a date (the Monday of its week) and items with title, body and docs (a path on https://linkedapi.io). A release counts as shipped at the end of its week, so --since in the middle of a week still returns that week's release – deduplicate by date. A malformed --since exits with code 5 and the server's message.

Account Management

linkedin account list                            # List accounts (* = active)
linkedin account switch "Name"                   # Switch active account
linkedin account rename "Name" --name "New Name" # Rename account
linkedin reset                                   # Remove active account
linkedin reset --all                             # Remove all accounts

Important Behavior

  • Sequential execution. All operations for an account run one at a time. Multiple requests queue up.
  • Not instant. A real browser navigates LinkedIn – expect 30 seconds to several minutes per operation.
  • Timestamps in UTC. All dates and times are in UTC.
  • Single quotes for text arguments. Use single quotes around message text, post text, and comments to avoid shell interpretation issues with special characters.
  • Action limits. Per-account limits are configurable on the platform. A limitExceeded error means the limit was reached.
  • URL normalization. All LinkedIn URLs in responses are normalized to https://www.linkedin.com/... format without trailing slashes.
  • Null fields. Fields that are unavailable are returned as null or [], not omitted.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.