Hourunze1997

oed-mcp

Community Hourunze1997
Updated

openEuler Infra gateway (oed CLI) as local MCP tools: CVE security notices, packages, forum, SIG docs, mailman, search, repos, issues.

oed-mcp

openEuler Infra gateway as local MCP tools.

A zero-dependency MCP server (stdio) thatexposes the oed CLI — openEuler'sunified CLI for every community online service — to any local MCP client:Claude Code, Cursor, Trae, Cline, Codex CLI, Gemini CLI, and friends.

Same three tools and the same model-facing contracts asdsh-plugin-oed, in thetransport-agnostic envelope.

Quickstart

One prerequisite: Node ≥ 18. That's all — the server fetches the oedCLI by itself on first use (via uvx, or a one-shot pip install --user),or uses it from PATH if you already have it.

Claude Code

claude mcp add oed -- npx -y oed-mcp

Cursor / Trae / Cline — put this in the client's mcp.json(Cursor: ~/.cursor/mcp.json; Trae: ~/.trae/mcp.json intl /~/.trae-cn/mcp.json CN):

{
  "mcpServers": {
    "oed": { "command": "npx", "args": ["-y", "oed-mcp"] }
  }
}

Cursor CLI from scratch

curl https://cursor.com/install -fsS | bash   # install the CLI
cursor-agent login                            # one-time browser auth
# then write ~/.cursor/mcp.json as above

dsh

dsh plugin add oed-mcp

Gemini CLI / Qwen Code — this repo ships gemini-extension.json /qwen-extension.json:

gemini extensions install Hourunze1997/oed-mcp   # or: qwen extensions install ...

Claude Code plugin — this repo is also a plugin marketplace (bundles theoed-cli Agent Skill + the MCP server):

/plugin marketplace add Hourunze1997/oed-mcp
/plugin install oed@oed-marketplace

Verify — ask your client:

查一下 CVE-2019-10082 在 openEuler 的安全公告编号和严重程度

Expect it to call oed_describe → oed_call and answeropenEuler-SA-2020-1002 / Medium.

Everything above works anonymously (CVE, packages, forum, mailman, search).Only AtomGit (ag) operations need oed ag login once — the token is storedin the OS keyring.

Manual setup

Any client with a raw command — the server is a plain stdio process:

oed-mcp          # JSON-RPC 2.0, one message per line, on stdin/stdout

dsh, hand-wired — equivalent to dsh plugin add, if you'd rather edit thepatch yourself (a new Cordis entry must use - insert: — top-level patchentries only override existing ones):

- insert:
    - id: mcp-oed
      name: '@deepseek-ai/dsh-mcp-client'
      config:
        serverName: oed
        transport: stdio
        command: npx
        args: ['-y', 'oed-mcp']

Tools

Tool Purpose
oed_services List every discovered openEuler service (name, base_url, description).
oed_describe Per-service operation list, or per-operation flag cheatsheet (--flags, required markers, body_schema for POST/PUT/PATCH).
oed_call Invoke one operation: params = query/path params object, body = JSON request body (top-level fields from body_schema), dry_run = preview without network.

Notes baked into the tool descriptions so the model can't trip on them: forumApi-Key/Api-Username are gateway-managed (never pass them), ag (AtomGit)calls need oed ag login once, and body fields only ever go in body.

Bootstrap behavior

Runner resolution order: oed on PATH → uvx --from oed-cli oed (ephemeralvenv, nothing system-wide changes) → one-shot pip install --user oed-cli.Runner successes are cached; failures are not — install oed mid-session andthe next call just works. Set OED_MCP_AUTO_INSTALL=0 to disable allautomatic installation and get an actionable error instead.

Auth model

This server is local by design: it runs on your machine, so authenticationuses your own oed credentials (oed ag login → OS keyring). Most gatewayendpoints (CVE, packages, forum reads, mailman, search, SIG docs) areanonymous; only ag operations need the login. Cloud/remote MCP deploymentsare out of scope here on purpose.

Layout

One file, zero npm dependencies: index.js speaks newline-delimitedJSON-RPC 2.0 over stdio (the MCP stdio transport), forwards every tool call tothe resolved oed runner — oed's JSON stdout goes to the model verbatim, itsfixed exit codes (0 ok / 1 user error / 2 network / 3 upstream / 4 not found)surface as isError tool results. A dsh bundle patch (cordis.patch.yml)makes the same package installable with dsh plugin add.

MCP Server · Populars

MCP Server · New