# from-openapi MCP server

> Converts OpenAPI specifications into MCP tool definitions with automatic parameter conflict resolution and built-in HTTP request building.

- Repository: https://github.com/agentfront/mcp-from-openapi
- Page: https://hostedmcp.org/servers/agentfront/mcp-from-openapi
- Transport: stdio
- Stars: 12
- License: Apache-2.0

## Install

### Claude Code

```sh
claude mcp add mcp-from-openapi -- npx -y mcp-from-openapi
```

### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "mcp-from-openapi": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-from-openapi"
      ]
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "mcp-from-openapi": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "mcp-from-openapi"
      ]
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"mcp-from-openapi","type":"stdio","command":"npx","args":["-y","mcp-from-openapi"]}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "mcp-from-openapi": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-from-openapi"
      ]
    }
  }
}
```

### Codex

```sh
codex mcp add mcp-from-openapi -- npx -y mcp-from-openapi
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.mcp-from-openapi]
command = "npx"
args = ["-y", "mcp-from-openapi"]
```

### Gemini CLI

```sh
gemini mcp add -s user mcp-from-openapi npx -- -y mcp-from-openapi
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "mcp-from-openapi": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-from-openapi"
      ]
    }
  }
}
```

## FAQ

### How does the library handle parameter conflicts in OpenAPI specs?

It automatically detects and resolves conflicts where the same parameter name appears in different locations like path, query, or body by renaming them.

### Can I use this with different AI clients like Claude or OpenAI?

Yes, it supports specific client compatibility targets including Claude, OpenAI, and Gemini by emitting schemas each client accepts.

### Does it help with managing token usage for tools?

Yes, it includes context-budget reports that estimate the token cost per tool and warn you when thresholds are reached.

### What authentication methods are supported?

The library provides framework-agnostic support for Bearer, Basic, Digest, API Key, OAuth2, OpenID, mTLS, HMAC, and AWS Sig V4.
