Back to MCP Catalog

OpenAPI Schema Explorer MCP Server

Developer ToolsJavaScript
Explore and understand OpenAPI specifications through specialized tools
Available Tools

list-endpoints

Lists all API paths and their HTTP methods with summaries in a nested object structure

get-endpoint

Gets detailed information about a specific endpoint including parameters and responses

get-request-body

Gets the request body schema for a specific endpoint and method

get-response-schema

Gets the response schema for a specific endpoint, method, and status code

get-path-parameters

Gets the parameters for a specific path

list-components

Lists all schema components (schemas, responses, parameters, etc.)

get-component

Gets detailed definition for a specific component

list-security-schemes

Lists all available security schemes

get-examples

Gets examples for a specific component or endpoint

search-schema

Searches across paths, operations, and schemas

The OpenAPI Schema Explorer provides a powerful interface for Large Language Models to interact with and understand API specifications. It allows models to explore paths, operations, parameters, schemas, and other components of any OpenAPI specification file in JSON or YAML format. This tool bridges the gap between complex API documentation and LLM understanding, enabling more accurate code generation, API usage guidance, and technical documentation assistance. With features like detailed schema exploration, component lookup, and search capabilities, it makes working with APIs significantly more efficient.

Overview

The OpenAPI Schema Explorer is a Model Context Protocol (MCP) server that enables Large Language Models to interact with and understand OpenAPI specifications. This tool is particularly useful for developers working with APIs, as it allows the LLM to provide more accurate guidance, code examples, and explanations based on the actual API structure.

Installation

You can install and run the OpenAPI Schema Explorer using NPX, which allows you to execute the package without installing it globally.

Basic Installation

The simplest way to use the OpenAPI Schema Explorer is through NPX:

# 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

Integration with Claude Desktop

To integrate the OpenAPI Schema Explorer with Claude Desktop:

  1. Locate your Claude Desktop configuration file:

    • macOS/Linux: ~/Library/Application Support/Claude/claude_desktop_config.json
    • Windows: $env:AppData\Claude\claude_desktop_config.json
  2. Edit the configuration file to include the OpenAPI Schema Explorer:

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

Replace /ABSOLUTE/PATH/TO/openapi.yaml with the actual path to your OpenAPI specification file.

Integration with Claude Code CLI

To use the OpenAPI Schema Explorer with Claude Code CLI:

  1. Add the OpenAPI Schema MCP server:
# 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
  1. Verify the MCP server is registered:
# List all configured servers
claude mcp list

# Get details for your OpenAPI schema server
claude mcp get openapi-schema
  1. To remove the server if needed:
claude mcp remove openapi-schema

Usage Tips

When using the OpenAPI Schema Explorer with an LLM:

  1. Start by asking about available endpoints using the list-endpoints tool
  2. Explore specific endpoints with get-endpoint to understand their parameters and responses
  3. Use get-request-body and get-response-schema to understand data structures
  4. Explore component definitions with list-components and get-component
  5. Search for specific terms or functionality using search-schema

Example queries to try:

  • "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 schemas are defined in this API?"
  • "Show me the definition of the Pet schema."

The OpenAPI Schema Explorer makes it much easier for LLMs to understand and work with API specifications, leading to more accurate and helpful responses when discussing API usage and implementation.

Related MCPs

Apple Shortcuts
Developer ToolsJavaScript

Control Apple Shortcuts automations from AI assistants

Clojars Dependency Lookup
Developer ToolsJavaScript

Fetch dependency information from Clojars, the Clojure community's artifact repository

Simple Timeserver
Developer ToolsPython

Provides Claude with current time and timezone information

About Model Context Protocol

Model Context Protocol (MCP) allows AI models to access external tools and services, extending their capabilities beyond their training data.

Generate Cursor Documentation

Save time on coding by generating custom documentation and prompts for Cursor IDE.