Ronniealgo/dsh-route-balance ↗★ 2
dsh-route-balance
在侧边栏展示API路由余额与ChatGPT/Codex额度。 适合需要通过本地认证路由统一监控多渠道API余额和使用额度的用户。
安裝
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Ronniealgo/dsh-route-balance說明文件
閱讀完整 README ↗配置
- insert:
- id: route-balance
name: "dsh-route-balance"
config:
slot: sidebar.footer.action
refreshMs: 300000
requestTimeoutMs: 15000
cacheMs: 10000
codex:
strategy: auto
warmMs: 240000
timeoutMs: 20000
snapshotPath: null
| 配置 | 含义 |
|---|---|
slot | 默认侧边栏底部;也可选 DSH 已声明的其它槽位 |
refreshMs | 页面轮询间隔,默认 5 分钟,最小 1 分钟 |
requestTimeoutMs | 每条供应商读取总时限,默认 15 秒 |
cacheMs | host 余额短缓存,默认 10 秒;并发请求共用一次读取 |
codex.strategy | auto 后台读取;snapshot 只读手工快照;off 隐藏且不读 |
codex.warmMs | 额度后台读取间隔,默认 4 分钟,最小 30 秒 |
codex.timeoutMs | 一次额度读取的总候选时限,默认 20 秒 |
codex.snapshotPath | 可指定快照;默认按 CODEX_HOME 或用户 Codex home 查找 |
网页接口固定为 /api/dsh-route-balance/balances,不再支持自定义 path。点击刷新只重新请求页面数据,可能仍使用短缓存;额度不会因为点击额外启动进程。