Skip to main content
Glama
Specwise MCP Server

Specwise MCP Server

validate_openapi

Read-onlyIdempotent

Validates OpenAPI 3.x or Swagger 2.0 documents and returns every error with JSON Pointer, line and column, plus lint warnings in one pass.

Instructions

Validate an OpenAPI 3.0/3.1/3.2 or Swagger 2.0 document. Returns every error (not just the first) with its JSON Pointer, line and column, plus lint warnings.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "validate_openapi"
  }
}

Input Schema

NameRequiredDescriptionDefault
specNoThe document as YAML or JSON text (or a JSON object).
spec_pathNoA local file instead of `spec`. Uploaded to the Specwise API; only *.yaml, *.yml or *.json inside the working directory (or SPECWISE_MCP_ROOT) are read.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.2.6
    • changedInput schema / properties / spec_path / description
      Previous value: -"A local file instead of `spec`."New value: +"A local file instead of `spec`. Uploaded to the Specwise API; only *.yaml, *.yml or *.json inside the working directory (or SPECWISE_MCP_ROOT) are read."
  2. First observedv0.2.2

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/destructive/openWorld, so the safety profile is covered. The description adds real behavioral value beyond that by disclosing the return contract: all errors rather than the first, each with JSON Pointer, line and column, plus lint warnings. It still does not say what happens on API failure or how large documents are handled.

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 sentences, zero filler, with the supported formats and the return behavior front-loaded. Every clause carries information an agent needs.

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?

With no output schema, the description usefully explains what comes back (all errors with pointer/location plus lint warnings) and annotations cover the safety profile. Only minor gaps remain, such as failure behavior and size limits, which is why it falls short of a 5.

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 both parameters are already documented in the schema, including the working-directory restriction on spec_path. The description only repeats that the input may be YAML or JSON text, adding no new semantics, so baseline 3 applies.

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?

States a specific verb and resource plus the exact supported formats (OpenAPI 3.0/3.1/3.2, Swagger 2.0), which is enough to tell it apart from diff_openapi on the resource alone. It does not explicitly contrast itself with validate_json_schema, so sibling differentiation is only implicit.

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 purpose strongly implies when to reach for it (you have a spec document you want checked), but there is no explicit guidance on when not to use it versus diff_openapi or validate_json_schema, and no mention of when to prefer spec_path over spec.

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

Deploy Server

Other Tools