Whale Paywall and Marketplace (dsh-whale-paywall)

Introduction

When DeepSeek Harness (DSH) is run locally, there is typically no paywall to control usage frequency. If you want to simulate a “paid subscription” or “premium feature” experience, the most straightforward approach is to hardcode the checks, but this introduces maintenance costs, multi-language adaptation challenges, and other issues. dsh-whale-paywall provides DSH with a unified billing and top-up mechanism: it adds a “Whale Coin” threshold to common actions and includes a built-in “Shop” entry in the settings panel, allowing users to purchase gift packs. The entire process is purely simulated and will not incur any real charges.

What It Is

dsh-whale-paywall is a plugin that provides a simulated paywall and Whale Coin shop for DeepSeek Harness. It was developed by the maintainer koishi-fumo-code and belongs to the “fun skin” category of plugins. The plugin injects payment popups and shop UI into the DSH client to bill for the following 7 actions: creating a new conversation, archiving a conversation, downloading a plugin, entering settings, enabling a plugin, web search, and switching models. All billing uses Whale Coins and does not involve real currency. Wallet data is stored in a local JSON file.

Core Features

Billed Actions

The plugin charges separately for the following actions:

  • Create new conversation: 6 Whale Coins
  • Archive conversation: 1 Whale Coin
  • Download plugin: 12 Whale Coins
  • Enter settings: 1 Whale Coin
  • Enable plugin: 1 Whale Coin
  • Web search (web_search / web_fetch): 1 Whale Coin
  • Switch model: 1 Whale Coin

Deduction Order

  • Use remaining action credits first (if available)
  • Deduct Whale Coins when credits are insufficient
  • Show a blocking popup when neither is sufficient

Purchasing a gift pack is equivalent to pre-accumulating action credits, eliminating the need to buy individually each time.

Shop

A new “Shop” entry is added to the settings panel (the last item in the left navigation). The top of the shop displays the current Whale Coin balance, the middle section shows the remaining credits for the 7 features (when at 0, the per-use price is displayed in red), and the bottom lists available gift packs. The initial balance is 50 Whale Coins, and gift pack buttons will never be disabled; when the balance is insufficient, the difference is automatically topped up before completing the purchase. The bottom of the shop page provides a “Top Up (Simulated)” button and a “Reset Wallet” function for repeated testing.

The gift packs are as follows:

  • Starter Pack: 16 Whale Coins
  • 3 new conversation credits
  • 9 archive credits
  • 1 plugin download credit
  • 3 web search credits
  • 1 model switch credit
  • 1 plugin enable credit
  • New Conversation Pack: 30 Whale Coins
  • 6 new conversation credits
  • Archive Pack: 6 Whale Coins
  • 10 archive credits
  • Plugin Download Pack: 60 Whale Coins
  • 10 plugin download credits

Multi-Language Support

The plugin does not hardcode Chinese text. Instead, it uses DSH’s built-in multi-language strings for button matching, supporting the following 8 interface languages: Simplified Chinese, English, Japanese, German, Spanish, French, Portuguese, and Russian. After switching to a different computer or changing the language, button labels and billing logic remain consistent.

Deadlock Prevention Design

  • Entering settings is billed, but the “Top Up” button grants direct access to the shop, so users can purchase gift packs even with a balance of 0.
  • After a successful top-up, the previously blocked action is automatically retried—no need to repeat it manually.
  • The popup overlay uses pointer-events: none to ensure it doesn’t swallow clicks across the entire page.
  • A React error boundary wraps the card rendering; on exception, the queue is cleared and the popup closes automatically.
  • The popup displays for a maximum of 25 seconds and supports the Esc key to close.
  • If wallet balance reading fails, the action is always allowed through—no feature lockout due to interface errors.

Installation & Enablement

The plugin offers three installation methods. Choose any one of the following.

① Local Directory (for development)

Copy the entire plugin folder to the target machine, then in DSH navigate to “Plugins → Add Plugin → Install Existing Plugin” and enter the absolute path to that folder.

② Pre-built Package

pnpm pack        # Generates dsh-whale-paywall-0.1.0.tgz

Copy the .tgz file to the target machine, then in “Plugins → Add Plugin” enter the tgz path or a file:// URL.

③ Publish to npm / Git

npm publish            # After publishing, the other party enters dsh-whale-paywall in the plugin list

After installation, enable dsh-whale-paywall on the “Plugins” page. No configuration files need to be modified—the cordis.patch.yml bundled in the package is injected automatically.

Verifying Installation

After a successful installation, check the following two items:

  • A new “Shop” entry appears in the settings panel.
  • When creating a new conversation or performing other billed actions, a payment prompt popup appears.

The wallet file is located at $DSH_HOME/whale-paywall.wallet.json. It is created automatically on first access with an initial balance of 50 Whale Coins. The Host and the browser side read and write the same file; deleting it resets everything to the initial state.

Use Cases & Notes

  • Suitable for developers and users who need to simulate a paywall, control feature usage frequency, or demonstrate a “paid subscription” experience.
  • The plugin runs with the permissions of the current DSH process. It is recommended to review the source code and license (MIT) before installing.
  • After uninstalling the plugin, payment popups and the shop entry disappear immediately, but the wallet file remains on local disk.

In Short

dsh-whale-paywall provides DSH with a lightweight simulated paywall solution through a unified billing and shop mechanism, allowing users to set usage thresholds for common actions without any hardcoding. For more details, check the plugin directory page and the GitHub repository.

羽毛球分组比赛记分
小程序二维码

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

Xiaoye