Introduction¶
DeepSeek Harness (dsh) is an agent development environment. When using DeepSeek models, checking account balance at any time is a basic requirement. balance-dock is a resident Web plugin designed for dsh and maintained by developer Cao-zhi-hao. It resolves the issue where dynamic plugins are invalidated after a refresh, and provides real-time balance status display below the session input box through a resident mechanism.
Core Features¶
- Persistent Residency: It remains available after page refreshes or process restarts and does not require manual activation.
- Secure Data Retrieval: The API key exists only on the host side, and the browser retrieves data only through the same-origin endpoint
/ds-balance. - Automatic Refresh: Refreshes every 60 seconds by default and supports manual refresh.
- Theme Adaptation: Automatically adapts to the light and dark themes of dsh.
- Multi-Currency: Supports display of CNY, USD, and EUR symbols.
Installation and Activation¶
Prerequisites¶
- DeepSeek Harness (dsh) is installed and running.
DEEPSEEK_API_KEYhas been configured (usually located in$DSH_HOME/.credentials.yaml).
Installation¶
It is recommended to install it using dsh’s built-in command, which automatically handles plugin registration:
dsh plugin --profile web add balance-dock
Verification¶
After restarting the dsh process, access the http://127.0.0.1:<port>/ds-balance endpoint. It should return JSON containing balance information. On any session page, a balance status bar should appear below the input box.
Notes¶
- The plugin depends on the host-side
DEEPSEEK_API_KEY. - If using manual installation, you must add the plugin line to
profiles/web/cordis.patch.ymland restart the dsh process. - Only CNY, USD, and EUR symbol display is supported.
Conclusion¶
Through its resident plugin mechanism, balance-dock makes balance checking seamless and secure.