dsh-cost-meter 1.8.30 → 1.8.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -8
- package/README.zh-CN.md +14 -8
- package/docs/custom-model-prices.md +5 -1
- package/docs/openrouter-prices.md +2 -2
- package/docs/tokenrhythm-balance.md +38 -0
- package/docs/update-notes-1.8.31.md +33 -0
- package/docs/update-notes-1.8.32.md +21 -0
- package/lib/client.js +5 -5
- package/lib/client.openrouter.js +2 -2
- package/lib/client.pricing.js +27 -1
- package/lib/custom-balance.js +3 -0
- package/lib/gateway-quota-adapters.js +9 -1
- package/lib/gateway-quotas.js +1 -1
- package/lib/store.js +5 -5
- package/lib/tokenrhythm-balance.js +95 -0
- package/lib/typert.host.js +2 -2
- package/package.json +6 -2
package/README.md
CHANGED
|
@@ -10,13 +10,13 @@ Community and feedback: [Join the WeChat group →](#community). The WeChat grou
|
|
|
10
10
|
|
|
11
11
|
Per-conversation cost · daily totals · OpenCode Go subscription quota display · budget with usage percentage · official account balance · custom provider balance · balance progress bar · history · peak/off-peak pricing hours display (peak hours UTC 01:00–04:00, 06:00–10:00; weekends and Chinese public holidays are off-peak all day, with separate labels) · pre-switch popup & system-notification alerts for peak/off-peak changes (position / lead time / alert type configurable) · one-click price sync from the official docs · Codex-style token usage heat grid · multi-vendor model pricing (built-in 170+ model-ID catalog with auto-matching) · mainstream Coding Plan quota queries & display (Anthropic / Z.ai / MiniMax / Kimi / OpenRouter / SiliconFlow / CommandCode / SCNet / Volcano Ark / Qwen / Xiaomi MiMo / Factory Droid) plan/API dual-track billing (subscription quota vs pay-as-you-go money separated, per-1% & full-window token/equivalent-cost estimates with daily/weekly/monthly curves) · · quota strip above the input box (budget / Go / coding-plan usage in one row, toggleable)
|
|
12
12
|
|
|
13
|
-
[](https://github.com/Han-1413141/dsh-cost-meter)
|
|
14
14
|
|
|
15
|
-
**v1.8.
|
|
15
|
+
**v1.8.32** adds [Token Rhythm available CNY balance](docs/tokenrhythm-balance.md#english), using the website session cookie with the existing balance cards and cache.
|
|
16
16
|
|
|
17
17
|
Desktop users: follow the [Desktop installation instructions](docs/install-troubleshooting.md#desktop-安装与更新) for the application's own CLI and `desktop` Profile.
|
|
18
18
|
|
|
19
|
-
Release notes: [
|
|
19
|
+
Release notes: [Token Rhythm balance — v1.8.32](docs/update-notes-1.8.32.md#english). Fully restart DSH after updating.
|
|
20
20
|
|
|
21
21
|
If startup reports **Ledger is busy** and the cost widgets are missing, see [ledger lock recovery](docs/ledger-lock-recovery.md#english).
|
|
22
22
|
|
|
@@ -327,22 +327,22 @@ On Node.js 20, use `npm install -g pnpm@10` instead. See [pnpm installation and
|
|
|
327
327
|
dsh plugin --profile web add dsh-cost-meter
|
|
328
328
|
```
|
|
329
329
|
|
|
330
|
-
**PowerShell one-click script** (copy the whole line, paste, press Enter; pnpm is provisioned automatically, git is auto-detected — no clone needed; the install chain is **pinned to the release tag `v1.8.
|
|
330
|
+
**PowerShell one-click script** (copy the whole line, paste, press Enter; pnpm is provisioned automatically, git is auto-detected — no clone needed; the install chain is **pinned to the release tag `v1.8.32`** — review the script before running):
|
|
331
331
|
|
|
332
332
|
```powershell
|
|
333
|
-
irm https://raw.githubusercontent.com/Han-1413141/dsh-cost-meter/v1.8.
|
|
333
|
+
irm https://raw.githubusercontent.com/Han-1413141/dsh-cost-meter/v1.8.32/install.ps1 | iex
|
|
334
334
|
```
|
|
335
335
|
|
|
336
336
|
**Or a plain command line** (the machine must already have pnpm and git; also pinned to the tag):
|
|
337
337
|
|
|
338
338
|
```sh
|
|
339
|
-
dsh plugin --profile web add github:Han-1413141/dsh-cost-meter#v1.8.
|
|
339
|
+
dsh plugin --profile web add github:Han-1413141/dsh-cost-meter#v1.8.32
|
|
340
340
|
```
|
|
341
341
|
|
|
342
342
|
Without git, use the GitHub tag archive:
|
|
343
343
|
|
|
344
344
|
```sh
|
|
345
|
-
dsh plugin --profile web add https://github.com/Han-1413141/dsh-cost-meter/archive/refs/tags/v1.8.
|
|
345
|
+
dsh plugin --profile web add https://github.com/Han-1413141/dsh-cost-meter/archive/refs/tags/v1.8.32.tar.gz
|
|
346
346
|
```
|
|
347
347
|
|
|
348
348
|
After installing, **restart** `dsh web` (plugin rows, the Typert manifest and the client bundle are all scanned at startup):
|
|
@@ -528,7 +528,13 @@ A per-version overview and the community-issue resolution log live in [docs/UPDA
|
|
|
528
528
|
|
|
529
529
|
## Star History
|
|
530
530
|
|
|
531
|
-
|
|
531
|
+
<a href="https://www.star-history.com/?repos=han-1413141%2Fdsh-cost-meter&type=timeline&legend=bottom-right">
|
|
532
|
+
<picture>
|
|
533
|
+
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/chart?repos=han-1413141/dsh-cost-meter&type=timeline&theme=dark&legend=bottom-right" />
|
|
534
|
+
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/chart?repos=han-1413141/dsh-cost-meter&type=timeline&legend=bottom-right" />
|
|
535
|
+
<img alt="Star History Chart" src="https://api.star-history.com/chart?repos=han-1413141/dsh-cost-meter&type=timeline&legend=bottom-right" />
|
|
536
|
+
</picture>
|
|
537
|
+
</a>
|
|
532
538
|
|
|
533
539
|
## License
|
|
534
540
|
|
package/README.zh-CN.md
CHANGED
|
@@ -10,13 +10,13 @@
|
|
|
10
10
|
|
|
11
11
|
本会话费用 · 当日费用 · OpenCode Go 订阅额度显示 · 预算与已用百分比 · 官方账户余额 · 自定义 Provider 余额查询(可配任意 HTTP 端点) · 余额三段进度条 · 历史记录 · 峰谷计价时段显示(UTC 01:00–04:00、06:00–10:00 为峰时段;周末与中国法定假日全天按谷价,分别标注) · 峰/谷切换前弹窗与系统通知提醒(位置/提前量/提醒类型可配) · 官方价格一键同步 · 类 Codex Token 用量热图 · 多厂商多模型价格计费(内置 170+ 模型 ID 价格目录与自动匹配) · 主流 Coding Plan 额度查询与显示(Anthropic / Z.ai / MiniMax / Kimi / OpenRouter / SiliconFlow / CommandCode / SCNet / 火山方舟 / 千问 / 小米 MiMo 十一家,含 Volcano Ark AK/SK 签名与 MiMo 控制台 Cookie 查询) · Plan/API 双轨计费(订阅额度与按量金额分离统计,每 1% 额度与满窗的 token/等值金额估算及日/周/月曲线) · 输入框上方额度横条(预算/Go/Coding Plan 用量一条横排显示,可开关)
|
|
12
12
|
|
|
13
|
-
[](https://github.com/Han-1413141/dsh-cost-meter)
|
|
14
14
|
|
|
15
|
-
**v1.8.
|
|
15
|
+
**v1.8.32** 新增 [Token Rhythm 人民币可用余额](docs/tokenrhythm-balance.md#中文),保存网站登录 Cookie 即可启用,沿用现有余额卡片、凭据库和刷新缓存。
|
|
16
16
|
|
|
17
17
|
桌面端用户请按 [Desktop 安装说明](docs/install-troubleshooting.md#desktop-安装与更新),使用应用自带的 CLI 和 `desktop` Profile。
|
|
18
18
|
|
|
19
|
-
更新说明:[v1.8.
|
|
19
|
+
更新说明:[v1.8.32 Token Rhythm 余额](docs/update-notes-1.8.32.md#中文)。更新后完全重启 DSH。
|
|
20
20
|
|
|
21
21
|
启动报 **Ledger is busy** 且费用卡片消失时,参见[账本锁恢复说明](docs/ledger-lock-recovery.md#简体中文)。
|
|
22
22
|
|
|
@@ -327,22 +327,22 @@ Node.js 20 请改用 `npm install -g pnpm@10`。版本要求见 [pnpm 官方安
|
|
|
327
327
|
dsh plugin --profile web add dsh-cost-meter
|
|
328
328
|
```
|
|
329
329
|
|
|
330
|
-
**PowerShell 一键脚本**(复制整行粘贴回车;自动补齐 pnpm、自动探测 git,无需克隆仓库;安装链**固定到发布 tag `v1.8.
|
|
330
|
+
**PowerShell 一键脚本**(复制整行粘贴回车;自动补齐 pnpm、自动探测 git,无需克隆仓库;安装链**固定到发布 tag `v1.8.32`**,建议先下载审阅再运行):
|
|
331
331
|
|
|
332
332
|
```powershell
|
|
333
|
-
irm https://raw.githubusercontent.com/Han-1413141/dsh-cost-meter/v1.8.
|
|
333
|
+
irm https://raw.githubusercontent.com/Han-1413141/dsh-cost-meter/v1.8.32/install.ps1 | iex
|
|
334
334
|
```
|
|
335
335
|
|
|
336
336
|
**或直接命令行**(机器上需已有 pnpm 与 git;同样固定到 tag):
|
|
337
337
|
|
|
338
338
|
```sh
|
|
339
|
-
dsh plugin --profile web add github:Han-1413141/dsh-cost-meter#v1.8.
|
|
339
|
+
dsh plugin --profile web add github:Han-1413141/dsh-cost-meter#v1.8.32
|
|
340
340
|
```
|
|
341
341
|
|
|
342
342
|
没有 git 时可用 GitHub tag 打包直链:
|
|
343
343
|
|
|
344
344
|
```sh
|
|
345
|
-
dsh plugin --profile web add https://github.com/Han-1413141/dsh-cost-meter/archive/refs/tags/v1.8.
|
|
345
|
+
dsh plugin --profile web add https://github.com/Han-1413141/dsh-cost-meter/archive/refs/tags/v1.8.32.tar.gz
|
|
346
346
|
```
|
|
347
347
|
|
|
348
348
|
安装后**重启** `dsh web`(插件行、Typert 清单与客户端 bundle 均在启动时扫描):
|
|
@@ -532,7 +532,13 @@ dsh --profile web --port 3099 # 真机启动(观察启
|
|
|
532
532
|
|
|
533
533
|
## Star 增长记录
|
|
534
534
|
|
|
535
|
-
|
|
535
|
+
<a href="https://www.star-history.com/?repos=han-1413141%2Fdsh-cost-meter&type=timeline&legend=bottom-right">
|
|
536
|
+
<picture>
|
|
537
|
+
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/chart?repos=han-1413141/dsh-cost-meter&type=timeline&theme=dark&legend=bottom-right" />
|
|
538
|
+
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/chart?repos=han-1413141/dsh-cost-meter&type=timeline&legend=bottom-right" />
|
|
539
|
+
<img alt="Star History Chart" src="https://api.star-history.com/chart?repos=han-1413141/dsh-cost-meter&type=timeline&legend=bottom-right" />
|
|
540
|
+
</picture>
|
|
541
|
+
</a>
|
|
536
542
|
|
|
537
543
|
## License
|
|
538
544
|
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
# 按渠道设置模型价格
|
|
2
2
|
|
|
3
|
-
在“设置 → 费用 →
|
|
3
|
+
在“设置 → 费用 → 价格 → 模型定价”中,搜索渠道或模型,先查看卡片上的当前单价。点击“设置价格”,再选择“自定义”,即可填写这个渠道的价格。
|
|
4
|
+
|
|
5
|
+
四种来源分别为“自动匹配”“价格表”“自定义”“本地”。选择“价格表”后再搜索并选择具体条目,选定前继续使用原价格;“本地”保留 Token 统计,后续调用的 API 费用记为 0。同一时间只展开一个模型的设置,收起前离开输入框会保存有效输入。
|
|
6
|
+
|
|
7
|
+
“参考价格表”按厂商分组,支持搜索和筛选;列表显示包含倍率的基础输入、缓存读取和输出价格,点击模型行再编辑完整单价。输入、缓存读取、缓存写入和输出列在各厂商间保持一致,窄窗口改为带标签的输入区。“同步与规则”集中放置峰谷计价、官方价格同步、历史费用重算和 OpenRouter 公开报价。切换分区与搜索都不会修改配置。首屏展示 24 个模型,可继续展开;搜索会查找完整列表。
|
|
4
8
|
|
|
5
9
|
输入、缓存读取、输出价格放在同一组,单位为每百万 Token,可选 USD 或 CNY。缓存写入和单独推理费用放在“更多计费项”中。推理已包含在输出价格中时无需另填;缓存写入留空则使用缓存读取价格。
|
|
6
10
|
|
|
@@ -10,7 +10,7 @@ Open **Settings → Cost → Prices → OpenRouter model prices** before choosin
|
|
|
10
10
|
|
|
11
11
|
The panel shows public input, output, cache-read and cache-write prices in **USD per million tokens**, plus context length. `$0` is a published zero rate; `—` means that the catalog did not provide the field. Paid models and `:free` variants are separate rows. Automatic routing entries with negative placeholder prices are omitted.
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
The panel immediately restores the previous catalog, search, sort order and page when reopened in the same DSH session. A snapshot checked less than a minute ago does not trigger another request. Older snapshots stay visible while a background refresh runs; closing and reopening during a request shares that request. While the panel and browser are visible, it refreshes every minute; returning to the foreground also refreshes. **Refresh prices** requests an update immediately, with a shared 15-second cache to limit duplicate requests across windows. The timestamp shows the last successful fetch. A failed request preserves the previous prices and timestamp and displays an error. **Price changed** marks token-rate changes since the previous successful refresh while this panel is open.
|
|
14
14
|
|
|
15
15
|
This lookup only sends an unauthenticated `GET` to [OpenRouter's public models endpoint](https://openrouter.ai/api/v1/models). It requires no API key, sends no model inference requests and incurs no model usage charges. Browsing does not change configured billing rates, credentials or the historical ledger. The existing background billing-price synchronization remains separate.
|
|
16
16
|
|
|
@@ -26,7 +26,7 @@ The catalog is a reference, not a binding quote for the next request. Provider r
|
|
|
26
26
|
|
|
27
27
|
面板显示输入、输出、缓存读取和缓存写入价格,单位为 **美元 / 百万 tokens**,同时列出上下文长度。`$0` 表示目录中的价格为零,`—` 表示目录没有提供该字段。付费模型与 `:free` 版本分别列出;负数占位价格的自动路由条目不显示。
|
|
28
28
|
|
|
29
|
-
|
|
29
|
+
在同一 DSH 会话中重新打开面板时,立即恢复上次价格、搜索词、排序和页码。一分钟内检查过的目录直接复用;超过一分钟时先显示旧表,再后台刷新。刷新期间关闭重开也共用同一次请求。面板与浏览器处于前台时每分钟刷新一次,返回前台时也会刷新。点击 **刷新价格** 可立即请求更新;多个窗口共享 15 秒缓存,避免重复请求。更新时间始终对应最近一次成功查询。查询失败时保留旧价格和原时间,并显示错误。面板打开期间,相比上次成功刷新发生变化的 token 单价标记为 **价格已变动**。
|
|
30
30
|
|
|
31
31
|
查询仅对 [OpenRouter 公开模型接口](https://openrouter.ai/api/v1/models) 发送不带凭据的 `GET` 请求,无需 API Key,不发送模型推理请求,不产生模型使用费用。浏览价格不会修改计费单价配置、凭据或历史账本。原有后台计费价格同步继续独立运行。
|
|
32
32
|
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Token Rhythm 余额
|
|
2
|
+
|
|
3
|
+
## 中文
|
|
4
|
+
|
|
5
|
+
在 **费用 → 额度 → 添加 Token Rhythm 余额** 中展开卡片,保存网站登录 Cookie,再启用卡片。余额可显示在侧栏、设置页或两处,默认每 15 分钟刷新,也可以手动刷新。
|
|
6
|
+
|
|
7
|
+
获取 Cookie:
|
|
8
|
+
|
|
9
|
+
1. 在浏览器登录 [Token Rhythm 账户页](https://tokenrhythm.studio/account)。
|
|
10
|
+
2. 打开开发者工具,在“应用 / 存储 → Cookie”中找到 `tr_session`,复制它的值;也可以在“网络”中查看账户请求,复制请求头中的 `Cookie`。
|
|
11
|
+
3. 填入插件的 **Token Rhythm Cookie** 输入框并保存。支持裸 `tr_session` 值、`tr_session=值` 或完整 Cookie 请求头;查询时只发送 `tr_session`。
|
|
12
|
+
|
|
13
|
+
Cookie 保存在 DSH 凭据库,不写入费用配置或账本,也不会回显。已有环境变量 `TOKENRHYTHM_COOKIE` 时可直接使用。出现登录失效提示后,重新登录官网并替换 Cookie。此处使用网站登录凭据,不使用模型 API Key。
|
|
14
|
+
|
|
15
|
+
显示值与当前官网账户页一致:读取 `GET https://tokenrhythm.studio/api/wallet/summary` 的 `availableBalanceCny`,按人民币显示。冻结金额、累计获赠和历史消费不计入可用余额;接口缺少有效金额时显示错误,真正的零余额正常显示。接口没有预算上限,因此不据此生成使用百分比。
|
|
16
|
+
|
|
17
|
+
沿用现有余额缓存、并行请求合并和取消机制。反复打开设置不会重查未过期的余额;改换或清除凭据后,旧结果立即失效。该功能仅查询余额,不发起模型调用。
|
|
18
|
+
|
|
19
|
+
### 来源与验证
|
|
20
|
+
|
|
21
|
+
- [ykoneee 的 issue #290](https://github.com/Han-1413141/dsh-cost-meter/issues/290) 提出余额显示需求,并提供参考插件。
|
|
22
|
+
- [162568316/dsh-tokenrhythm-bill](https://github.com/162568316/dsh-tokenrhythm-bill/tree/d6ee046d083571810fa8fc12030f67b4132841ec) 提供 `tr_session` 认证方式及字段参考;本插件使用现有余额适配器框架独立实现。
|
|
23
|
+
- 2026-10-16 核对官网账户页前端版本 `037ffef75d824b1638e65b609018b5054e368f71`,确认账户页已使用 `/wallet/summary` 的 `availableBalanceCny`,因此不再沿用参考插件的旧 `/usage-summary` 查询。
|
|
24
|
+
- 官方端点无凭据请求返回 HTTP 401;金额、鉴权、取消、缓存、凭据与设置交互使用模拟响应验证,未查询真实账户。
|
|
25
|
+
|
|
26
|
+
## English
|
|
27
|
+
|
|
28
|
+
Open **Cost → Quotas → Add Token Rhythm balance**, expand the card, save your website session cookie and enable the card. Choose the sidebar, settings or both. The default refresh interval is 15 minutes; manual refresh is available.
|
|
29
|
+
|
|
30
|
+
Sign in at the [official account page](https://tokenrhythm.studio/account). In browser DevTools, copy `tr_session` from Application / Storage → Cookies, or copy the account request's Cookie header from Network. Paste the raw session value, `tr_session=value`, or the full Cookie header into **Token Rhythm Cookie**. Only `tr_session` is sent upstream.
|
|
31
|
+
|
|
32
|
+
Credentials use the DSH credential store and are never returned to the UI or written to the ledger/configuration. `TOKENRHYTHM_COOKIE` is also supported as an environment fallback. Replace an expired cookie after signing in again. A model API key cannot replace the website session cookie.
|
|
33
|
+
|
|
34
|
+
The integration reads `availableBalanceCny` from `GET https://tokenrhythm.studio/api/wallet/summary`, matching the current account page's available CNY balance. Frozen funds, lifetime gifts and historical spend are separate. Missing amounts produce an error; valid zero balances remain zero. No usage percentage is invented without a budget limit.
|
|
35
|
+
|
|
36
|
+
Existing balance caching, request sharing and cancellation are reused. Reopening settings reuses a fresh result. Changing or clearing the credential invalidates the old result. No model calls are made.
|
|
37
|
+
|
|
38
|
+
Thanks to [ykoneee](https://github.com/ykoneee) for [the request and reference](https://github.com/Han-1413141/dsh-cost-meter/issues/290), and [162568316](https://github.com/162568316/dsh-tokenrhythm-bill/tree/d6ee046d083571810fa8fc12030f67b4132841ec) for the authentication/field reference. The current endpoint and available-balance field were checked against the official frontend on 2026-10-16. Automated checks use synthetic responses; no authenticated live account was tested.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# v1.8.31
|
|
2
|
+
|
|
3
|
+
## 中文
|
|
4
|
+
|
|
5
|
+
接入 [Oct1AtJoe 的 PR #288](https://github.com/Han-1413141/dsh-cost-meter/pull/288),Antigravity 额度改为优先查询生产端点,daily 和 sandbox 作为备用。另修复备用端点成功后仍解析第一个空响应的问题;生产端点不可用时可以继续显示备用额度,Gemini 筛选规则保留。验证使用模拟网关响应,未查询真实账号。
|
|
6
|
+
|
|
7
|
+
接入 [UNscientific-9 的 PR #287](https://github.com/Han-1413141/dsh-cost-meter/pull/287),把价格模型搜索与选择合并为单框。修复已有选择时搜索后回车仍保留旧值,以及末尾已选项未滚入视野的问题;候选列表定位完成后再滚动,搜索词改变时保持高亮项可见。
|
|
8
|
+
|
|
9
|
+
价格表改用统一的 SVG 展开箭头,随展开状态旋转。OpenRouter 面板重开时立即恢复上次价格、搜索、排序和页码,一分钟内直接复用;过期后保留旧表并后台刷新,失败不清空,关闭重开也不会重复发起进行中的请求。
|
|
10
|
+
|
|
11
|
+
概览卡片按可见数量等宽排列:今日、本月、累计三张同排;隐藏今日费用后两张平分宽度。窄窗口统一纵向排列,避免“2+1”留白。
|
|
12
|
+
|
|
13
|
+
价格设置分为“模型定价”“参考价格表”“同步与规则”。默认打开模型定价,按渠道和模型显示卡片,可搜索已使用的模型,并选择自动匹配、价格表、自定义价格或本地零费用。
|
|
14
|
+
|
|
15
|
+
模型默认显示单价摘要,点击“设置价格”再展开。自动匹配、价格表、自定义、本地改为四种明确的选择,只显示对应的控件;展开或搜索价格表时不会提交配置,选定条目后才切换。
|
|
16
|
+
|
|
17
|
+
参考价格表改为厂商分组列表,支持模型搜索和厂商筛选;点开一行才挂载编辑器,输入、缓存读写和输出的顺序统一,窄窗口显示字段标签。
|
|
18
|
+
|
|
19
|
+
自定义价格以完整宽度显示,输入、缓存读取、输出单价并列,币种单独标明。沿用原有统一与独立倍率操作,下方分项显示乘倍率后的实际单价;更多计费项按需展开。长模型名自动换行,深浅色沿用 DSH 主题,窄窗口自动调整列数。
|
|
20
|
+
|
|
21
|
+
首屏只渲染 24 个模型,搜索覆盖完整列表,可继续展开其余模型。价格表按厂商展开,同步和历史重算仅在打开相应分区后加载。搜索和切换分区不写入配置。
|
|
22
|
+
|
|
23
|
+
价格设置的调整沿用既有单价、倍率、计费与历史费用规则。
|
|
24
|
+
|
|
25
|
+
## English
|
|
26
|
+
|
|
27
|
+
Antigravity quota lookup now prioritizes the production endpoint, retaining daily and sandbox fallbacks, from Oct1AtJoe’s PR #288. Successful fallback responses are parsed from their actual slot rather than the failed primary slot. Gemini-only filtering remains intact. Tests use synthetic gateway responses without live account requests.
|
|
28
|
+
|
|
29
|
+
Pricing settings now have three sections: Model pricing, Price tables, and Sync & rules. The default model view uses channel/model cards with a local filter and a clear price-source selector.
|
|
30
|
+
|
|
31
|
+
Models start with rate summaries and expand on request. Automatic, table, custom and local pricing are explicit source buttons with contextual controls. Preparing a table selection does not save until a specific entry is chosen. Reference tables use searchable, provider-filtered lists with one editor open at a time and consistent field order. Custom-price fields use the full card width. Currency, input, cache and output rates are clearly separated; shared/per-rate multipliers reuse the existing controls, with individual effective-price previews. Long names wrap, narrow layouts adapt, and colors follow DSH theme tokens.
|
|
32
|
+
|
|
33
|
+
Only 24 model cards render initially. Search covers the full list and more results can be expanded. Catalog groups and sync/history controls mount on demand. Searching and navigating never save configuration. Billing and recorded historical amounts retain their existing behavior.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# v1.8.32
|
|
2
|
+
|
|
3
|
+
## 中文
|
|
4
|
+
|
|
5
|
+
新增 Token Rhythm 人民币可用余额显示。在“费用 → 额度”点击“添加 Token Rhythm 余额”,保存网站登录 Cookie 后启用,便可在侧栏和设置页查看。沿用 DSH 的额度卡片和凭据输入方式,可选择显示位置与刷新间隔。
|
|
6
|
+
|
|
7
|
+
查询使用当前官网账户页的钱包接口,显示 `availableBalanceCny`,避免把冻结金额或历史消费当作可用余额。未过期的结果直接复用;修改、清除凭据后旧余额作废。缺少有效金额或登录失效时给出明确提示。
|
|
8
|
+
|
|
9
|
+
感谢 [ykoneee](https://github.com/ykoneee) 提出 [#290](https://github.com/Han-1413141/dsh-cost-meter/issues/290) 并提供参考,感谢 [162568316 的开源插件](https://github.com/162568316/dsh-tokenrhythm-bill) 提供认证与字段参考。
|
|
10
|
+
|
|
11
|
+
[设置方法与验证范围](tokenrhythm-balance.md#中文)。更新后完全重启 DSH。
|
|
12
|
+
|
|
13
|
+
## English
|
|
14
|
+
|
|
15
|
+
Token Rhythm available CNY balance is now supported. Under Cost → Quotas, add a Token Rhythm balance card, save the website session cookie and enable the card. Display placement and refresh interval reuse the existing DSH quota UI.
|
|
16
|
+
|
|
17
|
+
The integration uses the current official wallet endpoint and `availableBalanceCny`, keeping frozen funds and historical spend separate. Fresh results are cached; changing or clearing credentials invalidates old results. Missing amounts and expired sessions produce clear errors.
|
|
18
|
+
|
|
19
|
+
Thanks to [ykoneee](https://github.com/ykoneee) for [issue #290 and the reference](https://github.com/Han-1413141/dsh-cost-meter/issues/290), and [162568316](https://github.com/162568316/dsh-tokenrhythm-bill) for the authentication and field reference.
|
|
20
|
+
|
|
21
|
+
See [setup and validation details](tokenrhythm-balance.md#english). Fully restart DSH after upgrading.
|