serverless-openapi-documenter 0.0.110 → 0.0.111
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -7
- package/package.json +1 -1
- package/src/definitionGenerator.js +1 -1
- package/test/helpers/redocly.json +1 -1
package/README.md
CHANGED
|
@@ -1009,18 +1009,18 @@ I am making use of https://www.npmjs.com/package/@redocly/openapi-core, which I
|
|
|
1009
1009
|
|
|
1010
1010
|
I have configured the validator to use these Rules:
|
|
1011
1011
|
|
|
1012
|
-
- [
|
|
1013
|
-
- [path-parameters-defined](https://redocly.com/docs/cli/rules/path-parameters-defined
|
|
1014
|
-
- [operation-2xx-response](https://redocly.com/docs/cli/rules/operation-2xx-response
|
|
1015
|
-
- [operation-4xx-response](https://redocly.com/docs/cli/rules/operation-4xx-response
|
|
1016
|
-
- [operation-operationId-unique](https://redocly.com/docs/cli/rules/operation-
|
|
1017
|
-
- [path-declaration-must-exist](https://redocly.com/docs/cli/rules/path-declaration-must-exist
|
|
1012
|
+
- [struct](https://redocly.com/docs/cli/rules/oas/struct)
|
|
1013
|
+
- [path-parameters-defined](https://redocly.com/docs/cli/rules/oas/path-parameters-defined)
|
|
1014
|
+
- [operation-2xx-response](https://redocly.com/docs/cli/rules/oas/operation-2xx-response)
|
|
1015
|
+
- [operation-4xx-response](https://redocly.com/docs/cli/rules/oas/operation-4xx-response)
|
|
1016
|
+
- [operation-operationId-unique](https://redocly.com/docs/cli/rules/oas/operation-operationId-unique)
|
|
1017
|
+
- [path-declaration-must-exist](https://redocly.com/docs/cli/rules/oas/path-declaration-must-exist)
|
|
1018
1018
|
|
|
1019
1019
|
However, you can configure your own rules from the [ruleset available on the Redocly site](https://redocly.com/docs/cli/rules/built-in-rules/). To do this, you will need to create a `redocly.json` file within an `options` folder. The file should look like:
|
|
1020
1020
|
|
|
1021
1021
|
```json
|
|
1022
1022
|
{
|
|
1023
|
-
"
|
|
1023
|
+
"struct": "error",
|
|
1024
1024
|
"path-parameters-defined": "error",
|
|
1025
1025
|
"operation-2xx-response": "error",
|
|
1026
1026
|
"operation-4xx-response": "error",
|
package/package.json
CHANGED
|
@@ -81,7 +81,7 @@ class DefinitionGenerator {
|
|
|
81
81
|
this.REDOCLY_RULES = require(path.resolve("options", "redocly.json"));
|
|
82
82
|
} catch (err) {
|
|
83
83
|
this.REDOCLY_RULES = {
|
|
84
|
-
|
|
84
|
+
struct: "error",
|
|
85
85
|
"path-parameters-defined": "error",
|
|
86
86
|
"operation-2xx-response": "error",
|
|
87
87
|
"operation-4xx-response": "error",
|