DeepSeek Harness Plugin Hub

Publish and manage complete Harness Profiles. Discover Plugins for your next setup.

Explore

PluginsPresetsDocsNews

Community

Publish a pluginContactReport an issue

Resources

Plugin Hub on GitHubDeepSeek HarnessSystem statusPrivacy notice
© 2026 DeepSeek Harness Plugin HubPowered byPaxTech

Independent and unofficial. Not affiliated with, authorized by, or endorsed by DeepSeek.

DeepSeek Harness Plugin Hub
ProfilesPluginsCategoriesNewsDocsSign inManage Profiles
ProfilesPluginsCategoriesNewsDocsSign in
← Plugins
A

dsh-aliyun-quota

Aliyun Quota

View your Aliyun account balance and spending directly in the DSH interface: available balance, voucher amounts and remaining balances (including the 300 RMB university student voucher), expiration reminders, billing trends, and token usage by model.

The plugin will be installed here. Keep web if you are unsure.

npx -y @deepseek-ai/dsh plugin --profile web add github:20132556/dsh-aliyun-quota#f4d3ade23f52525657f7533386b286740c47de86
READMECompatibilityVersions

Compatibility and provenance

Aliyun Quota is published as dsh-aliyun-quota and currently resolves to version 0.1.0. The Hub verifies its manifest and preserves the exact installation source for reproducible installs.

DSH compatibility
*
Runtime surfaces
web
Release source
github
Registry updated
11/4/2026

Versions

0.1.0stable
11/4/2026

Related plugins

Loading related plugins…

Latest
0.1.0
DSH
*
HMR
Process restart
Tree shaking
Safe tree shaking not declared
Unpacked size
Unavailable
Files
Unavailable
Surface
web
License
MIT
Source
github
GitHub
★ 1
Weekly downloads
0
Last push
11/4/2026
View source ↗
README badge

Click the badge to copy Markdown for your README.

Do you maintain this Plugin?Claim benefit · Priority security scan

Verify the GitHub repository declared in package.json to manage this listing. After you claim it, Hub will prioritize a security scan of the current version and publish the result when it passes.

Claim this Plugin →
Report an issue

Related plugins

More verified plugins in models-usage.

Experimental Cot Translation Bundle@deepseek-ai/dsh-experimental-cot-translation-bundleExperimental machine translation of expanded reasoningWhale Widgetdsh-whale-widgetDeepSeek balance whale widget in the bottom-right corner of the DSH Web interface: balance/today’s usage/peak-off-peak pricing, customizable bubble click sequence (text/balance/today/peak-off-peak/image/random phrases and parallel weighted selection), per-line styles and fonts, floating quick editinOur Free Model@ebony-vinyl/dsh-our-free-modelOur Free Model — Install this plugin in dsh to use cutting-edge models including DeepSeek V4.1 Flash and Kimi K3, with no login, registration, or API Key required. The desktop version also offers an EAC co-payment channel; starting with 2.0, it supports ten account channels: LobsterAI, Qoder, TRAE, Usage@linxin666/dsh-usageUsage statistics plugin for the dsh web GUI: per-provider balance and coding-plan quota detection plus a live token usage ledger, with a compact price glance card above the sidebar's Settings row

README

dsh-aliyun-quota

在 DSH 界面侧边栏直接查看阿里云账户的额度和花费:

  • 额度与券:可用余额、代金券面额与剩余、到期提醒(学生认证的 300 元券也在这里)
  • 花费与模型:本月已花多少、今日花费、近 8 个月账单趋势、每月 token 用量、按模型 / 按计费项的明细

不用再去控制台翻「我的权益」和「费用账单」。


安装

dsh plugin --profile desktop add dsh-aliyun-quota

装完重启 DSH 桌面端(插件在启动时加载)。

从本地源码安装

git clone https://github.com/20132556/dsh-aliyun-quota.git
cd dsh-aliyun-quota
dsh plugin --profile desktop add link:<本目录绝对路径>

手动安装

如果上面的命令不可用,改 profile 的两处配置:

~/.dsh/profiles/desktop/package.json
  - dependencies 里加   "dsh-aliyun-quota": "<版本或路径>"
  - dsh.profile.bundles 里加   "dsh-aliyun-quota"

然后 cd ~/.dsh/profiles/desktop && pnpm install,再重启 DSH。


用法

  1. 重启 DSH 桌面端(插件在启动时加载)
  2. 左侧边栏点 「阿里云额度」(圆形 ¥ 图标)
  3. 第一次会看到设置表单,填入 AccessKey
  4. 保存后立刻显示

面板顶部有两个标签:花费与模型 / 额度与券。

之后每 90 秒自动刷新,也可以手动点「刷新」。

花费页能做什么

  • 本月已花:按账期汇总的消费金额,以及其中多少由代金券抵掉
  • 今日花费:当天 0 点到现在
  • 每月账单趋势:近 8 个月的柱状图,鼠标悬停看明细
  • 本月 token 构成:输入 / 缓存命中 / 输出 三段占比,附缓存命中率
  • 按模型:每个模型的费用与 token 用量,展开可看计费项(输入·高峰、输入缓存·闲时、输出·高峰…)
  • 按产品:账号下多个产品时分别列出
  • 本月逐日:每天花了多少、多少 token、几条明细

账单接口的数据通常有 1–6 小时延迟,刚花的钱不一定立刻出现。控制台同理。


先拿 AccessKey

这个插件要用阿里云官方 BSS OpenAPI 查数据,需要一对 AccessKey。

步骤:

  1. 打开 RAM 访问控制 → AccessKey
  2. 建议用 「创建 RAM 用户」,不要用主账号 AK(主账号 AK 权限过大,泄露风险高)
  3. 创建后给这个 RAM 用户授予 AliyunBSSReadOnlyAccess(只读,足够查余额、代金券和账单)
  4. 把 AccessKey ID 和 Secret 粘进插件面板,点「保存并验证」

插件会先真的调一次接口验证,验证不过不会保存,避免存进去一堆废密钥。

如果用主账号 AK,需要确认账号没有被限制调用 BSS OpenAPI。


密钥存在哪

%USERPROFILE%\.dsh\dsh-aliyun-quota\config.json

内容就是明文 JSON:

{
  "accessKeyId": "LTAI5t...",
  "accessKeySecret": "..."
}

这个文件里是明文密钥。 如果你介意:

  • 更安全的做法是用环境变量,不落盘:
    setx ALIYUN_ACCESS_KEY_ID "LTAI5t..."
    setx ALIYUN_ACCESS_KEY_SECRET "..."
    
    然后重启 DSH。插件会优先读环境变量(面板会显示 source: env)。
  • 或者用 RAM 子账号的最小权限 AK,即使泄露损失有限。

面板上的「设置 → 清除密钥」会删掉这个文件。


能查到什么

额度

数据来源接口
账户可用余额(现金)QueryAccountBalance → AvailableAmount
可用现金 / 信控额度QueryAccountBalance → AvailableCashAmount / CreditAmount
代金券列表(面额、剩余、到期、状态、适用产品)QueryCashCoupons
合计可用(余额 + 券)本地汇总
最近到期提醒本地计算

大学生优惠券(云工开物 300 元那类)通常以代金券形式发放,会出现在明细里。

花费

数据来源接口
近 N 个月账期汇总(消费、券抵、折扣)QueryAccountBill(Granularity=MONTHLY)
逐日花费DescribeInstanceBill(Granularity=DAILY,每天一次)
按模型 / 计费项的 token 用量DescribeInstanceBill → InstanceID 第 3、4 段
按产品汇总本地聚合

百炼的模型是怎么认出来的:DescribeInstanceBill 返回的 InstanceID 形如

7752890;ws-wlhl9tvtza5rpkd6;deepseek-v4.1-flash-1017;output_token_peak;0
                                  └─ 模型名 ─┘        └─ 计费项 ─┘

第 3 段是模型名,第 4 段是计费项(输入/输出/缓存 × 高峰/闲时)。插件按这两段聚合,所以能精确告诉你哪个模型花了多少钱、用掉多少 token。

非百炼产品(ECS、OSS 等)没有这个格式,退回用产品名分组。

如果查不到券

可能的原因:

  1. 券还没到账 —— 学生认证通过后可能有几分钟到几小时延迟
  2. 不是代金券类型 —— 有些权益是「资源包」或「权益包」,不在 QueryCashCoupons 里,走的是另外的接口
  3. RAM 权限不足 —— 需要 bss:DescribeCoupons(AliyunBSSReadOnlyAccess 已包含)

如果花费是空的

  1. 账单延迟 —— BSS 出账有 1–6 小时延迟,刚消费的看不到
  2. 账期边界 —— 每月 1 号刚过,上个月的账期数据可能还在结算
  3. RAM 权限不足 —— 账单接口需要 bss:QueryBill / bss:DescribeInstanceBill(AliyunBSSReadOnlyAccess 已包含)

出现查不到的情况告诉我,我加对应接口。


技术实现

  • 零依赖:只用 node:crypto 和 node:fs,手写阿里云 RPC 签名(HMAC-SHA1),没有装 SDK
  • 服务端:注册 5 个路由在 /api/dsh-aliyun-quota/*,只允许本机回环访问
  • 客户端:侧边栏条目 + 主面板(两个标签页),用 ctx.slots 挂载,无构建步骤
  • 缓存:额度 45 秒,账单 5 分钟(账单一次要发 30+ 个请求,不宜频刷);并发请求合并
  • 并发:账单接口 6 路并发,近 8 个月 + 30 天明细约 2 秒出结果
  • 额外:注册了 aliyun_quota 和 aliyun_usage 两个工具,可以直接在对话里问额度 / 花费

接口

GET  /api/dsh-aliyun-quota/status?refresh=1   额度总览
GET  /api/dsh-aliyun-quota/usage?refresh=1    花费与模型用量(可加 &months=12)
GET  /api/dsh-aliyun-quota/config             是否已配置(不返回密钥)
POST /api/dsh-aliyun-quota/config             保存并验证 AccessKey
POST /api/dsh-aliyun-quota/clear              清除密钥
GET  /api/dsh-aliyun-quota/health             自检

验证

node test/routes.mjs

会挂一个临时 HTTP 服务,用假 DSH 上下文跑 20 项断言(含"假密钥必须被拒绝且不落盘"和 usage 路由的方法校验)。


排错

现象原因处理
侧边栏没有图标插件没加载确认 package.json 的 dsh.profile.bundles 里有它,重启 DSH
保存时报「密钥验证失败」AK 错 / 被禁用 / 权限不足去 RAM 控制台检查权限
报 SignatureDoesNotMatch系统时钟偏差超过 15 分钟校准系统时间
显示「没有查到代金券」券未到账或类型不是代金券等一会儿;或告诉我加接口
花费页一直空账单还没出 / 权限不足等 1–6 小时;确认有 AliyunBSSReadOnlyAccess
模型显示成产品名非百炼产品,InstanceID 没这个格式正常行为
报 Throttling刷太快触发频控等 1 分钟再点刷新

卸载

# 1. 从 profile 里去掉(两处都要改)
#    ~/.dsh/profiles/desktop/package.json
#      - dependencies 里删掉 "dsh-aliyun-quota"
#      - dsh.profile.bundles 里删掉 "dsh-aliyun-quota"
# 2. 重装依赖
cd ~/.dsh/profiles/desktop
pnpm install
# 3. 重启 DSH

并删掉 ~/.dsh/dsh-aliyun-quota/(里面有密钥)。


License

MIT