LinkedIn MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@LinkedIn MCP Server create a LinkedIn post about our new product launch"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
LinkedIn MCP Server (Python)
A Model Context Protocol server that lets any MCP client — Amazon Quick, Amazon Q, Claude Desktop, Cline, Continue — publish and manage LinkedIn content in natural language: create posts (text, image, multi-image, video, document, article, poll), upload media, edit/delete, comment, and reshare on a self-serve token. Reactions, engagement reads, and company-Page tools are also built in, gated behind opt-in flags because LinkedIn requires partner approval for them.
By default the server advertises the 10 tools that work on a self-serve token; the 7 partner-scoped tools stay hidden until you opt in (see Feature tiers).
Built with Python + FastMCP, plain LinkedIn REST, and OAuth 2.0. Runs over stdio (local) or streamable HTTP (hosted) from the same codebase.
Unofficial integration. Not affiliated with LinkedIn. Use within LinkedIn's API Terms.
Amazon Quick Desktop vs Amazon Quick Web — read this first
Amazon Quick comes in two forms with different MCP requirements:
Surface | Transport it needs | How to run this server |
Amazon Quick Desktop (native app) | Local connector (runs a command) or remote HTTP | Run over stdio (default). Add as a Local connector. |
Amazon Quick Web (browser / cloud, aka Quick Suite) | Remote only — streamable HTTP / SSE over HTTPS; stdio not supported | Run over HTTP and host it (e.g. behind Bedrock AgentCore Runtime), then add as a remote MCP connector. |
Every other MCP client — Amazon Q Developer CLI, Claude Desktop, Cline, Continue — runs the default stdio server locally, exactly like Quick Desktop.
The transport is a single env var (LINKEDIN_MCP_TRANSPORT=stdio|http) — no code
change between the two.
Related MCP server: Postoir
Feature tiers (what your token can actually reach)
The server advertises 10 tools by default — exactly the ones that work on a self-serve token. The other 7 are built in full but hidden behind two default-off flags, because LinkedIn requires partner approval for the scopes they need. Flip a flag only once your app is approved for that program; otherwise those tools would only return a ScopeError.
Flag | Default | Adds | Needs |
(none) | — | the 10 self-serve tools below |
|
|
| 3 reaction/metadata tools | Community Management ( |
|
| 4 organization tools | Marketing/Org scopes + Page admin role |
Tool count: default 10 → +SOCIAL_FEED 13 → +ORG 14 → both 17.
✅ Self-serve — advertised by default (10 tools)
Scopes openid profile email w_member_social, granted instantly by adding the
Sign In with LinkedIn (OIDC) and Share on LinkedIn products to your app.
Tool | What it does |
| Your name, email, picture, and person URN |
| Text / image / multi-image / video / document / article post |
| Poll post (2–4 options, 1/3/7/14-day) |
| Reshare an existing post with commentary |
| Edit a post's text |
| Delete a post |
| Upload an image → image URN |
| Upload a video → video URN |
| Upload a PDF/document → document URN |
| Comment on a post / reply to a comment |
⚠️ Community Management — gated behind LINKEDIN_ENABLE_SOCIAL_FEED (3 tools)
Need w_member_social_feed (reactions) / r_member_social_feed (metadata, which
LinkedIn marks Restricted — granted to select developers only). Plain
w_member_social is not sufficient — these endpoints return 403 until your
app is approved for the Community Management API.
Tool | What it does | Scope |
| Add a reaction to a post/comment |
|
| Remove your reaction |
|
| Like/comment counts + reaction summary |
|
🏢 Organization — gated behind LINKEDIN_ENABLE_ORG (4 tools)
Need Marketing Developer Platform approval or a Page admin role
(rw_organization_admin, r_organization_social). Fully implemented; until
approved they return a clear ScopeError.
Tool | What it does |
| Look up a company Page by org ID |
| Find a Page by its URL slug |
| Follower statistics for a Page |
| Pages you can administer |
Posting as an organization also works through linkedin_create_post — pass an
urn:li:organization:... author URN (needs w_organization_social + a Page role).
Clear errors, not opaque failures. Every tool is wrapped so a LinkedIn error comes back as a structured
{error, status, linkedin_response, hint}dict — a missing-scope 403 names the exact permission required instead of failing silently.
No native scheduling. LinkedIn's public Posts API only accepts
lifecycleState: PUBLISHED. Scheduling must live in your own layer.
Install
git clone <this-repo>
cd linkedin-mcp-server
python3 -m venv .venv && source .venv/bin/activate
pip install -e .Get a LinkedIn access token (quickest path)
Create a Company Page (LinkedIn requires every app to be linked to one): linkedin.com/company/setup/new.
Create an app at the Developer Portal linked to that Page.
Products tab → request access to Sign In with LinkedIn using OpenID Connect and Share on LinkedIn (both auto-approved).
Auth tab → add redirect URL
https://www.linkedin.com/developers/tools/oauth/redirect(for the token generator) andhttp://localhost:8765/callback(for this server's interactive login).Generate a token at the token generator with scopes
openid profile email w_member_social(expires in 60 days), or let this server run the interactive login (see Config below).
Configure
Copy .env.example → .env, or set the vars in your MCP client. Two auth modes:
Bring your own token (simplest / headless): set
LINKEDIN_ACCESS_TOKEN.Interactive OAuth (PKCE): set
LINKEDIN_CLIENT_ID(+LINKEDIN_CLIENT_SECRETif your app is confidential). The server opens a browser on first use and caches the token at~/.linkedin-mcp/token.json.
Partner-scoped tool groups are off by default. Once LinkedIn approves your app
for the relevant program, set LINKEDIN_ENABLE_SOCIAL_FEED=true (reactions /
social metadata) and/or LINKEDIN_ENABLE_ORG=true (organization tools) to make
them appear. See Feature tiers.
Client setup
Amazon Quick Desktop (Local connector)
Desktop App → Customize → Connectors → Create → Create local connector → Local:
Command:
/absolute/path/to/.venv/bin/pythonArguments:
-m linkedin_mcp.serverEnvironment variables:
LINKEDIN_ACCESS_TOKEN= your token
Amazon Quick Web (browser / cloud, remote HTTP)
Host the server with LINKEDIN_MCP_TRANSPORT=http behind an HTTPS endpoint
(e.g. Bedrock AgentCore Runtime). Then in the Quick console →
Connectors → Model Context Protocol (MCP) → set the MCP server endpoint
to your https://.../mcp URL and pick an auth method (No Auth / OAuth / S2S).
Amazon Q Developer CLI
q mcp add --name linkedin \
--command /absolute/path/to/.venv/bin/python \
--args '["-m", "linkedin_mcp.server"]'
# then set LINKEDIN_ACCESS_TOKEN in the environment / agent configClaude Desktop / Cline / Continue
{
"mcpServers": {
"linkedin": {
"command": "/absolute/path/to/.venv/bin/python",
"args": ["-m", "linkedin_mcp.server"],
"env": { "LINKEDIN_ACCESS_TOKEN": "paste-your-token-here" }
}
}
}Try it
"What's my LinkedIn profile?" → returns your name, email, and person URN. "Post on LinkedIn: Excited to share our new MCP server!" "Upload ~/pic.png and post it with the caption 'Launch day 🚀'." "Reshare urn:li:share:123 with the note 'This is great.'" "Delete my last post."
Development
pip install -e ".[dev]"
pytest # LinkedIn calls are mocked with respx — no network, no tokenArchitecture
src/linkedin_mcp/
server.py FastMCP app + stdio|http transport
config.py env-driven config
auth.py OAuth 2.0 PKCE loopback flow + token cache + env fallback
client.py REST client: versioned headers, URN encoding, media upload, error mapping
errors.py AuthError / ScopeError / APIError + tool_safe (structured-error wrapper)
tools/
profile.py whoami
posts.py create / poll / reshare / update / delete
media.py image / video / document upload
social.py comment (always) + react / unreact / social metadata (LINKEDIN_ENABLE_SOCIAL_FEED)
organizations.py company tools, gated behind LINKEDIN_ENABLE_ORGLicense
MIT
Available Tools
10 toolslinkedin_commentA
Comment on a post, or reply to a comment.
Scope: w_member_social.
Args:
actor_urn: Who is commenting (urn:li:person:... or org URN).
object_urn: The post URN being commented on.
text: The comment body.
parent_comment_urn: If replying to a comment, that comment's URN.
Inputs: text (required), actor_urn (required), object_urn (required), parent_comment_urn.
linkedin_create_pollA
Create a poll post with 2–4 options.
Poll content cannot be edited after creation. Do not ask for political opinions, health status, or other sensitive data (LinkedIn policy).
Args: author_urn: The author URN. question: The poll question (used as the post commentary). options: 2 to 4 answer options. duration: ONE_DAY, THREE_DAYS, SEVEN_DAYS, or FOURTEEN_DAYS.
Inputs: options (required), question (required), author_urn (required), duration, +1 more.
linkedin_create_postA
Create a LinkedIn post. Supports text, image, multi-image, video, document, and article/link posts — pick ONE media type per call.
Text only: pass just
commentary.Image: upload with
linkedin_upload_imagefirst, pass its URN inimage_urns(1 = single image, 2–20 = multi-image carousel).Video: pass
video_urnfromlinkedin_upload_video.Document: pass
document_urnfromlinkedin_upload_document.Article/link: pass
article_url(+ optional title/description); no upload needed.
Args:
author_urn: urn:li:person:... (self) or urn:li:organization:... (page).
commentary: The post text (an empty string is coerced to a single space).
visibility: PUBLIC, CONNECTIONS, or LOGGED_IN.
image_urns: Image URNs for an image/multi-image post.
image_alt_texts: Optional alt text per image (same order as image_urns).
video_urn: A video URN for a video post.
document_urn: A document URN for a document post.
article_url: A URL for an article/link post.
Inputs: author_urn (required), commentary (required), video_urn, image_urns, +8 more.
linkedin_delete_postC
Delete a post.
Args: post_urn: The post URN to delete.
Inputs: post_urn (required).
linkedin_get_profileA
Get the authenticated member's LinkedIn profile.
Returns name, email, profile picture, locale and — most importantly — the
member's person URN (e.g. urn:li:person:abc123), which is the
author_urn required by all post-creation tools. Call this first and
reuse the URN.
Inputs: no named parameters.
linkedin_update_postA
Edit an existing post's commentary (text).
LinkedIn's partial-update only supports editing the commentary of an existing post; author, media, and poll content cannot be changed.
Args:
post_urn: The post URN (urn:li:share:... or urn:li:ugcPost:...).
commentary: New post text.
Inputs: post_urn (required), commentary.
linkedin_upload_documentA
Upload a local document (e.g. PDF) and return its document URN.
Reference the returned urn:li:document:... via document_urn on
linkedin_create_post to publish a document/carousel-style post.
Args: author_urn: The owner URN. file_path: Absolute path to a local document (PDF).
Inputs: file_path (required), author_urn (required).
linkedin_upload_imageA
Upload a local image file and return its image URN.
Pass the returned urn:li:image:... to linkedin_create_post as one
of image_urns (one image = single-image post, 2–20 = multi-image).
Args:
author_urn: The owner URN (urn:li:person:... or urn:li:organization:...).
file_path: Absolute path to a local image (PNG/JPG/GIF).
Inputs: file_path (required), author_urn (required).
linkedin_upload_videoB
Upload a local video file and return its video URN.
LinkedIn processes video asynchronously; a freshly uploaded video may take a short while before a post referencing it goes fully live.
Args: author_urn: The owner URN. file_path: Absolute path to a local video (MP4).
Inputs: file_path (required), author_urn (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 10 tools
Each tool targets a distinct resource+action: three upload tools split cleanly by media type (image/video/document), and the post operations (create, create_poll, reshare, update, delete) plus comment and get_profile are mutually exclusive in purpose. Descriptions reinforce the boundaries, e.g. noting that create_post takes exactly one media type.
Every tool follows a uniform linkedin_verb_noun snake_case pattern (upload_video, create_post, create_poll, reshare_post, update_post, delete_post, get_profile). No mixed conventions or vague verbs appear.
Ten tools is well-scoped for the domain: uploads, post lifecycle, engagement, and identity lookup each earn their place with no redundancy or filler.
Post creation lifecycle (create/update/delete), media uploads, polls, reshares, comments, and profile lookup are all covered, forming a coherent surface. Minor gaps remain: no read/list tools for existing posts or comments, and no reaction/like operations, but core publishing workflows are fully achievable.
Maintenance
Related MCP Connectors
Create, schedule, and publish social posts, manage accounts, and read analytics as MCP tools.
Publish and schedule social posts, upload media, and review analytics through OAuth.
Create, schedule, and publish social posts through the hosted SocialSpool MCP connector.
Draft, validate, publish, schedule, and manage social posts across connected accounts.
Related MCP Servers
AlicenseAqualityBmaintenanceEnables managing social media posts, accounts, and AI-powered content features from any MCP client, including scheduling, publishing, analysis, and AI caption generation.1423 npmMIT- AlicenseNot gradedqualityCmaintenanceEnables MCP-compatible assistants to manage social publishing workflows, including creating drafts, uploading media, scheduling, publishing, and monitoring delivery.11 npmApache 2.0
- AlicenseNot gradedqualityCmaintenanceEnables signed-in users to create, edit, and delete their own LinkedIn posts, including text, images, video, documents, or article links, and to list locally tracked posts and check the authenticated account.3 npmMIT

Tempost MCP Serverofficial
AlicenseNot gradedqualityCmaintenanceEnables MCP clients to schedule and publish social media posts across connected channels, manage posts and media, and retrieve channel or post analytics.MIT