ReachMCP LinkedIn – Posts API
The LinkedIn – Posts API from ReachMCP — 6 operation(s) for linkedin – posts.
The LinkedIn – Posts API from ReachMCP — 6 operation(s) for linkedin – posts.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/reachmcp-com:reachmcp-com-linkedin-posts-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: MCP Reach LinkedIn – Posts API
description: '## MCP Reach API overview
This API lets you manage LinkedIn accounts connected to MCP Reach and query account activity.
The documented endpoints cover:
- listing and deleting LinkedIn accounts
- reading and updating account quotas
- reading request logs and aggregated request-log statistics
- querying LinkedIn `/me` through the account proxy
## API documentation
Interactive reference (Scalar): **`/scalar`** (alias: `/api/scalar`). Swagger UI: `/docs`. ReDoc: `/redoc`.
## Authentication
1. Open the MCP Reach frontend.
2. Go to **API Keys** and create/retrieve your API key.
3. Send this key in every request header:
`X-API-Key: `
Requests without a valid `X-API-Key` are rejected.
## Errors
Every error response carries `detail` (unchanged, for existing clients) and an `error` object built for agents: `code` (stable identifier such as `daily_quota_reached`), `message`, `status`, `safe_to_retry` (whether the same call can succeed if repeated), `retry_at` (ISO 8601, when it can) and `remediation` (what to do instead). Act on `code`, never on the wording of `message`.
## Idempotency
Send an `Idempotency-Key` header (any string up to 200 characters, a UUID is fine) on any POST/PATCH/DELETE under `/api/linkedin/`. Repeating the request with the same key returns the stored response with `Idempotent-Replayed: true` and does nothing on LinkedIn; the same key with a different body is refused with `409 idempotency_key_reused`. Only successful responses are kept; keys expire after 24 hours.
## Webhooks
Register an endpoint under `/api/webhooks/endpoints` to be called when a conversation gets a new message, the account gains a new connection, an account changes connection state, or a daily quota is close to or at its limit (`GET /api/webhooks/events` lists the types). Deliveries are signed: `Reach-Signature: t=,v1=.'')>`, retried for about 15 hours, and replayable from the dashboard or the API.'
version: 0.1.0
tags:
- name: LinkedIn – Posts
paths:
/api/linkedin/{account_id}/scrape-post:
get:
tags:
- LinkedIn – Posts
summary: 'LinkedIn proxy: scrape likers and/or commenters of a post'
description: 'Fetches up to 1 000 likers and/or up to 799 comments for a LinkedIn post using ``Voyager updatesV2?q=postSlug``.
**Input** (``post_id_or_url``):
- Full post URL: ``https://www.linkedin.com/posts/john-doe_title-7460167012225363968-iRyb``
- Feed update URL: ``https://www.linkedin.com/feed/update/urn:li:activity:7460167012225363968``
- Activity URN: ``urn:li:activity:7460167012225363968``
- Bare numeric ID: ``7460167012225363968``
- Post slug: ``john-doe_some-title-7460167012225363968-iRyb``
At least one of ``liked`` or ``comments`` must be ``true``.
Each item in ``items`` has ``type=''like''`` or ``type=''comment''``. Comment items also carry ``comment_id`` (full URN), ``comment_text``, and ``is_reply=true`` for nested replies.
The post''s counters come with them (``total_likes``, ``total_comments``, ``total_shares``, ``published_at``); on a post of the connected account, ``impressions`` too. ``video_views`` is set on video posts.'
operationId: linkedin_scrape_post_api_linkedin__account_id__scrape_post_get
security:
- XApiKeyAuth: []
parameters:
- name: account_id
in: path
required: true
schema:
type: integer
title: Account Id
- name: post_id_or_url
in: query
required: true
schema:
type: string
description: LinkedIn post URL or post slug.
title: Post Id Or Url
description: LinkedIn post URL or post slug.
- name: liked
in: query
required: false
schema:
type: boolean
description: Include people who liked the post.
default: false
title: Liked
description: Include people who liked the post.
- name: comments
in: query
required: false
schema:
type: boolean
description: Include people who commented on the post.
default: false
title: Comments
description: Include people who commented on the post.
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/LinkedInScrapePostOut'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/linkedin/{account_id}/scrape-my-posts:
get:
tags:
- LinkedIn – Posts
summary: 'LinkedIn proxy: scrape likers and/or commenters of the account''s recent posts'
description: 'Fetches the connected LinkedIn account''s posts that got likes, comments or shares recently (via the ``MY_POSTS_ALL`` notification feed), then retrieves likers and/or commenters for each post using the Voyager GraphQL reactions/comments APIs.
Each post carries its counters (``total_likes``, ``total_comments``, ``total_shares``), ``impressions`` (and ``video_views`` for a video), ``published_at`` (when the post was published) and ``last_activity_at`` (its latest notified engagement).
**Parameters:**
- ``liked`` — include people who liked each post (paginated, up to all reactions)
- ``comments`` — include people who commented on each post (paginated, up to all comments)
- ``since_hours`` — only consider posts with engagement in the last N hours (default 24), whenever they were published
- ``max_posts`` — maximum number of posts to process (default 10, max 20)
At least one of ``liked`` or ``comments`` must be ``true``.
Each item in ``items`` has ``type=''like''`` or ``type=''comment''``. Comment items also carry ``comment_id`` (full URN) and ``comment_text``.'
operationId: linkedin_scrape_my_posts_api_linkedin__account_id__scrape_my_posts_get
security:
- XApiKeyAuth: []
parameters:
- name: account_id
in: path
required: true
schema:
type: integer
title: Account Id
- name: liked
in: query
required: false
schema:
type: boolean
description: Include people who liked each post.
default: false
title: Liked
description: Include people who liked each post.
- name: comments
in: query
required: false
schema:
type: boolean
description: Include people who commented on each post.
default: false
title: Comments
description: Include people who commented on each post.
- name: since_hours
in: query
required: false
schema:
type: integer
maximum: 720
minimum: 1
description: Only consider posts with likes, comments or shares in the last N hours.
default: 24
title: Since Hours
description: Only consider posts with likes, comments or shares in the last N hours.
- name: max_posts
in: query
required: false
schema:
type: integer
maximum: 20
minimum: 1
description: Maximum number of posts to process.
default: 10
title: Max Posts
description: Maximum number of posts to process.
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/LinkedInScrapeMyPostsOut'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/linkedin/{account_id}/like-post:
post:
tags:
- LinkedIn – Posts
summary: 'LinkedIn proxy: like a post'
description: 'Likes a LinkedIn post on behalf of the connected account.
**Input** (``post_url_or_urn``):
- Full LinkedIn post URL: ``https://www.linkedin.com/posts/...``
- Post slug: ``john-doe_some-title-7460167012225363968-iRyb``
- Post URN: ``urn:li:activity:7460167012225363968``'
operationId: linkedin_like_post_api_linkedin__account_id__like_post_post
security:
- XApiKeyAuth: []
parameters:
- name: account_id
in: path
required: true
schema:
type: integer
title: Account Id
- name: post_url_or_urn
in: query
required: true
schema:
type: string
description: LinkedIn post URL, slug, or URN (urn:li:activity:...); a comment URN likes that comment.
title: Post Url Or Urn
description: LinkedIn post URL, slug, or URN (urn:li:activity:...); a comment URN likes that comment.
- name: page_id
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Act as this company page (page_id or vanity name from GET /pages). Omit to act as the member.
title: Page Id
description: Act as this company page (page_id or vanity name from GET /pages). Omit to act as the member.
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/linkedin/{account_id}/comment-post:
post:
tags:
- LinkedIn – Posts
summary: 'LinkedIn proxy: comment on a post'
description: 'Posts a comment on a LinkedIn post on behalf of the connected account.
**Input** (``post_url_or_urn``):
- Full LinkedIn post URL: ``https://www.linkedin.com/posts/...``
- Post slug: ``john-doe_some-title-7460167012225363968-iRyb``
- Post URN: ``urn:li:activity:7460167012225363968``'
operationId: linkedin_comment_post_api_linkedin__account_id__comment_post_post
security:
- XApiKeyAuth: []
parameters:
- name: account_id
in: path
required: true
schema:
type: integer
title: Account Id
- name: post_url_or_urn
in: query
required: true
schema:
type: string
description: LinkedIn post URL, slug, or URN.
title: Post Url Or Urn
description: LinkedIn post URL, slug, or URN.
- name: text
in: query
required: true
schema:
type: string
description: Comment text to post.
title: Text
description: Comment text to post.
- name: page_id
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Act as this company page (page_id or vanity name from GET /pages). Omit to act as the member.
title: Page Id
description: Act as this company page (page_id or vanity name from GET /pages). Omit to act as the member.
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/linkedin/{account_id}/reply-comment:
post:
tags:
- LinkedIn – Posts
summary: 'LinkedIn proxy: reply to a comment'
description: 'Posts a reply to an existing LinkedIn comment.
``comment_urn`` is the ``comment_id`` (URN) returned by the ``scrape-post`` endpoint — it is used directly as ``threadUrn`` in the LinkedIn API.'
operationId: linkedin_reply_comment_api_linkedin__account_id__reply_comment_post
security:
- XApiKeyAuth: []
parameters:
- name: account_id
in: path
required: true
schema:
type: integer
title: Account Id
- name: comment_urn
in: query
required: true
schema:
type: string
description: URN of the comment to reply to (comment_id from scrape-post).
title: Comment Urn
description: URN of the comment to reply to (comment_id from scrape-post).
- name: text
in: query
required: true
schema:
type: string
description: Reply text.
title: Text
description: Reply text.
- name: page_id
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Act as this company page (page_id or vanity name from GET /pages). Omit to act as the member.
title: Page Id
description: Act as this company page (page_id or vanity name from GET /pages). Omit to act as the member.
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/linkedin/{account_id}/user-posts:
get:
tags:
- LinkedIn – Posts
summary: 'LinkedIn proxy: get recent posts of a LinkedIn member'
description: 'Fetches recent posts published by a LinkedIn member via ``profileUpdatesV2``.
**Input** (``linkedin_id_or_url``):
- Internal member ID: ``ACoAABcDEFg...``
- Vanity name: ``john-doe``
- Full profile URL: ``https://www.linkedin.com/in/john-doe``
Use ``count`` and ``start`` for pagination.
Each post carries ``total_likes``, ``total_comments``, ``total_shares`` and ``published_at``. On the connected account''s own posts (its own ``linkedin_id``), it also carries ``impressions``: LinkedIn shows them to the author only. ``video_views`` is set on video posts.
Each call counts against the account''s daily ``profile_posts`` quota.'
operationId: linkedin_user_posts_api_linkedin__account_id__user_posts_get
security:
- XApiKeyAuth: []
parameters:
- name: account_id
in: path
required: true
schema:
type: integer
title: Account Id
- name: linkedin_id_or_url
in: query
required: true
schema:
type: string
description: LinkedIn member ID, vanity name, or profile URL.
title: Linkedin Id Or Url
description: LinkedIn member ID, vanity name, or profile URL.
- name: count
in: query
required: false
schema:
type: integer
maximum: 50
minimum: 1
description: Number of posts to fetch.
default: 10
title: Count
description: Number of posts to fetch.
- name: start
in: query
required: false
schema:
type: integer
minimum: 0
description: Pagination offset.
default: 0
title: Start
description: Pagination offset.
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/LinkedInUserPostsOut'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
LinkedInUserPostOut:
properties:
post_urn:
type: string
title: Post Urn
post_url:
type: string
title: Post Url
description: Public LinkedIn URL of the post.
post_text:
anyOf:
- type: string
- type: 'null'
title: Post Text
description: Post content text.
published_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Published At
description: ISO 8601 UTC time the post (or the repost) was published.
published_at_relative:
anyOf:
- type: string
- type: 'null'
title: Published At Relative
description: Human-readable relative publish time (e.g. '3 days ago').
is_repost:
type: boolean
title: Is Repost
description: 'The member reposted someone''s post (or their own): the counters are the original post''s.'
default: false
total_likes:
anyOf:
- type: integer
- type: 'null'
title: Total Likes
total_comments:
anyOf:
- type: integer
- type: 'null'
title: Total Comments
total_shares:
anyOf:
- type: integer
- type: 'null'
title: Total Shares
impressions:
anyOf:
- type: integer
- type: 'null'
title: Impressions
description: 'Times the post was shown. LinkedIn gives it to the post''s author only: filled on the connected account''s own posts, absent on anyone else''s and on reposts.'
video_views:
anyOf:
- type: integer
- type: 'null'
title: Video Views
description: Views of the post's video (video posts only).
type: object
required:
- post_urn
- post_url
title: LinkedInUserPostOut
description: A post published by a LinkedIn member.
LinkedInScrapeMyPostsOut:
properties:
posts:
items:
$ref: '#/components/schemas/LinkedInMyPostOut'
type: array
title: Posts
total_posts:
type: integer
title: Total Posts
type: object
required:
- posts
- total_posts
title: LinkedInScrapeMyPostsOut
description: Engagers across recent posts published by the connected account.
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
LinkedInUserPostsOut:
properties:
posts:
items:
$ref: '#/components/schemas/LinkedInUserPostOut'
type: array
title: Posts
total_posts:
type: integer
title: Total Posts
type: object
required:
- posts
- total_posts
title: LinkedInUserPostsOut
description: Recent posts published by a LinkedIn member.
LinkedInMyPostOut:
properties:
post_urn:
type: string
title: Post Urn
post_url:
type: string
title: Post Url
description: Public LinkedIn URL of the post.
post_text:
anyOf:
- type: string
- type: 'null'
title: Post Text
description: Excerpt of the post text (from the notification card).
published_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Published At
description: ISO 8601 UTC time the post was published.
last_activity_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Last Activity At
description: ISO 8601 UTC time of the latest like, comment or share notified on the post (what since_hours filters on).
total_likes:
anyOf:
- type: integer
- type: 'null'
title: Total Likes
total_comments:
anyOf:
- type: integer
- type: 'null'
title: Total Comments
total_shares:
anyOf:
- type: integer
- type: 'null'
title: Total Shares
impressions:
anyOf:
- type: integer
- type: 'null'
title: Impressions
description: 'Times the post was shown. LinkedIn gives it to the post''s author only: filled on the connected account''s own posts, absent on anyone else''s and on reposts.'
video_views:
anyOf:
- type: integer
- type: 'null'
title: Video Views
description: Views of the post's video (video posts only).
items:
items:
$ref: '#/components/schemas/LinkedInPostEngagerOut'
type: array
title: Items
type: object
required:
- post_urn
- post_url
- items
title: LinkedInMyPostOut
description: One of the account owner's posts with its engagers.
LinkedInPostEngagerOut:
properties:
type:
type: string
title: Type
description: '``like`` or ``comment``.'
author_type:
anyOf:
- type: string
- type: 'null'
title: Author Type
description: '``member`` or ``company`` (a page commenting or reacting: full_name is the page name, linkedin_id its company id).'
linkedin_id:
anyOf:
- type: string
- type: 'null'
title: Linkedin Id
linkedin_public_id:
anyOf:
- type: string
- type: 'null'
title: Linkedin Public Id
description: Member vanity name, or the page's for a company.
firstname:
anyOf:
- type: string
- type: 'null'
title: Firstname
lastname:
anyOf:
- type: string
- type: 'null'
title: Lastname
full_name:
anyOf:
- type: string
- type: 'null'
title: Full Name
headline:
anyOf:
- type: string
- type: 'null'
title: Headline
picture:
anyOf:
- type: string
- type: 'null'
title: Picture
comment_id:
anyOf:
- type: string
- type: 'null'
title: Comment Id
description: Full comment URN (comments only).
comment_text:
anyOf:
- type: string
- type: 'null'
title: Comment Text
reply_to_comment_id:
anyOf:
- type: string
- type: 'null'
title: Reply To Comment Id
description: URN of the parent comment when this item is a reply.
created_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Created At
description: ISO 8601 UTC timestamp of the like or comment.
type: object
required:
- type
title: LinkedInPostEngagerOut
description: A person who liked or commented on a LinkedIn post.
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
input:
title: Input
ctx:
type: object
title: Context
type: object
required:
- loc
- msg
- type
title: ValidationError
LinkedInScrapePostOut:
properties:
post_id:
type: string
title: Post Id
published_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Published At
description: ISO 8601 UTC time the post was published.
total_likes:
type: integer
title: Total Likes
default: 0
total_comments:
type: integer
title: Total Comments
default: 0
total_shares:
anyOf:
- type: integer
- type: 'null'
title: Total Shares
impressions:
anyOf:
- type: integer
- type: 'null'
title: Impressions
description: 'Times the post was shown. LinkedIn gives it to the post''s author only: filled on the connected account''s own posts, absent on anyone else''s and on reposts.'
video_views:
anyOf:
- type: integer
- type: 'null'
title: Video Views
description: Views of the post's video (video posts only).
items:
items:
$ref: '#/components/schemas/LinkedInPostEngagerOut'
type: array
title: Items
type: object
required:
- post_id
- items
title: LinkedInScrapePostOut
description: Aggregated likers and commenters for a LinkedIn post.
securitySchemes:
HTTPBearer:
type: http
scheme: bearer
APIKeyHeader:
type: apiKey
in: header
name: X-API-Key
XApiKeyAuth:
type: apiKey
in: header
name: X-API-Key
description: Create/retrieve the key in the frontend API Keys page and send it in this header.