mcp-openapi-schema

hybrid server

The server is able to function both locally and remotely, depending on the configuration or use case.

Integrations

  • Supports integration with Claude Desktop on Linux through configuration file located at ~/Library/Application Support/Claude/claude_desktop_config.json.

  • Supports integration with Claude Desktop on macOS through configuration file located at ~/Library/Application Support/Claude/claude_desktop_config.json.

  • Processes OpenAPI schema files in YAML format and presents schema information in YAML format for better LLM comprehension.

OpenAPI スキーマ モデル コンテキスト プロトコル サーバー

Claudeのような大規模言語モデル(LLM)にOpenAPIスキーマ情報を公開するモデルコンテキストプロトコル(MCP)サーバー。このサーバーにより、LLMは専用のツールセットを通じてOpenAPI仕様を探索し、理解することができます。

特徴

  • コマンドライン引数で指定された任意の OpenAPI スキーマファイル (JSON または YAML) をロードします。
  • API パス、操作、パラメータ、スキーマを調べる
  • 詳細なリクエストとレスポンスのスキーマを表示する
  • コンポーネントの定義と例を調べる
  • API仕様全体を検索
  • LLM をより良く理解するために、YAML 形式で応答を取得します。

使用法

コマンドライン

特定のスキーマ ファイルを使用して MCP サーバーを実行します。

# Use the default openapi.yaml in current directory npx -y mcp-openapi-schema # Use a specific schema file (relative path) npx -y mcp-openapi-schema ../petstore.json # Use a specific schema file (absolute path) npx -y mcp-openapi-schema /absolute/path/to/api-spec.yaml # Show help npx -y mcp-openapi-schema --help

クロードデスクトップ統合

この MCP サーバーを Claude Desktop で使用するには、 claude_desktop_config.json構成ファイルを編集します。

{ "mcpServers": { "OpenAPI Schema": { "command": "npx", "args": ["-y", "mcp-openapi-schema", "/ABSOLUTE/PATH/TO/openapi.yaml"] } } }

設定ファイルの場所:

  • macOS/Linux: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: $env:AppData\Claude\claude_desktop_config.json

クロード・コード統合

この MCP サーバーを Claude Code CLI で使用するには、次の手順に従います。

  1. Claude CodeにOpenAPIスキーマMCPサーバーを追加する
    # Basic syntax claude mcp add openapi-schema npx -y mcp-openapi-schema # Example with specific schema claude mcp add petstore-api npx -y mcp-openapi-schema ~/Projects/petstore.yaml
  2. MCPサーバーが登録されていることを確認する
    # List all configured servers claude mcp list # Get details for your OpenAPI schema server claude mcp get openapi-schema
  3. 必要に応じてサーバーを削除する
    claude mcp remove openapi-schema
  4. Claude Codeのツールを使用する設定が完了すると、OpenAPI スキーマに関する質問をすることで、Claude Code セッションでツールを呼び出すことができます。

ヒント:

  • -sまたは--scopeフラグをproject (デフォルト)またはglobalとともに使用して、構成が保存される場所を指定します。
  • 異なる名前を持つ異なる API に複数の MCP サーバーを追加する

MCPツール

サーバーは、LLM が OpenAPI スキーマと対話するための次のツールを提供します。

  • list-endpoints : すべての API パスとその HTTP メソッドを、ネストされたオブジェクト構造の概要とともに一覧表示します。
  • get-endpoint : パラメータやレスポンスを含む特定のエンドポイントに関する詳細情報を取得します。
  • get-request-body : 特定のエンドポイントとメソッドのリクエストボディスキーマを取得します。
  • get-response-schema : 特定のエンドポイント、メソッド、ステータスコードのレスポンススキーマを取得します。
  • get-path-parameters : 特定のパスのパラメータを取得します
  • list-components : すべてのスキーマ コンポーネント (スキーマ、応答、パラメーターなど) を一覧表示します。
  • get-component : 特定のコンポーネントの詳細な定義を取得します
  • list-security-schemes : 利用可能なすべてのセキュリティスキームを一覧表示します
  • get-examples : 特定のコンポーネントまたはエンドポイントの例を取得します
  • search-schema : パス、操作、スキーマを検索します

試してみるクエリの例:

What endpoints are available in this API? Show me the details for the POST /pets endpoint. What parameters does the GET /pets/{petId} endpoint take? What is the request body schema for creating a new pet? What response will I get from the DELETE /pets/{petId} endpoint? What schemas are defined in this API? Show me the definition of the Pet schema. What are the available security schemes for this API? Are there any example responses for getting a pet by ID? Search for anything related to "user" in this API.
-
security - not tested
F
license - not found
-
quality - not tested

ClaudeのようなLLMにOpenAPIスキーマ情報を公開するMCPサーバー。このサーバーにより、LLMはコンテキストにスキーマ全体をロードすることなく、一連の専用ツールを通じて大規模なOpenAPIスキーマを探索・理解することができます。

  1. Features
    1. Usage
      1. Command Line
      2. Claude Desktop Integration
      3. Claude Code Integration
    2. MCP Tools
      1. Examples
        ID: 9yqbiz3hwx