mcpify
Turns any OpenAPI specification into a fully working MCP server with a single command, enabling AI agents to call APIs without writing any glue code.
README
<div align="center">
mcpify
Turn any API into an MCP server. One command. No code.
</div>
npm install -g https://github.com/qualuo/mcpify/releases/latest/download/mcpify.tgz
mcpify https://petstore3.swagger.io/api/v3/openapi.json
✓ mcpify: Petstore v1.0.0 — 19 tools
base: https://petstore3.swagger.io/api/v3
transport: stdio
That's it. Your AI agent now has access to the entire Petstore API. No SDK to install. No glue code to write. No server to deploy.
Point it at any OpenAPI spec → get a fully working MCP server.
Why
Every team building agents hits the same wall: the model needs to call APIs, and wiring up each one means days of bespoke MCP server code, schema translation, and auth plumbing.
mcpify collapses that to one command. The OpenAPI spec already describes everything — endpoints, parameters, schemas, auth. We turn it into an MCP server at runtime, no codegen step, no source files to maintain.
Install
From the latest GitHub release:
npm install -g https://github.com/qualuo/mcpify/releases/latest/download/mcpify.tgz
Then run from anywhere:
mcpify <spec>
Requires Node.js 18+.
Update: re-run the install command above to pull the latest release.
Why a tarball URL?
npm install -g github:user/repois broken on Windows (creates dangling junctions to deleted temp dirs). The release tarball works reliably on every platform. An npm release will land once we've gathered some real-world usage feedback.
Use
From a hosted spec
mcpify https://api.example.com/openapi.json
From a local file (JSON or YAML)
mcpify ./spec.yaml
From a single curl command
mcpify --curl "curl -H 'Authorization: Bearer xxx' https://api.github.com/user/repos"
Generates a one-tool MCP server from any curl command. Body is parsed and turned into an input schema.
List tools without serving
mcpify list ./spec.json
Generate a standalone, hand-editable project
mcpify generate ./spec.json ./my-mcp
cd my-mcp && npm install && npm start
Use this when you want to fork the behavior — add caching, custom auth flows, post-processing, anything.
Auth
Set environment variables before launching. mcpify reads the spec's securitySchemes and matches them automatically.
# HTTP bearer schemes
export MCPIFY_BEARER_TOKEN=xxx
# apiKey schemes (header or query, as the spec says)
export MCPIFY_API_KEY=xxx
# HTTP basic
export MCPIFY_BASIC_AUTH=user:password
# Per-scheme override (use the scheme's name from the spec)
export MCPIFY_AUTH_<SCHEME_NAME>=xxx
# Free-form extra headers on every request
export MCPIFY_HEADERS='{"X-Trace-Id":"abc","X-Internal":"1"}'
Filter big specs
Stripe's full OpenAPI is ~600 endpoints. Most agents do not need all of them, and most clients won't tolerate that many tools. Trim:
# Only the customers tag
mcpify ./stripe.json --tag customers
# Only operations whose tool name matches a regex
mcpify ./stripe.json --filter "^createCustomer|^getCustomer"
# Hard cap
mcpify ./stripe.json --max-tools 30
Use with Claude Desktop
~/.config/claude/claude_desktop_config.json (Linux/macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
After running npm install -g github:qualuo/mcpify once, the mcpify binary is available on your PATH:
{
"mcpServers": {
"petstore": {
"command": "mcpify",
"args": ["https://petstore3.swagger.io/api/v3/openapi.json"]
},
"github": {
"command": "mcpify",
"args": ["--curl",
"curl -H 'Authorization: Bearer ghp_xxx' https://api.github.com/user/repos"]
}
}
}
Use with Cursor / Cline / Claude Code
Same idea — anywhere you can configure an MCP server with a command and args, this works. mcpify speaks stdio.
# Claude Code:
claude mcp add petstore -- mcpify https://petstore3.swagger.io/api/v3/openapi.json
Programmatic API
import { loadOpenApiSpec, parseOpenApi, serve } from "mcpify";
const raw = await loadOpenApiSpec("./spec.yaml");
const spec = parseOpenApi(raw);
await serve(spec, {
baseUrl: "https://staging.example.com",
filterTag: "users",
});
How it works
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ OpenAPI spec │ ─→ │ mcpify runtime │ ─→ │ MCP client │
│ (JSON / YAML) │ │ (stdio server) │ │ (Claude/Cursor) │
└─────────────────┘ └─────────────────┘ └─────────────────┘
│
↓ tool call
┌─────────┐
│ fetch │ → your API
└─────────┘
- Dereference the spec (resolve
$refs). - Convert each operation into an MCP tool: path/query/header params become input properties; the request body becomes a nested
bodyproperty. - On a tool call, build the URL, attach auth from env, send the request, return the response.
No codegen. No restart loop. The spec is the source of truth.
Limitations
- Streaming response bodies — currently buffered, capped at 64KB.
- OAuth2 flows — not run automatically; supply a pre-fetched token via
MCPIFY_BEARER_TOKEN. - File uploads (
multipart/form-data) — not yet supported. - Webhooks / callbacks — out of scope.
- Swagger 2.0 — partial; convert to OpenAPI 3 first for best results.
PRs welcome on all of the above.
Development
git clone https://github.com/qualuo/mcpify
cd mcpify
npm install
npm run build
npm test
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.