openpencil
ZSeven-W
The world's first open-source AI-native vector design tool and the first to feature concurrent Agent Teams. Design-as-Code. Turn prompts into UI directly on the live canvas. A modern alternative to Pencil.
Nichts0v0/dsh-mcp-manager
在 DeepSeek Harness 设置页管理 MCP 服务器:运行时添加/编辑/启停/重连/删除,实时状态、自动重连,中英双语界面。MCP server manager for DeepSeek Harness — add, edit, enable/disable, reconnect & delete MCP servers from the web settings page, with live status and auto-reconnect.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:Nichts0v0/dsh-mcp-manager
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
Manage MCP servers right from the DeepSeek Harness Web settings page — add, edit, enable/disable, reconnect and delete servers at runtime, with live status, automatic reconnect and config-file hot sync.
mcp__<serverName>__<tool> for every session.$DSH_HOME/mcp-servers.json is watched; external edits take effect within ~1 s, no restart needed.--dsw-alias-* token overrides from appearance plugins); UI ships in 简体中文 / English.
Option 1 — from npm (easiest):
dsh plugin --profile web add dsh-mcp-manager
Option 2 — from source:
Clone and build:
git clone https://github.com/Nichts0v0/dsh-mcp-manager.git
cd dsh-mcp-manager && npm install # the prepare script builds lib/ automatically
Make the package resolvable from the profile (pick one):
Run from the folder that contains the clone (no absolute path needed):
dsh plugin --profile web add ./dsh-mcp-manager
This installs the package as a plain pnpm dependency (this package has no
dsh.bundlelayer), which only makes it resolvable — you still need step 3 to mount the plugin row.
Or symlink the repository directory itself into the profile's node_modules (avoid copying, which would drag in dev node_modules):
mklink /J "%DSH_HOME%\profiles\web\node_modules\dsh-mcp-manager" <path-to-clone> — replace <path-to-clone> with your local clone pathln -s <path-to-clone> $DSH_HOME/profiles/web/node_modules/dsh-mcp-managerThen, whichever option — mount the plugin row in $DSH_HOME/profiles/web/cordis.patch.yml:
- insert:
- id: mcp-manager
name: dsh-mcp-manager
Restart dsh web and hard-refresh the browser page (Ctrl+Shift+R) so the new __DSH_BOOT__ loads, then open Settings → MCP Server Manager and add your first server.
Note: hot reload of
cordis.patch.ymlis disabled on the Web surface (DSH's shared HMR row is off), so configuration changes need a restart.
Follow every step, in order:
Read this README in full (especially Features, Known limitations, and this install section).
Install the package (npm is preferred): run dsh plugin --profile <profile> add dsh-mcp-manager in the profile you use (or npm install dsh-mcp-manager in $DSH_HOME/profiles/<profile> and use Option 2 below for the file layout).
cd dsh-mcp-manager, run npm install --ignore-scripts && npm run build (produces self-contained lib/index.js + lib/client.js; zero runtime dependencies), then link the folder into $DSH_HOME/profiles/<profile>/node_modules/dsh-mcp-manager (directory junction on Windows, symlink on POSIX).Mount the plugin row: append to $DSH_HOME/profiles/<profile>/cordis.patch.yml:
- insert:
- id: mcp-manager
name: dsh-mcp-manager
Restart dsh web (Web-surface config hot reload is disabled) and tell the user to hard-refresh the browser so the settings page shows the new section.
Verify: GET http://127.0.0.1:3080/mcp-manager/api/health must return {"ok":true,"name":"mcp-manager","version":"<x.y.z>",...}.
Open Settings → MCP Server Manager:
serverName is immutable); saving hot-reconfigures the live connection.streamable-http (URL + optional headers) or stdio (command + args), with a configurable connection-wait timeout.| Status | Meaning |
|---|---|
| Connected (n tools) | tools are registered |
| Connecting | handshake / reconnecting in progress |
| Offline | was connected, but the server process is unreachable (probed) |
| Error | initial connect failed (reason shown) or 30 s connect timeout |
| Disabled | switched off — not connected, no tools |
$DSH_HOME/mcp-servers.json — shared by every profile and session:
{
"version": 1,
"servers": [
{ "serverName": "my-server", "transport": "streamable-http", "url": "http://127.0.0.1:8080/mcp", "enabled": true }
]
}
The file is watched live: manual edits (add / remove / change / enable) take effect within ~1 s; POST /mcp-manager/api/reload triggers it on demand.
| Method | Path | Purpose |
|---|---|---|
| GET | /mcp-manager/api/health |
liveness + version + store path |
| GET | /mcp-manager/api/servers |
list with live (probed) status |
| GET | /mcp-manager/api/servers/<name> |
single server |
| POST | /mcp-manager/api/servers |
add & connect |
| POST | /mcp-manager/api/servers/<name>/update |
update config & hot-reconnect (serverName immutable) |
| POST | /mcp-manager/api/servers/<name>/toggle |
enable / disable ({"enabled": true|false}) |
| POST | /mcp-manager/api/servers/<name>/reconnect |
disconnect & reconnect |
| DELETE | /mcp-manager/api/servers/<name> |
disconnect & delete |
| POST | /mcp-manager/api/reload |
re-read the config file from disk |
The /mcp-manager/* API can start stdio servers — i.e. execute arbitrary commands — so it is access-controlled:
Optional access token. Set a top-level token in $DSH_HOME/mcp-servers.json:
{ "version": 1, "token": "use-a-random-long-string", "servers": [] }
Generate one with node -e "console.log(require('crypto').randomBytes(24).toString('hex'))".
When set, every request must carry Authorization: Bearer <token> (all endpoints, including health):
curl -H "Authorization: Bearer <token>" http://127.0.0.1:3080/mcp-manager/api/servers
The settings page shows an "Access token" field — enter it there once (stored locally in the browser) and it is sent automatically.
Network-exposure guard. When dsh web binds to a non-loopback address (--host 0.0.0.0) and no token is configured, the manager logs a loud error and *rejects all `/mcp-manager/` requests** (403) until a token is set and dsh is restarted. Loopback-only + no token stays fully open, matching the single-user local posture.
Token comparison is timing-safe (crypto.timingSafeEqual).
The token is stored in plaintext in mcp-servers.json — protect that file (same trust level as the DSH credentials store).
npm install # build-only devDependencies; prepare auto-builds
npm run build # esbuild: lib/index.js (host, fully bundled) + lib/client.js (browser)
npm run watch # watch the client bundle (works with dsh-client-hmr)
Publishing: bump version in package.json, then npm publish (the prepare script builds lib/ automatically before packing; the package ships lib/ + both READMEs + LICENSE).
No runtime dependencies: the host half inlines @deepseek-ai/dsh-mcp-client, the MCP SDK and cross-spawn; the browser half is a closure-factory bundle served by DSH's client module system.
failOnStartupError is on, so a failed first connect shows error and retries up to every 60 s; once connected, mcp-client's own reconnect handles drops.streamable-http servers (any HTTP response counts as reachable); stdio servers are not probed./mcp-manager/* has no built-in user accounts; use the optional token (see Security) before exposing --host 0.0.0.0 (stdio servers execute arbitrary commands).MIT
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: mcp。