DSH Quota Watch: Visualizing GLM and Copilot Quotas

In DSH environments, real-time monitoring is required for quota snapshots and subscription usage details of the GLM Coding Plan and GitHub Copilot. The DSH Quota Watch plugin provides a persistent floating capsule and a details panel to intuitively display the quota snapshot reported by the service provider.

Plugin Positioning

This plugin is maintained by iasiv5 and addresses the need to instantly view GLM and Copilot quota snapshots and subscription details within the DSH interface.

Core Features

  1. Floating Capsule and Details Panel: The capsule displays the used percentage for GLM and Copilot. Clicking it allows you to view the quota window, reset time, and usage statistics. The capsule is draggable, and its position is remembered and kept within the visible area.
  2. GLM Details: Displays today’s tokens, call count, quota window, and per-model usage.
  3. Copilot Details: Displays the available quota, used quota for the current period, and reset time reported by the service provider.
  4. Sidebar Card: Optional, occupying the first slot in the sidebar footer; disabled by default.
  5. Fault Tolerance and Language Adaptation: The interface follows the DSH language setting; if detection fails, the last successful snapshot is retained.

Installation and Enablement

Run the following commands in the command line to install:

dsh plugin --profile web add @iasiv5/dsh-quota-watch
dsh plugin --profile desktop add @iasiv5/dsh-quota-watch

Both the Web and Desktop profiles have been tested and adapted.

Usage Instructions

View Quota

Click the floating capsule to view the quota window, reset time, and usage statistics reported by the service provider.

Manual Use of the Reset Card (Domestic Site Personal Edition Only)

A reset card is a consumable, non-revocable subscription benefit. Only the domestic site personal edition configured as zai-coding-cn is supported.

The operation process is as follows:

  1. Select the card type.
  2. Perform a secondary confirmation in the panel, specifying the card type, affected window, and a non-revocable warning.
  3. Before the host sends the non-revocable POST, it first persistently records the current attempt in the host-side one-time usage record.

Data Safety

The plugin does not read the DSH session token; credentials are resolved by the DSH host, and the browser only receives the organized quota data.

Precautions

  1. API Stability: The Copilot quota endpoint and the GLM reset card API are not stable public contracts; fields or behavior may change.
  2. Reset Card Limitations: Manual use of a reset card still requires special caution, as the domestic site reset card endpoint is not public and may change. Cards other than the domestic site personal edition configured as zai-coding-cn are not supported.
  3. Removal of Automatic Card Usage: On the first host startup, the automatic card usage switch saved by historical versions is persistently overwritten to off once (even if the settings file does not exist, an all-off override is written), so rolling back to an older version will not revive the previous authorization.
  4. Privacy and Storage: The plugin does not write keys, OAuth grants, or raw service provider responses to disk, and it does not save quota history.
羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye