Degurechaff57/dsh-openapi
DeepSeek Harness 的安全 OpenAPI 3.x 发现与 API 调用工具
Project Overview项目介绍
dsh-openapi is a native plugin built exclusively for DeepSeek Harness (DSH), packaged with a DSH bundle manifest to work natively within the DSH ecosystem. It is designed to give DSH agents a safe, structured interface for accessing any OpenAPI 3.x compliant API, adding three model-facing tools to DSH. The tools are openapi_list for discovering configured APIs and searching for specific operations, openapi_describe for fetching detailed parameters, request bodies, server information, and response schemas for a selected operation, and openapi_call for validating and invoking the selected operation with bounded output. To install the plugin, users run the command dsh plugin --profile web add github:Degurechaff57/dsh-openapi in their terminal, and since it is written in plain ESM JavaScript, no build or prepare script is required after installation.
This plugin is targeted at developers who want to let DSH agents interact with external APIs securely without compromising context window efficiency. While DSH already provides agents with shell access to external tools, calling APIs directly requires loading entire large OpenAPI specifications into the model context, which wastes valuable context space and introduces unnecessary security risks. This plugin adds necessary security controls without modifying the core DSH agent loop. After installation, users pre-configure their desired APIs in the cordis.patch.yml profile file, specifying the source of the OpenAPI spec, base URL, allowed HTTP methods, and credential mappings for authentication.
dsh-openapi is released under the permissive MIT open source license, and currently supports OpenAPI 3.0 and 3.1 specifications in both JSON and YAML formats. It supports local #/... references within a single spec, but intentionally does not yet support remote $ref documents or specialized serialization formats like deepObject, failing loudly instead of making ambiguous, incorrect requests. It ships with strict security defaults: APIs start as read-only with only GET and HEAD enabled, private network access is blocked by default, response sizes are capped, and credentials are pulled from environment variables instead of config files and never exposed to the model. The current release is tested against DSH CLI 0.1.0-rc.5 and npm prerelease 0.1.0-rc.6, with compatibility updates planned for upstream breaking changes.
dsh-openapi 是专为 DeepSeek Harness(DSH)开发的原生插件,用于为 DSH 智能体提供安全、结构化的 OpenAPI 3.x API 访问入口。它为模型提供了三个专用工具:openapi_list 用于发现 API 和搜索操作,openapi_describe 用于获取单个操作的详细参数和定义,openapi_call 用于验证并调用目标操作。该插件采用纯 ESM JavaScript 编写,安装后无需执行构建或 prepare 脚本,可通过 dsh 命令直接从 GitHub 安装。
该插件主要面向需要让 DSH 智能体安全访问外部开放 API 的开发者,解决了直接将完整 OpenAPI 文档载入模型上下文的效率问题,同时增加了多项安全控制。安装完成后,用户需要在个人配置文件 cordis.patch.yml 中预先添加需要访问的 API 条目,指定 API 文档源、基础地址、允许调用的方法等信息。使用时,智能体可通过列表工具发现操作、描述工具获取参数、调用工具发起请求,完成整个 API 访问流程。
该插件采用 MIT 许可证开源,目前支持 OpenAPI 3.0 和 3.1 版本的 JSON 和 YAML 格式文档,支持本地引用,暂不支持远程引用文档和特殊序列化格式。插件内置多项安全默认设置,默认仅允许 GET 和 HEAD 方法,禁止访问私有网络,限制响应大小,凭证从环境变量读取不会泄露。当前版本适配 DSH 0.1.0-rc.5 源码 CLI 和 0.1.0-rc.6 npm 预发布版,后续会跟进上游更新。
请帮我安装这个 DSH 插件。安装前先完成【兼容性检查 + 安全性检查】,检查通过再动手。
插件:dsh-openapi(Degurechaff57/dsh-openapi)
仓库:https://github.com/Degurechaff57/dsh-openapi
本站详情页:https://www.yhbd.top/plugins/degurechaff57-dsh-openapi/
本站登记:类型 plugin · 归类 原生 DSH 插件 · 许可证 MIT · ⭐ 3 · 最近提交 2026-08-13 · 主语言 JavaScript
按下面顺序执行,每步先把结论告诉我,再进入下一步:
【1 兼容性检查】
① 我这边:DSH 版本、Node 版本、操作系统、当前 profile(web / desktop)。
② 读它的 README、package.json、插件 manifest,列出它要求的 DSH 版本 / Node 版本 / 操作系统 / 外部依赖 / 需要另外先装的运行时。
③ 逐条比对,结论只写「满足 / 不满足 / 未知」三种;不满足的给出可行替代方案。
④ 检查是否和我已装的插件冲突:命令名重复、skill / tool 重名、端口占用、重复注册的 MCP server。
【2 安全性检查】
① 仓库可信度:和上面「本站登记」是否一致;star / fork 数、创建时间、最近提交,是否归档或长期停更。
② 安装脚本:逐行看 package.json 的 preinstall / install / postinstall,以及 install.sh、setup.ps1 之类脚本。出现 curl|bash、下载后直接执行、混淆代码、访问与插件功能无关的域名,立刻停下来告诉我,不要继续装。
③ 依赖:列出新增依赖,标出无人维护、或与知名包拼写近似的可疑包(typosquatting)。
④ 权限与副作用:它会读写哪些目录、访问哪些域名、需要哪些 DSH 权限(filesystem / network / shell / clipboard 等),以及怎么卸载和回滚。
⑤ 如果它要求 sudo / 管理员权限,或权限明显超出功能所需,先停下来问我。
【3 安装】
上面两步没有「不满足」和「高危项」时才执行;用官方推荐方式安装,不要自行提权。
【4 汇报】
用表格输出:检查项 / 结论 / 依据 / 是否需要我决策。拿不准的一律写「未知」并说明要我怎么确认——不要猜,也不要替我决定。
Send this message to DSH in your current session: it verifies compatibility and security first (answering met / not met / unknown item by item) and only installs once everything checks out — it will stop and ask you if it finds a high-risk item. The box scrolls; the copy is the full prompt. CLI install commands may not be accurate across systems, so DSH is the safer route.把上面这条消息直接发给当前会话里的 DSH:它会先核对兼容性与安全性(逐条给「满足 / 不满足 / 未知」),确认没问题再安装,有高危项会停下来问你。框内可滚动,复制到的是完整提示词;安装命令不一定准确,发给 DSH 更稳。
- Only 3 stars - very few users, little community feedback星标只有 3,几乎没人在用,遇到问题缺少社区反馈
DSH walks through these 9 checksDSH 会逐条核对这 9 项
Compatibility兼容性
- DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
- External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
- Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册
Security安全性
- Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
- Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
- curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
- Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
- Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
- Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式
Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。
Or use CLI install (for developers)或使用命令行安装(适合开发者)
CLI Install命令行安装
dsh plugin --profile web add github:Degurechaff57/dsh-openapi
把 Degurechaff57/dsh-openapi 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-openapi
Give DeepSeek Harness a safe, structured doorway into any OpenAPI 3.x API.
dsh-openapi is a native DeepSeek Harness bundle that indexes configured OpenAPI documents and adds three model-facing tools:
openapi_listdiscovers APIs and searches operations.openapi_describereturns parameters, request bodies, servers, and responses for one operation.openapi_callvalidates and invokes an operation with bounded output.
It is plain ESM JavaScript, so installing from GitHub does not run a build or prepare script.
Why this plugin
Harness already gives an agent a shell. APIs still benefit from a narrower interface: operation discovery without reading a huge spec into the model context, declared-parameter validation, environment-backed credentials, read-only defaults, SSRF checks, and response limits. This plugin provides those controls without patching the Harness agent loop.
Install
dsh plugin --profile web add github:Degurechaff57/dsh-openapi
The bundle installs with an empty API catalog. Add API entries to your profile's cordis.patch.yml:
- id: openapi
config:
apis:
- id: petstore
source: https://petstore3.swagger.io/api/v3/openapi.json
baseUrl: https://petstore3.swagger.io/api/v3
allowedMethods: [GET, HEAD]
Start Harness and ask:
Use
openapi_listto find the operation that lists pets, describe it, then call it.
For a source checkout, install the local directory instead:
dsh plugin --profile web add /absolute/path/to/dsh-openapi
Credentials
Keep secrets out of YAML. Map a request header to an environment variable:
- id: openapi
config:
apis:
- id: internal-api
source: ./openapi/internal.yml
baseUrl: https://api.example.com/v1
headers:
Accept: application/json
credentials:
- header: Authorization
env: INTERNAL_API_TOKEN
prefix: 'Bearer '
allowedMethods: [GET, HEAD, POST]
The credential header is applied after model-supplied header parameters, so a tool call cannot override it. Missing environment variables fail the call before network I/O.
Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →
toby-bridges/api-relay-audit
lxzy-7/dsh-plugin-guard
huangziyuan-general/dsh-novel-forge
omdsh-dev/dsh-security-audit
hccccc01333/dsh-excel-chat
EL4CTEO/roblox-devforum-mcp