John Cole

Aug 14, 2026 • 3 min read

How to Track LinkedIn Post Engagement as JSON (No LinkedIn API)

Pull public LinkedIn posts and their like, comment, and share counts as structured JSON from a profile or post URL, with no LinkedIn API partnership.

I keep a short list of people whose LinkedIn posts I study, and every time I want to know what actually landed, I end up scrolling. LinkedIn shows the numbers one post at a time and buries anything older than a few weeks. I wanted the counts as data, one row per post, so I could sort and compare them.

The LinkedIn Posts API returns public LinkedIn posts and their engagement counts as structured JSON, discovered from a profile URL or fetched from specific post URLs.

What it returns

  • Post URL and a stable post ID

  • Date posted and the full text, with hashtags broken out

  • Author name, headline, and follower count

  • Likes, comments, and shares, with a sample of top comments

  • Media, embedded links, and tagged companies and people

Because each row carries the author follower count, you can normalize engagement against audience size instead of comparing raw likes.

Run it in three steps

1. Open the LinkedIn Posts API and click Try for free.

2. Paste profile URLs to discover a person's recent posts, or post URLs for specific ones, and set how many posts per profile.

3. Run it and export JSON or CSV.

Use it as a REST API

Start a run with a POST to the Apify API, then read the dataset when it finishes.

POST /v2/acts/johnvc~linkedin-posts-api/runs

The full request and response shapes are in the Apify API docs.

Wire it into Claude with MCP

Over Apify's MCP server the Actor becomes a callable tool for Claude, Claude Code, and Cursor. Ask "summarize what this founder posted this quarter and what got traction" and it runs the Actor and returns rows, with no scraping code. The Get LinkedIn posts in Claude via MCP task has the setup.

What people build with it

Marketing teams run social listening on their category. Creator analysts benchmark which posts earn engagement. Founders track a competitor's posting cadence and share of voice. The LinkedIn posts data API for Python task and the Analyze LinkedIn post engagement task are the two common starting points, and there are more runnable examples on the Peerlist project page.

FAQ About Scraping LinkedIn Posts

Where does the LinkedIn posts scraper get its data?

It collects what a logged-out visitor sees on public LinkedIn post pages and returns it as JSON. The counts are snapshots at collection time, so re-run on a schedule to see how a post ages.

Does the scraper need my LinkedIn login?

No. It reads public posts, so you never lend your own account to automation or put it at risk.

How much does the API cost per post?

Billing is pay per post collected, so twenty posts cost twenty events and a capped run stays a capped bill. New Apify accounts include free credit that covers a first collection.

Can Claude use this LinkedIn posts scraper over MCP?

Yes. Connected through Apify's MCP server it is a callable tool, and the MCP example task above is the fastest working setup.

Can an AI agent pay for this scraper in USDC with x402?

Yes. The LinkedIn Posts API supports agentic payments via the x402 protocol, so AI agents and MCP clients can pay for runs in USDC on Base with no Apify account or API token. Point your agent at the Apify MCP server and it can discover, pay for, and run the scraper autonomously; the Apify x402 announcement has the details.

Every run returns rows, and if a single post cannot be read you get an error row for it instead of a dead run. I answer issues on the Actor page within a day.

Join John on Peerlist!

Join amazing folks like John and thousands of other builders on Peerlist.

peerlist.io/

It’s available... this username is available! 😃

Claim your username before it's too late!

This username is already taken, you’re a little late.😐

0

0

0