dsh-sub2api-sync
DiscoveredDeepSeek Harness (DSH) plugin: sync one sub2api instance's groups, keys, and models into dsh-llm-pi-ai provider routes — one relay key, one provider.
dsh-sub2api-sync
中文说明:README.zh.md
A DeepSeek Harness (DSH) plugin that syncs one sub2api instance's groups, relay keys, and models into dsh-llm-pi-ai provider routes — log in once, integrate automatically, keep syncing.
Highlights
- Panel-driven login — panel email/password (+TOTP); the web OAuth + PKCE channel lands once sub2api deploys its OAuth endpoints.
- Keys-driven sync — tick one or many relay keys from the panel's Keys card (cross-group); one key becomes one provider under a stable route name
sub2api-<10-hex>that leaks no key ordering. - Model experience — model catalog from instance discovery, enriched from the models.dev directory (display names, context windows, image input, reasoning efforts) with a bundled offline snapshot fallback.
- Secrets stay secret — panel tokens, passwords, and relay keys live only in the harness credential store; never in settings, logs, or sessions.
- Bilingual UI — full zh/en settings card and plugin config card.
- Coexists cleanly — the community plugin
GodD6366/dsh-sub2apican stay installed; route names and credential references do not collide.
Requirements: DSH ≥ 0.2.0-rc.2 · Node ≥ 22.19 · a sub2api panel account that can read relay key plaintext (admin).
Install
Four equivalent channels — all ship the built lib/, no local build needed.
npm — two names, same code, same version (scoped canonical + unscoped alias):
dsh plugin --profile web add @mangoc/dsh-sub2api-sync
# or
dsh plugin --profile web add dsh-sub2api-sync
GitHub Releases — a stable-name tarball that always points to the latest release:
dsh plugin --profile web add https://github.com/Shuai-S/dsh-sub2api-sync/releases/latest/download/dsh-sub2api-sync.tgz
From source — pnpm runs the prepare build on git dependencies (needs a local toolchain):
dsh plugin --profile web add github:Shuai-S/dsh-sub2api-sync#path:packages/llm/sub2api-sync
While this repository is private, the two GitHub channels require repository access.
After installing, restart the app or toggle the plugin off/on; failed entries are not retried automatically.
Usage
- Click Login in the settings card, enter the instance URL (e.g.
https://cn.api.nexarelay.com) plus panel credentials (TOTP supported; the password is stored in the credential store). - The Keys card lists the instance's relay keys — tick one or many (cross-group), or create a new key inline.
- Hit Sync selected (N) — the engine builds one provider per key, discovers models, and writes routes into
llm-pi-ai.providers. - Models become selectable on the next request; the sync report supports per-entry removal (local routes and credentials only, the panel is never called).
Full manual: packages/llm/sub2api-sync/README.zh.md · English
Repository layout
| Path | Contents |
|---|---|
packages/llm/sub2api-sync/ | The plugin package: server half (src/), client UI (src/client/), tests, locale, offline model snapshot |
docs/design/ | Design notes: Phase 1 sync engine, client UI rev.5, OAuth provider |
.github/workflows/release.yml | Tag-driven dual-channel release (GitHub Release + npm dual publish) |
Development
pnpm install # installs deps and runs the prepare build
pnpm check # typecheck + tests + build
dsh plugin --profile web add ./packages/llm/sub2api-sync
dsh plugin add only symlinks local directories — build first (pnpm build), or the plugin never activates.
Release (maintainers)
- Bump
versioninpackages/llm/sub2api-sync/package.json. - Commit, then
git tag vX.Y.Z && git push origin vX.Y.Z. - CI runs checks, packs both published names (scoped canonical + unscoped alias — the plugin identity is injected per variant), attaches the stable-name tarball to the GitHub Release, and publishes to npm.
The first publish of a brand-new package name parks in npm's Staged Packages queue — confirm it once on npmjs.com; later releases go straight through.
Manual dual publish: packages/llm/sub2api-sync/README.md.
License
Comments
Loading…
Similar plugins
by tearslee
DeepSeek Harness (dsh) plugin: supervise a workbuddy2api gateway process and auto-register its models as an LLM provider
★ 7
↓ 693/wk
MIT
TypeScript
Oct 20, 2026
dsh plugin --profile web add dsh-workbuddy2apiby jdz321
DeepSeek Harness (dsh) plugin that routes model traffic through any new-api-family relay panel (one-api / new-api / Veloera / done-hub / ...)
★ 0
MIT
TypeScript
Oct 14, 2026
dsh plugin --profile web add dsh-plugin-relayby Retr67
DeepSeek Harness (DSH) plugin: one-click OpenCode Go model sync in the settings panel - fetch all server models, probe availability & vision, write back to llm-pi-ai config
★ 4
MIT
JavaScript
Oct 22, 2026
dsh plugin --profile web add dsh-opencode-modelsby Fast-Editor
DeepSeek Harness (dsh) plugin: registers Lynkr as a custom OpenAI-compatible provider
★ 0
MIT
TypeScript
Aug 28, 2026
dsh plugin --profile web add lynkr-dsh-pluginby ZSeven-W
DeepSeek Harness (DSH) plugin: a read-only ledger for the plugins you already have installed — a capability inventory with file:line evidence, declared-vs-detected reconciliation, cross-profile versio
★ 25
↓ 101/wk
MIT
JavaScript
Oct 23, 2026
dsh plugin --profile web add @zseven-w/dsh-harborby iJetLi
deepseek-harness plugin: sign in and manage accounts across multiple AI coding providers, with multi-account pools and silent credential refresh
★ 12
↓ 1.1k/wk
MIT
TypeScript
Oct 24, 2026
dsh plugin --profile web add dsh-providers-hub