@agentrouter-top/dsh-plugin
Public AgentRouter provider bundle for official DeepSeek Harness. This package is maintained by AgentRouter and is not an official DeepSeek Harness package.
The npm package is public, while its development repository is private. The published tarball contains compiled JavaScript, type declarations, this README, the MIT license, and the DSH patch only; it intentionally excludes source maps and original TypeScript sources. Because the source repository is private, npm public-source provenance is unavailable. Release verification instead binds the registry integrity value to the exact accepted tarball bytes.
Install
Install and update official DSH through its official npm distribution. Then add this bundle to the profile you use:
dsh plugin --profile web add @agentrouter-top/dsh-plugin
Upgrade the same profile and restart its running DSH process:
dsh plugin --profile web update --latest @agentrouter-top/dsh-plugin
Install or roll back an exact version with
dsh plugin --profile web add @agentrouter-top/dsh-plugin@<version>. Official
DSH owns profile package management; running npm update from an unrelated
directory does not update the profile. This plugin never checks npm or installs
code silently at startup.
Configure
The bundle declares these values:
- credential reference:
AGENTROUTER_API_KEY; - Base URL:
https://api.agentrouter.top/v1; - initial model:
deepseek-chat; - provider id:
agentrouter.
Store the key with official DSH's Models settings page or export
AGENTROUTER_API_KEY before launching. Do not put the literal key in a patch,
settings document, issue, or log. For local or self-hosted testing, set the
non-secret AGENTROUTER_BASE_URL to the complete /v1 root. Set
AGENTROUTER_MODEL to the initial model exposed to the profile.
Official DSH's Models page can interrogate an OpenAI-compatible endpoint and
replace the model list in its llm-pi-ai settings namespace. Advanced users
can make the same override in their official DSH user layer. User layers are
applied after this bundle and remain authoritative.
On a new graphical profile the plugin contributes an AgentRouter step before DSH's provider-neutral onboarding completes. It uses only public DSH browser contracts:
- the entered key is sent once to
llm.discoverModelsfor the stablehttps://api.agentrouter.top/v1endpoint; - after a successful check, the key is written through
credentials.setto theAGENTROUTER_API_KEYreference and immediately removed from the form; - the returned model directory and selected default are written through
settings.mutate; - subsequent edits use DSH's official Models page.
The plugin never adds a local proxy. Model requests and streams continue to go
directly from the official DSH pi-ai adapter to AgentRouter /v1.
Errors and recovery
MISSING_CREDENTIALor 401: setAGENTROUTER_API_KEYto a valid user API key. The key value is never included in the diagnostic.UNKNOWN_MODEL, 403, or model unavailable: refresh/replace the AgentRouter model list and select a model the key can access.- network or 5xx failure: verify the complete Base URL and AgentRouter service health; DSH's official adapter preserves its normal recoverable error.
- empty model directory: enter a confirmed model ID in the onboarding fallback, or use the official Models page after choosing another provider.
- incompatible DSH adapter: install a supported official DSH version or remove this bundle. The plugin never changes DSH on the user's behalf.
Remove the bundle without touching other profile data:
dsh plugin --profile web remove @agentrouter-top/dsh-plugin