OpenAPI Required Fields Check
Before you hand an API description to a teammate, a client or a docs generator, make sure the required fields are in place. Paste your document above and the tool confirms the version field, info.title, info.version and paths, listing anything missing.
How to check the required fields
-
1
Paste the document
Paste your spec as JSON or YAML, even if it is still a work in progress.
-
2
Run the check
Continue to the results step. Each missing field appears as its own error.
-
3
Add what is missing
Add the listed fields to your file using the snippets below.
-
4
Recheck
Paste the updated spec and run it again until no errors are shown.
The four required pieces
| Field | Where it goes | Example |
|---|---|---|
| Version field | Top level | openapi: 3.0.3 or swagger: "2.0" |
| info.title | Inside info |
title: Orders API |
| info.version | Inside info |
version: 1.0.0 |
| paths | Top level | paths: with at least your first route |
The info.version value is the version of your own API, not of the OpenAPI specification. People often leave it out because the spec version is already at the top.
A worked example with everything missing
servers:
- url: https://api.example.com
This tiny document has none of the required pieces. The report lists three errors:
| Finding | Type |
|---|---|
| Missing ‘openapi’ or ‘swagger’ version field. | Error |
| Missing ‘info’ object. | Error |
| Missing ‘paths’ object. | Error |
When the whole info object is absent, the tool reports that one error and does not also list the title and version separately. Add info with both fields and the next run will report them if either is still missing.
Starter skeleton
openapi: 3.0.3
info:
title: Orders API
version: 1.0.0
paths:
/orders:
get:
summary: List orders
This skeleton clears every required-field check. Replace the names with your own and build outward from there. Responses, schemas and security are not part of this check.
When to run this check
Run it when you start a new spec from scratch, after generating one from code, and before sending it to anyone who will import it into another tool. Many importers stop at the first missing required field with a short message, so catching all of them in one pass saves several round trips. It is also a handy reminder for newcomers, who often forget info.version or leave paths out while sketching an API.
After the required fields pass, the next useful additions are a short description under info, a servers entry and an operationId on each operation. None of these are checked here, but they make the spec easier to read and to turn into client code.
Frequently Asked Questions
No. The openapi field states which version of the specification you use. info.version is the version of your own API, such as 1.0.0.
The key must exist as an object, and this check does not require any routes inside it. Add real routes before you publish.
The title and version checks run only when the info object exists. Add it, then rerun to see whether its fields are complete.
No. Only the version field, info, title, version and paths are required here. Operation-level details are not examined.
Related Tools
Color Wheel Explorer
Explore the colour wheel interactively. Rotate harmonies, compare HSL vs RYB, spot complementary and triadic pairs in real time.
FPS Counter
Measure browser FPS with requestAnimationFrame, smoothing, min/max frame rate, warnings and an optional graph. Runs locally with no upload or API.
Placeholder Image Generator
Create a 1–4000 px placeholder with custom colors and text, download it as PNG, or copy a URL and HTML image tag.
Random Phone Number Generator
Generate 1 to 50 fictional phone numbers from officially reserved ranges for the US, Canada, UK, Australia or Germany.
GitHub Profile README Generator
Build the README.md for your GitHub profile page (the username/username repo) with tagline, skills, stats cards and language breakdown.
Color Palette Generator
Generate monochromatic, analogous, complementary, triadic or tetradic color palettes from a base HEX color and export copy-ready CSS variables.
Tool available in other languages
- ตรวจฟิลด์ที่จำเป็นของ OpenAPI [TH]
- Sprawdzenie wymaganych pól OpenAPI [PL]
- Kiểm tra các trường bắt buộc của OpenAPI [VI]
- Pemeriksaan Kolom Wajib OpenAPI [ID]
- فحص الحقول المطلوبة في OpenAPI [AR]
- OpenAPI Pflichtfelder-Prüfung [DE]
- OpenAPI 必須フィールドチェック [JA]
- Verificação de campos obrigatórios do OpenAPI [PT]
- Comprobación de campos obligatorios de OpenAPI [ES]
- OpenAPI 필수 필드 검사 [KO]
- Kontroll av obligatoriska fält i OpenAPI [SV]
- Contrôle des champs obligatoires OpenAPI [FR]
- OpenAPI controle van verplichte velden [NL]
- Controllo dei campi obbligatori OpenAPI [IT]
- Проверка обязательных полей OpenAPI [RU]
- OpenAPI Zorunlu Alan Kontrolü [TR]
- OpenAPI 必填字段检查 [ZH]