MCP Catalogs
Home

openapi2mcptools

by 2013xile·19·Score 34

Converts OpenAPI specifications to MCP tools for faster MCP server development.

developer-toolsai-llm
7
Forks
2
Open issues
18 mo ago
Last commit
2d ago
Indexed

Overview

openapi2mcptools is a TypeScript utility library that facilitates the conversion of OpenAPI specifications into MCP (Model Context Protocol) tools. It provides a straightforward Converter class that can load OpenAPI specifications and automatically generate a list of tools along with a tool caller. This library significantly reduces the development time required to create MCP servers based on existing REST API definitions, making it easier for developers to expose their APIs through the MCP protocol.

Try asking AI

After installing, here are 5 things you can ask your AI assistant:

you:Rapidly create MCP servers from existing REST API documentation
you:Enable AI models to interact with web APIs through the MCP protocol
you:Convert complex API specifications into tool formats accessible to AI assistants
you:What OpenAPI versions are supported?
you:Can I customize the tool names and descriptions?

When to choose this

Choose this tool when you need to quickly convert existing REST API documentation into MCP tools without implementing the protocol details manually.

When NOT to choose this

Avoid this if you need advanced API features like webhooks, complex authentication flows, or real-time streaming endpoints that go beyond standard REST API patterns.

Comparable tools

api2mcprest-mcpopenapi-to-mcpmcp-rest-server

Installation

npm install openapi2mcptools

For Claude Desktop integration, add to your claude_desktop_config.json:

{
  "mcpServers": {
    "openapi2mcptools": {
      "command": "node",
      "args": ["path/to/your/script.js"]
    }
  }
}

Where your script.js uses the example code from the README to create an MCP server from your OpenAPI specs.

FAQ

What OpenAPI versions are supported?
The library supports OpenAPI 3.0 and 3.1 specifications, but may have limitations with complex features.
Can I customize the tool names and descriptions?
The README doesn't explicitly show customization options, but the Converter class likely provides configuration methods to modify tool metadata.

Compare openapi2mcptools with

GitHub →

Last updated · Auto-generated from public README + GitHub signals.