Z.ai · GLM Coding Plan · Stream Deck

Your quota, on your keys.

Z.ai Usage Deck keeps the GLM Coding Plan windows in view — how much is left, when each one resets, your burn rate, and what ZCode is doing — at a glance, on an Elgato Stream Deck.

Get it on the Elgato Marketplace A Stream Deck grid showing the plugin's key faces

The deck, in pictures

Requirements

Quick start

The seven actions

What Remains

Concentric rainbows whose filled length is the quota left in each window, with the reset countdown under the arch.

Reset Timer

Live countdown to the next reset: the shorter window on top, the longer one beneath, ticking on the key's own clock.

Pace

How long each window lasts at the pace it is being drained — ~2H 10M, or steady when nothing is running.

24h Tokens

A sparkline of token burn across the last day, the current hour brightest, with the 24-hour total.

Status / Refresh

Plan label, tokens used in the last 24 hours and data freshness. Press to refresh any time.

Agent Confirm

Lights up when ZCode awaits a permission decision. Press to approve, hold to deny.

Agent Stopped

Lights up green when a ZCode thread finishes responding, cleared by the next prompt or a press.

About the Pace key

The quota API reports what is left, never how fast it is going — so the plugin watches its own readings. A fresh Pace key shows warming up for the first few polls; after roughly twelve minutes of history it shows the estimate, and a window nobody is draining shows steady rather than an invented number. The history lives only in memory.

ZCode bridge (agent keys)

The two agent keys talk to the ZCode CLI through hook scripts the plugin ships inside its bundle. Run the installer once — it copies the scripts to ~/.zcode-bridge and merges a hooks block into ~/.zcode/cli/config.json, backing the file up first:

macOS
node "$HOME/Library/Application Support/com.elgato.StreamDeck/Plugins/com.zeroquarry.zai-usage-deck.sdPlugin/bridge/install.mjs"

Windows
node "%appdata%\Elgato\StreamDeck\Plugins\com.zeroquarry.zai-usage-deck.sdPlugin\bridge\install.mjs"

Until the installer has run, the agent keys show an amber NO BRIDGE card. The hooks defer to the app's own dialogs whenever the keys are not on screen; ZCODE_BRIDGE_DISABLED=1 bypasses the bridge without uninstalling, and deleting the hooks key removes it entirely. Every decision lands in ~/.zcode-bridge/journal.log, so an alert can always be explained after the fact.

Where the data comes from

The plugin reads the monitoring endpoints your own API key already exposes — GET /api/monitor/usage/quota/limit and GET /api/monitor/usage/model-usage — from the host you choose. Windows are named after the durations the API actually reports: an account whose short window is an hour is labelled 1H, not 5H. A five-hour reset that claims to be more than five hours away is dropped rather than corrected for a guessed timezone.

Privacy

The plugin talks to exactly one service: the Z.ai / BigModel monitoring host you configure. It sends only your API key, as the Authorization header of a quota request, plus the Organization and Project headers in team scope. No telemetry, no analytics, no third-party requests of any kind. The API key is stored in Stream Deck's own settings on your machine, is never written to logs or per-key settings, and is only ever shown masked. The agent keys read and write only the local ~/.zcode-bridge/ working files.

Support