forked from goharbor/harbor
-
Notifications
You must be signed in to change notification settings - Fork 7
/
.spectral.yaml
41 lines (35 loc) · 928 Bytes
/
.spectral.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
extends: [[spectral:oas, all]]
functionsDir: "./tools/spectral/functions"
functions: [requireRequestId]
rules:
info-contact: false
info-license: false
license-url: false
no-$ref-siblings: false
oas2-valid-definition-example: false
oas2-valid-response-schema-example: false
openapi-tags: false
operation-default-response: false
operation-tag-defined: false
required-operationId:
description: must have a operationId.
given: $.paths[*][*]
severity: error
then:
field: operationId
function: truthy
camel-case-operationId:
description: should be camelCased.
type: style
given: $.paths[*][*].operationId
then:
function: casing
functionOptions:
type: camel
requestId-required:
description: must have a requestId paramaters.
given: $.paths[*][*]
severity: error
then:
field: parameters
function: requireRequestId