MCP OpenAPI Connector is an MCP server that integrates any REST API defined by an OpenAPI or Swagger specification directly into AI interfaces. It connects client applications to authenticated web APIs through a single-process architecture, eliminating the requirement for external proxy servers. Built for developers, software engineers, and technical teams using assistants like Claude Desktop or Cursor, this server parses an OpenAPI JSON specification file to dynamically create executable Model Context Protocol tools. In addition to handling dynamic tool generation from API operations, it manages OAuth2 authentication cycles by automatically requesting tokens, caching them, and handling token refreshes on request failures. Users can filter operations using inclusion or exclusion lists, prefix generated tool names, and register custom JavaScript tools for tailored interactions. This setup enables AI agents to query remote resources, submit structured payloads, and orchestrate backend workflows across third-party web services within conversational interfaces.
Category: Developer Tools & Code Intelligence
Tags: authentication, oauth2, openapi, rest, swagger
@ssossan/mcp-openapi-connector. 2. Obtain an OpenAPI specification file in JSON format and place it on your system. 3. Add the server entry to your Claude Desktop configuration file (claude_desktop_config.json) under the mcpServers object: json { "mcpServers": { "openapi-connector": { "command": "npx", "args": ["@ssossan/mcp-openapi-connector"], "env": { "CLIENT_ID": "your-client-id", "CLIENT_SECRET": "your-client-secret", "API_BASE_URL": "https://api.example.com", "AUTH_PATH": "/oauth/token", "OPENAPI_SPEC_PATH": "/path/to/openapi.json" } } } } 4. Alternatively, configure optional environment variables such as OPENAPI_TOOL_PREFIX, OPENAPI_INCLUDE_ONLY, or OPENAPI_EXCLUDE to limit endpoints. 5. Restart Claude Desktop to begin using the generated tools.Part of MCP Servers
You can install it globally via npm with the command npm install -g @ssossan/mcp-openapi-connector, or run it directly using npx @ssossan/mcp-openapi-connector. You can also clone the repository from GitHub, install dependencies with npm install, and build the source.
MCP OpenAPI Connector reads an OpenAPI or Swagger JSON specification file and translates the documented operations into executable MCP tools. It also handles OAuth2 authentication, automatically acquiring and refreshing access tokens so AI clients can call authenticated APIs directly without an external proxy.
The server works with any client supporting the Model Context Protocol stdio transport. The project includes explicit configuration instructions and interactive setup wizards tailored for Claude Desktop and Cursor.
Yes, MCP OpenAPI Connector is open-source software licensed under the MIT License, and the source code is hosted on GitHub.