MCP API Translator

v0.4.1
io.github.krishgok/mcp-api-translator Checked 2 days ago Published 1 month ago

Turn OpenAPI / Postman specs into runnable MCP servers, or serve any API as live MCP tools.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

analyze_spec Analyze API spec (preview)

Parse an OpenAPI or Postman spec and preview the MCP tools that would be generated, without writing any files. Use this to curate (filter/inspect) before generating.

ParameterTypeDescription
excludeOperationsarrayDrop operations by operationId, tool name, or tag.
formatstringForce a format; defaults to auto-detect.
includeTagsarrayKeep only operations with these tags.
methodsarrayKeep only these HTTP methods, e.g. [GET, POST].
pathGlobstringKeep only matching paths, e.g. "/v1/**".
specstringInline spec text (OpenAPI or Postman; JSON or YAML).
specPathstringPath to a local spec file (JSON or YAML).

generate_mcp_server Generate MCP server

Generate a complete, runnable TypeScript MCP server project from an OpenAPI or Postman spec. Writes the project to outputDir. Use force to overwrite a non-empty directory.

ParameterTypeDescription
outputDir *stringDirectory to write the generated project into.
authAuth to use when the spec declares no security schemes of its own. Applied only to operations whose own security list is empty; credentials are read from env vars as usual.
excludeOperationsarrayDrop operations by operationId, tool name, or tag.
forcebooleanOverwrite a non-empty / existing project.
formatstringForce a format; defaults to auto-detect.
includeTagsarrayKeep only operations with these tags.
languagestringOutput language. Defaults to typescript.
methodsarrayKeep only these HTTP methods, e.g. [GET, POST].
pathGlobstringKeep only matching paths, e.g. "/v1/**".
pythonVariantstringPython server flavor (requires language: python): the low-level MCP SDK (default) or FastMCP. Both serve the same raw JSON-Schema tool inputs.
serverNamestringnpm/package name; defaults from the API title.
serverVersionstring
specstringInline spec text (OpenAPI or Postman; JSON or YAML).
specPathstringPath to a local spec file (JSON or YAML).
toolCatalogbooleanAlso write tool-catalog.json (name/summary/tags per tool) for discovery layers.
transportstringTransport(s) to generate (TypeScript only). Defaults to stdio.

extend_mcp_server Extend an existing generated MCP server

Append the operations from another spec to an already-generated project (identified by its .mcp-translator.json manifest). Idempotent: operations already present are skipped, and hand-edited tool files are preserved unless force is set. Enables aggregating multiple APIs into one MCP server.

ParameterTypeDescription
projectDir *stringPath to an existing generated project.
authAuth to use when the spec declares no security schemes of its own. Applied only to operations whose own security list is empty; credentials are read from env vars as usual.
excludeOperationsarrayDrop operations by operationId, tool name, or tag.
forcebooleanOverwrite existing tool files of the same name.
formatstringForce a format; defaults to auto-detect.
includeTagsarrayKeep only operations with these tags.
methodsarrayKeep only these HTTP methods, e.g. [GET, POST].
pathGlobstringKeep only matching paths, e.g. "/v1/**".
specstringInline spec text (OpenAPI or Postman; JSON or YAML).
specPathstringPath to a local spec file (JSON or YAML).
toolCatalogbooleanAlso write tool-catalog.json; defaults to refreshing it if the project has one.

list_supported_features List supported features

Report the input formats, auth schemes, transports, and limits this tool supports.