mcpo
A simple, secure MCP-to-OpenAPI proxy server
What it is and what it does
mcpo is a proxy server that translates MCP (Model Context Protocol) servers—which typically communicate over stdio—into standard HTTP/OpenAPI endpoints. This solves a fundamental compatibility gap: MCP servers are inherently insecure and incompatible with tools expecting REST APIs, but mcpo bridges that gap by wrapping any MCP server command and exposing its tools via FastAPI with auto-generated interactive documentation, authentication, and standard HTTP semantics.
You run mcpo with an MCP server command (or point it to an SSE or HTTP-based MCP endpoint), and it immediately serves an OpenAPI schema at `/docs` and proxy routes for each tool. It supports single servers via command-line flags, multiple servers via a Claude Desktop–compatible config file with hot-reload, and OAuth 2.1 for protected endpoints. The proxy adds security (API keys, auth), stability (HTTP error handling), and interoperability (any OpenAPI client can now call your MCP tools) without requiring custom glue code.
Use it for:
- Integrate MCP tools (like mcp-server-time) with LLM agents or applications that only understand OpenAPI, enabling tool use without protocol translation.
- Expose a suite of MCP servers behind a single HTTP gateway with per-tool routing and authentication, suitable for multi-tenant or shared environments.
- Serve MCP tools behind a reverse proxy or subpath in production using `--root-path`, with hot-reload config for zero-downtime updates.
- Provide interactive API documentation and testing UI for MCP tools via the auto-generated `/docs` endpoint, improving discoverability and debugging.
- Secure stdio-based MCP servers by wrapping them in an authenticated HTTP layer with API keys or OAuth 2.1, preventing unauthorized access.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Exposes MCP (Model Context Protocol) servers as OpenAPI-compatible HTTP endpoints, making them accessible to standard REST clients and LLM agents without custom protocol handling.
Yes. mcpo solves a real interoperability problem (MCP servers are stdio-only, most tools expect OpenAPI) with low install friction, active maintenance, and no known vulnerabilities. The license treatment is unclear, so verify the actual license before use. For any workflow where you need to expose MCP tools to REST clients or LLM agents, this is the right tool.
Install
mcpo on PyPI
pip
pip install mcpouv
uv add mcpopoetry
poetry add mcpoInstalling mcpo
Before you install
Low friction: pure Python wheel with no compiled dependencies. Active maintenance (latest release 2026-02-27). Depends on well-established libraries (FastAPI, Uvicorn, Pydantic, Click, Typer) with no known security issues.
License in practice
License treatment is unclear—no SPDX identifier or raw license text provided in metadata. Verify the actual license (description mentions MIT) before use in proprietary or restricted contexts.
Quickstart
pip install mcpo
mcpo --port 8000 --api-key "secret" -- your_mcp_server_command
# Access OpenAPI docs at http://localhost:8000/docs
Requires Python 3.11 or later.
Verify before relying
- License metadata shows 'unclear' treatment despite description claiming MIT—confirm actual license terms before deployment.
- No documented security audit or threat model for the proxy layer itself; verify authentication and token handling for production use.
- OAuth 2.1 support mentioned in description but not reflected in runtime dependencies—confirm implementation completeness.
Package facts
| License | not declared (unclear) |
| Python support | supports the current Python release (>=3.11) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 10 — click, fastapi, mcp, passlib, pydantic, pyjwt, python-dotenv, typer, uvicorn, watchdog |
| Maintenance | actively maintained — 168 days since the last release |
| First released | |
| Downloads | 289,951/month — #7,995 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: mcpo-0.0.20-py3-none-any.whl
Tags
More WWW/HTTP packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
h11h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
httpxHTTPX is a fully featured HTTP client library…
permissive · top 100 on PyPI
httpcoreA minimal low-level HTTP client library that…
permissive · top 100 on PyPI
aiohttpaiohttp is an async HTTP client and server…
permissive · top 100 on PyPI
llama-index-tools-mcpConnects LlamaIndex agents to MCP (Model…
permissive · top 15,000 on PyPI
mcpBuild and connect to Model Context Protocol…
permissive · top 1,000 on PyPI
mcp-proxymcp-proxy bridges Model Context Protocol (MCP)…
permissive · top 5,000 on PyPI
mcp-server-timeProvides a Model Context Protocol server that…
permissive · top 15,000 on PyPI
fastapi-mcpAutomatically exposes FastAPI endpoints as…
permissive · top 5,000 on PyPI
databricks-mcpProvides helpers and utilities to integrate MCP…
permissive · top 5,000 on PyPI
awslabs.aws-api-mcp-serverExposes AWS services to AI assistants through…
permissive · top 15,000 on PyPI
excel-mcp-serverProvides a Model Context Protocol server that…
unclear · top 15,000 on PyPI
lean-lsp-mcpProvides an MCP server that exposes the Lean…
permissive · top 5,000 on PyPI
mcpadaptAdapts MCP (Model Context Protocol) servers…
permissive · top 15,000 on PyPI