DeepSeek Harness (DSH) follows the “everything is a plugin” philosophy. In the Web profile scenario, DSH has a built-in pi-ai integration but does not provide a native OAuth login entry point. When developers need to integrate third-party AI services (such as GitHub Copilot, Kimi, etc.), they typically have to manually handle complex authorization flows. dsh-oauth-adapter fills this gap for the DSH Web profile by standardizing the existing login workflow.

What Is This

dsh-oauth-adapter is a plugin maintained by edge-sky that provides a unified OAuth account page for the DSH Web profile. It exposes the existing provider login workflows through the DSH Authorization Service. DSH owns the OAuth credentials and login state, while this plugin is responsible for displaying authorization options in the Web UI and storing model configuration in dsh-oauth-adapter.modelStore.

Core Features

The plugin supports multiple mainstream AI service providers and adapts to different authentication flows:

  • Multi-provider support:
    • OpenAI Codex: Supports browser callback or device code login.
    • GitHub Copilot: Supports device code login for GitHub or GitHub Enterprise.
    • Anthropic: Supports browser callback, with fallback to manual code entry or redirect on failure.
    • Kimi For Coding: Supports device code login.
    • OpenRouter: Supports browser PKCE callback.
    • xAI: Supports device code login.
  • Authorization fallback mechanism: If the host environment does not provide ctx.authorization, the plugin mounts an authorization fallback page to ensure the login flow is not interrupted.
  • State storage: Login state and model configuration are managed uniformly by DSH, with configuration stored in dsh-oauth-adapter.modelStore.

Installation and Enabling

Before installing, ensure your environment meets the following requirements:
* Node.js: ^22.19.0 or >=24.0.0
* Dependency checks: @deepseek-ai/cordis >=4.0.4 <5, @deepseek-ai/dsh-authorization >=0.2.0-rc.2 <0.3.0-0

The installation command for DSH 0.2.0-rc.2 is:

dsh plugin --profile web add @edge-sky/dsh-oauth-adapter

For DSH 0.1.2-rc.1 through 0.1.5-rc.1, use the 0.1.3 series adapter release; for DSH 0.1.1-rc.2, use @edge-sky/dsh-oauth-adapter@0.1.2-rc.0.

After installation, start the Web profile to use it:

npx @deepseek-ai/dsh web

Use Cases and Notes

  • Intended users: Developers who need to integrate multiple third-party AI services (such as Copilot, Kimi, etc.) in the Web UI, or users who need to manage DSH login state centrally.
  • Permission risks: The plugin runs with the permissions of the current DSH process and involves OAuth credentials and login state. Please review the source code and license (MIT) before installing.
  • Version compatibility: The plugin has specific DSH version requirements. Confirm that your current DSH version matches the plugin version before installing.