Sign inSign up

pivotalservicesoss/openapi-to-mcp

By pivotalservicesoss

•Updated 7 months ago

Generic MCP gateway that converts any OpenAPI spec into MCP tools for AI agents.

Image
Integration & delivery
Machine learning & AI
Developer tools
0

266

pivotalservicesoss/openapi-to-mcp repository overview

⁠openapi-to-mcp

A zero-code MCP (Model Context Protocol) gateway that reads any OpenAPI 3.x spec and automatically exposes each operation as an MCP tool — making existing REST APIs instantly accessible to AI agents.


⁠Features

  • Auto-generates MCP tools from any OpenAPI spec (no code changes required)
  • Filter tools by tag, whitelist, or exclude list
  • Inbound JWT/OIDC authentication middleware
  • Outbound OAuth2 client-credentials auth to upstream APIs
  • Multi-arch image (linux/amd64, linux/arm64)

⁠Quick Start

docker run -p 8000:8000 \
  -e API_BASE_URL=https://your-api.example.com \
  pivotalservicesoss/openapi-to-mcp:latest

MCP endpoint: http://localhost:8000/mcp⁠


⁠Minimal Configuration

For advanced configuration and usage, please refer to source repository(link provided below) readme or docs.

⁠Core
VariableDescriptionDefault
API_BASE_URLUpstream API base URLrequired
API_SPEC_URLOpenAPI spec URL{API_BASE_URL}/openapi.json
PORTListening port8000
LOG_LEVELLog levelinfo
APP_ENVproduction or developmentproduction
SKIP_SSL_VERIFYSkip SSL verificationfalse
API_TIMEOUTRequest timeout (seconds)30

⁠Tool Filtering
VariableDescriptionDefault
TOOL_TAGSInclude operations matching these tagsmcp
TOOL_WHITELISTInclude only these operation IDs—
TOOL_EXCLUDEExclude these operation IDs—

⁠Outbound OAuth2
VariableDescriptionDefault
API_TOKEN_URLToken endpoint URL—
API_CLIENT_IDClient ID—
API_CLIENT_SECRETClient secret—
API_SCOPERequested scope—

⁠Inbound JWT
VariableDescriptionDefault
AUTH_PROXY_ISSUEROIDC issuer for JWT validation—
AUTH_PROXY_AUDIENCEExpected JWT audience—
TRUST_INBOUNDSkip inbound auth validationfalse

⁠Source

https://github.com/PivotalServicesOss/openapi-to-mcp⁠

Tag summary

Content type

Image

Digest

sha256:7275fb430…

Size

272.8 kB

Last updated

7 months ago

docker pull pivotalservicesoss/openapi-to-mcp:sha256-34b7e0ae99053fca9b6f0d0f7fd1dd5825d1b6407e99ed9ca8118471e70a24ed.sbom