linkedin-relay-mcp 3.13.0 → 3.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: linkedin-relay
3
- description: Research LinkedIn from the user's own account — find people by company, past company, school, place, title, degree or whose connections they are, search companies, hunt jobs with every filter LinkedIn has and collect their apply links, read profiles, read the chronological feed — and, through the lnrelay CLI, post (text, image or video), comment, reply, react, delete and edit the user's own profile (headline, About, roles, skills) under the approval mode the owner chose. Use when finding or evaluating people (who works or worked somewhere, alumni, people in a role or a city, someone's connections), companies, roles or job openings on LinkedIn, when the user wants job listings or application links, when reading what the user's network is posting, or when the user asks to post, engage or update their profile on LinkedIn. Not for messaging, connection requests or applying to jobs, which do not exist.
3
+ description: Research LinkedIn from the user's own account — find people by company, past company, school, place, title, degree or whose connections they are, search posts, companies, groups, events, courses, products, services and schools, hunt jobs with every filter LinkedIn has and collect their apply links, read profiles, read the chronological feed — and, through the lnrelay CLI, post (text, image or video), comment, reply, react, delete and edit the user's own profile (headline, About, roles, skills) under the approval mode the owner chose. Use when finding or evaluating people (who works or worked somewhere, alumni, people in a role or a city, someone's connections), companies, groups, events, courses, posts on a topic, roles or job openings on LinkedIn, when the user wants job listings or application links, when reading what the user's network is posting, when the user wants to read their LinkedIn messages or draft replies to them, or when the user asks to post, engage or update their profile on LinkedIn. Cannot send messages, connect, or apply to jobs: those do not exist.
4
4
  ---
5
5
 
6
6
  # linkedin-relay
@@ -12,8 +12,8 @@ in the request path.
12
12
  ## Three things to know before you call anything
13
13
 
14
14
  1. **Every call spends a budget that cannot be topped up.** Caps are deliberately low (30 profile
15
- reads a day, 25 searches, 350 requests total; job hunting has its own 150 job searches and 60
16
- job reads) because LinkedIn restricts accounts for *read*
15
+ reads a day, 25 search calls shared by `people`, `search` (every kind) and name lookups, 350
16
+ requests total; job hunting has its own 150 job searches and 60 job reads) because LinkedIn restricts accounts for *read*
17
17
  velocity alone — several documented restrictions involved no automation and no writes, just fast
18
18
  browsing. Check `meta.budget.remaining`; when it's low, tell the user and stop rather than
19
19
  spending the rest.
@@ -30,8 +30,10 @@ in the request path.
30
30
  ## The funnel
31
31
 
32
32
  ```
33
- search cheap — cast wide, rank on the returned headline/location
34
- ↓ pick 2-3 finalists from the search rows alone, not by reading each one
33
+ people 1 call / 50 — find people with filters (company, school, place, degree, …)
34
+ jobs 1 call / 100 — find jobs with filters; `job` reads finalists, 100 a call
35
+ search 1 call / 50 — posts, companies, groups, events, courses, products, services, schools
36
+ ↓ pick 2-3 finalists from the rows alone, not by reading each one
35
37
  profile mid — deep-read ONLY the finalists
36
38
  feed mid — what the user's network is posting right now
37
39
  ↓ feed rows carry likes/comments counts — rank on those before reading a thread
@@ -41,7 +43,7 @@ whoami cheap — who we are authenticated as
41
43
  risk / budget free — check standing BEFORE spending
42
44
  ```
43
45
 
44
- Search rows already carry name, headline, location and URL. **Rank on those.** Calling `profile` on
46
+ People and search rows already carry name, headline, location and URL. **Rank on those.** Calling `profile` on
45
47
  every search result is how a day's budget disappears in one request.
46
48
 
47
49
  ## Finding people — the recipe
@@ -75,6 +77,9 @@ From a shell: `lnrelay people "engineering manager" "head of engineering" --comp
75
77
  "who does A know" is `connectionOf` with A's `id`. Keywords match anywhere on a profile.
76
78
  - **`title` is free text against the current title**; `companyText`/`schoolText` are free text too,
77
79
  for when there is no single organisation to name.
80
+ - **Budget:** people searches and name lookups spend the general search budget, 25 calls a day.
81
+ A deep query of 1000 people is 20 of them, so ask for the depth you need (`limit`), not the most
82
+ LinkedIn serves; check `budget` before a big run.
78
83
  - **LinkedIn pages at most 1000 people per query.** `meta.servedLimit` means it claimed more: split
79
84
  the query (by location, by company) rather than reporting the 1000 as everyone.
80
85
  - **Not everyone is named.** LinkedIn may return people outside the user's network as
@@ -126,18 +131,51 @@ and `lnrelay job 4479248573 4475225930 4476083905`.
126
131
 
127
132
  ## Commands
128
133
 
129
- ### `search` — cheap. The net.
130
- ```
131
- search kind:people|companies query:"<terms>" [limit:1-25] (people with filters: `people`; jobs: `jobs`)
132
- ```
133
- Returns `{items, meta}`. Each item: `name`, `headline`, `location`, `url`, `urn`.
134
-
135
- `meta.claimedCount` is LinkedIn's total for the query (often millions) — it is **not** how many you
136
- got. `meta.state` is always `unknown` here: this is one page of many and we never claim exhaustion.
137
-
138
- Out-of-network people come back as `name: "LinkedIn Member"` with a `/headless` URL. That is real
139
- LinkedIn behaviour, not a bug — LinkedIn will not name them to this account. Say so rather than
140
- presenting it as a data problem.
134
+ ### `search` — everything else in the search box: posts, companies, groups, events, courses, products, services, schools
135
+ ```
136
+ search kind:posts|companies|groups|events|courses|products|services|schools
137
+ keywords:"<terms>" | ["<terms>", …] [filter:["key=v1,v2"]] [limit:N per keyword set] [start:N] [compact]
138
+ companies, services: [location:"<place>"] [network:[1st|2nd|3rd+]] companies: [industry:[ids]]
139
+ posts: [sort:recent|relevant] [posted:24h|week|month] [type:[videos|images|jobs|live|articles|documents]]
140
+ [postedBy:[1st|me]] [from:[profile ids]] [mentions:[profile ids]] [fromCompany:["<name|id>"]]
141
+ [mentionsCompany:["<name|id>"]] [authorCompany:["<name|id>"]] [authorIndustry:[ids]] [authorTitle:"<text>"]
142
+ ```
143
+ CLI: `lnrelay search <kind> "<terms>" ["<more>" …] [flags]`; `lnrelay search people|jobs …` hands over to
144
+ `people` and `jobs` with all their flags. One call returns 50 results (posts: 20); several keyword
145
+ sets merge by id, with `matched`, as for `people`.
146
+
147
+ Rows other than posts are `id`, `name`, `subtitle`, `detail`, `summary`, `url`, in LinkedIn's own
148
+ lines; what each line holds depends on the kind:
149
+
150
+ | kind | `subtitle` | `detail` | `id` |
151
+ |---|---|---|---|
152
+ | companies | industry • HQ | followers | company id (`people company:[id]` takes it) |
153
+ | groups | members | — | group id |
154
+ | events | when | where • organiser | event id |
155
+ | courses | length | instructor • released | course id |
156
+ | products | category by vendor | — | product page id |
157
+ | services | the provider's headline | place | the provider's profile id |
158
+ | schools | place | students and alumni | school id (`people school:[id]` takes it) |
159
+
160
+ **Posts** rows: `id` (the post's urn — `post` reads its comments), `url`, `author`, `authorHeadline`
161
+ (people only), `authorUrl` (a profile or a company page), `posted` (as LinkedIn shows it, in the user's
162
+ LinkedIn language: "5h", or "5 órája" in Hungarian), `text`, `reactions`, `comments`, `reposts`.
163
+ - Every `search` call, name lookup included, spends the general search budget (25 a day, shared
164
+ with `people`); ask for the depth you need.
165
+ - A posts call is heavy (about half a megabyte a post on LinkedIn's side), so ask for the depth you
166
+ need. Posts come in LinkedIn's ranking unless `sort:"recent"`.
167
+ - `fromCompany` is the company's own posts; `authorCompany` is posts by people who work there.
168
+ - A group post may come back with no author or counts: LinkedIn keys those differently.
169
+ - Most other filters for a kind (company size, course level, product category, …) go in raw
170
+ `filter`, with the keys and ids `search_filters` lists for that kind.
171
+
172
+ ### `search-filters` — 1 search call. A kind's knobs, with ids.
173
+ ```
174
+ search_filters kind:companies|groups|events|courses|products|services|schools [keywords] [location]
175
+ ```
176
+ Every filter that kind has for the query, with option ids and live counts. Companies, for example:
177
+ `companyHqGeo`, `industryCompanyVertical`, `companySize` (B = 1-10 employees … ), `hasJobs`, `network`.
178
+ Groups, events and schools have none.
141
179
 
142
180
  ### `people` — 1 search call per 50 people. People search with every filter.
143
181
  ```
@@ -310,6 +348,38 @@ experience
310
348
  Each role on their profile with its `positionId` and title. The id is what `lnrelay role edit` and
311
349
  `lnrelay role remove` take.
312
350
 
351
+ ### `inbox` — 1 page call per 20 conversations. The user's messages.
352
+ ```
353
+ inbox [folder:inbox|primary|other|archive|requests|spam] [unread] [limit:N] [compact]
354
+ ```
355
+ CLI: `lnrelay inbox [--folder archive] [--unread] [--limit N] [--compact]`. Each conversation: `id`,
356
+ `url` (the thread), `with` (each person or organisation: `name`, `kind`, `headline`, `degree`, `url`),
357
+ `unread`, `lastActivity`, `last` (`from`, `fromMe`, `at`, `text`, `sponsored`), `folders`, `inmail`.
358
+ `meta.unread` counts conversations with unread messages. `inbox` is LinkedIn's Inbox folder; much
359
+ of a mailbox may sit in `archive` or `other`, so look there before saying there is nothing.
360
+
361
+ ### `messages` — 1 page call. One conversation.
362
+ ```
363
+ messages conversation:"<id from inbox | /messaging/thread/ URL>"
364
+ ```
365
+ The latest messages, oldest first: `from` ("you" for the user), `fromMe`, `at`, `text`, `subject`.
366
+ `meta.state: "partial"` means a full page came back and older messages may exist.
367
+
368
+ **Reading is invisible to the other side.** The browser, opening a conversation, also marks it read
369
+ (the sender sees it), clears "unseen" and acknowledges delivery; those are separate calls, and this
370
+ tool makes none of them. Nothing read is stored. These are private messages: summarise or quote them
371
+ to the user, never into anything else (a post, a comment, a file someone else will read).
372
+
373
+ ### `draft` / `drafts` — local. A reply for the user to send.
374
+ ```
375
+ draft conversation:"<id | thread URL>" text:"<reply>" drafts draft remove:"<draft id>"
376
+ ```
377
+ CLI: `lnrelay draft <conversation> "<text>" | --file <path>`, `lnrelay drafts`, `lnrelay draft remove <id>`.
378
+ Saves the reply ON THIS MACHINE with the conversation's link (one read, to check the conversation
379
+ and who it is with). **Nothing is sent, and nothing can be: there is no send.** Show the user the
380
+ draft and the link; they open it, paste, review, and send it themselves. Write drafts in the user's
381
+ own voice and language, from what the conversation actually says.
382
+
313
383
  ### `skills` — live, ~3 calls. The user's skills.
314
384
  ```
315
385
  skills
@@ -348,10 +418,10 @@ Every collection carries:
348
418
  |---|---|
349
419
  | `state: complete` | every reference resolved; an empty `items` here genuinely means none |
350
420
  | `state: partial` | **some references failed to resolve** — the record is incomplete, not small |
351
- | `state: unknown` | we stopped at the limit and cannot prove exhaustion (people/company `search`, `post`, `reactions`) |
352
- | `next` | `jobs` / `people`: the `start` that continues this search; absent when the results ran out |
353
- | `servedLimit` | `people`: LinkedIn claimed more matches than it serves (1000 a query) — the list is NOT everyone; narrow the query |
354
- | `searches` / `duplicates` | `jobs` / `people` with several keyword sets: each set's own count and state, and how many repeats were merged |
421
+ | `state: unknown` | we stopped at the limit and cannot prove exhaustion (`post`, `reactions`, `feed`) |
422
+ | `next` | `jobs` / `people` / `search`: the `start` that continues this search; absent when the results ran out |
423
+ | `servedLimit` | `people` / `search`: LinkedIn claimed more matches than it serves (1000 a query) — the list is NOT everyone; narrow the query |
424
+ | `searches` / `duplicates` | `jobs` / `people` / `search` with several keyword sets: each set's own count and state, and how many repeats were merged |
355
425
  | `unread` | `jobs --details` / `job`: jobs LinkedIn did not return in full — they are not closed, just unread |
356
426
  | `returnedCount` vs `claimedCount` | `claimed > 0` with `returned === 0` is a **failed fetch**, never "no results" |
357
427
  | `excludedCount` | ads and UI chrome deliberately dropped |
@@ -444,10 +514,12 @@ Things worth telling a user who asks:
444
514
  preview's own words, which name the timezone.
445
515
  - **Deleting a comment also deletes every reply under it**, including other people's. Verified live.
446
516
 
447
- Connecting and messaging do not exist at all, in any surface. They are the actions where the
448
- enforcement reports cluster, and an agent bug there is visible to a third party and unrecoverable.
517
+ **Sending a message and connecting do not exist at all, in any surface.** Messages can be read and
518
+ replies drafted (below), but a draft stays on this machine for the user to send. These are the
519
+ actions where the enforcement reports cluster, and an agent bug there is visible to a third party
520
+ and unrecoverable.
449
521
 
450
- Also absent by design: inbox reading, notifications, nested comment replies, and bulk sweeps.
522
+ Also absent by design: notifications, nested comment replies, and bulk sweeps.
451
523
 
452
524
  ## Honest risk
453
525
 
package/README.md CHANGED
@@ -11,6 +11,8 @@ npm i -g linkedin-relay-mcp
11
11
  lnrelay login # mint a session from your own Chrome
12
12
  lnrelay people "engineering manager" --company Microsoft --location Hungary --compact
13
13
  # people search with every filter, names looked up
14
+ lnrelay search posts "AI agents" --posted week --sort recent --compact
15
+ # posts, companies, groups, events, courses, products, …
14
16
  lnrelay jobs "frontend engineer" "AI agent developer" --workplace remote --posted week --compact
15
17
  # one merged job list across keyword sets
16
18
  lnrelay job 4479248573 4475225930 # full jobs, with their apply links
@@ -22,7 +24,7 @@ lnrelay local "rust" # then search it offline, free
22
24
 
23
25
  ## As an MCP server
24
26
 
25
- Twenty-one read-only tools, so an agent does the reading. Writes are not on that surface at any price.
27
+ Twenty-six tools, none of which writes to LinkedIn, so an agent does the reading. Writes are not on that surface at any price.
26
28
  The bundled Claude Code skill (`.claude/skills/linkedin-relay/SKILL.md`) teaches an agent the
27
29
  funnels, the budget, and how to read `meta` — including step-by-step recipes for finding people and
28
30
  for job hunting.
@@ -36,10 +38,12 @@ claude mcp add linkedin-relay -s user -- bun "$(npm root -g)/linkedin-relay-mcp/
36
38
  | | |
37
39
  |---|---|
38
40
  | `people` · `people-filters` | people search with every filter: company, past company, school, place, degree, title, someone's connections |
39
- | `search` · `profile` · `feed` | one-page search of people or companies, a profile, your feed |
41
+ | `search` · `search-filters` | posts, companies, groups, events, courses, products, services, schools — each with its filters |
42
+ | `profile` · `feed` | a profile, your feed |
40
43
  | `jobs` · `job` · `job-filters` | job search with every filter, several keyword sets merged in one call, and apply links |
41
44
  | `post` · `reactions` | a post's comment thread, and who engaged |
42
45
  | `scheduled` · `experience` · `skills` | your queued posts, and your own roles and skills |
46
+ | `inbox` · `messages` · `draft` · `drafts` | read your messages without marking them read; draft replies locally — nothing is ever sent |
43
47
  | `sync` · `local` · `connections` · `my-posts` | fill a local cache, then query it for free |
44
48
  | `whoami` · `doctor` · `risk` · `budget` · `cache-status` | session, standing and spend |
45
49
  | `share` · `comment` · `reply` · `edit` · `react` · `delete` | writes to your feed — OAuth when available, private API otherwise |
@@ -80,6 +84,42 @@ approved the way **you** chose with `lnrelay approval set` (only at a real termi
80
84
  There is no `--yes` and no environment variable. Every approval and outcome is logged to
81
85
  `~/.lnrelay/writes.jsonl`.
82
86
 
87
+ ## Messages: read, and draft — never send
88
+
89
+ ```bash
90
+ lnrelay inbox --folder archive --unread --compact # conversations, who with, unread, last message
91
+ lnrelay messages <conversation-id|thread-url> # a conversation, oldest first
92
+ lnrelay draft <conversation-id> "Thanks — let's talk Tuesday." # saved locally, with the thread link
93
+ lnrelay drafts # your drafts; open the link and send it yourself
94
+ ```
95
+
96
+ - **Reading leaves no trace.** Opening a conversation in the browser marks it read, clears "unseen"
97
+ and acknowledges delivery — separate calls this tool never makes. Nothing read is stored.
98
+ - **There is no send.** A draft is a local note (`~/.lnrelay/drafts.json`, owner-only) with the
99
+ conversation's link; you review and send it yourself. Agents get `inbox`, `messages` and `draft`
100
+ over MCP for exactly that: read, then draft.
101
+ - Folders: `inbox`, `primary`, `other`, `archive`, `requests`, `spam`.
102
+
103
+ ## Searching everything else
104
+
105
+ `lnrelay search <kind>` covers the rest of the search box — `posts`, `companies`, `groups`, `events`,
106
+ `courses`, `products`, `services`, `schools` — and hands `people` and `jobs` to their own commands.
107
+
108
+ ```bash
109
+ lnrelay search posts "AI agents" --posted week --author-company Microsoft --compact
110
+ lnrelay search companies "fintech" --location Hungary --filter companySize=C,D --compact
111
+ lnrelay search courses "python" --filter difficultyLevel=Beginner
112
+ lnrelay search-filters companies "fintech" # every filter for a kind, ids and counts
113
+ ```
114
+
115
+ - **Posts** come with author, time, text and reaction, comment and repost counts, filterable by date,
116
+ type, author, author's company, industry and title, and mentions. LinkedIn serves them over a
117
+ heavier interface than the rest, 20 a call.
118
+ - **Everything else** comes back 50 a call as LinkedIn's own lines (a company's industry and HQ and
119
+ followers, an event's time and place, a course's length and instructor), with each kind's filters
120
+ through `--filter key=value` and `search-filters`.
121
+ - Several keyword sets merge by id, as for people and jobs.
122
+
83
123
  ## Finding people
84
124
 
85
125
  ```bash
@@ -98,6 +138,8 @@ lnrelay people-filters "frontend developer" --location Budapest
98
138
  the tool never does. Several keyword sets merge by person, as for jobs.
99
139
  - **LinkedIn serves at most 1000 people per query**, whatever it claims to have matched;
100
140
  `meta.servedLimit` says when it held back, and the list is reported partial, not complete.
141
+ - People searches and name lookups spend the general search budget (25 calls a day), so a
142
+ 1000-person query takes most of a day's allowance.
101
143
 
102
144
  ## Job hunting
103
145
 
@@ -121,7 +163,7 @@ lnrelay job <id> <id> <id> # finalist
121
163
  - **The apply link** is the employer's own site (`external`) or LinkedIn's Easy Apply. This tool
122
164
  finds jobs; it does not apply to them.
123
165
  - Job hunting has its own daily budget — 150 search calls, 60 job reads — so it neither uses up nor
124
- is stopped by people and company research.
166
+ is stopped by the other searches, which share 25 search calls a day.
125
167
 
126
168
  ## Design in one screen
127
169