-
Notifications
You must be signed in to change notification settings - Fork 3
/
nerm-path-ruleset.yaml
71 lines (71 loc) · 2.12 KB
/
nerm-path-ruleset.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
functions:
[
parameter-example-check,
word-count,
deprecation,
path-parameter-integer-number-formats,
response-validator,
path-query-parameter-check,
path-descriptions-check,
path-oauth-scope-check,
path-operation-check
]
rules:
path-parameters-must-have-description:
description: "Rule 303: Path/Query parameters must have a description: https://sailpoint-oss.github.io/sailpoint-api-guidelines/#303"
given: $.*.parameters.*
severity: error
then:
field: description
function: truthy
path-parameters-must-have-a-lengthy-description:
description: "Rule 303: The description of parameters must be at least 8 characters: https://sailpoint-oss.github.io/sailpoint-api-guidelines/#303"
type: style
given: $.*.parameters.*
severity: error
then:
field: description
function: length
functionOptions:
min: 8
path-parameters-must-have-example:
message: "{{error}}: https://sailpoint-oss.github.io/sailpoint-api-guidelines/#304"
given: $.*.parameters.*
severity: error
then:
function: parameter-example-check
functionOptions:
rule: 304
path-parameters-must-have-valid-formats-for-numbers-and-integers:
message: "{{error}}: https://sailpoint-oss.github.io/sailpoint-api-guidelines/#171"
given: $.*.parameters.*
severity: error
then:
function: path-parameter-integer-number-formats
functionOptions:
rule: 171
path-summary-length:
message: "{{error}}: https://sailpoint-oss.github.io/sailpoint-api-guidelines/#305"
given: $.*.summary
severity: warn
then:
function: word-count
functionOptions:
maxWordCount: 5
rule: 305
path-description-html-chars:
message: "{{error}}"
given: $.*.description
severity: error
then:
function: path-descriptions-check
functionOptions:
rule: 405
path-operation-check:
message: "{{error}}: https://sailpoint-oss.github.io/sailpoint-api-guidelines/#400"
given: $
severity: error
then:
function: path-operation-check
functionOptions:
rule: 400