Skip to main content
Glama

mcpify

Verwandeln Sie jede API in einen MCP-Server. Ein Befehl. Kein Code.

npm License: MIT CI

npx 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

Das ist alles. Ihr KI-Agent hat jetzt Zugriff auf die gesamte Petstore-API. Kein SDK zu installieren. Kein Klebecode zu schreiben. Kein Server bereitzustellen.

Zeigen Sie auf eine beliebige OpenAPI-Spezifikation → erhalten Sie einen voll funktionsfähigen MCP-Server.


Warum

Jedes Team, das Agenten baut, stößt auf dasselbe Problem: Das Modell muss APIs aufrufen, und die Anbindung jeder einzelnen bedeutet tagelange Arbeit für maßgeschneiderten MCP-Server-Code, Schema-Übersetzung und Authentifizierungs-Infrastruktur.

mcpify reduziert das auf einen einzigen Befehl. Die OpenAPI-Spezifikation beschreibt bereits alles – Endpunkte, Parameter, Schemas, Authentifizierung. Wir verwandeln sie zur Laufzeit in einen MCP-Server, ohne Codegenerierungsschritt, ohne zu pflegende Quelldateien.

Related MCP server: mcpify

Installation

Verwenden Sie es bei Bedarf mit npx (empfohlen):

npx mcpify <spec>

Oder installieren Sie es global:

npm install -g mcpify

Erfordert Node.js 18+.

Verwendung

Von einer gehosteten Spezifikation

npx mcpify https://api.example.com/openapi.json

Von einer lokalen Datei (JSON oder YAML)

npx mcpify ./spec.yaml

Von einem einzelnen curl-Befehl

npx mcpify --curl "curl -H 'Authorization: Bearer xxx' https://api.github.com/user/repos"

Generiert einen MCP-Server mit einem Tool aus jedem beliebigen curl-Befehl. Der Body wird geparst und in ein Eingabeschema umgewandelt.

Tools auflisten, ohne sie bereitzustellen

npx mcpify list ./spec.json

Ein eigenständiges, manuell bearbeitbares Projekt generieren

npx mcpify generate ./spec.json ./my-mcp
cd my-mcp && npm install && npm start

Verwenden Sie dies, wenn Sie das Verhalten anpassen möchten – fügen Sie Caching, benutzerdefinierte Authentifizierungsabläufe, Nachbearbeitung oder Ähnliches hinzu.

Authentifizierung

Setzen Sie Umgebungsvariablen vor dem Start. mcpify liest die securitySchemes der Spezifikation und gleicht sie automatisch ab.

# 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"}'

Große Spezifikationen filtern

Stripes vollständige OpenAPI umfasst etwa 600 Endpunkte. Die meisten Agenten benötigen nicht alle, und die meisten Clients vertragen nicht so viele Tools. Kürzen Sie sie:

# Only the customers tag
npx mcpify ./stripe.json --tag customers

# Only operations whose tool name matches a regex
npx mcpify ./stripe.json --filter "^createCustomer|^getCustomer"

# Hard cap
npx mcpify ./stripe.json --max-tools 30

Verwendung mit Claude Desktop

~/.config/claude/claude_desktop_config.json (Linux/macOS) oder %APPDATA%\Claude\claude_desktop_config.json (Windows):

{
  "mcpServers": {
    "petstore": {
      "command": "npx",
      "args": ["-y", "mcpify", "https://petstore3.swagger.io/api/v3/openapi.json"]
    },
    "github": {
      "command": "npx",
      "args": ["-y", "mcpify", "--curl",
        "curl -H 'Authorization: Bearer ghp_xxx' https://api.github.com/user/repos"]
    }
  }
}

Verwendung mit Cursor / Cline / Claude Code

Das gleiche Prinzip – überall dort, wo Sie einen MCP-Server mit einem command und args konfigurieren können, funktioniert dies. mcpify spricht stdio.

# Claude Code:
claude mcp add petstore -- npx -y mcpify https://petstore3.swagger.io/api/v3/openapi.json

Programmatische 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",
});

Funktionsweise

┌─────────────────┐    ┌─────────────────┐    ┌─────────────────┐
│   OpenAPI spec  │ ─→ │ mcpify  runtime │ ─→ │   MCP client    │
│  (JSON / YAML)  │    │  (stdio server) │    │ (Claude/Cursor) │
└─────────────────┘    └─────────────────┘    └─────────────────┘
                            │
                            ↓ tool call
                       ┌─────────┐
                       │  fetch  │ → your API
                       └─────────┘
  1. Dereferenzierung der Spezifikation (Auflösung von $refs).

  2. Konvertierung jeder Operation in ein MCP-Tool: Pfad-/Abfrage-/Header-Parameter werden zu Eingabeeigenschaften; der Request-Body wird zu einer verschachtelten body-Eigenschaft.

  3. Bei einem Tool-Aufruf wird die URL erstellt, die Authentifizierung aus der Umgebung angehängt, die Anfrage gesendet und die Antwort zurückgegeben.

Keine Codegenerierung. Keine Neustart-Schleife. Die Spezifikation ist die Quelle der Wahrheit.

Einschränkungen

  • Streaming-Antwort-Bodies – derzeit gepuffert, auf 64 KB begrenzt.

  • OAuth2-Abläufe – werden nicht automatisch ausgeführt; stellen Sie ein vorab abgerufenen Token über MCPIFY_BEARER_TOKEN bereit.

  • Datei-Uploads (multipart/form-data) – noch nicht unterstützt.

  • Webhooks / Callbacks – außerhalb des Geltungsbereichs.

  • Swagger 2.0 – teilweise; für beste Ergebnisse zuerst in OpenAPI 3 konvertieren.

PRs für all das Obige sind willkommen.

Entwicklung

git clone https://github.com/qualuo/mcpify
cd mcpify
npm install
npm run build
npm test

Lizenz

MIT

A
license - permissive license
Not graded
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
1Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    Automatically converts Swagger/OpenAPI specifications into MCP servers, enabling AI agents to interact with any REST API through natural language by exposing endpoints as AI-friendly tools.
    3
  • A
    license
    Not graded
    quality
    B
    maintenance
    Converts any OpenAPI specification into an MCP server, allowing AI assistants to interact with REST APIs through natural language.
    9
    1
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Turns any OpenAPI REST or GraphQL API into an MCP server, allowing AI assistants like Claude to interact with APIs without writing code.
    18
    MIT

View all related MCP servers

Related MCP Connectors

  • Self-hosted MCP gateway: turn any API, database or MCP server into AI connectors — no code.

  • MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.

  • MCP server for secureFlows: token-free URL builders and integration-linting tools for AI agents.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/qualuo/mcpify'

If you have feedback or need assistance with the MCP directory API, please join our Discord server