sunyuhuirong/deepseek-account ↗★ 0
@deepseek-ai/dsh-deepseek-account
DeepSeek account plugin for DeepSeek Harness: shows the configured account's API balance in the web GUI sidebar (wallet button + balance card) and exposes a deepseek_balance tool. Balance display only — API keys stay in Settings (DEEPSEEK_API_KEY credential).
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:sunyuhuirong/deepseek-account说明文档
阅读完整 README ↗dsh-deepseek-account
English | 中文
一个面向 DeepSeek Harness 的 DeepSeek 账户插件。它在 Web GUI 侧边栏"设置"旁边加一个钱包按钮,点击弹出当前配置账户的余额卡片;同时提供一个 deepseek_balance 工具,让 agent 也能查询余额。
只做余额展示。 本插件不存储任何 API 密钥——密钥始终留在 Harness 设置的 DEEPSEEK_API_KEY 凭据中。
功能
- 侧边栏钱包按钮 + 余额弹层(支持窄栏/宽栏两种侧边栏状态)
deepseek_balance工具(agent 可直接调用)- 国际化:中文 + English
安装
需要 DeepSeek Harness(Node ^22.19 或 >=24,~/.dsh profiles)。
# 在任意 harness profile 下
dsh plugin add @deepseek-ai/dsh-deepseek-account --profile web
然后在设置中配置账户(插件直接读取已有的 DEEPSEEK_API_KEY 凭据,无需额外配置)。
从源码构建
pnpm install
pnpm bundle # 构建 src -> lib
pnpm test # 单元测试
插件在 harness monorepo(packages/extensions/deepseek-account)内开发;本独立仓库镜像同一份源码,依赖改为可在 npm 安装的版本范围。peer 依赖(client runtime、slots 等)由 Harness 运行时提供。
工作原理
- Host 端(
src/index.ts、src/balance.ts):注册deepseek_balance工具,通过 harness 凭据服务读取账户凭据并调用 DeepSeek 余额 API。 - Client 端(
src/client/):注册到settings.triggerExtra槽(设置旁的钱包按钮),渲染余额卡片弹层。
许可
MIT