Post to LinkedIn as the signed-in member and read their basic profile: create and delete posts, register image uploads. Uses a member access token from the LinkedIn developer portal. Reading posts and company pages needs LinkedIn's approval of the app. 5 tools.
7 天免费 · 无需信用卡 · EU 托管
问 LinkedIn 任何事
通过 AnythingMCP 对 LinkedIn 试一个真实提示 — Claude 调用工具并返回答案。在你的消息上按 Enter 即可在 Cloud 安装。
在 Cloud 上安装 LinkedInClaude 是 AI,可能会出错。请核对回答。
2 分钟设置
- 1在 cloud.anythingmcp.com 开始免费试用。
- 2在连接器商店点击 LinkedIn。提示时粘贴凭据。
- 3生成 MCP API 密钥,将 AI 客户端指向生成的 MCP URL。
LinkedIn 指南
面向主流 AI 客户端的逐步设置。
配置 LinkedIn
直接来自连接器定义:在哪里获取凭据、需要哪些权限,以及该适配器调用的是哪个 API。 由连接器作者以英文提供。
This connector posts to LinkedIn as the member whose access token you paste, and reads that member's basic profile. Posts and images go through LinkedIn's versioned API at https://api.linkedin.com/rest with the header LinkedIn-Version: 202609; the profile comes from the OpenID Connect endpoint https://api.linkedin.com/v2/userinfo, which is not versioned.
What LinkedIn allows. LinkedIn's API is tightly gated. Without a review by LinkedIn an app gets two self-serve products: Sign In with LinkedIn using OpenID Connect (scopes openid, profile, email) and Share on LinkedIn (scope w_member_social: create and delete the member's own posts, upload images). Reading posts (r_member_social), posting for a company page (w_organization_social), and searching people or connections all need LinkedIn's approval of the app for the Community Management API. A token without those scopes cannot reach them, whatever the connector does.
Setup.
- Create an app at https://www.linkedin.com/developers/apps. LinkedIn asks you to link it to a company page.
- On the app's Products tab, add Sign In with LinkedIn using OpenID Connect and Share on LinkedIn.
- Open https://www.linkedin.com/developers/tools/oauth, pick the app, tick
openid,profile,emailandw_member_social, and generate a token, signed in as the member you want to post as. - Paste the token into
LINKEDIN_ACCESS_TOKENand install. Tokens last 60 days; then generate a new one and update the variable.
Posting.
- Call
linkedin_userinfo. Itssubis the member id; the author URN isurn:li:person:<sub>. - Call
linkedin_create_postwith thatauthorand the text incommentary. Visibility defaults toPUBLIC(orCONNECTIONSfor the member's network only); the post goes to the main feed and is published at once, LinkedIn has no drafts here. LinkedIn answers 201 with an empty body: the new post's URN (urn:li:share:...orurn:li:ugcPost:...) is in thex-restli-idresponse header, which the tool returns with the result. linkedin_delete_posttakes that URN as it is, for exampleurn:li:share:7123456789012345678; the connector encodes it for the address. Deleting is idempotent.
Images. linkedin_register_image_upload with {owner: 'urn:li:person:<sub>'} returns an uploadUrl and an image URN (urn:li:image:...). The file itself has to be sent to uploadUrl with an HTTP PUT outside this connector. Then create the post with content: {media: {id: '<image URN>'}}.
Links. LinkedIn does not fetch a preview from the address, so a link post needs the details itself: content: {article: {source: '<URL>', title: '<title>', description: '<optional>'}}, with an uploaded image URN as thumbnail if you want a picture.
Reading a post. linkedin_get_post needs r_member_social, which LinkedIn grants to approved apps only. With the two self-serve products it answers 403, even for the member's own posts.
Errors. 401: the token expired or was revoked; generate a new one. 403 ACCESS_DENIED: the token lacks the scope for that call (see above). 400 MISSING_FIELD or INVALID_URN_TYPE: check that author is urn:li:person:<sub> and that commentary is not empty. 426 or a version error: LinkedIn retired the LinkedIn-Version the tools send (each version is supported for at least a year); update the connector from the catalog. 429: the daily limit per member and app; try again later.