rea
morluto
Reverse engineer anything with agents, from app behavior down to native binaries.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:hexiao160705-dev/dsh-account-ring
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
A multi-provider balance / quota ring for DeepSeek Harness (DSH). It sits beside Settings in the sidebar foot:
magpie is running, balances and quotas come from its /v1/magpie/quotas endpoint~/.codex/auth.json, ve CLI, LobeHub API) whenever Magpie is offline or a provider has no quota there~/.dsh/account-ring.jsonhex***@gmail.com); Codex access tokens, account ids, and raw usage payloads stay in the host half.MAGPIE_BASE_URL (default http://127.0.0.1:3425).~/.codex/auth.json; a refreshed access token stays in host memory only.ctx.remote.account.getBalance), which already returns sanitized wallet amounts.From GitHub:
dsh plugin --profile desktop add github:hexiao160705-dev/dsh-account-ring
Or from a checkout:
dsh plugin --profile desktop add /absolute/path/to/dsh-account-ring
Reload/restart DSH. The ring appears in the sidebar footer.
When Magpie is running, every row it reports comes from GET http://127.0.0.1:3425/v1/magpie/quotas:
kind: balance rows (balance: "¥31.54") become currency rows.kind: subscription / plan rows with windows become percentage rows using each window's remaining value.display is Unknown (for example Codex image generation) are skipped.Trae is intentionally hidden. To show it again, remove trae-cn from HIDDEN_PROVIDERS in index.js.
DeepSeek can have several wallets. The one matching the signed-in DSH account keeps the plain deepseek id so the ring does not jump to another account; the others get deepseek:2, deepseek:3 and a label naming their account.
Uses the signed-in DSH account. No DEEPSEEK_API_KEY is required. The ring shows the recharge wallet; details also show granted bonus when present.
The ring reads the Agent Plan AFP quota through the locally logged-in ve CLI:
ve ark GetAFPUsage --force --version 2024-01-01 --method POST --output json
It shows the 5-hour, daily, weekly and monthly AFP windows, plus the Volcengine cash balance (ve billing QueryBalanceAcct). Set VOLCENGINE_CLI if ve is not on PATH. Both rows are read-only; no AK/SK is stored by the plugin.
Reads ~/.codex/auth.json (or $CODEX_HOME/auth.json), calls the ChatGPT usage endpoint, and normalizes the 5-hour and weekly windows. If the login expired it shows 请先在终端执行 codex login; it never renders the token.
GET https://app.lobehub.com/api/v1/usage with LOBEHUB_API_KEY is still read directly, because Magpie does not report LobeHub. The row shows the quota percentage, the remaining balance and the reset time.
For a tool that is not a DSH model provider, add a manual entry to ~/.dsh/account-ring.json:
{
"providers": [
{ "id": "some-api", "label": "Some API", "amount": 18.5, "currency": "CNY" }
]
}
Manual entries support remainingPercent or amount + currency.
主 button makes a provider the ring's primary display; the choice persists in localStorage.MIT
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: deepseek-harness。