Skip to main content
Glama

Spectacle

An MCP server that lets Claude (and other MCP clients) query, search, and explore OpenAPI specifications. Point it at a spec file and ask questions about endpoints, parameters, schemas, and more.

Supports OpenAPI 3.x (JSON/YAML) and Swagger 2.0 (auto-converted).

Tools

Tool

Description

spec_load

Load an OpenAPI/Swagger spec from a local file path

list_endpoints

List all endpoints, optionally filtered by HTTP method or tag

get_endpoint

Get detailed info about a specific endpoint (brief/normal/full verbosity)

search_endpoints

Full-text search across endpoints with relevance ranking

Related MCP server: openapi-mcp-proxy

Setup

Prerequisites

  • Node.js 18+

  • pnpm

Install

git clone https://github.com/your-username/spectacle-mcp.git
cd spectacle-mcp
pnpm install

Configure in Claude Code

Add to your project's .mcp.json:

{
  "mcpServers": {
    "spectacle": {
      "command": "pnpm",
      "args": ["tsx", "/absolute/path/to/spectacle-mcp/src/index.ts"],
    }
  }
}

Usage

Once configured, Claude can use the tools directly. Some example prompts:

"Load the spec at ./openapi.yaml and list all endpoints"

"What parameters does POST /users accept?"

"Search the API for anything related to authentication"

"Show me the full details of GET /orders/{id} including response schemas"

Tool details

spec_load — Load and cache a spec. Swagger 2.0 files are automatically converted to OpenAPI 3.x. Specs are cached in memory and reloaded when the file changes.

list_endpoints — Two output formats:

  • compact — one line per endpoint (GET /pets)

  • grouped — organized by tag with summaries

get_endpoint — Three verbosity levels:

  • brief — method, path, summary

  • normal — adds parameters, request body, response codes

  • full — adds complete expanded schemas

search_endpoints — Keyword search with AND semantics (all terms must match). Results are ranked by relevance with weighted field scoring (path > operationId > summary > tags > parameters > description). Three return formats: snippets, ids, or full.

Development

pnpm start       # Run the MCP server
pnpm dev         # Run with file watching (auto-restart on changes)

Running tests

pnpm tsx test/smoke.ts         # Integration tests
pnpm tsx test/swagger2-test.ts # Swagger 2.0 conversion tests

Project structure

src/
  index.ts    — MCP server setup and tool registration
  spec.ts     — Spec loading, caching, $ref resolution, and indexing
  format.ts   — Output formatting and search scoring
test/
  petstore.yaml     — OpenAPI 3.0 test fixture
  swagger2.json     — Swagger 2.0 test fixture
  smoke.ts          — Integration tests
  swagger2-test.ts  — Conversion tests

Available Tools

4 tools
get_endpointB

Get detailed information about a specific API endpoint.

ParametersJSON Schema
NameRequiredDescriptionDefault
pathYesAPI path (e.g. /users/{id})
methodYesHTTP method (GET, POST, etc.)
spec_pathYesPath to the spec file
verbosityNoDetail levelnormal

TDQS

B3.2/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It only repeats that the tool 'gets detailed information,' which is already implied by the name, and does not disclose what the returned details contain, whether it reads the spec file, or how verbosity affects the result.

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

Conciseness4/5

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

The description is a single, front-loaded sentence with no filler. It could include more usage or behavioral context, but for its length it is efficient and every word contributes to the core meaning.

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

Completeness3/5

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

The operation is simple and the input schema is thorough, but there is no output schema and no annotation coverage. The description does not specify what 'detailed information' includes, how verbosity changes the response, or how this tool relates to spec_load, leaving some important context absent.

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

Parameters3/5

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

Schema description coverage is 100%, so the input schema documents all four parameters meaningfully. The description adds no extra semantic value beyond saying 'specific API endpoint,' but it does not need to compensate because the schema already covers the parameters.

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

Purpose4/5

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

The description states a clear verb and resource: get detailed information about a specific API endpoint. It conveys the targeted nature of the operation, which distinguishes it from list/search siblings, though it does not explicitly name them.

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

Usage Guidelines3/5

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

The wording 'specific API endpoint' implies this is for retrieving one endpoint's details rather than listing or searching, but the description gives no explicit guidance about when to prefer this over spec_load, list_endpoints, or search_endpoints.

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

list_endpointsA

List all API endpoints in a loaded spec. Filter by method or tag.

ParametersJSON Schema
NameRequiredDescriptionDefault
tagNoFilter by tag name
formatNoOutput formatcompact
methodNoFilter by HTTP method (GET, POST, etc.)
spec_pathYesPath to the spec file

TDQS

A3.5/5.0
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions listing and filtering but does not clarify whether the spec is loaded from the spec_path at call time, what counts as a 'loaded spec,' or what the output structure looks like. This ambiguity is notable given the spec_path parameter.

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

Conciseness5/5

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

The description is two short sentences with no filler. The primary action is front-loaded, and the filtering capabilities are stated in the second sentence, making it easy to scan.

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

Completeness3/5

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

The tool has low complexity and a fully documented schema, but the description does not clarify how it relates to spec_load or search_endpoints, nor does it describe the return format despite there being no output schema. The 'loaded spec' wording also creates ambiguity around whether a prior load step is required. Overall it is adequate but leaves some gaps for the agent to resolve.

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

Parameters3/5

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

Schema description coverage is 100%, so all four parameters are documented in the schema itself. The description adds slight context by mentioning method and tag filters, but does not explain format values or the relationship between spec_path and a 'loaded spec,' so it stays at the baseline.

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

Purpose5/5

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

The description clearly states the verb ('List') and resource ('all API endpoints in a loaded spec'), and adds the filtering dimensions by method or tag. This differentiates it from siblings like get_endpoint (single endpoint) and search_endpoints (search), making the tool's purpose immediately recognizable.

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

Usage Guidelines3/5

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

The description implies this tool is for broad listing with optional filters, but it does not explicitly state when to prefer this over search_endpoints or get_endpoint. No exclusions or alternative conditions are given, leaving some routing decisions to inference.

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

search_endpointsA

Search API endpoints by keyword. AND semantics — all terms must match.

ParametersJSON Schema
NameRequiredDescriptionDefault
qYesSearch query (space-separated terms)
limitNoMax results to return
returnNoOutput formatsnippets
spec_pathYesPath to the spec file

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It does add meaningful behavior by stating that all search terms must match under AND semantics, which goes beyond the schema. But it does not mention output behavior, edge cases, or whether the operation is read-only, leaving some transparency gaps.

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

Conciseness5/5

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

The description is two short sentences with no filler. The core purpose is front-loaded, and the AND semantics sentence adds critical clarifying information without unnecessary elaboration.

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

Completeness4/5

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

For a straightforward search tool with a fully described schema, the description is largely sufficient. It covers the purpose and key matching semantics, but it could be slightly more complete by noting what the output contains or how it differs from list_endpoints.

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

Parameters3/5

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

The input schema already provides descriptions for 100% of the parameters, so the baseline is 3. The description adds no parameter-specific meaning beyond the AND semantics already noted, which mainly clarifies the q parameter's matching behavior.

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

Purpose5/5

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

The description states a specific action ('Search'), resource ('API endpoints'), and method ('by keyword'), and even clarifies matching behavior with 'AND semantics'. This clearly distinguishes it from sibling tools like list_endpoints or get_endpoint, which serve different purposes.

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

Usage Guidelines3/5

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

The description implies when to use the tool: when an agent needs to find API endpoints by keyword. However, it does not explicitly state when not to use it or mention alternatives such as list_endpoints or get_endpoint, so the routing guidance is left to inference.

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

spec_loadA

Load an OpenAPI spec from a local file path. Converts Swagger 2.0 automatically.

ParametersJSON Schema
NameRequiredDescriptionDefault
spec_pathYesAbsolute or relative path to the OpenAPI/Swagger spec file
force_reloadNoForce reload even if cached

TDQS

A3.8/5.0
Behavior3/5

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

No annotations are provided, so the description carries the behavioral burden. It does disclose two useful behaviors: reading from a local path and automatically converting Swagger 2.0. Yet it omits meaningful statefulness around the force_reload parameter, such as caching behavior, and does not mention side effects, errors, or whether successful loading returns the spec or stores it for subsequent sibling calls.

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

Conciseness5/5

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

Two short sentences with no filler. The core action is front-loaded, and the Swagger conversion note earns its place by adding compatibility information.

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

Completeness2/5

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

With no output schema and no annotations, the description should explain what 'loading' means: does it return the parsed spec, mutate internal state, or persist something for sibling tools? The force_reload parameter hints at caching, but the description is silent on that behavior, leaving an agent to guess the postcondition and return value.

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

Parameters4/5

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

Schema description coverage is 100%, so baseline is 3. The description adds value beyond the schema by specifying that the path is local and that Swagger 2.0 input is accepted and converted automatically, enriching the meaning of spec_path beyond its bare type/description.

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

Purpose5/5

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

The description uses a specific verb ('Load') with a concrete resource ('OpenAPI spec') and a clear source ('local file path'), making the tool's function immediately identifiable. It also distinguishes itself from the sibling endpoint inspection tools by targeting the spec itself rather than operations on it.

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

Usage Guidelines3/5

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

The phrase 'from a local file path' and the automatic Swagger 2.0 conversion imply when this tool is appropriate: when a caller needs to ingest a local spec file. However, it does not explicitly state when to prefer this over alternatives, when not to use it, or any prerequisites for the siblings that operate on loaded specs.

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

TDQS

A3.7/5.0
Disambiguation4/5

Each tool has a distinct primary purpose: load a spec, list all endpoints, get one endpoint, or search endpoints. The only possible confusion is between list_endpoints and search_endpoints, but the filtering vs. keyword-search distinction is clear enough.

Naming Consistency4/5

Most tools follow a clear verb_noun pattern: list_endpoints, get_endpoint, search_endpoints. spec_load is a minor deviation—load_spec would be more consistent—but overall the naming is readable and predictable.

Tool Count5/5

Four tools is a well-scoped size for an OpenAPI inspection server. Each tool is non-redundant and covers a necessary part of the workflow without bloat.

Completeness4/5

The toolset covers the core inspection lifecycle: load a spec, list endpoints, get details, and search. There are minor gaps like retrieving spec metadata or listing tags, but the primary use cases are fully supported and there are no dead ends.

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
    F
    maintenance
    A MCP server that exposes OpenAPI schema information to LLMs like Claude. This server allows an LLM to explore and understand large OpenAPI schemas through a set of specialized tools, without needing to load the whole schema into the context
    358
    50
    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/mjmarrazzo/spectacle-mcp'

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