OpenAPI Linter (2026)
Lint your OpenAPI / Swagger spec against documentation-quality rules. Catches missing operationIds, missing descriptions, undocumented errors, duplicate IDs, and more — issues that pass validation but break SDK generation and developer experience.
Validation vs linting
Validation checks that the document is legal OpenAPI. Linting checks that it's a good OpenAPI document. A spec can be 100% valid and still produce SDKs full of getApiV1UsersByIdEndpoint functions because operationIds are missing. Linting catches that.
Why these rules matter
- operationId drives every code generator. Without it, function names regress to method+path and break on every refactor.
- summary / description is what developers read in your docs. No description = sparse docs = support tickets.
- tags group operations in rendered docs (Specway uses them as sidebar sections). No tags = wall of endpoints.
- 4xx responses tell consumers how errors look. Without them, every client reverse-engineers your error shape from production traffic.
- info.contact tells stuck developers where to ask. Cheap to add, lossy to skip.
Linting in CI
For full rule coverage, install Spectral (@stoplight/spectral), commit a .spectral.yaml with your team's rules, and run on every PR. Or use Specway — it auto-runs Spectral plus internal quality checks on every spec import and surfaces issues alongside validation errors.