tools/call over POST /linkedin-ads/mcp. The connector is connected with OAuth
(LinkedIn login). See Forbind din konto.
Endpoint:
https://mcp.consile.ai/linkedin-ads/mcp. LinkedIn Ads is its own
named connector with only its own tools. Tool names are namespaced as
linkedin-ads__<tool> in the transport (e.g. linkedin-ads__list_ad_accounts);
the AI resolves these automatically.Scopes & authentication
The connector requests three OAuth scopes from LinkedIn:| Scope | What it enables |
|---|---|
r_ads | Read ad accounts, campaign groups, campaigns, creatives, users |
rw_ads | All ad-management write tools (create/update/status/budget) |
r_ads_reporting | All analytics, demographics, ROAS, forecasts, audiences, conversions, lead forms |
r_organization_admin,
r_organization_social, w_organization_social, w_member_social,
r_basicprofile, r_1st_connections_size) are not requested in v1 because
LinkedIn rejects the full authorization if any requested scope is unapproved. Until
the app receives Community Management API approval, the 8 organic-social write tools
are exposed but fail with HTTP 403. All read tools for organization pages, posts,
comments, reactions, member profile, and connection count still work within the
r_ads surface.
LinkedIn access tokens do not come with a standard
refresh_token unless the app
is in the LinkedIn Marketing Developer Program (MDP). Re-authorize in the portal
approximately every 60 days if the connector stops responding.Guardrail model (write tools)
All 19 write tools pass through the connector-localapplyOrPreview guardrail.
The rules are:
- New ad objects (
create_campaign_group,create_campaign) are created inDRAFTstatus by default. They do not serve and do not spend. - New organic posts (
create_organization_post,create_member_post) default toDRAFTlifecycle. They are not publicly visible. - Confirmation required (
confirm: true) whenever the action:- sets status to
ACTIVE(starts serving / spending); - sets status to
ARCHIVED(destructive); - changes a budget or bid amount;
- publishes public content (a post, comment, or reaction);
- removes a campaign↔conversion association.
- sets status to
- Without
confirm: true, the tool returns aWritePreviewobject (the exact method, path, and body it would send) and calls no upstream API. - Setting status to
PAUSEDorDRAFTis always safe and applies without confirmation (stops serving/spend immediately).
WritePreview shape
When a confirmation-gated tool is called withoutconfirm: true, it returns:
Shared parameters
Numeric ids
Most tools take bare numeric id strings (digits only, no URN prefix). The connector builds the required URNs internally.LinkedIn ad account id (digits only). Obtain from
list_ad_accounts or
search_ad_accounts.Campaign group id (digits only). From
list_campaign_groups.Campaign id (digits only). From
list_campaigns.Organization (Company Page) id (digits only). From
list_administered_organizations.Money format
All money values (budgets, bids, conversion values) use LinkedIn’s major-unit format: a decimal string plus a currency code (not micros).currencyCode must match the ad account’s currency. Supply amounts as
dailyBudgetAmount / totalBudgetAmount / unitCostAmount (string) plus
currencyCode (ISO 4217 three-letter code).
Limit
Maximum rows returned by list/finder tools (max 1000). The client paginates
internally and returns up to
limit elements.Analytics facet
The analytics tools (get_ad_analytics, get_ad_statistics, get_ad_demographics,
get_attributed_revenue) require exactly one of these facets:
Ad account ids to report on (most common).
Campaign ids to report on.
Campaign group ids to report on.
Read tools (45)
Ad accounts & structure
list_ad_accounts
List every ad account the connected member can access, with account URN and role. The entry point that yields the account ids all other tools take.search_ad_accounts
Search accessible ad accounts with full detail (currency, status, servingStatuses, type). No filter returns all accessible accounts.Filter by account status. Enum:
ACTIVE DRAFT CANCELED
PENDING_DELETION REMOVED.get_ad_account
Fetch one ad account by id: currency, status, type, servingStatuses, reference, notification flags, test flag.list_ad_account_users
List all users and roles on a given ad account (audit who has access). Inverse oflist_ad_accounts.
list_campaign_groups
Search/list campaign groups under an account (the budget/status container above campaigns): name, status, runSchedule, totalBudget/dailyBudget, objective.Filter by status. Enum:
ACTIVE PAUSED DRAFT ARCHIVED REMOVED.get_campaign_group
Fetch one campaign group: name, status, runSchedule, totalBudget/dailyBudget, servingStatuses, objective.list_campaigns
Search/list campaigns within an account: status, type, objectiveType, costType, budgets, bid (unitCost), runSchedule, targetingCriteria, servingStatuses.Filter by status. Enum:
ACTIVE PAUSED DRAFT ARCHIVED COMPLETED
REMOVED.Scope to one campaign group id.
get_campaign
Fetch one campaign with full targetingCriteria, budgets, bid (unitCost), runSchedule, objectiveType, optimizationTargetType, servingStatuses, versionTag.list_creatives
Search/list creatives (ads) under an account: reference, status (intendedStatus), variant content.get_creative
Fetch one creative by its URN (status, content reference, variant/intendedStatus).The creative URN, e.g.
urn:li:sponsoredCreative:123.get_ad_preview
Render a preview of an existing creative in a placement, matching the render LinkedIn Campaign Manager shows.urn:li:sponsoredCreative:123 to preview.Reporting & analytics
get_ad_analytics
Core single-pivot performance report: group metrics by one dimension over a date range and time granularity. Cost fields are decimal strings in the account currency (not micros).Dimension to group by. One of:
COMPANY ACCOUNT SHARE CAMPAIGN
CREATIVE CAMPAIGN_GROUP CONVERSION CONVERSION_COMPONENT
OBJECTIVE_TYPE SERVING_LOCATION PLACEMENT_NAME
IMPRESSION_DEVICE_TYPE, plus the MEMBER_* demographic set (see
get_ad_demographics).Time bucketing:
ALL (one total) | DAILY | MONTHLY | YEARLY.Report window start (YYYY-MM-DD).
Report window end (YYYY-MM-DD).
Ad account ids (most common facet; provide exactly one facet).
Campaign ids (alternative facet).
Campaign group ids (alternative facet).
CSV of metric fields (max 20). Defaults to:
impressions,clicks,costInLocalCurrency,externalWebsiteConversions,oneClickLeads,landingPageClicks.get_ad_statistics
Multi-dimensional report: group metrics by up to three pivots at once (e.g. CAMPAIGN × CREATIVE × SERVING_LOCATION) for cross-tabs the single-pivot finder cannot express.1–3 dimensions from the same enum as
get_ad_analytics.get_ad_demographics
Professional-demographic breakdown: analytics pivoted by aMEMBER_* dimension
(company/size/industry/seniority/job title/function/country/region): “who saw or
engaged with my ads”. Data is delayed approximately 12–24 hours; resolve the
returned URNs with resolve_targeting_urns.
One of:
MEMBER_COMPANY MEMBER_COMPANY_SIZE MEMBER_INDUSTRY
MEMBER_SENIORITY MEMBER_JOB_TITLE MEMBER_JOB_FUNCTION
MEMBER_COUNTRY_V2 MEMBER_REGION_V2 MEMBER_COUNTY.Defaults to
impressions,clicks,costInLocalCurrency.get_attributed_revenue
CRM revenue-attribution report (ROAS, won/open opportunities, deal size, days-to-close) by ACCOUNT / CAMPAIGN_GROUP / CAMPAIGN. Returns empty results unless the advertiser has connected a CRM to Business Manager.1–3 from
ACCOUNT CAMPAIGN_GROUP CAMPAIGN.CSV of
revenueAttributionMetrics fields.get_budget_pricing
Suggested, minimum and maximum bids plus daily-budget limits for a bid/campaign type on an account. Forecast only. No spend.e.g.
CPM, CPC, CPV.e.g.
SPONSORED_UPDATES, TEXT_AD, DYNAMIC.Optional bid match type.
Advanced: a pre-built RestLi targetingCriteria fragment (passed verbatim).
{amount, currencyCode} money objects.
forecast_ad_supply
Forecast impressions, clicks, spend, reach, and leads for a hypothetical campaign’s targeting + competing bid over a time range.e.g.
SPONSORED_UPDATES.A pre-built RestLi targeting fragment (
target.includedTargetingFacets:...).Forecast window start (epoch ms).
Forecast window end (epoch ms).
Optional competing bid fragment.
get_organization_page_statistics
Organization page view and click statistics. Lifetime breakdown (by geo, country, function, industry, seniority, staffCountRange) is shown when no time interval is given.get_organization_follower_statistics
Follower demographics (lifetime, by 7 facets). The total count is not here. Useget_organization_follower_count for that.
get_organization_share_statistics
Organic engagement stats for an org’s posts: aggregate lifetime stats (impressions, clicks, likes, comments, shares, engagement rate). Organic only. For sponsored content useget_ad_analytics.
Audiences & targeting
get_audience_count
Estimate the reachable LinkedIn audience size (active + total) for a targetingCriteria expression. Validates the 300-member campaign minimum before launch. Returnstotal: 0 when the audience is below LinkedIn’s privacy floor.
A pre-built RestLi targetingCriteria fragment. Build facet URNs with the
targeting tools below.
list_targeting_facets
List all targeting facet categories (industries, titles, seniorities, skills, locations, jobFunctions, staffCountRanges, interests, etc.) and which entity finders each supports. The catalog you buildtargetingCriteria from.
No arguments.
list_targeting_entities
Enumerate all values for an enumerable facet (e.g. seniorities, genders, jobFunctions, ageRanges), resolving closed-list facets to URNs.The facet name (e.g.
seniorities) or a full adTargetingFacet URN.Optional locale, e.g.
en_US.typeahead_targeting_entities
Free-text search for targeting entity URNs within a facet (find geo / skill / company / title / field-of-study URNs). The main way to turn natural-language words into targeting URNs.The facet name (e.g.
locations, skills) or a full adTargetingFacet URN.Free-text search, e.g.
Copenhagen or machine learning.Optional locale, e.g.
en_US.similar_targeting_entities
Given seed entity URN(s) in a facet, return similar entities (lookalike companies / industries / skills / titles) for audience expansion.The facet name or a full adTargetingFacet URN.
Seed entity URNs (at least one).
resolve_targeting_urns
Resolve a batch of entity URNs to human-readable names and facet membership (e.g.urn:li:geo:102095887 → "California, United States") to display a
campaign’s stored targeting or demographics.
Entity URNs to resolve (at least one).
Conversions & Insight Tag
list_conversion_rules
List all conversion rules for an ad account (includingconversionMethod=CONVERSIONS_API
and enabled flags). The value field is {currencyCode, amount} in major units.
get_conversion_rule
Fetch one conversion rule by id: type, attribution windows, value, urlMatchRuleExpression, associated campaigns, imagePixelTag.Numeric conversion id (digits only).
get_insight_tag
Find the Insight Tag for an ad account and retrieve its tracking snippet and firstParty state.list_insight_tag_domains
List domains observed firing the account’s Insight Tag (most recent first) with blocked status and last-callback time. Verify tag installation.list_campaign_conversions
List all conversion-rule associations for one or more campaigns (which campaigns attribute which conversions).Campaign ids to look up (at least one).
Lead form definitions
These tools expose form structure only: questions, hidden fields,
consent text, post-submission CTA. Retrieving actual submitted lead PII requires
the separate LinkedIn Lead Sync API program (
r_marketing_leadgen_automation),
which is not part of this connector.list_lead_forms
List lead gen form definitions for an ad account.get_lead_form
Fetch one lead gen form definition by id (full questions, hidden fields, consents, post-submission CTA).Numeric form id (digits only).
Organization pages & organic content (read)
list_administered_organizations
List the organizations the connected member administers (org URN, role, state). The entry point for organization selection. Filter toADMINISTRATOR + APPROVED
for usable organizations.
get_organization
Fetch full admin-visible org profile by id (name, website, industries, locations, logo, staffCountRange).find_organization_by_vanity_name
Resolve an organization by its vanityName (URL slug) to its URN and profile.The URL slug, e.g.
microsoft.get_organization_follower_count
Total first-degree follower count for an organization (the headline number).list_organization_posts
List organic posts authored by an organization (the page’s content feed), newest first.LAST_MODIFIED or CREATED.get_post
Fetch a single organic post by its share/ugcPost URN (commentary, author, visibility, content).urn:li:share:123 or urn:li:ugcPost:123.get_post_social_metadata
Reaction and comment summary for a post (commentsState, commentSummary, reactionSummaries by type). Works for organic and sponsored posts.The post/share/ugcPost URN.
list_post_comments
List comments on a post (or nested replies on a comment).The post/share/ugcPost URN.
list_post_reactions
List reactions on a post or comment withreactionType
(LIKE / PRAISE / EMPATHY / INTEREST / APPRECIATION / ENTERTAINMENT).
The post/share/ugcPost URN.
Member profile
get_my_profile
The connected member’s own profile: id (person URN), name, headline, vanityName (public-URL slug), photo. Also useful as a connect-confirmation / whoami check. No arguments.get_my_connections_count
The connected member’s number of first-degree connections (count only, not the list). The viewer is implied by the access token. No arguments.Number of first-degree connections.
Advanced: query (read escape-hatch)
query
GET any allow-listed LinkedIn REST or v2 path with a safelisted set of read parameters, for the long tail not covered by a dedicated tool. Read-only by construction (GET-only + path and param guard).A bare path under
/rest or /v2, e.g. /rest/adCampaigns/123 or /v2/me
(no scheme, no traversal).Read params as a string/number record. Only safelisted keys are forwarded;
others are dropped silently. Percent-encode URN values. Allowed keys include:
q, fields, projection, start, count, pageSize, pageToken,
search, pivot, pivots, timeGranularity, dateRange, facet,
query, urns, entities, ids, owner, account, organization,
sort, sortBy, sortOrder, edgeType.adAccounts, adAccountUsers,
adCampaignGroups, adCampaigns, creatives, adPreviews, adAnalytics,
adBudgetPricing, adSupplyForecasts, audienceCounts, adTargetingFacets,
adTargetingEntities, conversions, insightTags, insightTagDomains,
campaignConversions, leadForms, organizations, organizationAcls,
organizationPageStatistics, organizationalEntityFollowerStatistics,
organizationalEntityShareStatistics, networkSizes, posts,
socialMetadata, socialActions, reactions, me, connections, geo.
Ad-management write tools (11)
All 11 tools go through the guardrail described above. See Handlinger & guardrails for the full model.Campaign groups
create_campaign_group
Create a campaign group (the budget/status container above campaigns). Created DRAFT by default (no serving);status: "ACTIVE" requires confirm: true.
1–100 characters.
runSchedule.start (epoch ms).
runSchedule.end (epoch ms; required if totalBudget is set).
DRAFT | ACTIVE | PAUSED | ARCHIVED. ACTIVE requires confirm: true.Total budget as a decimal string (major units).
ISO 4217 code; required when a budget amount is provided.
Set
true to apply when confirmation is required.update_campaign_group
Edit a campaign group’s name, schedule, or total budget. A budget change always requiresconfirm: true.
New runSchedule.end (epoch ms).
set_campaign_group_status
Set a campaign group to DRAFT / ACTIVE / PAUSED / ARCHIVED. PAUSED stops serving immediately and applies without confirmation. ACTIVE and ARCHIVED requireconfirm: true.
DRAFT | ACTIVE | PAUSED | ARCHIVED.Campaigns
create_campaign
Create a campaign under a group. Created DRAFT by default (no spend).status: "ACTIVE" requires confirm: true. Money is major units.
Parent campaign group id.
Campaign type, e.g.
SPONSORED_UPDATES, TEXT_AD, DYNAMIC.Bidding cost type:
CPM | CPC | CPV.locale.country (ISO 3166-1 alpha-2).
locale.language (ISO 639-1).
Daily budget (decimal string). Provide daily OR total.
Total budget (decimal string). Provide daily OR total.
Required when a budget amount is provided.
Bid (unitCost) amount (decimal string).
targetingCriteria as a JSON object string. Build URNs with the targeting read tools.
e.g.
WEBSITE_VISITS, LEAD_GENERATION, BRAND_AWARENESS.Required by LinkedIn (2025-08+) on create; set the value appropriate to your account/region.
DRAFT | ACTIVE | PAUSED | ARCHIVED. ACTIVE requires confirm: true.update_campaign
Edit a campaign’s name, budgets, bid (unitCost), or targetingCriteria. A budget or bid change always requiresconfirm: true.
New targetingCriteria as a JSON object string.
set_campaign_status
Set a campaign to DRAFT / ACTIVE / PAUSED / ARCHIVED. PAUSED stops spend immediately (no confirmation needed). ACTIVE and ARCHIVED requireconfirm: true.
DRAFT | ACTIVE | PAUSED | ARCHIVED.Creatives
set_creative_status
Set a creative (ad) to DRAFT / ACTIVE / PAUSED / ARCHIVED. PAUSED is immediate. ACTIVE (starts serving and spending) and ARCHIVED requireconfirm: true.
urn:li:sponsoredCreative:123.DRAFT | ACTIVE | PAUSED | ARCHIVED.Conversion tracking
create_conversion_rule
Create a conversion rule for an account (measurement setup; does not spend). Returns the new id and the imagePixelTag snippet. Applies withoutconfirm: true
by default (measurement only, no spend or publish).
e.g.
LEAD, PURCHASE, SIGN_UP, ADD_TO_CART, DOWNLOAD, KEY_PAGE_VIEW.LAST_TOUCH_BY_CAMPAIGN | LAST_TOUCH_BY_CONVERSION.Post-click attribution window (days).
View-through attribution window (days).
Optional fixed conversion value (decimal string, major units).
Required when
valueAmount is provided.update_conversion_rule
Edit a conversion rule’s name, enabled state, or value. Editing the value does not retroactively re-attribute past events. Applies withoutconfirm: true.
associate_campaign_conversion
Attach a conversion rule to a campaign so that campaign attributes that conversion. Use theurn:lla conversion URN form (e.g.
urn:lla:llaPartnerConversion:123). Applies without confirm: true.
urn:lla:llaPartnerConversion:123 (note the urn:lla namespace).remove_campaign_conversion
Detach a conversion rule from a campaign (stops conversion attribution for that campaign). Destructive to reporting and optimization. Requiresconfirm: true.
urn:lla:llaPartnerConversion:123.Organic-social write tools (8): requires Community Management API approval
When activated, the same guardrail applies: new posts default to DRAFT lifecycle (not publicly visible), and publishing public content (a published post, a comment, or a reaction) and deleting content requireconfirm: true.
Posts
create_organization_post
Publish an organic post authored by an organization (Company Page). Defaults toDRAFT lifecycle (not publicly visible); lifecycleState: "PUBLISHED" publishes
public content under the brand and requires confirm: true.
Post text (supports #hashtags).
PUBLIC | CONNECTIONS | LOGGED_IN.DRAFT | PUBLISHED. PUBLISHED requires confirm: true.create_member_post
Publish an organic post authored by the connected member (person). Defaults toDRAFT; PUBLISHED posts public content under the member’s name and requires
confirm: true. The author is resolved from /v2/me and is never taken from tool input.
Post text.
PUBLIC | CONNECTIONS | LOGGED_IN.DRAFT | PUBLISHED. PUBLISHED requires confirm: true.update_post
Edit a post’s commentary or lifecycleState. Editing the text of a (possibly public) post, or publishing a DRAFT (lifecycleState: "PUBLISHED"), mutates
public content and requires confirm: true.
urn:li:share:123 or urn:li:ugcPost:123.DRAFT | PUBLISHED.delete_post
Permanently delete a post. Irreversible removal of (possibly public) content. Requiresconfirm: true.
urn:li:share:123 or urn:li:ugcPost:123.Comments & reactions
create_comment
Post a public comment on a post, as the organization (passorganizationId) or
the connected member. Public content under the brand or member identity. Requires
confirm: true.
The post/share/ugcPost URN to comment on.
The comment text.
Comment AS this organization; omit to comment as the connected member.
delete_comment
Delete a comment on a post (your own, or moderating others’ comments on your post), as the organization or the connected member. Destructive. Requiresconfirm: true.
The post/share/ugcPost URN the comment is on.
The comment id (numeric id or full comment URN).
Acting AS this organization; omit to act as the connected member.
create_reaction
React (LIKE / PRAISE / EMPATHY / INTEREST / APPRECIATION / ENTERTAINMENT) to a post, as the organization or the connected member. A public brand or member action. Requiresconfirm: true.
The post/share/ugcPost URN to react to.
LIKE | PRAISE | EMPATHY | INTEREST | APPRECIATION | ENTERTAINMENT.React AS this organization; omit to react as the connected member.
delete_reaction
Remove a reaction previously made (as the organization or the connected member) from a post. Low-stakes cleanup. Applies withoutconfirm: true.
The post/share/ugcPost URN the reaction is on.
The reaction’s actor was this organization; omit for the connected member.
Code examples
A revoked or expired access token returns an authentication error. Re-authorize
in the portal (approximately every 60 days). See
Errors & limits.