Skip to main content
Glama
ahmedekramalsada

LinkedIn MCP Server

LinkedIn MCP 서버

AI 에이전트(batabeto/OpenClaw)가 사용자를 대신하여 LinkedIn을 제어(게시물 작성, 댓글, 좋아요, 네트워크 관리)할 수 있게 해주는 풀스택 MCP 서버입니다.


아키텍처

AI Agent (batabeto) ──MCP/HTTP──► LinkedIn MCP Server ──REST──► LinkedIn API
                                         │
                                   OAuth2 + Token Store
                                         │
                                    Dashboard UI

Related MCP server: LinkedIn MCP Server

설정 가이드

1. LinkedIn 앱 생성

  1. LinkedIn 개발자 페이지로 이동합니다.

  2. **앱 만들기(Create App)**를 클릭합니다.

  3. 앱 이름, LinkedIn 페이지, 로고를 입력합니다.

  4. 인증(Auth) 탭에서 Authorized redirect URLs를 추가합니다:

    http://YOUR_EC2_IP:3000/auth/callback

    (nginx를 사용하는 경우 도메인을 입력하세요)

  5. 제품(Products) 탭에서 다음을 요청합니다:

    • Share on LinkedIn (w_member_social 범위 제공)

    • Sign In with LinkedIn using OpenID Connect (openid profile email 제공)

  6. **클라이언트 ID(Client ID)****클라이언트 보안 비밀(Client Secret)**을 복사합니다.

2. 설치 및 구성

git clone <your-repo> linkedin-mcp
cd linkedin-mcp
npm install

cp .env.example .env
nano .env

.env 파일을 작성합니다:

LINKEDIN_CLIENT_ID=your_client_id
LINKEDIN_CLIENT_SECRET=your_client_secret
BASE_URL=http://YOUR_EC2_IP:3000
PORT=3000
MCP_SECRET_KEY=$(openssl rand -hex 32)

3. 서버 실행

# Production
npm start

# Development (auto-restart)
npm run dev

# As a systemd service (recommended for EC2)
sudo nano /etc/systemd/system/linkedin-mcp.service

systemd 서비스 파일:

[Unit]
Description=LinkedIn MCP Server
After=network.target

[Service]
Type=simple
User=ubuntu
WorkingDirectory=/home/ubuntu/linkedin-mcp
ExecStart=/usr/bin/node server.js
Restart=always
RestartSec=5
EnvironmentFile=/home/ubuntu/linkedin-mcp/.env

[Install]
WantedBy=multi-user.target
sudo systemctl enable linkedin-mcp
sudo systemctl start linkedin-mcp
sudo systemctl status linkedin-mcp

4. LinkedIn 인증

  1. http://YOUR_EC2_IP:3000에 접속합니다.

  2. **LinkedIn 연결(Connect LinkedIn)**을 클릭합니다.

  3. LinkedIn에서 앱을 승인합니다.

  4. 다시 리디렉션되며 상태가 ✅ 연결됨(Connected)으로 표시됩니다.

5. AI 에이전트에 연결

OpenClaw (batabeto)의 경우:

에이전트의 MCP 설정에 다음을 추가합니다:

{
  "mcpServers": {
    "linkedin": {
      "url": "http://YOUR_EC2_IP:3000/mcp",
      "transport": "http",
      "headers": {
        "Authorization": "Bearer YOUR_MCP_SECRET_KEY"
      }
    }
  }
}

Claude Desktop의 경우:

{
  "mcpServers": {
    "linkedin": {
      "command": "npx",
      "args": ["mcp-remote", "http://YOUR_EC2_IP:3000/mcp", "--header", "Authorization: Bearer YOUR_MCP_SECRET_KEY"]
    }
  }
}

사용 가능한 도구

도구

설명

linkedin_get_profile

이름, 헤드라인, 이메일, 사진 가져오기

linkedin_create_post

텍스트, 기사, 링크 게시

linkedin_get_my_posts

최근 게시물 목록 가져오기

linkedin_delete_post

URN으로 게시물 삭제

linkedin_get_post_analytics

좋아요/댓글/공유 수 가져오기

linkedin_like_post

게시물에 좋아요 표시

linkedin_comment_on_post

게시물에 댓글 달기

linkedin_get_connections

네트워크 목록 가져오기

linkedin_search_people

키워드로 사람 검색

linkedin_get_auth_status

인증 상태 확인


에이전트 프롬프트 예시

"Post on LinkedIn: Excited to share that I just deployed a full Kubernetes cluster
 with ArgoCD GitOps! #DevOps #Kubernetes"

"Get my last 5 LinkedIn posts"

"Delete my LinkedIn post with ID urn:li:ugcPost:1234567890"

"Comment 'Great insight!' on post urn:li:ugcPost:9876543210"

"Check my LinkedIn connection status"

API 제한 사항 (LinkedIn)

LinkedIn의 공개 API는 제한적입니다. 작동하는 기능과 그렇지 않은 기능은 다음과 같습니다:

기능

상태

참고

게시물 작성

✅ 작동

텍스트, 기사, 링크

게시물 삭제

✅ 작동

본인 게시물만

게시물 좋아요

✅ 작동

볼 수 있는 모든 게시물

댓글 달기

✅ 작동

볼 수 있는 모든 게시물

내 게시물 가져오기

✅ 작동

UGC Posts API 사용

연결 가져오기

⚠️ 범위 필요

r_network_size 필요

사람 검색

❌ 제한됨

파트너 API 필요

메시지 전송

❌ 제한됨

파트너 프로그램 필요

이미지 게시물

🔜 가능

미디어 업로드 흐름 필요


보안

  • MCP 엔드포인트는 MCP_SECRET_KEY로 보호되므로 비밀로 유지하세요.

  • OAuth 토큰은 로컬의 data/tokens.json에 저장되므로 이 파일을 커밋하지 마세요.

  • LinkedIn 토큰은 60일간 유효하며, 새로 고침 토큰은 365일간 유효합니다.

  • 서버는 토큰 만료 5일 전부터 자동으로 토큰을 갱신합니다.


EC2 포트 열기

# In AWS Security Group, allow inbound:
# Port 3000, TCP, from your agent's IP (or 0.0.0.0/0 for testing)

또는 nginx를 사용하여 yourdomain.com/mcplocalhost:3000/mcp로 프록시하세요.

A
license - permissive license
Not graded
quality - not tested
C
maintenance

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    A
    quality
    D
    maintenance
    Enables AI agents to manage professional networking on LinkedIn by providing tools for posting updates, searching for jobs, and analyzing profiles. It facilitates secure interaction with the LinkedIn platform through OAuth 2.0 authentication and the Model Context Protocol.
    17
    11
    MIT
  • A
    license
    B
    quality
    C
    maintenance
    Enables AI agents to manage LinkedIn profiles, posts, connections, skills, education, and certifications through the LinkedIn API.
    18
    176
    64
    MIT
  • A
    license
    B
    quality
    A
    maintenance
    Enables AI agents with read/write access to LinkedIn API, including profile, posts, media, organizations, comments, reactions, and analytics.
    20
    14
    MIT

View all related MCP servers

Related MCP Connectors

View all MCP Connectors

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/ahmedekramalsada/linkedin-mcp'

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