Unofficial maven plugin using Zally for OpenAPI 3.x specification validation.
- Simple to use and tweak rules to fit your requirements
- No Zally installation/server setup required
- Supports API definitions with external references out of the box
<plugin>
<groupId>com.ethlo.zally</groupId>
<artifactId>zally-maven-plugin</artifactId>
<version>VERSION</version>
<configuration>
<!--Configure severities that fail the build. Default is MUST, SHOULD -->
<failOn>MUST</failOn>
<!-- The input file to validate -->
<source>src/main/resources/openapi/api.yaml</source>
<!--Ignore certain rules. Default is none -->
<ignore>
146,174,134
</ignore>
<!-- Write the result of the validation to file. Optional-->
<resultFile>target/api_validation_result.yaml</resultFile>
</configuration>
<executions>
<execution>
<goals>
<goal>validate</goal>
</goals>
</execution>
</executions>
</plugin>