# OpenAPI Lint

> OpenAPI Lint is an open-source MCP server for developer tools. Lint OpenAPI 3.x files for missing security, responses and docs, and inspect operations. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, self-hosted
- **Website:** https://basitalisandhu.github.io/dev-mcp-servers/
- **Repository:** https://github.com/basitalisandhu/dev-mcp-servers/tree/HEAD/packages/openapi-lint
- **MCP Registry name:** io.github.basitalisandhu/mcp-openapi-lint
- **Categories:** developer tools
- **Listing updated:** 2026-11-15

## About

A single file is loaded from a path or passed inline, in JSON or YAML, then checked for security and completeness. Findings are sorted by severity with a rule ID and JSON Pointer path. Rules include http servers, missing or unused security schemes, operations without security or explicitly public, API keys in query strings, HTTP Basic notes, missing success or error responses, undescribed parameters, duplicate operationIds, unversioned paths and deprecated operations.

Beyond linting it lets an assistant explore the API: list operations with their effective security (public, or inherited-none when nothing applies), fetch one operation with path-level parameters merged and local references resolved, and ask for any rule to be explained with a fix. Rules can be suppressed individually.

Only local # references are resolved and nothing is fetched. Swagger 2.0 files are flagged rather than linted. It runs from a pinned Docker image over stdio with a read-only mount, reads files up to 5 MB, and sends no telemetry. MIT licensed.

## Features

- **Security-focused rules:** Flags missing, undefined or weak security schemes and public operations.
- **Completeness checks:** Finds missing responses, descriptions, operationIds and versioning.
- **Operation listing:** Shows each operation with effective security and response codes.
- **Rule explanations:** Explains severity, detection and fix for any rule.
- **Suppressible findings:** Ignore chosen rules per run.

## Good for

- Review an API spec before release
- Find operations that are unintentionally public
- List every endpoint with its auth requirement
- Understand why a rule fired and how to fix it

## Install

### Claude Code (Terminal)

```sh
claude mcp add mcp-openapi-lint -- docker run -i --rm ghcr.io/basitalisandhu/mcp-openapi-lint:0.3.0
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "mcp-openapi-lint": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-openapi-lint:0.3.0"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "mcp-openapi-lint": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-openapi-lint:0.3.0"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "mcp-openapi-lint": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-openapi-lint:0.3.0"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "mcp-openapi-lint": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-openapi-lint:0.3.0"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "mcp-openapi-lint": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/basitalisandhu/mcp-openapi-lint:0.3.0"
      ]
    }
  }
}
```

## Tools

- `lint_openapi`: Lint an OpenAPI document and return findings with rule ID, path and message.
- `list_operations`: List operations with tags, effective security, parameters and response codes.
- `get_operation`: Return one operation in full with merged parameters and resolved local references.
- `explain_rule`: Explain a rule's severity, what it detects and how to fix it.

## FAQ

### Which versions are supported?

OpenAPI 3.0 and 3.1; Swagger 2.0 is reported by the openapi-version rule rather than linted.

### Does it call my API?

No. Findings describe the document, not the running API, and nothing is fetched.

### How big can the file be?

Up to 5 MB.

### Can I silence a rule?

Yes, with the ignore option.

### Is OpenAPI Lint free?

Yes. OpenAPI Lint is open source, so you can use and self-host it for free.

### How do I add OpenAPI Lint to Claude Code?

Run this command in your terminal: claude mcp add mcp-openapi-lint -- docker run -i --rm ghcr.io/basitalisandhu/mcp-openapi-lint:0.3.0

### What are the best alternatives to OpenAPI Lint?

The closest alternatives to OpenAPI Lint are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.
- [Ouroboros](https://ai-powered.com/mcp/ouroboros): Ouroboros is an open-source MCP server for developer tools.
- [Claude Code Ultimate Guide](https://ai-powered.com/mcp/claude-code-ultimate-guide): Claude Code Ultimate Guide is an open-source MCP server for ai models and llm tooling.
- [Concord MCP](https://ai-powered.com/mcp/concord-mcp): Concord MCP is a freemium MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/openapi-lint-2
