DeepSeek Harness plugin

dsh-balance-display-liuty

DeepSeek API balance overlay for DeepSeek Harness

Jump to install

Source facts

Repository
Liu-ty/dsh-balance-display
Latest update
Aug 13, 2026
Category
Tools & Capabilities
GitHub stars
1
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/Liu-ty/dsh-balance-display
Plugin: dsh-balance-display-liuty
Author: Liu-ty

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

dsh-balance-display

English | 简体中文

dsh-balance-display is an installable DeepSeek Harness bundle that shows the current DeepSeek API account balance in a collapsible shell.overlay panel.

The Host resolves DEEPSEEK_API_KEY through the Harness credentials service for every refresh and calls the official GET https://api.deepseek.com/user/balance endpoint. The browser receives only validated balance fields, availability, a check time, or a stable error code. The API key is never sent to the browser, persisted by this plugin, logged, included in error details, or recorded in snapshots.

Features

  • CNY and USD rows with total, granted, and topped-up balances
  • Account availability and last refresh time
  • Collapsible panel, manual refresh, and manual/1/5/15-minute auto-refresh choices
  • Periodic refresh pauses while the page is hidden and refreshes when it becomes visible
  • Harness light/dark theme tokens and zh-CN/en-US locale dictionaries
  • Explicit missing-credential, 401, timeout, network, upstream, and invalid-response states
  • No balance history, synthetic data, local token-cost estimates, or provider abstraction

Requirements

  • DeepSeek Harness with the Web profile and the current profile-bundle system
  • Node.js ^22.19.0 || >=24.0.0
  • A DEEPSEEK_API_KEY available through Harness credentials for live balance reads

Without a credential, the plugin still loads and shows the missing-credential state.

Install

From a local checkout:

dsh plugin --profile web add F:\path\to\dsh-balance-display
dsh --profile web --dump-config
dsh --profile web

From the prebuilt release tarball:

dsh plugin --profile web add .\dsh-balance-display-0.1.0.tgz

From the fixed v0.1.0 source tag:

dsh plugin --profile web add github:Liu-ty/dsh-balance-display#v0.1.0

Git installs fetch source and run this package's prepare build. pnpm may refuse that install until the profile's pnpm-workspace.yaml explicitly contains:

allowBuilds:
  dsh-balance-display: true

This allowance permits package code to execute on the machine at install time, outside the agent sandbox. Review the source and pin a tag or commit before granting it. A release tarball contains prebuilt files and does not need build permission.

Configuration

The bundle inserts one Host/Client row:

- id: balance-display
  name: dsh-balance-display
  inject: [credentials, webServer]
  config:
    requestTimeoutMs: 10000

Override that entire row in the profile or home cordis.patch.yml to change the positive integer timeout. Auto-refresh interval and collapsed state are browser-local preferences; the plugin stores no balance values.

Security model

  • The Host resolves the credential once per balance operation and does not cache it.
  • Authorization is added only to the outgoing DeepSeek request.
  • Non-success bodies from DeepSeek are never forwarded or logged.
  • Successful bodies are parsed against the documented field set and reduced to camel-cased display values.
  • Host responses use Cache-Control: no-store.
  • The plugin has no model-visible input or token-accounting integration.

Development

pnpm install
pnpm run typecheck
pnpm run test
pnpm run build
pnpm pack

Tests cover route disposal, Client slot and locale disposal, timer/listener cleanup, response validation, explicit UI states, and secret non-disclosure. A real Cordis composition smoke mounts and disposes the built Host entry.

License

[MIT](LICENSE)