LinkedIn MCP Server

LinkedIn MCP Server

An MCP server that enables AI assistants to interact with LinkedIn, including job search, profile viewing, resume/cover letter generation, and application tracking.

Category
访问服务器

README

LinkedIn MCP Server

License: MIT Python 3.11+ MCP SDK

An MCP server that gives AI assistants full access to LinkedIn — search jobs, view profiles and companies, generate AI-powered resumes and cover letters, and track applications. Built with the official MCP Python SDK (FastMCP).


What It Does

Category Capabilities
Job Search Search with filters (keywords, location, type, experience level, remote, recency), get job details, get recommendations
Profiles & Companies Fetch any LinkedIn profile or company page, AI-powered profile analysis with optimization suggestions
Resume Generation Generate resumes from LinkedIn profiles, tailor resumes to specific job postings, 3 built-in templates
Cover Letters AI-generated cover letters personalized to each job, 2 built-in templates
Application Tracking Track applications locally with status workflow (interested → applied → interviewing → offered/rejected/withdrawn)
Output Formats HTML, Markdown, and PDF (via WeasyPrint)

Quick Start

1. Install

# Core installation
pip install -e .

# With AI features (resume/cover letter generation, profile analysis)
pip install -e ".[ai]"

# With PDF export
pip install -e ".[pdf]"

# Everything
pip install -e ".[all]"

2. Configure

cp .env.example .env

Edit .env with your credentials:

LINKEDIN_USERNAME=your_email@example.com
LINKEDIN_PASSWORD=your_password
ANTHROPIC_API_KEY=sk-ant-...    # Optional — enables AI features

3. Run

Standalone:

linkedin-mcp

With Claude Desktop — add to your claude_desktop_config.json:

{
  "mcpServers": {
    "linkedin": {
      "command": "linkedin-mcp"
    }
  }
}

With Claude Code — add to .mcp.json:

{
  "linkedin": {
    "command": "linkedin-mcp"
  }
}

Tools Reference

Job Tools (3)

Tool Parameters Description
search_jobs keywords, location, job_type, experience_level, remote, date_posted, page, count Search LinkedIn jobs with rich filters
get_job_details job_id Get full description, skills, and metadata for a job posting
get_recommended_jobs count Get personalized job recommendations

Profile Tools (3)

Tool Parameters Description
get_profile profile_id Fetch a LinkedIn profile ("me" for your own) — experience, education, skills
get_company company_id Get company info — description, size, headquarters, specialties
analyze_profile profile_id AI-powered profile review with actionable optimization suggestions

Document Generation Tools (4)

Tool Parameters Description
generate_resume profile_id, template, output_format Generate a resume from a LinkedIn profile
tailor_resume profile_id, job_id, template, output_format Generate a resume tailored to a specific job posting
generate_cover_letter profile_id, job_id, template, output_format Create a personalized cover letter for a job
list_templates template_type List available templates (resume, cover_letter, or all)

Templates: modern · professional · minimal (resume) | professional · concise (cover letter) Formats: html · md · pdf

Application Tracking Tools (3)

Tool Parameters Description
track_application job_id, job_title, company, status, notes, url Start tracking a job application
list_applications status List all tracked applications, optionally filtered by status
update_application_status job_id, status, notes Update application status

Status values: interested · applied · interviewing · offered · rejected · withdrawn


Architecture

src/linkedin_mcp/
├── server.py                    # FastMCP entry point — 13 tools, 1 resource
├── config.py                    # Settings from .env (frozen dataclass)
├── exceptions.py                # 7-class exception hierarchy
├── models/
│   ├── linkedin.py              # Profile, Job, Company models (Pydantic v2)
│   ├── resume.py                # Resume & cover letter content models
│   └── tracking.py              # Application tracking model
├── services/
│   ├── linkedin_client.py       # LinkedIn API wrapper (async via asyncio.to_thread)
│   ├── job_search.py            # Job search with TTL caching
│   ├── profile.py               # Profile/company access with caching
│   ├── resume_generator.py      # AI-enhanced resume generation
│   ├── cover_letter_generator.py
│   ├── application_tracker.py   # Local JSON-based application tracking
│   ├── cache.py                 # Unified JSON file cache with TTL
│   ├── template_manager.py      # Jinja2 sandboxed template engine
│   └── format_converter.py      # HTML → PDF/Markdown conversion
├── ai/
│   ├── base.py                  # Abstract AI provider interface
│   └── claude_provider.py       # Anthropic Claude implementation
└── templates/
    ├── resume/                  # modern.j2, professional.j2, minimal.j2
    └── cover_letter/            # professional.j2, concise.j2

Key Design Decisions

  • Official MCP SDK — Uses FastMCP with @mcp.tool() decorators, not a custom protocol implementation
  • Async throughout — All sync LinkedIn API calls wrapped in asyncio.to_thread() to avoid blocking
  • Layered architecture — Tools → Services → Client, with caching at the service layer
  • AI is optional — Core LinkedIn features work without an Anthropic API key; AI enhances resume/cover letter generation
  • Security hardened — Jinja2 SandboxedEnvironment, WeasyPrint SSRF protection, path traversal guards, credential redaction, input validation

Configuration

All settings are loaded from environment variables (.env file supported):

Variable Required Default Description
LINKEDIN_USERNAME Yes — Your LinkedIn email
LINKEDIN_PASSWORD Yes — Your LinkedIn password
ANTHROPIC_API_KEY No — Enables AI features (resume/cover letter generation, profile analysis)
AI_MODEL No claude-sonnet-4-20250514 Claude model to use
DATA_DIR No ~/.linkedin_mcp/data Directory for cache, tracking data, generated files
CACHE_TTL_HOURS No 24 How long to cache LinkedIn API responses
LOG_LEVEL No INFO Logging level (DEBUG, INFO, WARNING, ERROR)

Development

# Install with all dependencies
pip install -e ".[all,dev]"

# Run tests (82 tests)
pytest

# Run with coverage
pytest --cov=linkedin_mcp

# Lint
ruff check src/ tests/

Test Coverage

Tests cover all layers: config, models, services (cache, tracker, job search, profile, resume/cover letter generation, LinkedIn client formatters, format converter), AI provider, and MCP tool handlers.


Usage Examples

Once connected, ask your AI assistant:

"Search for remote Python developer jobs in the US"

"Show me the profile for satyanadella"

"Generate a resume from my LinkedIn profile tailored to job 3847291056"

"Create a cover letter for job 3847291056 using the concise template"

"Track my application for the Senior Engineer role at Google — status: applied"

"List all my applications that are in the interviewing stage"

"Analyze my LinkedIn profile and suggest improvements"


License

MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选