npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@bestfunc-com/argus-file-mcp

v0.1.2

Published

Argus 本地文件 MCP Server — 通过 HTTP 直连 argus.bestfunc.com/api/transfers/* 实现大文件上传/下载,绕开 MCP base64 内联限制

Readme

@bestfunc-com/argus-file-mcp

Argus 远程管理代理系统的本地文件 MCP Server——为 AI CLI(Claude Code / Qwen Code 等)提供大文件上传/下载能力,绕开 MCP 协议的 base64 内联限制。

为什么需要

MCP 协议只认 JSON-RPC over HTTP POST(或 stdio),payload 必须是 JSON 字符串——传二进制只能走 base64 内联,AI 客户端的 context window 直接成为单文件传输上限。Argus 远程 MCP 的 upload_file 只能处理几 MB 以内的文件,遇到 13 MB 的 exe 就会把 AI 上下文挤爆。

本地 MCP 用带外 HTTP 直连 Argus Server 的 /api/transfers/* 接口,文件流完全不过 MCP 通道:

AI 客户端 ──stdio── argus-file-mcp (本地进程)
                     ├─ 读本地文件(Node fs)
                     └─ multipart HTTP → argus.bestfunc.com/api/transfers/upload
                                         → MinIO → WebSocket 推送 Agent

AI 的 context 只过 {agent_id, local_path, remote_path} 这种短 JSON 和返回的 {status, size, transfer_id} 短 JSON——与文件大小完全解耦。

安装

本 MCP Server 随 Argus_Plugins 一起分发,不需要单独安装

# Claude Code
/plugin marketplace add bestfunc/Argus_Plugins
/plugin install argus@argus-plugins
# → 会同时装好 argus (remote MCP) + argus-files (本地 MCP, 即本包)

# Qwen Code
qwen extensions install bestfunc/Argus_Plugins:argus

首次调用 upload_file / download_file 时会自动开浏览器做 OAuth 授权(RFC 8252 loopback),完成后 30 天有效,自动续期。

工具清单

| 工具 | 功能 | |---|---| | upload_file(agent_id, local_path, remote_path) | 上传本地文件到 Agent 宿主机任意路径 | | upload_to_sandbox(agent_id, local_path, filename?) | 上传到固定沙盒目录(Linux /tmp/argus-mcp/ / Windows C:\argus-mcp\) | | download_file(agent_id, remote_path, local_path) | 从 Agent 宿主机下载到本地 |

鉴权与授权

  • OAuth 2.1 + PKCE + DCR(RFC 7591 动态客户端注册)
  • access_token 存在 ~/.argus/local-mcp.json(权限 600)
  • Bearer token 打 Authorization: Bearer mak-xxx header,Argus Server 的 get_current_user 依赖统一识别(JWT / mak- 前缀 / ak_ 前缀 三种 token 格式共用一套)
  • 不走 MCP dispatcher 的 L2/L3 审批流程——这些工具的权限边界等价于 Web Console 用户通过 Transfers 页上传下载(工作组成员身份 + menu 级别权限控制)

开发

npm install
npm run build          # 产出 dist/*.js
npm run dev            # tsx 直接跑 src/
npm link               # 本地调试,软链到全局 bin

Smoke test(验证 MCP 协议握手):

(echo '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"test","version":"0.0.1"}}}'; \
 sleep 0.3; \
 echo '{"jsonrpc":"2.0","method":"notifications/initialized"}'; \
 sleep 0.2; \
 echo '{"jsonrpc":"2.0","id":2,"method":"tools/list","params":{}}'; \
 sleep 0.3) | node dist/index.js

许可

Apache-2.0 © Bestfunc (ShangHai) Technology Information System Co.,Ltd.