Publish text or article/URL shares to one connected LinkedIn personal profile and manage LinkedIn Campaign Manager through the Marketing/Advertising API. Share operations support personal profile lookup and text/article posting. Image and video shares are intentionally not included because LinkedIn requires a separate binary upload to a per-asset URL. Manage LinkedIn Campaign Manager through the Marketing/Advertising API: ad accounts, campaign groups, campaigns, creatives, and analytics reporting. The hierarchy is account -> campaign group -> campaign -> creative. Requires an approved LinkedIn Advertising API application. Calls succeed only with the vetted scopes r_ads (read), rw_ads (read/write), and r_ads_reporting (analytics), and an ad-account role that permits the action (VIEWER is read-only even with rw_ads). Money is an object {amount, currencyCode} where amount is a decimal STRING, e.g. {"amount":"50.00","currencyCode":"USD"}. runSchedule uses epoch milliseconds. Activating a campaign or creative (status/intendedStatus ACTIVE) spends real budget against the account's funding source. VX Agents stores one OAuth2 connection per uploaded spec, so the connected LinkedIn application must be approved for every requested Share and Ads scope.
Connect this API to an AI agent Browse all specs
What you can do with linkedin via MCP
Every endpoint below becomes a governed tool your AI agent (Claude, ChatGPT, or a customer-facing VX agent) can call — with scoped permissions, sandbox testing, and audit logs.
| Method | Path | Operation | Description |
|---|---|---|---|
| GET | /v2/userinfo |
getLinkedInProfile | Get the connected LinkedIn personal profile before publishing |
| POST | /v2/ugcPosts |
createLinkedInShare | Publish a LinkedIn personal share (text, or an article/URL link). IMPORTANT: confirm the exact text, any link, and the connected profile with the user before calling; a share cannot be silently undone. Do not retry after an ambiguous failu… |
| GET | /rest/adAccounts |
getAdAccounts | List the ad accounts the connected member can access |
| GET | /rest/adAccounts/{adAccountId} |
getAdAccount | Get a single ad account by id |
| GET | /rest/adAccounts/{adAccountId}/adCampaignGroups |
getCampaignGroups | List campaign groups in an ad account |
| POST | /rest/adAccounts/{adAccountId}/adCampaignGroups |
createCampaignGroup | Create a campaign group (confirm budget and dates with the user first). |
| GET | /rest/adAccounts/{adAccountId}/adCampaignGroups/{campaignGroupId} |
getCampaignGroup | Get a single campaign group by id |
| POST | /rest/adAccounts/{adAccountId}/adCampaignGroups/{campaignGroupId} |
updateCampaignGroup | Update a campaign group via partial update (confirm spend-affecting changes with the user first). |
| DELETE | /rest/adAccounts/{adAccountId}/adCampaignGroups/{campaignGroupId} |
deleteCampaignGroup | Delete a DRAFT campaign group (confirm with the user first; cannot be undone). |
| GET | /rest/adAccounts/{adAccountId}/adCampaigns |
getCampaigns | List campaigns in an ad account |
| POST | /rest/adAccounts/{adAccountId}/adCampaigns |
createCampaign | Create a campaign (confirm budget, bid, dates, and targeting with the user first — an ACTIVE campaign spends real money). |
| GET | /rest/adAccounts/{adAccountId}/adCampaigns/{campaignId} |
getCampaign | Get a single campaign by id |
| POST | /rest/adAccounts/{adAccountId}/adCampaigns/{campaignId} |
updateCampaign | Update a campaign via partial update (confirm spend-affecting changes with the user first). |
| DELETE | /rest/adAccounts/{adAccountId}/adCampaigns/{campaignId} |
deleteCampaign | Delete a DRAFT campaign (confirm with the user first; cannot be undone). |
| GET | /rest/adAccounts/{adAccountId}/creatives |
getCreatives | List creatives in an ad account |
| POST | /rest/adAccounts/{adAccountId}/creatives |
createCreative | Create a creative (confirm with the user first — an ACTIVE creative begins serving and spending under its campaign). |
| POST | /rest/adAccounts/{adAccountId}/creatives/{creativeId} |
updateCreative | Update a creative via partial update (confirm with the user first). |
| DELETE | /rest/adAccounts/{adAccountId}/creatives/{creativeId} |
deleteCreative | Delete a creative (confirm with the user first; cannot be undone). |
| GET | /rest/adAnalytics |
getAdAnalytics | Get advertising performance analytics |
Authentication
LinkedInOAuth2
OAuth 2.0
Scopes: openid profile w_member_social r_ads rw_ads r_ads_reporting
Usage guide
Connect
- Add to agent, then Connect LinkedIn in the agent's Connections tab. No LinkedIn developer app is needed.
- Sign in with the LinkedIn member who will post, and who has a role on the ad accounts the agent should manage.
- Posting needs
w_member_social. Ads tools needr_ads(read),rw_ads(write) andr_ads_reporting(analytics); the member must be an ad account user in Campaign Manager.
Posting
- Call
getLinkedInProfilefirst and confirm with the user which profile is connected. createLinkedInSharepublishes text, or text with an article/URL link, to that personal profile. Company pages and image/video posts are not supported.- Always show the user the exact text and link before publishing. A share cannot be silently undone, and an ambiguous failure must not be retried blindly: check the profile's feed first.
Ads (Campaign Manager)
| Step | Tools |
|---|---|
| Find accounts | getAdAccounts, getAdAccount |
| Read structure | getCampaignGroups, getCampaigns, getCreatives and their single-item variants |
| Report | getAdAnalytics (pivot by campaign or creative, with a date range and granularity) |
| Change | create*, update*, delete* for campaign groups, campaigns and creatives |
- Every write can spend money: confirm budget, bid, dates, targeting and status with the user before calling. Create new campaigns as DRAFT or PAUSED and let the user activate them.
- Only DRAFT campaign groups and campaigns can be deleted.
- Ads calls need the
LinkedIn-Versionheader (formatYYYYMM) andX-Restli-Protocol-Version: 2.0.0; pin them as preset parameters so the model does not have to guess.
Errors
- 401: the LinkedIn connection expired; reconnect.
- 403: the member lacks the scope or has no role on that ad account.
- An error about the API version: update the pinned
LinkedIn-Versionto a currently supported month (for example202607).
How to use this spec
- Create a free VX Agents account (sandbox tools included).
- Open the marketplace and connect “linkedin” to an agent.
- Expose it as an MCP server for Claude/ChatGPT, or chat with it directly.