dsh-plugin-mock-server: Starting and Stopping a Local HTTP Mock Service in DSH

Introduction

In Harness, debugging external APIs often involves manually changing environment variables, temporarily starting nginx, or repeatedly pasting fake responses into the chat. While these methods can get the job done once, routing and response bodies are difficult to version control, and it is hard for agents to use a unified interface to query “is the Mock running and which paths is it occupying?”

Below is an introduction to the community plugin dsh-plugin-mock-server: it starts a configurable HTTP Mock service locally with routes and response bodies, and allows controlling it via DSH tools using status, start, and stop. It falls under the category “Network Tools”, maintained by thegabopacheco-sudo.

What is it

dsh-plugin-mock-server is a plugin for DeepSeek Harness (DSH) that exposes Mock control capabilities to the current session via MCP. The positioning in the README is: Start a local HTTP mock server (configurable routes and responses) for integration testing, with start/stop and confirmation mechanisms—meaning using configurable routes and responses for integration testing, accompanied by start/stop and confirmation mechanisms.

The plugin is listed on the Skillhub directory; source code can be found in the GitHub repository; the license is MIT. package.json indicates the current package version is 0.1.0, and the runtime environment requires Node.js >= 20.

Core Features

The tools listed in README fall into three categories, with each section corresponding to one thing:

Tool Function
status View Mock service status
start Start Mock
stop Stop Mock

In addition to start/stop and status, the documentation emphasizes that the Mock’s routes and responses are configurable, aimed at local integration verification rather than replacing production gateways.

Installation and Enablement

The DSH ecosystem is organized around “everything is a plugin”; the community directory is maintained by independent sites like Skillhub and has no official affiliation with DeepSeek or Huafan. Before installing, it is recommended to browse the source code and LICENSE on GitHub, and remember: Plugin scripts run with the permissions of the current dsh process.

Two methods consistent with README:

  1. Install github:thegabopacheco-sudo/dsh-plugin-mock-server in DSH → Settings → Plugins and allow script execution as prompted.
  2. Specify profile in the command line to add the plugin:
dsh plugin --profile <perfil> add github:thegabopacheco-sudo/dsh-plugin-mock-server

Replace <perfil> with your actual DSH profile name. The installation process will execute postinstall (see scripts.postinstall in package.json).

Typical Usage

The documentation does not provide an end-to-end example with specific URLs, but a reproducible path is: after installing the plugin, in the session, sequentially call the MCP tools exposed by the plugin: status to confirm if it is running, start when debugging, and stop after finishing. The Mock routes and response bodies should be configured according to the plugin documentation or docs/ inside the repository (listed in the files field of package.json); if you have already written mock definitions in your project, you can let DSH handle “start/stop service” and leave “modifying mock data” in the repository version control.

Security and Suitability

The “Seguridad” (Security) section of the README states:

  • Defaults to read-only; write operations require confirm:true and explicit request.
  • Setting the environment variable DSH_MOCK_SERVER_MODE=read-only can disable write actions.
  • Whitelists and audit logs are located at <DSH_HOME>\cache\mock-server\audit.jsonl (backslashes in the path come from the original README, please use your DSH_HOME as the standard in the actual environment).

Who is it for: Integration developers who need to quickly start/stop local Mocks in Harness conversations without manually typing scripts every time; Not suitable as a permanent API exposed to the public internet or a substitute for production traffic.

Reminder again: Mock listens on local machine HTTP, and permissions are consistent with the dsh process; use only in intranets or local development environments, and perform routine checks on audit files.

Conclusion

dsh-plugin-mock-server brings “local HTTP Mock + configurable routes/responses + start/stop/status” into a DSH plugin, facilitating integration probing in agent workflows. To install or see update notes, you can open the Skillhub directory page and GitHub README.

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

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

Xiaoye