extends: spectral:oas rules: vnc-operation-summary-title-case: description: All operation summaries must use Title Case. severity: warn given: "$.paths[*][*].summary" then: function: pattern functionOptions: match: "^([A-Z][a-z]*(\\s[A-Z][a-z]*)*)" vnc-path-kebab-case: description: Path segments must use kebab-case. severity: warn given: "$.paths" then: function: pattern functionOptions: match: "^(\\/[a-z0-9{}-]+)+$" vnc-operation-ids-camel-case: description: OperationIds must use camelCase. severity: warn given: "$.paths[*][*].operationId" then: function: pattern functionOptions: match: "^[a-z][a-zA-Z0-9]*$" vnc-tags-required: description: Each operation must have at least one tag. severity: error given: "$.paths[*][*]" then: field: tags function: truthy vnc-error-response-schema: description: Error responses (4xx/5xx) must reference the Error schema. severity: warn given: "$.paths[*][*].responses[4,5][0-9][0-9]" then: field: content function: truthy vnc-api-version-in-server: description: Server URLs must include an API version path segment. severity: warn given: "$.servers[*].url" then: function: pattern functionOptions: match: ".*\\/[0-9]+\\.[0-9]+.*" vnc-basic-auth-security: description: The API must declare Basic authentication as a security scheme. severity: error given: "$.components.securitySchemes" then: function: truthy vnc-pagination-limit-parameter: description: List operations should support a limit query parameter for pagination. severity: info given: "$.paths[*].get.parameters[?(@.name == 'limit')]" then: field: schema.type function: enumeration functionOptions: values: - integer