Skip to main content
Glama
pshare-share-mcp

pshare-share-mcp

by ntanhprt

pshare-share-mcp

MCP 서버로 모든 AI(Claude Code, Claude Desktop 또는 기타 MCP 클라이언트)가 파일/폴더를 Pshare에 업로드하고 공유 링크를 받을 수 있게 해줍니다 — UI를 통해 업로드한 후 Share 버튼을 눌러 링크를 복사하는 수동 조작과 동일합니다.

로그인/토큰이 전혀 필요 없습니다 — 현재 Pshare의 아키텍처와 일관됩니다(웹 클라이언트 자체도 실제 인증을 하지 않고, 자동 생성된 X-Browser-Id만 사용합니다).

요구 사항: Pshare 인스턴스가 어딘가(localhost 또는 LAN 내)에서 이미 실행 중이어야 합니다 — 이 저장소는 Pshare의 REST API를 호출하는 MCP 서버일 뿐이며, Pshare를 자체적으로 실행하지 않습니다.

제공 도구

pshare_upload

필드

필수

설명

paths

✅

MCP 서버가 실행 중인 머신의 절대 경로 배열(파일 또는 폴더). 폴더는 하위 디렉터리 구조를 유지한 채 재귀적으로 업로드됩니다.

title

❌

공유 카드에 표시되는 제목

senderName

❌

수신자에게 표시되는 발신자 이름

password

❌

공유 링크를 여는 데 필요한 비밀번호

description

❌

공유 카드에 표시되는 설명

ttlMinutes

❌

링크가 유지되는 시간(분). 비워두면 만료되지 않음

반환 결과: http://<pshare-host>/?share=<N> 형식의 공유 링크와 파일 수 및 비밀번호 상태.

90MB를 초과하는 파일은 자동으로 청크 업로드로 전환됩니다(웹 클라이언트의 LAN 업로드 동작과 동일). 추가로 신경 쓸 필요가 없습니다.

Related MCP server: mcp_file_manager

설치

이 저장소만 클론하면 됩니다 — Pshare 전체를 다운로드할 필요가 없습니다:

git clone https://github.com/ntanhprt/Pshare-mcp.git
cd Pshare-mcp
pnpm install
pnpm build      # biên dịch ra dist/

구성(환경 변수)

변수

기본값

설명

PSHARE_BASE_URL

http://localhost:5173

MCP가 업로드/공유를 위해 호출할 Pshare 서버의 URL

PSHARE_MCP_HOST

0.0.0.0

HTTP 전송 실행 시 바인딩할 호스트

PSHARE_MCP_PORT

7317

HTTP 전송 실행 시 포트

PSHARE_MCP_ALLOWED_HOSTS

(설정 안 함)

허용된 호스트 목록(쉼표로 구분). 0.0.0.0 바인딩 시 DNS-리바인딩 보호를 활성화하는 데 사용

localhost는 MCP 서버가 Pshare가 실행 중인 바로 그 머신에서 실행될 때만 올바릅니다. localhost는 항상 "해당 프로세스를 실행 중인 머신 자체"를 가리킵니다. 따라서 이 MCP를 Pshare가 실행 중인 머신과 다른 머신/노트북(같은 LAN이라도)에 설치하는 경우, 반드시 Pshare가 실행 중인 머신의 실제 IP로 변경해야 합니다. 예를 들어 Pshare가 IP 192.168.3.7인 머신에서 실행 중인 경우:

PSHARE_BASE_URL=http://192.168.3.7:5173 claude mcp add pshare-share -- node "$(pwd)/dist/index.js"

MCP(stdio)를 Pshare가 실행 중인 동일한 머신에서 실행할 때만 기본값 localhost를 유지하세요.

독립 실행 테스트

# stdio (mặc định)
pnpm start

# HTTP/SSE — AI ở máy khác trong LAN cũng gọi được
pnpm start:http
# → nghe tại http://<PSHARE_MCP_HOST>:<PSHARE_MCP_PORT>/mcp

다른 개발자를 위한 통합 가이드

1. Claude Code와 함께 사용(stdio 전송 — AI가 Pshare와 같은 머신/호스트에서 실행될 때 권장)

클론 + 빌드 후(위 설치 섹션 참조), Pshare-mcp 디렉터리에서:

claude mcp add pshare-share -- node "$(pwd)/dist/index.js"

다른 머신의 Pshare를 가리키려면 -e로 env를 전달하세요(구성 섹션의 localhost 참고 사항 확인):

claude mcp add pshare-share \
  -e PSHARE_BASE_URL=http://192.168.3.7:5173 \
  -- node "$(pwd)/dist/index.js"

등록되었는지 확인:

claude mcp list

2. Claude Desktop과 함께 사용(stdio 전송)

구성 파일(~/Library/Application Support/Claude/claude_desktop_config.json(macOS), %APPDATA%\Claude\claude_desktop_config.json(Windows))을 열고 추가:

{
  "mcpServers": {
    "pshare-share": {
      "command": "node",
      "args": ["/đường/dẫn/tuyệt/đối/tới/Pshare-mcp/dist/index.js"],
      "env": {
        "PSHARE_BASE_URL": "http://localhost:5173"
      }
    }
  }
}

pshare_upload 도구를 받으려면 Claude Desktop을 다시 시작하세요.

3. HTTP/SSE를 통한 사용(같은 LAN의 다른 머신에서 AI가 실행될 때)

Pshare를 호스팅하는 머신(또는 Pshare에 연결할 수 있는 모든 머신)에서 MCP 서버 실행:

PSHARE_BASE_URL=http://localhost:5173 pnpm start:http

클라이언트 머신(Claude Code 또는 HTTP 전송을 지원하는 모든 MCP 클라이언트)에서 다음을 가리키세요:

http://<IP-máy-chạy-mcp>:7317/mcp

Claude Code 예시:

claude mcp add --transport http pshare-share http://192.168.3.7:7317/mcp

4. 다른 AI/에이전트 프레임워크와 함께 사용

MCP는 표준 JSON-RPC 프로토콜입니다 — 모든 MCP 클라이언트(LangChain MCP 어댑터, 커스텀 에이전트 등)도 연결할 수 있습니다. 필요한 것은 다음과 같습니다:

  • stdio: node dist/index.js 명령을 spawn하고 stdin/stdout을 통해 통신.

  • HTTP: MCP의 Streamable HTTP 전송 사양에 따라 POST http://<host>:<port>/mcp 호출.

보안 참고 사항

이 MCP 서버는 인증을 수행하지 않습니다 — 여기에 연결할 수 있는 사람(프로세스 실행 권한이 있는 경우 stdio를 통해, 또는 host:port에 접근할 수 있는 경우 HTTP를 통해)은 누구나 실제 Pshare에 파일을 업로드/공유할 수 있습니다. 이는 Pshare 자체와 일관되지만(업로드/공유 API에 인증이 없음), HTTP 전송을 LAN 외부로 열 때 주의해야 합니다.

Available Tools

1 tool
pshare_uploadUpload to Pshare and get a share linkA

Uploads one or more files/folders from this machine to Pshare (LAN file sharing) and returns the same share link a user would get by uploading through the UI and clicking "Share".

Inputs: paths (required), title, password, senderName, +2 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.9/5.0

    Scored across 1 tool

    Disambiguation5/5

    With only a single tool, there is no possibility of confusion or overlap. The tool's purpose is clearly unique by virtue of being the only one.

    Naming Consistency5/5

    A single tool name cannot be inconsistent with itself. 'pshare_upload' uses a clear prefix plus verb structure, and there are no other names to compare against.

    Tool Count2/5

    A one-tool server for a file-sharing service feels too thin. While the tool covers the upload action, the apparent scope of 'share' implies at least download or retrieval functionality, making a single tool insufficient.

    Completeness2/5

    The tool surface is severely limited to uploading. There are no tools for downloading, listing, deleting, or managing shares, which means agents have no way to complete a full sharing workflow.

    Maintenance

    ActivityInactive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI agents to securely transfer files between machines via encrypted, expiring share links, with tools for upload, download, status checks, and link management.
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Enables AI agents and users to upload and download files via MCP, generating shareable links and identifier codes. Files are automatically deleted after 24 hours.
      9
      MIT
    • F
      license
      A
      quality
      B
      maintenance
      Enables AI agents to split large files, zips, or folders into size-capped parts with SHA-256 checks, verify or regenerate missing parts, and rebuild the original across platforms so handoffs respect strict per-file upload limits.
      8
      1
      -
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI agents to privately store files and create controlled share links with expiry, open limits, recipient restrictions, approval gates, revocation, and access logging.
      MIT