rea
morluto
Reverse engineer anything with agents, from app behavior down to native binaries.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:happyde2b/dsh-balance-display-simple
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
DSH 侧边栏顶部品牌行下方实时显示 DeepSeek API 账户余额。
名字里的
simple是实话:只做「查余额、显示余额」。没有图表、历史记账、多供应商切换。
API 余额 ¥19.74,多币种用 · 拼接浏览器 / 渲染进程不接触 API Key:
lib/index.js)注册同源端点 GET /api/deepseek-balance-simple,通过 credentials
服务解析 DEEPSEEK_API_KEY(来源:进程环境 > <DSH_HOME>/.credentials.yaml > .env),
由服务端调用 https://api.deepseek.com/user/balance(15 秒超时,cache-control: no-store)。lib/client.js)只请求这个本地端点,经 MutationObserver 在侧边栏品牌行后注入余额条,
React 重渲染后自动重新挂载。前置:Node.js 20+;DSH_HOME 指向 DSH 数据家,或用 --dsh-home 显式传入。
方式 A:手动复制(不需要 pnpm)
git clone https://github.com/happyde2b/dsh-balance-display-simple.git
cd dsh-balance-display-simple
node install.js # → <DSH_HOME>\profiles\desktop\node_modules\dsh-balance-display-simple
node install.js --profile web # 指定 profile
# 同时更新 profile 的 package.json(dependencies + dsh.profile.bundles)
方式 B:官方插件管理器
node install.js --pack # 产物:<DSH_HOME>\downloads\dsh-balance-display-simple-<版本>.tgz
# 在 DSH「插件 → 添加插件」里填该 tgz 的绝对路径,安装后启用
安装后重启 DSH 桌面端生效。
暂无配置项。轮询间隔在 lib/client.js 顶部 REFRESH_MS = 60000,改后重启桌面端。
node --check lib/index.js
node --check lib/client.js
桌面端运行中可直接查端点:
curl http://127.0.0.1:<DSH Web 端口>/api/deepseek-balance-simple
# {"ok":true,"fetchedAt":...,"is_available":true,"balance_infos":[{"currency":"CNY","total_balance":"19.74"}]}
lib/index.js Host 半区:注册余额端点
lib/client.js Client 半区:侧边栏余额条
cordis.patch.yml bundle 配置层(插入插件行)
install.js 手动安装 / 打包脚本
MIT
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: deepseek、deepseek-harness。