Skip to main content
Glama
southleft

LinkedIn Intelligence MCP Server

by southleft

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
LOG_LEVELNoLogging level (DEBUG, INFO, WARNING, ERROR)INFO
DATABASE_URLNoDatabase connection URLsqlite+aiosqlite:///data/linkedin_mcp.db
LINKEDIN_API_ENABLEDNoEnable the LinkedIn API clientfalse
FEATURE_POST_SCHEDULINGNoEnable post schedulingtrue
FEATURE_BROWSER_FALLBACKNoEnable Playwright browser automationtrue
FEATURE_ANALYTICS_TRACKINGNoEnable analytics featurestrue

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{
  "tasks": {
    "list": {},
    "cancel": {},
    "requests": {
      "tools": {
        "call": {}
      },
      "prompts": {
        "get": {}
      },
      "resources": {
        "read": {}
      }
    }
  }
}

Tools

Functions exposed to the LLM to take actions

NameDescription
debug_context

Debug tool to check the internal state of the MCP server.

Returns information about:

  • Whether LinkedIn client is initialized

  • Settings configuration

  • Cookie file status

  • Initialization errors

get_my_profile

Get the authenticated user's LinkedIn profile.

Returns profile data including:

  • Basic info (name, email, picture)

  • LinkedIn member ID

Uses the Official LinkedIn API (OAuth 2.0) when available for reliable results. Falls back to unofficial API if official client is not configured.

get_profile

Get comprehensive LinkedIn profile data with multi-source enrichment.

Uses the Profile Enrichment Engine to aggregate data from multiple endpoints in parallel, providing the most complete profile information available.

Args: profile_id: LinkedIn public ID (e.g., "johndoe") or URN use_cache: Whether to use cached data if available (default: True) include_activity: Include recent activity/posts (default: True) include_network: Include network stats like connections/followers (default: True) include_badges: Include member badges like Premium status (default: True)

Returns comprehensive profile data including:

  • Basic info (name, headline, location, photo)

  • Contact information (if available)

  • Skills and endorsements

  • Network information (connections, followers, distance)

  • Member badges (Premium, Creator, etc.)

  • Recent activity summary

  • Enrichment metadata showing data sources used

get_profile_contact_info

Get contact information for a LinkedIn profile.

Args: profile_id: LinkedIn public ID

Returns contact info including email, phone, websites, and social profiles.

get_profile_skills

Get skills and endorsements for a LinkedIn profile.

Args: profile_id: LinkedIn public ID

Returns skills categorized by endorsement count with top endorsers.

get_profile_interests

Get profile interests including influencers, companies, groups, and topics.

This data is unique to the Professional Network Data API and provides insights into what/who a person follows on LinkedIn.

Args: profile_id: LinkedIn public ID (e.g., "johndoe")

Returns: Profile interests organized by category (influencers, companies, groups, topics)

get_similar_profiles

Get profiles similar to a given profile.

Uses the Professional Network Data API to find similar profiles based on industry, role, skills, and other factors.

Args: profile_id: LinkedIn public ID (e.g., "johndoe") limit: Maximum number of similar profiles to return (default: 10)

Returns: List of similar profiles with relevance scoring

get_profile_articles

Get articles written by a LinkedIn profile.

Uses the Professional Network Data API to fetch articles (long-form content) published by the specified profile.

Args: profile_id: LinkedIn public ID (e.g., "johndoe") limit: Maximum number of articles to return (default: 20)

Returns: List of articles with title, content preview, and engagement metrics

get_article

Get the full content of a LinkedIn article.

Uses the Professional Network Data API to fetch the complete article content, author information, and engagement metrics.

Args: article_url: Full URL of the LinkedIn article

Returns: Article content with title, body, author info, and engagement data

get_company_by_domain

Get company information by website domain.

Uses the Professional Network Data API to look up a company by its website domain (e.g., "anthropic.com" → Anthropic).

Args: domain: Company website domain (e.g., "anthropic.com")

Returns: Company information including name, industry, size, and LinkedIn URL

get_network_stats

Get statistics about the authenticated user's LinkedIn network.

Returns network size, growth indicators, and connection insights.

batch_get_profiles

Get multiple LinkedIn profiles efficiently.

Args: profile_ids: Comma-separated list of profile public IDs (max 10)

Returns profiles with basic info and success/failure status for each.

get_cache_stats

Get cache statistics and performance metrics.

Returns cache size, hit rate, and memory usage.

get_feed

Get the authenticated user's LinkedIn feed.

Args: limit: Maximum number of feed items to return (default: 10, max: 50) use_cache: Whether to use cached data if available (default: True)

Returns recent feed posts with engagement data.

get_profile_posts

Get posts from a specific LinkedIn profile.

Args: profile_id: LinkedIn public ID or URN limit: Maximum number of posts to return (default: 10, max: 50) use_cache: Whether to use cached data if available (default: True)

Returns posts with engagement metrics (likes, comments, shares).

create_post

Create a new LinkedIn post using the Official API (recommended) or unofficial API.

Uses the Official LinkedIn API with w_member_social scope when available. This is the TOS-compliant method that requires enabling "Share on LinkedIn" product.

Args: text: Post content (max 3000 characters) visibility: Post visibility - PUBLIC or CONNECTIONS

Returns the created post details including post URN.

create_image_post

Create a LinkedIn post with an image using the Official API.

Requires "Share on LinkedIn" product enabled in your LinkedIn Developer app.

Args: text: Post text content (max 3000 characters) image_path: Image source - can be: - Absolute path to local file (JPG, PNG, GIF) - URL to image (http:// or https://) - Base64-encoded image (data:image/png;base64,...) alt_text: Accessibility text describing the image (recommended) visibility: Post visibility - PUBLIC or CONNECTIONS

Returns the created post details including post URN and image URN.

create_video_post

Create a LinkedIn post with a video using the Official API.

Requires "Share on LinkedIn" product enabled in your LinkedIn Developer app.

LinkedIn supports video uploads up to 10 minutes for most users. Supported formats: MP4 (recommended), MOV Maximum file size: 200MB Recommended specs: 1080p, H.264 codec, AAC audio, 30fps

Args: text: Post text content (max 3000 characters) video_path: Video source - can be: - Absolute path to local file (MP4, MOV) - URL to video (http:// or https://) title: Optional title for the video visibility: Post visibility - PUBLIC or CONNECTIONS

Returns the created post details including post URN and video URN. Note: Video may take a few minutes to process before appearing in the feed.

create_document_post

Create a LinkedIn post with a document (PDF, PPTX, DOCX) using the Official API.

Documents appear as carousel-style slideshows in the LinkedIn feed. Great for sharing presentations, guides, reports, etc.

Requires "Share on LinkedIn" product enabled in your LinkedIn Developer app.

Supported formats: PDF (recommended), PPTX, DOCX Maximum file size: 100MB

Args: text: Post text content (max 3000 characters) document_path: Document source - can be: - Absolute path to local file (PDF, PPTX, DOCX) - URL to document (http:// or https://) title: Optional title for the document (defaults to filename) visibility: Post visibility - PUBLIC or CONNECTIONS

Returns the created post details including post URN and document URN.

create_poll

Create a LinkedIn poll using the Official API.

Requires "Share on LinkedIn" product enabled in your LinkedIn Developer app.

Args: question: Poll question (also displayed as post text, max 140 characters) options: Comma-separated poll options (2-4 options, each max 140 characters) duration_days: Poll duration - 1, 3, 7, or 14 days (default: 7) visibility: Post visibility - PUBLIC or CONNECTIONS

Returns the created poll post details.

delete_post

Delete a LinkedIn post using the Official API.

Requires "Share on LinkedIn" product enabled in your LinkedIn Developer app.

Args: post_urn: The URN of the post to delete (e.g., "urn:li:share:123456")

Returns success status.

edit_post

Edit/update an existing LinkedIn post using the Official API.

Requires "Share on LinkedIn" product enabled in your LinkedIn Developer app.

Args: post_urn: The URN of the post to edit (e.g., "urn:li:share:123456") text: New text content for the post (optional, max 3000 characters) image_path: Path to new image file to replace existing media (optional) alt_text: Alt text for the new image (optional)

Returns: Success status with updated fields information.

Note: At least one of 'text' or 'image_path' must be provided. This uses LinkedIn's PARTIAL_UPDATE method to update only specified fields.

create_comment

Create a comment on a LinkedIn post using the Official API.

Requires "Share on LinkedIn" product enabled in your LinkedIn Developer app.

Args: post_urn: The URN of the post to comment on (e.g., "urn:li:share:123456" or "urn:li:activity:123456") text: The comment text content (max 1250 characters) parent_comment_urn: Optional URN of parent comment for nested replies image_path: Optional image source (only for nested replies) - can be: - Absolute path to local file (JPG, PNG, GIF) - URL to image (http:// or https://) - Base64-encoded image (data:image/png;base64,...)

Returns the created comment details including comment ID.

Note: LinkedIn only allows images in nested comments (replies to other comments), not in top-level comments directly on posts.

Note: Commenting requires the "Community Management API" product from LinkedIn, which has a separate approval process. The "Share on LinkedIn" product only allows creating posts, not comments. If you receive a permission error, you'll need to apply for Community Management API access in your Developer Portal.

delete_comment

Delete a comment from a LinkedIn post using the Official API.

Requires "Community Management API" product enabled in your LinkedIn Developer app.

Args: post_urn: The URN of the post containing the comment (e.g., "urn:li:share:123456" or "urn:li:activity:123456") comment_id: The ID or URN of the comment to delete

Returns success status.

Note: You can only delete comments that you have authored.

get_comments_official

Get comments on a LinkedIn post using the Official API.

Requires "Community Management API" product enabled in your LinkedIn Developer app.

Args: post_urn: The URN of the post (e.g., "urn:li:share:123456" or "urn:li:ugcPost:123456") start: Pagination start index (default: 0) count: Number of comments to return (default: 50, max: 100)

Returns list of comments with: - id: Comment ID - urn: Full comment URN (use this as parent_comment_urn to reply) - actor_urn: URN of the comment author - actor_name: Name of the comment author (if available) - text: Comment text content - parent_comment: URN of parent comment if this is a reply - created_at: Timestamp when comment was created

Use the returned comment URN as parent_comment_urn in create_comment to reply to a comment.

create_reaction

Add a reaction to a LinkedIn post or comment using the Official API.

Requires "Community Management API" product enabled in your LinkedIn Developer app.

Args: target_urn: The URN of the post or comment to react to (e.g., "urn:li:share:123456", "urn:li:activity:123456", "urn:li:comment:(urn:li:activity:123,456)") reaction_type: Type of reaction to add. Options: - LIKE (👍 Like) - default - PRAISE or CELEBRATE (👏 Celebrate) - EMPATHY or LOVE (❤️ Love) - INTEREST or INSIGHTFUL (💡 Insightful) - APPRECIATION or SUPPORT (🙏 Support) - ENTERTAINMENT or FUNNY (😄 Funny)

Returns the created reaction details.

Note: The MAYBE reaction type is deprecated and no longer supported.

delete_reaction

Remove a reaction from a LinkedIn post or comment using the Official API.

Requires "Community Management API" product enabled in your LinkedIn Developer app.

Args: target_urn: The URN of the post or comment to remove reaction from (e.g., "urn:li:share:123456", "urn:li:activity:123456")

Returns success status.

Note: This removes your reaction from the specified content.

get_auth_status

Get LinkedIn authentication status for both official and unofficial APIs.

Returns detailed status including:

  • Official API status (OAuth token expiry, available features)

  • Unofficial API status (cookie freshness, available features)

  • Recommended actions if not authenticated

search_ads

Search for ads in the LinkedIn Ad Library.

The Ad Library provides transparency into ads running on LinkedIn. At least one of keyword or advertiser must be provided.

Requires "LinkedIn Ad Library" product enabled in your LinkedIn Developer app.

Args: keyword: Search term to find in ad content advertiser: Company/advertiser name to search for country: ISO 3166-1 alpha-2 country code (e.g., "US", "GB", "DE") count: Number of results to return (default 25, max 100)

Returns: List of ads matching the search criteria with details including: - Advertiser and payer information - Ad content (text, images, videos) - Impression data and targeting parameters

search_ads_by_advertiser

Search for all ads by a specific advertiser/company.

Requires "LinkedIn Ad Library" product enabled in your LinkedIn Developer app.

Args: advertiser_name: Name of the advertiser/company to search for country: Optional country filter (ISO 3166-1 alpha-2 code) count: Number of results to return (default 25, max 100)

Returns: List of ads from the specified advertiser with full details.

search_ads_by_keyword

Search for ads containing a specific keyword.

Requires "LinkedIn Ad Library" product enabled in your LinkedIn Developer app.

Args: keyword: Search term to find in ad content country: Optional country filter (ISO 3166-1 alpha-2 code) count: Number of results to return (default 25, max 100)

Returns: List of ads matching the keyword with full details.

analyze_draft_content

Analyze draft content and get suggestions for improvement.

Args: content: Draft post content to analyze industry: Optional industry for targeted hashtag suggestions

Returns content analysis with score, suggestions, and recommended hashtags.

create_draft

Create a content draft for later publishing.

Args: content: Draft content title: Optional title for organization tags: Comma-separated tags for categorization

Returns the created draft details.

list_drafts

List all content drafts.

Args: tag: Optional tag to filter by

Returns list of drafts sorted by last update.

get_draft

Get a specific draft by ID.

Args: draft_id: ID of the draft

Returns the draft details.

update_draft

Update a content draft.

Args: draft_id: ID of the draft to update content: New content (optional) title: New title (optional) tags: New comma-separated tags (optional)

Returns the updated draft.

delete_draft

Delete a content draft.

Args: draft_id: ID of the draft to delete

Returns success status.

publish_draft

Publish a draft as a LinkedIn post.

Args: draft_id: ID of the draft to publish visibility: Post visibility - PUBLIC, CONNECTIONS, or LOGGED_IN

Returns the published post details.

schedule_post

Schedule a post for future publishing.

Args: content: Post content scheduled_time: ISO format datetime (e.g., "2024-12-25T10:00:00") visibility: Post visibility - PUBLIC, CONNECTIONS, or LOGGED_IN timezone: Timezone for the scheduled time (default: UTC)

Returns the scheduled post details with job_id.

list_scheduled_posts

List all scheduled posts.

Args: status: Filter by status (pending, published, failed, cancelled)

Returns list of scheduled posts.

get_scheduled_post

Get a specific scheduled post.

Args: job_id: ID of the scheduled post

Returns the scheduled post details.

cancel_scheduled_post

Cancel a scheduled post.

Args: job_id: ID of the scheduled post to cancel

Returns success status.

update_scheduled_post

Update a scheduled post.

Args: job_id: ID of the scheduled post content: New content (optional) scheduled_time: New ISO format datetime (optional) visibility: New visibility (optional)

Returns the updated scheduled post.

get_post_reactions

Get reactions/likes on a specific post.

Args: post_urn: LinkedIn post URN (e.g., "urn:li:activity:123456789")

Returns list of users who reacted and reaction types.

get_post_comments

Get comments on a specific post.

Args: post_urn: LinkedIn post URN limit: Maximum comments to return (default: 50)

Returns list of comments with author info.

search_people

Search for people on LinkedIn.

Args: keywords: General search keywords limit: Maximum results to return (default: 10, max: 50) keyword_title: Filter by job title (e.g., 'VP Engineering', 'Product Manager') keyword_company: Filter by company name

Note: Location/region filters are not supported by the underlying API.

Returns list of matching profiles with name, title, location, and profile URL.

Search priority:

  1. Fresh Data API (requires Pro plan $45/mo for search-leads endpoint)

  2. linkedin-api (cookie-based, may be blocked by LinkedIn bot detection)

search_companies

Search for companies on LinkedIn.

Args: keywords: Search keywords limit: Maximum results to return (default: 10, max: 50)

Returns list of matching companies.

Search priority:

  1. Fresh Data API (requires Pro plan $45/mo for search-companies endpoint)

  2. linkedin-api (cookie-based, may be blocked by LinkedIn bot detection)

get_company

Get detailed company information.

Args: public_id: Company's public identifier (URL slug, e.g., 'microsoft')

Returns company details including description, industry, employee count, etc.

get_company_updates

Get recent posts/updates from a company page.

Args: public_id: Company's public identifier (URL slug) limit: Maximum updates to return (default: 10, max: 50)

Returns list of company posts/updates.

get_organization_followers

Get follower count for an organization using the Community Management API.

This tool uses the official LinkedIn Community Management API which provides accurate follower counts for organizations you have admin access to.

Args: organization_id: LinkedIn organization URN ID (numeric, e.g., '12345678')

Returns follower count and organization details.

Note: Requires Community Management API access and admin permissions for the organization.

get_school

Get school/university information.

Args: public_id: School's public identifier (URL slug)

Returns school details including name, description, follower count, etc.

get_post_analytics

Get analytics for a specific post.

Args: post_urn: LinkedIn post URN

Returns engagement metrics including reactions, comments, and shares. Note: View count requires Partner API access.

get_rate_limit_status

Get current rate limit status.

Returns remaining API calls and rate limit information.

analyze_engagement

Perform deep engagement analysis on a specific post.

Args: post_urn: LinkedIn post URN follower_count: Author's follower count for rate calculation (optional)

Returns comprehensive engagement metrics, reaction distribution, and quality score.

analyze_content_performance

Analyze content performance patterns for a profile.

Args: profile_id: LinkedIn public ID post_limit: Number of posts to analyze (default: 20, max: 50)

Returns content analysis with type distribution, engagement patterns, and recommendations.

analyze_optimal_posting_times

Analyze optimal posting times based on engagement patterns.

Args: profile_id: LinkedIn public ID post_limit: Number of posts to analyze (default: 30, max: 50)

Returns optimal posting times by hour and day with engagement averages.

analyze_post_audience

Analyze the audience engaging with a specific post.

Args: post_urn: LinkedIn post URN

Returns audience demographics based on commenters' profiles.

analyze_hashtag_performance

Analyze hashtag usage and performance.

Args: profile_id: LinkedIn public ID post_limit: Number of posts to analyze (default: 30, max: 50)

Returns hashtag frequency, engagement correlation, and recommendations.

generate_engagement_report

Generate a comprehensive engagement report for a profile.

Args: profile_id: LinkedIn public ID post_limit: Number of posts to analyze (default: 20)

Returns a full engagement report with content analysis, timing, and recommendations.

get_profile_sections

Get all editable profile sections with current content.

Returns overview of profile sections including:

  • Basic info (name, headline, location)

  • About/Summary

  • Experience count

  • Education count

  • Skills overview

get_profile_completeness

Calculate profile completeness score with improvement suggestions.

Returns:

  • Completeness score (0-100)

  • Completed vs total sections

  • Specific suggestions for improvement

update_profile_headline

Update profile headline.

Requires Playwright browser automation to be enabled.

Args: headline: New headline text (max 220 characters)

Returns success status.

update_profile_summary

Update profile summary/about section.

Requires Playwright browser automation to be enabled.

Args: summary: New summary text (max 2600 characters)

Returns success status.

upload_profile_photo

Upload a new profile photo.

Requires Playwright browser automation to be enabled.

Args: photo_path: Absolute path to the photo file (JPG, PNG)

Returns success status.

upload_background_photo

Upload a new background/banner photo.

Requires Playwright browser automation to be enabled.

Args: photo_path: Absolute path to the photo file (JPG, PNG)

Returns success status.

add_profile_skill

Add a skill to your profile.

Requires Playwright browser automation to be enabled.

Args: skill_name: Name of the skill to add

Returns success status.

check_browser_automation_status

Check if browser automation is available for profile updates.

Returns availability status and feature capabilities.

Prompts

Interactive templates invoked by user choice

NameDescription
engagement_analysis_promptGenerate a prompt to analyze engagement patterns for a profile.
content_strategyGenerate a prompt for LinkedIn content strategy development.
competitor_analysisGenerate a prompt to analyze competitor LinkedIn activity. Args: competitor_ids: Comma-separated list of competitor profile IDs

Resources

Contextual data attached and managed by the client

NameDescription
server_infoGet LinkedIn MCP server information and status.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/southleft/linkedin-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server