openapi-toolkit:bundle
Full name:
net.mwalser:openapi-toolkit-maven-plugin:0.2.0:bundle
Description:
Bundles each API description into a single file (redocly bundle): resolves $refs to other files and applies the decorators configured in redocly.yaml.
Attributes:
- Requires a Maven project to be executed.
- The goal is thread-safe and supports parallel builds.
- Binds by default to the lifecycle phase:
generate-resources.
Optional Parameters
| Name | Type | Since | Description |
|---|---|---|---|
<addResource> |
boolean |
- |
Add the bundles as project resources, packaged under their file names at the root of the JAR or under resourceTargetPath. The goal must run before process-resources, which copies resources into the JAR.Default: falseUser Property: openapi.toolkit.bundle.addResource |
<apis> |
List<String> |
- |
The API descriptions to process: aliases from the apis section of the configuration file, paths relative to the project base directory, or URLs. Empty: every API in the configuration file. Without a configuration file, paths or URLs are required and Redocly's built-in recommended ruleset applies.User Property: openapi.toolkit.apis |
<attach> |
boolean |
- |
Attach each bundle as a build artifact other modules can depend on: type is the output extension, classifier is the alias, or classifier for inputs without one. Aliases must be distinct per type.Default: falseUser Property: openapi.toolkit.bundle.attach |
<classifier> |
String |
- |
Classifier of attached bundles whose input has no alias. Default: openapiUser Property: openapi.toolkit.bundle.classifier |
<componentNamesStrategy> |
String |
- |
Naming of components pulled in from other files: basename (file name; Redocly's default when unset) or title (the schema's title).User Property: openapi.toolkit.bundle.componentNamesStrategy |
<componentRenamingConflicts> |
String |
- |
Severity of component name conflicts between files: warn (Redocly's default when unset), error or off.User Property: openapi.toolkit.bundle.componentRenamingConflicts |
<configFile> |
File |
- |
The Redocly configuration file. Unset: redocly.yaml in the project base directory if it exists, otherwise no configuration file.User Property: openapi.toolkit.configFile |
<dereferenced> |
boolean |
- |
Produce a fully dereferenced bundle (no $ref left).Default: falseUser Property: openapi.toolkit.bundle.dereferenced |
<ext> |
String |
- |
Output format and file extension: yaml, yml or json. Unset: the extension of outputFile, else the input's format (JSON stays JSON), else yaml.User Property: openapi.toolkit.bundle.ext |
<extendsRulesets> |
List<String> |
- |
Replaces the extends list of the configuration. Built-in rulesets: minimal, recommended, recommended-strict, spec.User Property: openapi.toolkit.extendsAlias: extends |
<force> |
boolean |
- |
Write the bundle even when errors were encountered. Default: falseUser Property: openapi.toolkit.bundle.force |
<keepUrlReferences> |
boolean |
- |
Keep absolute URL $refs instead of inlining them.Default: falseUser Property: openapi.toolkit.bundle.keepUrlReferences |
<lintConfig> |
String |
- |
Severity of problems in the configuration file, which is linted before the goal runs: warn (reported, invalid entries are ignored), error (fails the build) or off.Default: warnUser Property: openapi.toolkit.lintConfig |
<maxProblems> |
int |
- |
Maximum number of problems printed to the build log, per API description and for the configuration file. Report files are not limited. Default: 100User Property: openapi.toolkit.maxProblems |
<outputDirectory> |
File |
- |
Directory the bundles are written to, named after the alias (APIs from the configuration file) or the file name (paths), with the output extension. Default: ${project.build.directory}/generated-resources/openapiUser Property: openapi.toolkit.bundle.outputDirectory |
<outputFile> |
File |
- |
File to write the bundle to instead of outputDirectory. Requires a single selected API.User Property: openapi.toolkit.bundle.outputFile |
<removeUnusedComponents> |
boolean |
- |
Remove components that are not referenced anywhere. Default: falseUser Property: openapi.toolkit.bundle.removeUnusedComponents |
<resourceTargetPath> |
String |
- |
Directory inside the JAR for addResource, relative to its root: META-INF/resources/openapi for bundles that Spring Boot, Quarkus and servlet containers serve as static files under /openapi/. Unset: the root of the JAR.User Property: openapi.toolkit.bundle.resourceTargetPath |
<skip> |
boolean |
- |
Skip execution. As the property openapi.toolkit.skip it skips every goal of the plugin; the goal-specific properties such as openapi.toolkit.lint.skip skip one goal.Default: falseUser Property: openapi.toolkit.skip |
<skipBundle> |
boolean |
- |
Skip this goal only; openapi.toolkit.skip skips every goal of the plugin.Default: falseUser Property: openapi.toolkit.bundle.skip |
<skipDecorators> |
List<String> |
- |
Decorators not to apply, by decorator id. User Property: openapi.toolkit.bundle.skipDecorators |
Parameter Details
<addResource>
Add the bundles as project resources, packaged under their file names at the root of the JAR or under
resourceTargetPath. The goal must run before process-resources, which copies resources into the JAR.- Type:
boolean - Required:
No - User Property:
openapi.toolkit.bundle.addResource - Default:
false
<apis>
The API descriptions to process: aliases from the
apis section of the configuration file, paths relative to the project base directory, or URLs. Empty: every API in the configuration file. Without a configuration file, paths or URLs are required and Redocly's built-in recommended ruleset applies.- Type:
java.util.List<java.lang.String> - Required:
No - User Property:
openapi.toolkit.apis
<attach>
Attach each bundle as a build artifact other modules can depend on: type is the output extension, classifier is the alias, or
classifier for inputs without one. Aliases must be distinct per type.- Type:
boolean - Required:
No - User Property:
openapi.toolkit.bundle.attach - Default:
false
<classifier>
Classifier of attached bundles whose input has no alias.
- Type:
java.lang.String - Required:
No - User Property:
openapi.toolkit.bundle.classifier - Default:
openapi
<componentNamesStrategy>
Naming of components pulled in from other files:
basename (file name; Redocly's default when unset) or title (the schema's title).- Type:
java.lang.String - Required:
No - User Property:
openapi.toolkit.bundle.componentNamesStrategy
<componentRenamingConflicts>
Severity of component name conflicts between files:
warn (Redocly's default when unset), error or off.- Type:
java.lang.String - Required:
No - User Property:
openapi.toolkit.bundle.componentRenamingConflicts
<configFile>
The Redocly configuration file. Unset:
redocly.yaml in the project base directory if it exists, otherwise no configuration file.- Type:
java.io.File - Required:
No - User Property:
openapi.toolkit.configFile
<dereferenced>
Produce a fully dereferenced bundle (no
$ref left).- Type:
boolean - Required:
No - User Property:
openapi.toolkit.bundle.dereferenced - Default:
false
<ext>
Output format and file extension:
yaml, yml or json. Unset: the extension of outputFile, else the input's format (JSON stays JSON), else yaml.- Type:
java.lang.String - Required:
No - User Property:
openapi.toolkit.bundle.ext
<extendsRulesets>
Replaces the
extends list of the configuration. Built-in rulesets: minimal, recommended, recommended-strict, spec.- Type:
java.util.List<java.lang.String> - Required:
No - User Property:
openapi.toolkit.extends - Alias:
extends
<force>
Write the bundle even when errors were encountered.
- Type:
boolean - Required:
No - User Property:
openapi.toolkit.bundle.force - Default:
false
<keepUrlReferences>
Keep absolute URL
$refs instead of inlining them.- Type:
boolean - Required:
No - User Property:
openapi.toolkit.bundle.keepUrlReferences - Default:
false
<lintConfig>
Severity of problems in the configuration file, which is linted before the goal runs:
warn (reported, invalid entries are ignored), error (fails the build) or off.- Type:
java.lang.String - Required:
No - User Property:
openapi.toolkit.lintConfig - Default:
warn
<maxProblems>
Maximum number of problems printed to the build log, per API description and for the configuration file. Report files are not limited.
- Type:
int - Required:
No - User Property:
openapi.toolkit.maxProblems - Default:
100
<outputDirectory>
Directory the bundles are written to, named after the alias (APIs from the configuration file) or the file name (paths), with the output extension.
- Type:
java.io.File - Required:
No - User Property:
openapi.toolkit.bundle.outputDirectory - Default:
${project.build.directory}/generated-resources/openapi
<outputFile>
File to write the bundle to instead of
outputDirectory. Requires a single selected API.- Type:
java.io.File - Required:
No - User Property:
openapi.toolkit.bundle.outputFile
<removeUnusedComponents>
Remove components that are not referenced anywhere.
- Type:
boolean - Required:
No - User Property:
openapi.toolkit.bundle.removeUnusedComponents - Default:
false
<resourceTargetPath>
Directory inside the JAR for
addResource, relative to its root: META-INF/resources/openapi for bundles that Spring Boot, Quarkus and servlet containers serve as static files under /openapi/. Unset: the root of the JAR.- Type:
java.lang.String - Required:
No - User Property:
openapi.toolkit.bundle.resourceTargetPath
<skip>
Skip execution. As the property
openapi.toolkit.skip it skips every goal of the plugin; the goal-specific properties such as openapi.toolkit.lint.skip skip one goal.- Type:
boolean - Required:
No - User Property:
openapi.toolkit.skip - Default:
false
<skipBundle>
Skip this goal only;
openapi.toolkit.skip skips every goal of the plugin.- Type:
boolean - Required:
No - User Property:
openapi.toolkit.bundle.skip - Default:
false
<skipDecorators>
Decorators not to apply, by decorator id.
- Type:
java.util.List<java.lang.String> - Required:
No - User Property:
openapi.toolkit.bundle.skipDecorators
