Skip to main content
Glama
gurvinder-dhillon

Unbundle OpenAPI Specs MCP

Разделение OpenAPI MCP Server

значок кузнеца

Этот проект предоставляет сервер Model Context Protocol (MCP) с инструментами для разделения файлов спецификаций OpenAPI на несколько файлов или извлечения определенных конечных точек в новый файл. Он позволяет клиенту MCP (например, помощнику AI) программно манипулировать спецификациями OpenAPI.

Предпосылки

  • Node.js (рекомендуется версия LTS, например v18 или v20)

  • npm (входит в состав Node.js)

Related MCP server: openapi-mcp-proxy

Использование

Установка через Smithery

Чтобы автоматически установить Unbundle OpenAPI MCP Server для Claude Desktop через Smithery :

npx -y @smithery/cli install @auto-browse/unbundle_openapi_mcp --client claude

Самый простой способ использовать этот сервер — через npx , что гарантирует вам постоянное использование последней версии без необходимости глобальной установки.

npx @auto-browse/unbundle-openapi-mcp@latest

Кроме того, вы можете установить его глобально (что обычно не рекомендуется):

npm install -g @auto-browse/unbundle-openapi-mcp
# Then run using: unbundle-openapi-mcp

Сервер запустится и будет прослушивать запросы MCP на стандартном вводе/выводе (stdio).

Конфигурация клиента

Чтобы использовать этот сервер с клиентами MCP, такими как VS Code, Cline, Cursor или Claude Desktop, добавьте его конфигурацию в соответствующий файл настроек. Рекомендуемый подход использует npx .

VS Code / Клайн / Курсор

Добавьте следующее в файл User settings.json (доступный через Ctrl+Shift+P > Preferences: Open User Settings (JSON) ) или в файл .vscode/mcp.json в корневом каталоге рабочей области.

// In settings.json:
"mcp.servers": {
  "unbundle_openapi": { // You can choose any key name
    "command": "npx",
    "args": [
      "@auto-browse/unbundle-openapi-mcp@latest"
    ]
  }
  // ... other servers can be added here
},

// Or in .vscode/mcp.json (omit the top-level "mcp.servers"):
{
  "unbundle_openapi": { // You can choose any key name
    "command": "npx",
    "args": [
      "@auto-browse/unbundle-openapi-mcp@latest"
    ]
  }
  // ... other servers can be added here
}

Клод Десктоп

Добавьте следующее в файл claude_desktop_config.json .

{
	"mcpServers": {
		"unbundle_openapi": {
			// You can choose any key name
			"command": "npx",
			"args": ["@auto-browse/unbundle-openapi-mcp@latest"]
		}
		// ... other servers can be added here
	}
}

После добавления конфигурации перезапустите клиентское приложение, чтобы изменения вступили в силу.

Предоставляемые инструменты MCP

split_openapi

Описание: Выполняет команду redocly split для разделения файла определения OpenAPI на несколько меньших файлов на основе его структуры.

Аргументы:

  • apiPath (строка, обязательно): абсолютный путь к входному файлу определения OpenAPI (например, openapi.yaml ).

  • outputDir (string, required): Абсолютный путь к каталогу, в котором должны быть сохранены разделенные выходные файлы. Этот каталог будет создан, если он не существует.

Возврат:

  • При успешном выполнении: текстовое сообщение, содержащее стандартный вывод команды redocly split (обычно подтверждающее сообщение).

  • При сбое: сообщение об ошибке, содержащее стандартные сведения об ошибке или исключении при выполнении команды, отмеченное как isError: true .

Пример использования (концептуальный запрос MCP):

{
	"tool_name": "split_openapi",
	"arguments": {
		"apiPath": "/path/to/your/openapi.yaml",
		"outputDir": "/path/to/output/directory"
	}
}

extract_openapi_endpoints

Описание: Извлекает определенные конечные точки из большого файла определения OpenAPI и создает новый, меньший файл OpenAPI, содержащий только эти конечные точки и их ссылочные компоненты. Это достигается путем разделения исходного файла, изменения структуры для сохранения только указанных путей, а затем объединения результата.

Аргументы:

  • inputApiPath (строка, обязательно): абсолютный путь к большому входному файлу определения OpenAPI.

  • endpointsToKeep (массив строк, обязательно): список точных путей конечных точек (строк), которые следует включить в конечный вывод (например, ["/api", "/api/projects/{id}{.format}"] ). Пути, не найденные в исходной спецификации, будут игнорироваться.

  • outputApiPath (string, required): Абсолютный путь, по которому должен быть сохранен окончательный, меньший упакованный файл OpenAPI. Каталог будет создан, если он не существует.

Возврат:

  • В случае успеха: текстовое сообщение с указанием пути к созданному файлу и стандартный вывод команды redocly bundle .

  • При ошибке: сообщение об ошибке, содержащее сведения о шаге, который не был выполнен (разделение, изменение, объединение), отмеченное как isError: true .

Пример использования (концептуальный запрос MCP):

{
	"tool_name": "extract_openapi_endpoints",
	"arguments": {
		"inputApiPath": "/path/to/large-openapi.yaml",
		"endpointsToKeep": ["/users", "/users/{userId}/profile"],
		"outputApiPath": "/path/to/extracted-openapi.yaml"
	}
}

Примечание: Этот сервер использует npx @redocly/cli@latest внутренне для выполнения базовых команд split и bundle . Для npx может потребоваться подключение к Интернету для извлечения @redocly/cli если он не кэширован. Временные файлы создаются во время процесса extract_openapi_endpoints и автоматически очищаются.

Разработка

Если вы хотите внести свой вклад или запустить сервер из исходного кода:

  1. Клонировать: Клонировать этот репозиторий.

  2. Перейдите: cd unbundle_openapi_mcp

  3. Установка зависимостей: npm install

  4. Сборка: npm run build (компилирует TypeScript в dist/ )

  5. Запустить: npm start (запускает сервер, используя скомпилированный код в dist/ )

Available Tools

2 tools
extract_openapi_endpointsD
ParametersJSON Schema
NameRequiredDescriptionDefault
endpointsToKeepYesList of exact endpoint paths to keep (e.g., ['/users', '/users/{id}']).
inputApiPathYesAbsolute path to the large input OpenAPI definition file.
outputApiPathYesAbsolute path where the final, smaller bundled OpenAPI file should be saved.

TDQS

D1/5.0
Behavior1/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Tool has no description.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness1/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Tool has no description.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness1/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Tool has no description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Tool has no description.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose1/5

Does the description clearly state what the tool does and how it differs from similar tools?

Tool has no description.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines1/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Tool has no description.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

split_openapiD
ParametersJSON Schema
NameRequiredDescriptionDefault
apiPathYesAbsolute path to the input OpenAPI definition file.
outputDirYesAbsolute path to the directory for split output files.

TDQS

D1/5.0
Behavior1/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Tool has no description.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness1/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Tool has no description.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness1/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Tool has no description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Tool has no description.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose1/5

Does the description clearly state what the tool does and how it differs from similar tools?

Tool has no description.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines1/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Tool has no description.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 2 tool updatesv1.0.0
    • First observedextract_openapi_endpoints
    • First observedsplit_openapi

TDQS

D1.7/5.0
Disambiguation4/5

The two tools have clearly distinct purposes: 'extract_openapi_endpoints' likely retrieves endpoints from an OpenAPI spec, while 'split_openapi' probably divides a spec into parts. There is no overlap in functionality, though the lack of descriptions leaves some room for minor uncertainty about exact differences.

Naming Consistency5/5

Both tools follow a consistent snake_case naming pattern with a verb_noun structure ('extract_endpoints', 'split_openapi'). The naming is predictable and aligned, making it easy to understand the action and target for each tool.

Tool Count2/5

With only two tools, the server feels thin for its purpose of unbundling OpenAPI specs. This limited set may not cover essential operations like validation, merging, or transformation, leaving obvious gaps in functionality for a domain that typically requires more comprehensive handling.

Completeness2/5

The tool surface is severely incomplete for unbundling OpenAPI specs. Missing are tools for tasks such as validating specs, merging split parts, converting formats, or handling errors. Agents will likely encounter dead ends when trying to perform common workflows in this domain.

Maintenance

ActivityInactive
ResponsivenessSyncing

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    A
    maintenance
    MCP server providing token-efficient access to OpenAPI/Swagger specs via MCP Resources for client-side exploration.
    234
    76
    MIT
  • A
    license
    A
    quality
    C
    maintenance
    Parses Swagger 2.0 and OpenAPI 3.x specifications, exposing API endpoints, schemas, and authentication through MCP tools with local caching to reduce token usage.
    11
    27
    1
    MIT

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/gurvinder-dhillon/unbundle_openapi_mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server