Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tools/spectral/ipa/rulesets/IPA-005.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ rules:
xgen-IPA-005-exception-extension-format:
description: 'IPA exception extensions must follow the correct format. http://go/ipa/5'
message: '{{error}} http://go/ipa/5'
severity: warn
severity: error
given: '$..x-xgen-IPA-exception'
then:
function: 'exceptionExtensionFormat'
2 changes: 1 addition & 1 deletion tools/spectral/ipa/rulesets/IPA-102.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ rules:
xgen-IPA-102-path-alternate-resource-name-path-param:
description: 'Paths should alternate between resource names and path params. http://go/ipa/102'
message: '{{error}} http://go/ipa/102'
severity: warn
severity: error
given: '$.paths'
then:
field: '@key'
Expand Down
4 changes: 2 additions & 2 deletions tools/spectral/ipa/rulesets/IPA-109.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@ rules:
xgen-IPA-109-custom-method-must-be-GET-or-POST:
description: 'The HTTP method for custom methods must be GET or POST. http://go/ipa/109'
message: '{{error}} http://go/ipa/109'
severity: warn
severity: error
given: '$.paths[*]'
then:
function: 'eachCustomMethodMustBeGetOrPost'

xgen-IPA-109-custom-method-must-use-camel-case:
description: 'The custom method must use camelCase format. http://go/ipa/109'
message: '{{error}} http://go/ipa/109'
severity: warn
severity: error
given: '$.paths[*]'
then:
function: 'eachCustomMethodMustUseCamelCase'
2 changes: 1 addition & 1 deletion tools/spectral/ipa/rulesets/IPA-123.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ rules:
xgen-IPA-123-enum-values-must-be-upper-snake-case:
description: 'Enum values must be UPPER_SNAKE_CASE. http://go/ipa/123'
message: '{{error}} http://go/ipa/123'
severity: warn
severity: error
given: '$..enum'
then:
function: 'eachEnumValueMustBeUpperSnakeCase'
10 changes: 5 additions & 5 deletions tools/spectral/ipa/rulesets/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ For rule definitions, see [IPA-005.yaml](https://github.com/mongodb/openapi/blob

| Rule Name | Description | Severity |
| --------------------------------------- | ------------------------------------------------------------------------ | -------- |
| xgen-IPA-005-exception-extension-format | IPA exception extensions must follow the correct format. http://go/ipa/5 | warn |
| xgen-IPA-005-exception-extension-format | IPA exception extensions must follow the correct format. http://go/ipa/5 | error |

### IPA-102

For rule definitions, see [IPA-102.yaml](https://github.com/mongodb/openapi/blob/main/tools/spectral/ipa/rulesets/IPA-102.yaml).

| Rule Name | Description | Severity |
| ---------------------------------------------------- | -------------------------------------------------------------------------------- | -------- |
| xgen-IPA-102-path-alternate-resource-name-path-param | Paths should alternate between resource names and path params. http://go/ipa/102 | warn |
| xgen-IPA-102-path-alternate-resource-name-path-param | Paths should alternate between resource names and path params. http://go/ipa/102 | error |

### IPA-104

Expand All @@ -48,8 +48,8 @@ For rule definitions, see [IPA-109.yaml](https://github.com/mongodb/openapi/blob

| Rule Name | Description | Severity |
| ---------------------------------------------- | ------------------------------------------------------------------------- | -------- |
| xgen-IPA-109-custom-method-must-be-GET-or-POST | The HTTP method for custom methods must be GET or POST. http://go/ipa/109 | warn |
| xgen-IPA-109-custom-method-must-use-camel-case | The custom method must use camelCase format. http://go/ipa/109 | warn |
| xgen-IPA-109-custom-method-must-be-GET-or-POST | The HTTP method for custom methods must be GET or POST. http://go/ipa/109 | error |
| xgen-IPA-109-custom-method-must-use-camel-case | The custom method must use camelCase format. http://go/ipa/109 | error |

### IPA-113

Expand All @@ -65,6 +65,6 @@ For rule definitions, see [IPA-123.yaml](https://github.com/mongodb/openapi/blob

| Rule Name | Description | Severity |
| ------------------------------------------------- | ------------------------------------------------------- | -------- |
| xgen-IPA-123-enum-values-must-be-upper-snake-case | Enum values must be UPPER_SNAKE_CASE. http://go/ipa/123 | warn |
| xgen-IPA-123-enum-values-must-be-upper-snake-case | Enum values must be UPPER_SNAKE_CASE. http://go/ipa/123 | error |


Loading