OpenCodeGo quota monitor for the DSH Web GUI: a breathing indicator at the input's bottom-right (green/yellow/red by remaining share), a liquid-glass panel with rolling/weekly/monthly usage windows and reset times, auto-refreshing every 30 s; API key read from DSH credentials.
Install
# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)
dsh plugin --profile web add github:BeiZi6/dsh-opencodego-usage
Any plugin you install runs third-party code with your own permissions — it can read your files, use your credentials, and reach the network, and tool approvals don’t sandbox it. GitHub-sourced plugins also run build scripts at install time. Only install sources you trust, and pin a commit (github:owner/repo#sha).
README
OpenCodeGo quota monitor for the DeepSeek Harness (DSH) Web GUI: a breathing indicator at the bottom-right of the input box shows your remaining quota at a glance; click it to open a liquid-glass panel with per-window progress bars and reset times.
Features
- 🟢🟡🔴 Breathing indicator — color-coded by remaining quota (>50% green, 20–50% yellow, <20% red) with a gentle 3.6 s breathing animation
- 📊 Three-window progress panel —
rolling(≈ last 5 h),weekly(≈ last 7 d) andmonthly(≈ last 30 d) bars with used · remaining amounts and a reset time for each window - 🔑 Zero-config key handling — reads your API key from DSH credentials automatically (only when the provider is
opencode-go); an in-panel override is available - 🪟 Liquid-glass panel — mouse-follow highlight, frosted blur and a window-style diagonal open animation
- ⏱ Auto-refresh — fetches fresh quota every 2 minutes
Installation
Requires DeepSeek Harness with the web profile enabled. Install from the official registry:
dsh plugin --profile web add github:BeiZi6/dsh-opencodego-usage
Restart dsh web for the plugin to take effect.
To remove:
dsh plugin --profile web remove dsh-opencodego-usage
Usage
The indicator sits at the bottom-right of the conversation input; its color reflects the lowest remaining share across the three windows:
Remaining share Color > 50% 🟢 green 20–50% 🟡 yellow < 20% 🔴 red Click it to expand the panel:
rolling— quota used in roughly the last 5 hoursweekly— quota used in roughly the last 7 daysmonthly— quota used in roughly the last 30 days
Each window shows the used percentage, the remaining share and the exact reset time.
A manual API key override can be entered in the panel for the current session; clearing it falls back to automatic resolution.
Data refreshes automatically every 2 minutes.
API key resolution
The plugin looks for a key in this order:
- Manual override entered in the panel (kept in a small state file under
$DSH_HOME; the path can be moved with theOCG_STATE_PATHenvironment variable) - DSH credentials — only when the active provider is
opencode-go, the credential referenced byllm-pi-ai.providers.opencode-go.apiKeyEnvis resolved - Process environment
- The state file
The key is only ever sent to the official OpenCodeGo quota endpoint over HTTPS.
How it works
Host half (
index.js) — registers a same-origin route/opencodego-usageon the DSH web server. The route queries the official OpenCodeGo quota API (GET https://opencode.ai/zen/go/v1/usage, Bearer auth) and parses the window data:{ "usage": { "rolling": { "status": "ok", "percent": 86, "resetsAt": "…" }, "weekly": { "status": "ok", "percent": 34, "resetsAt": "…" }, "monthly": { "status": "ok", "percent": 17, "resetsAt": "…" } } }Older
used/limitnumeric pair shapes are tolerated as well.Client half (
client.js) — a web-shell module registered into theconversation.input.rightslot; it polls the same-origin route every 2 minutes and renders the indicator and the panel.
Known limitations
- The state file only stores a manually overridden key; deleting it never affects credential-based resolution.
- Quota values and reset times are reported by the OpenCodeGo API as-is — no local estimation.
Compatibility
- DeepSeek Harness Web GUI (
dsh web) - Node.js >= 22.19
- Peer dependencies:
@deepseek-ai/cordis(^4),@deepseek-ai/dsh-host-webserver(^0.1.0-rc.6)
License
MIT © Xu Yuanshan
Links
- Repository: https://github.com/BeiZi6/dsh-opencodego-usage
- Issues: https://github.com/BeiZi6/dsh-opencodego-usage/issues
中文简介
为 DSH Web GUI 打造的 OpenCodeGo 剩余额度监控插件:输入框右下角呼吸灯(>50% 绿 / 20–50% 黄 / <20% 红,3.6 秒慢呼吸),点击展开液态玻璃面板——近 5 小时 / 近 7 天 / 近 30 天三窗口进度条与重置时间,每 2 分钟自动刷新;API Key 自动读取 DSH 凭据(仅限 opencode-go 提供商),也可在面板内手动覆盖。
Links
More in this category
zhu1090093659/dsh-web-ui#packages/dsh-web-ui-all★ 2078
Plugin and skin collection for the DSH Web UI: task board, Git graph, right-side panel, remote mobile UI, pet, live token stats, and a skin center.
ccch1mneyyy/dsh-TUI★ 962
Claude Code-style full-screen terminal UI: pixel-whale header, live status line, and streaming thought expansion.
omdsh-dev/DSH-better-sidebar★ 834
Full sidebar workbench with file rendering and editing, terminal, Git, and subagents; third-party plugins can register new tabs.
omdsh-dev/dsh-at-file★ 147
Codex-style `@file` mentions: search workspace files in the composer and attach their contents to prompts.
huiliyi37/dsh-tianshu-tui★ 139
A terminal UI (TUI) for DeepSeek Harness.
Nagi-ovo/dsh-visualize★ 86
In-conversation generative UI: the model renders interactive HTML cards into the chat stream, with streaming preview and sandboxed rendering.