DeepSeek Harness plugin

dsh-quota-cards

DSH profile bundle: account quota cards beside the composer — DeepSeek balance with a configurable refresh interval (1/5/10/30/60 min), and OpenCode Go 5h/weekly/monthly token usage. The card follows

Jump to install

Source facts

Repository
ShiraGawaAnri/dsh-quota-cards
Latest update
Aug 16, 2026
Category
Tools & Capabilities
GitHub stars
0
Format
plugin
Catalog evidence
Upstream dsh.bundle evidence
Evidence path
package.json#dsh.bundle
Checked against
0.1.0-rc.8
Upstream check date
2026-08-20

This evidence comes from the upstream catalog. This site has not installed, run, or security-reviewed the plugin.

Install

Start with a prompt that asks an agent to review the GitHub repository and source. Switch to the command if you want to install it yourself.

Copy this prompt into DSH, Codex, or another agent and ask it to review the GitHub repository and source first.

Do not install or run any commands yet. Read this plugin's GitHub repository, README, and relevant source code. Then answer the questions below clearly and directly so I can decide whether it fits my needs:

1. What is this plugin, and what problem does it solve?
2. Who is it for, and what are its typical use cases?
3. How is it used after installation? Include one minimal example.
4. What known limitations or privacy, security, compatibility, or maintenance risks does it have?
5. Give a clear recommendation: recommend, conditionally recommend, or do not recommend, with reasons.

Distinguish statements documented by the repository, inferences from source code, and unknowns. If evidence is insufficient, say so explicitly. Do not guess or simply repeat the README.

GitHub: https://github.com/ShiraGawaAnri/dsh-quota-cards
Plugin: dsh-quota-cards
Author: ShiraGawaAnri

Check the source files

Read the README and other files from this plugin directory before installing.

File explorer4 files
README.mdSource · read only
README language

中文 | English

dsh-quota-cards

A DSH account-quota plugin. It keeps a resident Card at the left end of the composer that follows the selected model and shows the matching account readout — DeepSeek balance, or OpenCode Go remaining token usage over the 5h (rolling) / weekly / monthly windows — with a debounced manual refresh button and interval-based auto refresh.

Features

Composer-left quota Card (conversation.input.left)

  • DeepSeek: account balance (total, with granted/topped-up detail in the

tooltip). Credential reference and refresh interval are configured in Settings.

  • OpenCode Go: remaining token traffic for the **5h (rolling) / weekly /

monthly** windows as percentages (tooltip carries the used share and reset time).

  • Follows the model: each refresh re-resolves the current provider via the

session.models RPC; providers whose id contains deepseek show the balance card, opencode providers show the usage card, anything else shows a muted placeholder. The model is re-checked on mount, after each finished turn (running flips), on connection reset, and on settings changes.

  • Manual refresh (debounced): a click refreshes immediately (bypassing the

host cache); clicks inside the 2 s cooldown window, or while a request is in flight, are ignored.

  • Auto refresh: every configured interval (1 / 5 / 10 / 30 / 60 min);

the next tick is re-scheduled with the latest interval after each fetch.

Settings → 额度查询

  • DeepSeek balance: credential reference (default DEEPSEEK_API_KEY) +

refresh interval, with a configured/missing badge.

  • OpenCode Go usage: credential reference (default OPENCODE_GO_API_KEY) +

refresh interval.

  • Saves apply live; credential values never reach the browser.

Data sources & security

  • DeepSeek: GET https://api.deepseek.com/user/balance with

Authorization: Bearer <key>.

  • OpenCode Go: GET https://opencode.ai/zen/go/v1/usage with

Authorization: Bearer <key> (the same Anthropic-compatible key used when ANTHROPIC_BASE_URL points at opencode.ai/zen/go).

  • Keys are resolved host-side via ctx.credentials.resolve(); the browser only

receives read-only fetched results. Settings writes require a same-origin POST.

  • The host caches each provider's readout for its configured interval; manual

refresh (force=1) bypasses the cache.

Installation

Prerequisites: DSH installed (dsh web runs) and pnpm on PATH (dsh plugin forwards to pnpm).

# 1. Unzip to a folder, e.g. D:\plugins\dsh-quota-cards
# 2. Install into the web profile:
dsh plugin --profile web add file:D:/plugins/dsh-quota-cards

dsh plugin add runs pnpm and adds @dsh-external/dsh-quota-cards to the profile's dsh.profile.bundles.

# 3. Restart dsh web
# 4. Open Settings → 额度查询, confirm both credential references, and make
#    sure the keys exist (e.g. in .credentials.yaml or env):
#      DEEPSEEK_API_KEY: sk-xxxx
#      OPENCODE_GO_API_KEY: sk-yyyy
# 5. Back on the chat page, the quota Card sits at the left of the composer.

Uninstall

dsh plugin --profile web remove @dsh-external/dsh-quota-cards
# then restart dsh web

Compatibility

  • Host services: settings, credentials, sessions, agentDefaultModel,

optional webServer; client services slots, connection; slots conversation.input.left and settings.section (declared by the shipped ui-conversation / ui-settings bundles).

  • Provider matching is by provider id (deepseek → balance card, opencode

usage card); DeepSeek's official provider id is deepseek-official and the common OpenCode Go id is opencode-go.

  • No third-party runtime deps of its own (schemastery and the @deepseek-ai

packages are peerDependencies resolved from the profile).