R · API Governance Rules
R API Rules
Spectral linting rules defining API design standards and conventions for R.
13 Rules
error 2
warn 10
info 1
Rule Categories
no
path
r
schema
servers
Rules
warn
r-operation-summary-title-case
All operation summaries must use Title Case
$.paths[*][*].summary
warn
r-tags-title-case
All tags must use Title Case
$.paths[*][*].tags[*]
warn
r-operation-ids-must-be-camel-case
Operation IDs must use camelCase
$.paths[*][*].operationId
warn
r-paths-kebab-case
Path segments must use kebab-case
$.paths[*]~
error
r-responses-must-include-success
All operations must define at least one 2xx response
$.paths[*][get,post,put,patch,delete]
warn
r-parameters-must-have-descriptions
All parameters must have descriptions
$.paths[*][*].parameters[*]
warn
r-components-schemas-pascal-case
Schema component names must use PascalCase
$.components.schemas[*]~
error
servers-https-only
Server URLs must use HTTPS.
$.servers[*].url
warn
servers-expected-domain
Server URLs should be on the r-pkg.org domain.
$.servers[*].url
warn
path-params-casing
Path parameters should be snake_case (the dominant convention in this API).
$.paths[*].parameters[?(@.in=='path')].name
warn
schema-names-casing
Component schema names should be PascalCase (the dominant convention in this API).
$.components.schemas
info
schema-properties-casing
Schema properties should be snake_case (the dominant convention in this API).
$.components.schemas[*].properties
warn
no-empty-descriptions
Descriptions must not be empty strings.
$..description