Revel Systems · API Governance Rules
Revel Systems API Rules
Spectral linting rules defining API design standards and conventions for Revel Systems.
34 Rules
error 8
warn 18
info 8
Authorship not recorded
No authorship marker is recorded for this file. It is not presented as the provider's; it was most likely written by an API Evangelist pass before outputs were stamped.
Rule Categories
get
info
openapi
operation
parameter
paths
request
response
schema
security
servers
tag
tags
write
Rules
warn
info-title-revel
API title should reference Revel.
$.info.title
warn
info-description-required
Info object must have a description of reasonable length.
$.info
error
info-version-required
Info object must declare a version.
$.info
info
info-contact-required
Provide contact information.
$.info
warn
openapi-version-3
Specs should target OpenAPI 3.0.x.
$.openapi
error
servers-defined
At least one server must be defined.
$.servers
error
servers-https
Server URLs must use HTTPS.
$.servers[*].url
warn
servers-description
Each server should have a description.
$.servers[*]
warn
paths-pascalcase-resource
Resource path segments use PascalCase (Tastypie resource names), e.g. /Order/.
$.paths[*]~
warn
paths-trailing-slash
Tastypie endpoints terminate with a trailing slash.
$.paths[*]~
error
paths-no-query-string
Path keys must not contain query strings.
$.paths[*]~
error
operation-summary-required
Every operation must have a summary.
$.paths[*][get,post,patch,put,delete]
warn
operation-description-required
Every operation must have a description.
$.paths[*][get,post,patch,put,delete]
error
operation-operationid-required
Every operation must have an operationId.
$.paths[*][get,post,patch,put,delete]
warn
operation-operationid-camelcase-verb
operationId is camelCase and begins with a CRUD verb.
$.paths[*][get,post,patch,put,delete].operationId
warn
operation-tags-required
Every operation must be tagged.
$.paths[*][get,post,patch,put,delete]
info
operation-microcks-extension
Operations should carry x-microcks-operation for mock-server compatibility.
$.paths[*][get,post,patch,put,delete]
warn
tags-global-defined
A global tags array should be declared.
$
warn
tag-title-case
Tag names use Title Case.
$.tags[*].name
info
tag-description
Each declared tag should have a description.
$.tags[*]
info
parameter-description-required
Parameters should have descriptions.
$.paths[*][*].parameters[*]
warn
parameter-snake-case
Query and path parameter names use snake_case (allowing Tastypie __ field lookups).
$.paths[*][*].parameters[?(@.in=='query' || @.in=='path')].name
info
parameter-pagination-names
Use limit/offset for pagination, not page/size.
$.paths[*][get].parameters[?(@.in=='query')].name
warn
request-body-json
Request bodies must offer application/json.
$.paths[*][post,patch,put].requestBody.content
error
response-2xx-required
Every operation must define at least one 2xx response.
$.paths[*][get,post,patch,put,delete].responses
info
response-401-defined
Authenticated operations should document a 401 response.
$.paths[*][get,post,patch,put,delete].responses
info
response-429-on-reads
List operations should document a 429 rate-limit response.
$.paths[*][get].responses
warn
schema-property-snake-case
Schema properties use snake_case.
$.components.schemas[*].properties[*]~
warn
schema-property-typed
Schema properties must declare a type or a $ref.
$.components.schemas[*].properties[*]
info
schema-resource-uri-present
Tastypie resources expose a resource_uri field.
$.components.schemas[?(@.properties && @.properties.id)].properties
warn
security-global-defined
A global security requirement must be declared.
$
warn
security-scheme-apikey-header
The API key security scheme is delivered via the API-AUTHENTICATION header.
$.components.securitySchemes[?(@.type=='apiKey')]
error
get-no-request-body
GET operations must not declare a request body.
$.paths[*].get
warn
write-has-request-body
POST/PUT/PATCH operations should declare a request body.
$.paths[*][post,put,patch]
Spectral Ruleset
Work with this as data
Every ruleset here is available over the APIs.io API and to AI agents over MCP.