DSH (DeepSeek Harness) provides a unified conversation and management interface. In practice, developers often need to connect to multiple providers such as DeepSeek, Zhipu, and Moonshot at the same time. Frequently switching between platforms to check balances or quotas can interrupt the workflow.

The dsh-ai-wallet plugin adds a draggable floating ball in the lower-right corner of the DSH interface. It aggregates and displays in real time the balance/quota for the model used in the current conversation. Click it to expand and view the monetary balances or quota remaining across all configured providers.

Core Features

The floating ball and panel are the main interaction modes of the plugin. The floating ball can be fixed anywhere on the interface, supports free dragging, and remembers its position automatically.

The ball surface displays in real time the balance/quota of the model currently used in the conversation (data is inferred from the most recent model call and refreshed every 60 seconds). Click the ball or overlay to expand the full balance panel.

The panel provides the following capabilities:
- View the monetary balances or quota remaining for all configured providers on one screen.
- For quota-based providers, display a progress bar and reset time.
- Support manual refresh, and provide friendly messages for missing keys or API errors.

The plugin includes 8 built-in themes (including Liquid Glass, Light Glass, Cyber Cyan, and Dracula), which can be switched with one click at the bottom of the panel. Theme and floating ball position are persisted to a server-side file (~/.dsh/dsh-ai-wallet.prefs.json), preventing loss when the DSH port changes.

Installation and Enabling

Install the plugin via command line. DSH must be restarted after installation for changes to take effect.

dsh plugin --profile desktop add dsh-ai-wallet

Configuration and Usage

By default, the plugin enables the deepseek and zhipu providers. Override the configuration in cordis.patch.yml for your profile to adjust the panel display order or enable specific providers.

- id: dsh-ai-wallet
  config:
    providers:
      - deepseek
      - moonshot
      - zhipu

The order in the providers array determines the order in which providers appear on the panel.

Custom Provider Integration

For providers not in the built-in allowlist, or providers using private endpoints, you can integrate them declaratively via config.customProviders without modifying the source code. It supports quota (progress bar) and balance (monetary amount row) types, with bearer (default) and cookie authentication methods.

- id: dsh-ai-wallet
  config:
    providers:
      - deepseek
      - my-gateway
    customProviders:
      - id: my-gateway
        name: 内部网关
        kind: quota
        url: https://your-gateway.example.com/api/profile/quota
        auth: cookie
        keyNames: [GATEWAY_COOKIE]
        fields:
          level: data.status
          limits:
            label: 月度配额
            remaining: data.remainingCny
            total: data.limitCny
            percentage: data.utilizationPercent
            resetTime: data.period.resetsAt

Supported Providers

The plugin supports built-in balance queries for the following providers:

  • DeepSeek
  • Zhipu GLM
  • Z.ai (International GLM)
  • Moonshot (Kimi)
  • MiniMax
  • StepFun
  • SiliconFlow
  • OpenRouter
  • xAI (Grok)

Notes

  • xAI limitation: The xai provider uses a community-maintained unofficial credits endpoint. Because xAI prepaid credits do not have a public API, if that community endpoint fails, the panel will display an error.
  • Unsupported providers: Providers that are console-only and do not expose a public balance API (such as Qwen, Baichuan, and Groq) are not supported for now. Ordinary keys for OpenAI and Anthropic also do not support usage queries, so they are not built in.
  • Permissions and security: The plugin runs with DSH process permissions. Before installation, it is recommended to review the source code and license (MIT).

Summary

dsh-ai-wallet centralizes multi-provider balance and quota queries inside the DSH interface through a floating ball and panel. Developers can monitor resource usage without leaving their current workflow, making it suitable for scenarios requiring simultaneous management of multiple AI service accounts.