How it behaves
dsh-cost-meter presents cost information in the session view, sidebar and settings page. A session badge can appear below the input area or in the session title bar. The sidebar can show today’s cost, official balance and a budget card. The settings page includes today, monthly and cumulative totals, per-session details, daily history, a 26-week token heatmap and a configurable history-retention period. The documented default is 180 days.
Billing is separated by provider and model and can include input, output, cached and reasoning tokens. Unknown model IDs can be normalised and matched against the price table; this matching can be disabled in favour of exact matching. Prices are expressed in USD per 1M tokens, with input/output shorthand supported.
Configuration
Settings are edited in the DSH interface and are saved automatically. Documented controls include:
- budget amount and period: today, month, cumulative, or a custom date range;
- peak/off-peak prices and the UTC peak windows
01:00–04:00 and 06:00–10:00;
- the display gates
peakNotice, peakEnabled, peakEffectiveAt and peakWindows;
- OpenCode Go display period, independently switchable 5-hour, weekly and monthly views;
- interface language: Simplified Chinese, English or browser-following mode.
The default OpenCode Go primary view is the rolling 5-hour allowance. The built-in reference catalogue can be mounted into billing, then edited.
Credentials and synchronisation
OpenCode Go can discover OPENCODE_GO_API_KEY from the DSH credential store, the environment, or an opencode login state. A key may also be entered manually. Coding-plan integrations have separate switches and keys; the README states that credentials are sent only to official endpoints. Official price synchronisation fetches and parses the provider’s pricing page before applying the result.
Requirements
The README requires Node.js ≥ 20 and DeepSeek Harness with the dsh plugin command. After installation or an update, restart the web interface with dsh web so the plugin and client bundle are rescanned.
Written from the project's own documentation and kept in sync with it. Where the two disagree, the source is authoritative — read the README on GitHub