Automating LinkedIn search by getting Claude to build and test a new skill
An exploration in agentic AI use
To further my explorations of agentic AI uses that might help educators, I decided to see if I could automate an annoyingly slow task that comes up as I try to keep track of and respond to conversations about AI in education.
I’ve been frustrated with the slowness of LinkedIn’s search filter system; for example, you can’t just search for posts by a particular person that reference particular keywords; you have to do a general search on keywords and then narrow down by “post” and then by “member.” Google doesn’t index LinkedIn posts reliably.
I love connecting people who are talking about the same topics and cross-referencing conversations. I often think of a post where someone talked about something and want to review it or link to it but give up because I don’t have time or patience for the excruciating search process it would take to dig it up.
I knew that you could save instructions on how to complete particular tasks as “skills” in a Claude account. I decided to see if Claude could develop a reliable way to search LinkedIn with the Claude in Chrome browser extension. I interviewed it about LinkedIn search strategies, and it interviewed me about what search capabilities and kinds of outputs I wanted (see the whole chat transcript). It drafted a skill. I asked it to test. There were some false starts, as when Claude got no results and I did get results with the same search terms. But when I pointed this out, it was able to figure out the problem with its view of the site and update the skill. It started working.
In one test, I asked it to “Look for recent posts from Joel Gladd where he describes his use of Claude Code.” It surfaced two posts I remembered and one I hadn’t seen, then offered to keep going; I asked it to summarize all of Joel Gladd’s uses, and I was delighted to read its summaries as well as the posts themselves and discover quite a few experiments of his that I had missedit did. True, I could have searched myself or scrolled through his post history, but the thought of the user interface experience that would involve makes me shudder.
In another test in a fresh chat session, I wanted to find a particular post by Bonni Stachowiak from the Teaching in Higher Ed podcast and see if Jon Ippolito has posted separately on the same topic. In the chat, Claude first attempted to search LinkedIn without the skill and failed to find Bonni Stachowiak’s post. Then I told it to use the skill, and it succeeded.
I’m excited to keep using this and hopeful that Claude with the LinkedIn search skill will help me more easily learn more and help connect conversations and people on LInkedIn.
If this sounds useful to you, please try it and let me know if it works! You’ll see that it includes a process for searching comments; I haven’t tested that yet. Maybe the skill will need futher tweaking. Below is the text of the skill (a skill is just text instructions, not code). Again, this was generated and refined by Claude and depends on the Claude in Chrome browser extension having access to a LinkedIn account. To use it, Go to “Cusotmize” in Claude, “Create new skill,” call it “LinkedIn Search” and copy this text in. (See Anthropic’s guides What are Skills? and Use Skills in Claude.)
LinkedIn Post & Comment Search
Search LinkedIn for posts or comments using keyword and author filters via Chrome browser automation, with a Google site-search fallback.
Prerequisites
The user must be logged into LinkedIn in their Chrome browser.
The Claude in Chrome extension must be active and connected.
Confirm both before beginning the workflow. Do not attempt to log in on the user’s behalf.
Gathering the Search Request
Before searching, clarify the following with the user. Items marked with a default can be skipped if the user doesn’t specify them.
ParameterRequired?DefaultKeywordsYes—Search scopeNoPosts onlyAuthor (person’s name)NoAny authorCompany (posted by company, or author’s company)NoAnyDate rangeNoAny timeContent type (video, image, document, newsletter, carousel)NoAnyConnection degree (1st, 2nd, 3rd+)NoAnyOutput formatNoURLs only
Search scope options
Posts only (default): Search post content using LinkedIn native search + filters
Comments by a person: Search a specific person’s comment history (see Comment Search section below)
Both: Search posts first, then comments
Output format options
URLs only (default): Return just the LinkedIn post URL(s)
Summary: URL + brief description of post content
Extracted text: URL + full text of each post
Screenshot: URL + screenshot of each post in the browser
Primary Method: LinkedIn Native Search
Step 1: Build the search URL
Construct a URL to skip straight to filtered post results where possible:
https://www.linkedin.com/search/results/content/?keywords=ENCODED_KEYWORDSURL-encode the keywords. If the user wants an exact phrase, wrap it in quotes before encoding (LinkedIn supports quoted phrase search).
Use
navigateto go to this URL.Step 2: Take a screenshot and verify the page loaded
Use
computerwith actionscreenshotto confirm:
The page loaded (not a login wall or error)
The Posts tab / content results are visible
If a login wall appears, stop and remind the user of the prerequisite.
Step 3: Apply filters
Click “All filters” (use
findto locate the button, thencomputerto click it).The filter panel includes these fields relevant to post search:
FilterHow to useToolSort by“Relevance” or “Latest”
form_inputorcomputerclickDate postedPast 24 hours / Past week / Past monthcomputerclickContent typeVideo, Image, Document, Newsletter, CarouselcomputerclickFrom memberType person’s name, select from autocompleteform_inputthencomputerto selectFrom companyType company name, select from autocompleteform_inputthencomputerto selectAuthor companyFilter by where the author worksform_inputthencomputerto selectAuthor industryFilter by author’s industryform_inputthencomputerto selectConnection degreeNot directly in “All filters” — see Step 3a—After setting filters, click “Show results” (use
findto locate, thencomputerto click).Step 3a: Connection degree filtering
LinkedIn’s Posts search does not always expose a direct “Connections” filter in All Filters. Two approaches:
Posted by filter: In All Filters, look for “Posted by” which may include options like “People you follow” or “1st connections.” Use this if available.
Boolean + profile cross-reference: If connection filtering isn’t available in the filter panel, note this limitation to the user. You can check individual authors’ connection degree from their profile if needed.
Step 4: Read and extract results
Use
read_pageorget_page_textto extract post results from the page.For each result, extract:
Post URL: Look for links in the results that follow the pattern
linkedin.com/feed/update/orlinkedin.com/posts/. Useread_pageto find link elements within each result card.Author name: Typically displayed above each post.
Post snippet: The preview text shown in search results.
Date: Relative timestamp (e.g., “3d”, “1w”).
If extracting URLs from the accessibility tree is difficult, use
javascript_toolto run:javascript
Array.from(document.querySelectorAll('a[href*="/feed/update/"], a[href*="/posts/"]')).map(a => a.href)Step 5: Scroll for more results if needed
If the user needs more results than are initially visible, use
computerwithscrollaction (direction: “down”) and repeat Step 4.Step 6: Deliver results
Based on the requested output format:
URLs only (default): List the post URLs in chat.
Summary: For each URL, include the author, date, and a 1-2 sentence description of the post content from the snippet.
Extracted text: Navigate to each post URL, use
get_page_textto extract the full post text, and present it.Screenshot: Use
computerwithscreenshotaction on each post.Fallback Method: Google Site Search
Use this method if:
LinkedIn’s native search isn’t returning results
The browser automation encounters issues (UI changes, loading problems)
The user prefers a faster, less interactive approach
How to construct the Google search
Use the
web_searchtool with queries structured as:Posts by a specific person on a topic:
site:linkedin.com/posts "Person Name" "keyword or phrase"Articles/newsletters by a specific person:
site:linkedin.com/pulse "Person Name" "keyword or phrase"Posts from a specific company:
site:linkedin.com/posts "Company Name" "keyword"Limitations of the fallback
Only finds publicly indexed posts (not posts with restricted visibility)
Cannot filter by connection degree, content type, or date range with precision
May return profile pages or other LinkedIn content mixed in with posts
Less reliable for recent posts (indexing lag)
Tips for Effective LinkedIn Post Search
Short, specific keywords work better than long queries in LinkedIn’s native search.
Boolean operators work in LinkedIn’s search bar: AND, OR, NOT, and quoted phrases for exact match. Example:
"agentic AI" AND "academic integrity".“From member” autocomplete requires a few characters before suggesting names. Type at least the first name and wait for suggestions.
“Mentioning member” is different from “From member” — use it to find posts that tag someone, not posts written by them.
If searching for a person with a common name, adding the “From member” filter is far more reliable than including their name in the keyword search.
Troubleshooting
ProblemSolutionLogin wall appearsRemind user they must be logged into LinkedIn. Do not attempt login.”No results found”Try broader keywords, remove filters one at a time, or switch to fallback method.Filter panel layout has changedTake a screenshot, use
read_pageto inspect current UI elements, and adapt. LinkedIn frequently updates its UI.Autocomplete not showing the right personTry typing more of their name, or their full name. If still not found, the person may have restricted their profile visibility.Cannot extract URLs from resultsUsejavascript_toolto query the DOM directly for link elements.Rate limiting or CAPTCHAStop and inform the user. Do not attempt to bypass.Comment Search
LinkedIn does not provide any native search for comments — not through the search bar, filters, or API. Comment search requires a browser-based workaround with significant limitations.
Method: Activity Page Scroll + JavaScript Search
Step 1: Navigate to the person’s comment activity page
Construct the URL using their LinkedIn profile slug:
https://www.linkedin.com/in/PROFILE_SLUG/recent-activity/comments/If searching the logged-in user’s own comments, their profile slug can be found in the URL when viewing their profile. Use
navigateto go to this page.Step 2: Verify the page loaded
Use
computerwithscreenshotto confirm the Activity page loaded with the “Comments” tab selected. If not, click the “Comments” tab.Step 3: Scroll and search with JavaScript
Use
javascript_toolto scroll down and search for the keyword in loaded content. This loads comments via infinite scroll and checks for the keyword after each scroll:javascript
async function scrollAndSearch(keyword, maxScrolls = 30) { for (let i = 0; i < maxScrolls; i++) { window.scrollTo(0, document.body.scrollHeight); await new Promise(r => setTimeout(r, 1500)); if (document.body.innerText.toLowerCase().includes(keyword.toLowerCase())) { const text = document.body.innerText; const idx = text.toLowerCase().indexOf(keyword.toLowerCase()); const start = Math.max(0, idx - 300); const end = Math.min(text.length, idx + 300); return { found: true, scrolls: i + 1, context: text.substring(start, end) }; } } return { found: false, scrolls: maxScrolls }; } scrollAndSearch('your keyword here')Adjust
maxScrollsbased on how far back the user thinks the comment might be. Each scroll loads roughly 3-5 comments. 30 scrolls covers roughly 90-150 comments.Step 4: If found, extract the post URL
When the keyword is found, take a screenshot to see the context. Use
findorread_pageto identify the parent post that was commented on. The parent post’s link can be extracted from the result card.Critical Limitations of Comment Search
Truncation problem: The activity page shows comment previews that are truncated with “...more” links. Keywords that appear later in a comment will not be found by the JavaScript text search unless the “...more” link is clicked to expand each comment. Clicking every “...more” link is possible but extremely slow.
No date filtering: There is no way to jump to a specific date range. The only approach is scrolling from most recent backward.
Only shows the person’s own comments: This view only shows comments by the profile owner. You cannot search across all comments on a particular post without opening that post directly.
Incomplete history: LinkedIn may not load the complete comment history for very active users. The infinite scroll may stop loading at some point.
Parent post context: The activity page shows the parent post the user commented on, but the parent post text is also truncated — the keyword might appear in either the comment or the parent post preview.
When to suggest the Data Export alternative
If the scroll-and-search approach fails or is too slow (e.g., the user has a very long comment history or the comment is old), suggest the LinkedIn Data Export method instead.
Alternative: LinkedIn Data Export
LinkedIn allows users to download an archive of their data, including all their comments. This is the most thorough method for searching old comments.
How to guide the user
Tell the user to go to Settings & Privacy > Data privacy > Get a copy of your data (or navigate to
https://www.linkedin.com/mypreferences/d/download-my-data).The user should select at minimum “Comments” (they can also include “Posts” and other data).
LinkedIn will prepare the archive and email a download link — this can take up to 24 hours but often arrives within minutes for smaller requests.
The downloaded archive is a ZIP file containing CSV files.
Once downloaded, the user can open the Comments CSV and use Ctrl+F or any text editor to search for their keyword.
Important: Claude cannot initiate this data request on the user’s behalf — it requires clicking through LinkedIn’s privacy settings and potentially re-authenticating. Guide the user through the steps verbally, or navigate them to the settings page and let them complete it.
What the data export includes
Full text of every comment (not truncated)
Date and time of each comment
URL of the post that was commented on
The export does not include comments by others on the user’s posts — only the user’s own comments on any posts


I've just started exploring Claude skills for important but time consuming tasks. The first one is verify the veracity and correctness of bibliographies in student papers. Right now, I look up every single source myself! Claude believes that he can build a good skill for that. I haven't finished the session yet so have nothing to report, but I will let you know!
This is so helpful. Thank you for diving in with AI agents so the rest of us can wade in with confidence!