mcp-skill-bridge
v0.0.1
Published
`mcp-skill-bridge` is an HTTP MCP server that turns a local skills directory into MCP-readable context for agents that can only attach MCP servers.
Downloads
12
Readme
mcp-skill-bridge
mcp-skill-bridge is an HTTP MCP server that turns a local skills directory into MCP-readable context for agents that can only attach MCP servers.
Instead of requiring a client to understand a custom skill system, this server exposes skill discovery as MCP resources and keeps skill detail lookup plus shell execution as MCP tools. That lets an agent discover available skills, fetch a skill's SKILL.md, and then execute local commands when the skill instructs it to do so.
Why This Exists
Many agent products support adding MCP servers, but do not support a native "skills" mechanism.
This server bridges that gap:
- A local
SKILLS_DIRbecomes MCP-readable discovery data. - Each skill remains a normal folder on disk.
- The agent can discover skills and fetch skill docs over MCP without needing direct filesystem integration.
- The agent can still run local commands through the
shelltool when the skill requires scripts or terminal steps.
This is especially useful when a skill folder contains:
SKILL.md- helper scripts under
scripts/ - reference files, templates, or examples next to the skill document
When a skill document is read, the server appends a final note telling the model which local directory that skill lives in, so mentions of sibling scripts and files are grounded to an actual path.
Capabilities
Resources
skills://root- Returns the configured
SKILLS_DIRabsolute path.
- Returns the configured
skills://index- Returns all valid skills discovered under
SKILLS_DIR. - Scans subdirectories recursively for
SKILL.mdfiles, case-insensitive. - Reads YAML frontmatter and extracts:
namedescription- optional
metadata
- Returns all valid skills discovered under
Tool
get_skill_detail- Returns the full
SKILL.mdfor a single skill. - Input: skill directory name.
- The response appends an extra English note like:
Note: The current skill directory is ...
- Returns the full
shell- Runs a shell command in a child process.
- Inherits the current process environment variables.
- Supports timeout control.
- Returns:
return_codestdoutstderrtimeout
Skill Discovery Rules
The server treats a folder as a valid skill only when all of the following are true:
- The folder contains a file named
SKILL.md, case-insensitive. - The file starts with YAML frontmatter.
- Frontmatter contains non-empty string fields:
namedescription
Invalid skill folders are skipped and do not break the whole index.
Project Stack
- Node.js
- TypeScript
- Hono
- Official MCP TypeScript SDK
The server uses Streamable HTTP MCP transport over /mcp.
Getting Started
1. Install dependencies
npm install2. Set SKILLS_DIR
$env:SKILLS_DIR = "C:\path\to\skills"SKILLS_DIR must point to an existing directory.
3. Build
npm run build4. Start
npm startOr run the published package directly:
npx -y mcp-skill-bridgeBy default, the server listens on:
- Host:
127.0.0.1 - Port:
5151
Endpoints:
- MCP endpoint:
http://127.0.0.1:5151/mcp - Health check:
http://127.0.0.1:5151/healthz
Environment Variables
SKILLS_DIR- Required.
- Root directory containing skills.
HOST- Optional.
- Default:
127.0.0.1
PORT- Optional.
- Default:
5151
LOG_LEVEL- Optional.
- Default:
info
Example:
$env:SKILLS_DIR = "C:\Users\me\skills"
$env:HOST = "127.0.0.1"
$env:PORT = "5151"
$env:LOG_LEVEL = "debug"
npx -y mcp-skill-bridgeExample Skill Layout
skills/
my-skill/
SKILL.md
scripts/
setup.ps1
references/
example.txtExample SKILL.md frontmatter:
---
name: My Skill
description: Explains how to run a local workflow
metadata:
category: automation
---
Use `scripts/setup.ps1` to prepare the environment.When the agent calls get_skill_detail for my-skill, the server returns the document plus a final note indicating that the skill directory is:
.../skills/my-skill/How A Client Typically Uses It
- Connect to the MCP endpoint.
- List resources.
- Read
skills://indexto discover available skills. - Call
get_skill_detailfor the skill you want to apply. - Call
shellif the skill asks for terminal commands or local scripts.
Development
Build:
npm run buildRun tests:
npm testType-check only:
npx tsc --noEmitNotes
npm startruns compiled output fromdist/, not source files directly.- Published builds can be started with
npx -y mcp-skill-bridge. - After changing source code, rebuild before starting again.
shellis intentionally separate from resources because it performs execution, not data retrieval.
