dsh-provider-headers
Run the following command in DeepSeek Harness:
dsh plugin install duanyunlun/dsh-provider-headers
Paste the following prompt into your AI chat to install this plugin:
Run dsh plugin install duanyunlun/dsh-provider-headers inside DeepSeek Harness to install this plugin; the source repository is hosted at https://github.com/duanyunlun/dsh-provider-headers .
About this plugin
DeepSeek Harness already supports per-provider request headers on the pi-ai routing layer, yet the model settings page ships no GUI entry for that field, leaving users to hand-edit settings.yaml. dsh-provider-headers drops a row-based "Custom Headers" editor into every pi-ai provider card on the settings page. You add, edit, and remove name/value pairs, hit Save, and the values land in the same native Harness field. Uninstalling the plugin restores everything; no dsh source code or packaged bundle is modified.
The native config cannot do one thing: make a header value change per session. On the host side the plugin listens on the llm/stream waterfall, wraps each streaming call in an AsyncLocalStorage scope that carries the call's session ID, and patches globalThis.fetch so that, only within that scope, header values containing the ${sessionId} token are expanded to the real session ID before the request goes out. Requests outside the scope pass through untouched, and wrappers installed by other plugins are never overwritten. Fixed-value headers still ride the native Harness path. A practical example: services like OpenCode Go that require a stable x-opencode-session header per request only need a single row with the ${sessionId} placeholder.
This plugin is aimed at dsh users who need to attach dynamic request headers to a specific pi-ai provider without editing YAML or patching the Harness core. Keep in mind it only covers pi-ai routes (the llm-deepseek official route has no headers field at all), user-agent is a reserved name skipped on both paths, ${sessionId} expansion applies exclusively to streaming model requests (not the one-shot model-discovery call), and header values are stored as plain text in settings.yaml, so credentials should go in the dedicated apiKeyEnv field instead.
Use Cases
- Attach custom request headers to a specific pi-ai provider from the settings UI
- Use the ${sessionId} placeholder in header values for per-session dynamic expansion
- Replace manual settings.yaml edits with a visual header editor
Best For
- dsh users who need dynamic request headers on pi-ai providers
- Developers who prefer GUI configuration over hand-editing YAML or patching source
- Service integrators that require per-session unique header values such as x-opencode-session
Related Plugins
A unified suite combining hot runtime injection, task-aware thinking-mode routing, and a graded session protocol with red-team gates to sustain model diligence across long-horizon inference.
ModLens is a vision plugin for DeepSeek Harness that gives text-only models sight by reading images pasted directly into chat, with zero-config setup and multiple vision engines.
On-demand vision for text-only DeepSeek Harness agents: built-in free keyless vision chain and 14 vision tools, routing image turns as tool calls to vision models with pixel fidelity, no Python needed, one-command install.
Give text-only models in DeepSeek Harness eyes, enabling image Q&A, long-screenshot OCR, UI restoration, and GUI visual tasks.