Token导航 LogoToken导航TokenDH.com
开发敏感数据clawhub未标认证来源可访问clear审计提醒

mcp-to-skillMCP TO 技能

Agent Skill

mcp-to-skill 用于辅助前端页面、组件、样式和交互逻辑开发,适合在 OpenClaw 中需要维护前端项目、生成组件或检查界面实现时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

7,075

周安装

289

GitHub Stars

1

下载量

2,266
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:mcp-to-skill(MCP TO 技能)
来源仓库:https://github.com/jalanchao/mcp-to-skill
安装命令:
openclaw skills install mcp-to-skill
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install mcp-to-skill

简介

将任意 MCP 服务器转换为独立技能包,无需依赖外部 MCP 进程运行。

  • 适用于 OpenClaw 中需要将现有 MCP 能力封装为标准技能调用的场景。
  • 转换过程自动生成接口定义和调用示例,兼容主流宿主环境。
  • 需确保源 MCP 配置正确,且宿主支持对应工具格式。
  • 建议测试转换后技能的功能完整性,避免运行时异常。

SKILL.md

name
mcp-to-skill
description
|
Does
connects to MCP server to extract tool schemas, analyzes source code to infer equivalent Bash commands,

mcp-to-skill

Converts an MCP server into a zero-dependency skill package so AI agents can invoke tools directly via Bash commands, without launching an MCP process or injecting all tool definitions upfront.


Step 1: Get MCP information

Determine the input type:

A — User provided a command string / local path / URL: Confirm the command is available, proceed to Step 2.

B — User pasted tool schema JSON: Save the JSON to a temp file, skip Step 2, go directly to Step 3. Use the Write tool to save the pasted JSON to /tmp/mcp-schema-input.json. In Step 3, use --schema-json /tmp/mcp-schema-input.json.

C — User hasn't specified, wants to pick from registered MCPs: List the MCPs currently registered with the agent and let the user choose. In Claude Code: run claude mcp list

Language preference: If the user specifies a language for the generated skill (e.g. "generate in Chinese", "用中文生成"), note it and apply it to all generated files in Step 5. Default is English.


Step 2: Run mcp_inspector.py (only for input type A or C)

Locate mcp_inspector.py: it is in the same directory as this SKILL.md. Determine the absolute path of that directory from the path information provided by the agent framework when loading this skill, then run:

# Ensure mcp SDK is installed
pip show mcp > /dev/null 2>&1 || pip install mcp

python /path/to/skill-dir/mcp_inspector.py "<MCP command>" --output /tmp/mcp-inspector-output.json

Example output:

✓ Written to /tmp/mcp-inspector-output.json: 12 tools, source: /tmp/mcp-to-skill-cache/server-github

Use the Read tool to read /tmp/mcp-inspector-output.json and extract: server_name, source_path (may be null), tools[].


Step 3: AI analysis — infer equivalent commands

Read the inspector output (or the schema file from Step 1B).

If source_path is not null: Use Read / Grep tools to read the source files, locate the implementation for each tool, and extract:

  • HTTP endpoint (URL, method, headers, body structure)
  • or CLI invocation pattern

If source_path is null: Infer reasonable equivalent commands based solely on each tool's description and inputSchema.

Write a command draft for each tool with a confidence marker:

  • [VERIFIED] — confirmed by source code (only when source is available)
  • [INFERRED] — AI-inferred, logically sound but untested (max level when source_path is null)
  • [TODO] — cannot be auto-generated, leave a placeholder with explanation

Step 4: Test read-only commands

For each [INFERRED] command that is a read-only operation (GET request, query), execute it with the Bash tool:

  • Pass → upgrade to [VERIFIED]
  • Fail → keep [INFERRED], add a comment above the command noting the failure reason
  • Write operations (POST/PUT/DELETE, file modifications) — skip testing, keep [INFERRED]
  • [TODO] items — do not test

Step 5: Generate skill package

Create the skill directory in the user's current working directory (or a user-specified path):

<mcp-server-name>/
  SKILL.md
  config.json            # public config (safe to commit)
  secrets.json           # secrets (gitignored, never commit)
  secrets.json.example   # secrets template (safe to commit)
  .gitignore
  helpers/               (create on demand, do not pre-create empty)
    tools-extended.md    (when tool count > 8)
    <tool>.py / <tool>.sh  (when logic cannot fit in a single command)

Progressive disclosure rules:

  • tool count ≤ 8: write all tools into the SKILL.md quick-reference section
  • tool count > 8: SKILL.md lists only the 8 most common tools; the rest go into helpers/tools-extended.md; add a note at the bottom of SKILL.md: "More tools: see helpers/tools-extended.md"

SKILL.md frontmatter template:

---
name: <server-name>
description: |
  [When to use]: <summarize usage scenarios from tool descriptions>
  [Does]: <core capabilities>
  [Does NOT]: <explicitly excluded scenarios>
  [Requires]: <runtime dependencies; write "no runtime dependencies" if none>
---

Config file separation (secret safety):

config.json — public config only, safe to commit:

{
  "endpoint": "<base URL extracted from source, or leave as placeholder>"
}

secrets.json — secrets only, must be gitignored:

{
  "auth_token": "<actual token>"
}

secrets.json.example — secrets template, safe to commit, for onboarding:

{
  "auth_token": "your-api-token-here"
}

.gitignore — contents:

secrets.json

Read order for scripts: secrets.json → environment variable (e.g. X_API_TOKEN). If both are empty, error and prompt user to copy the example file and fill it in.

Important: config.json and secrets.json are read on every tool call (not cached at startup).

Language: Generate all text content in the language specified in Step 1. Default is English.

If skill-creator is loaded in the agent context: Pass the analysis results (tool list + inferred commands + confidence markers) to skill-creator to generate SKILL.md.


Step 6: Register skill with the current AI agent

Goal: register the generated skill directory so it is immediately available. Probe in order and use the first that works:

  1. Check if npx skills is available:
   which npx && npx skills --version 2>/dev/null

If available: npx skills add <skill-path> -g -y

  1. Check if running in Claude Code:
   claude --version 2>/dev/null

If available: symlink to ~/.claude/skills/<skill-name>:

   ln -sf <skill-path> ~/.claude/skills/<skill-name>

Note: /add-dir is an interactive slash command and cannot be called via Bash.

  1. If neither applies: output the skill path and tell the user how to register manually:

> "Skill generated at <path>. Please register it with your AI agent. > Claude Code users: run /add-dir <path> > npx skills users: run npx skills add <path> -g"


Step 7: Ask about removing the original MCP (optional)

Only prompt when Step 1 was type A or C (not pasted schema):

"MCP <server-name> has been converted to a skill. Would you like to remove the MCP configuration from your AI agent?"
  • User confirms → assist with removal (agent decides how)
  • User declines or no response → skip, skill and MCP can coexist

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

87.66%
按下载量换算1,986

安全审计

VirusTotal

可疑

ClawScan

可疑

Static analysis

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills