JSON Schema

The OAS Generator provides an JSON Schema to simplify the writing of the configuration file.

The JSON schema is available at the following URL:

The following sections will show you how to enable the JSON schema support in some IDEs.

IntelliJ IDEA

  1. Open the Settings window and search for "JSON Schema Mappings".

  2. Click the icon to add a custom JSON Schema Mapping

  3. Select Version 7 and add the URL listed above.

  4. Add mappings to the File path pattern, for example oas-generator.yml. You can add as many path mappings as you like.

json schema intellij

VS Code

To use the JSON Schema within Visual Studio Code the YAML (Red Hat) extension must be installed. Then the mapping of the schema URL to the file names must be added to the settings.json:

settings.json
{
  "yaml.schemas": {
    "https://chhorz.github.io/oas-generator/schema/oas-generator.schema.json": ["oas-generator.yml"]
  }
}