Albato · API Governance Rules
Albato API Rules
Spectral linting rules defining API design standards and conventions for Albato.
31 Rules
error 16
warn 15
Rule Categories
albato
no
path
query
schema
servers
Rules
error
albato-auth-apikey-required
Albato APIs must define API key authentication
$.components.securitySchemes
error
albato-global-security
Global security must be defined
$
error
albato-info-title
API must have a title
$.info
error
albato-info-description
API must have a description
$.info
error
albato-info-version
API must have a version
$.info
error
albato-path-lowercase
Paths must be lowercase
$.paths
error
albato-operation-id
Operations must have operationId
$.paths[*][get,post,put,patch,delete]
error
albato-operation-summary
Operations must have a summary
$.paths[*][get,post,put,patch,delete]
warn
albato-operation-description
Operations should have a description
$.paths[*][get,post,put,patch,delete]
error
albato-operation-tags
Operations must have tags
$.paths[*][get,post,put,patch,delete]
error
albato-response-200-get
GET operations must return 200
$.paths[*].get.responses
warn
albato-response-201-post
POST operations should return 201
$.paths[*].post.responses
warn
albato-response-401
Operations should document 401
$.paths[*].get.responses
error
albato-response-json
Responses must use application/json
$.paths[*][get,post,put].responses[200,201].content
warn
albato-schema-description
Schemas must have descriptions
$.components.schemas[*]
error
albato-property-type
Properties must have types
$.components.schemas[*].properties[*]
warn
albato-parameter-description
Parameters should have descriptions
$.paths[*][*].parameters[*]
error
albato-path-param-schema
Path parameters must have schemas
$.paths[*][*].parameters[?(@.in=='path')]
warn
albato-operation-id-camel-case
operationId must use camelCase
$.paths[*][*].operationId
warn
albato-schema-pascal-case
Schema names must use PascalCase
$.components.schemas
error
albato-request-body-json
Request bodies must use application/json
$.paths[*][post,put,patch].requestBody.content
warn
albato-request-body-required
POST request bodies should be required
$.paths[*].post.requestBody
error
albato-servers-defined
API must define servers
$
warn
albato-tags-at-root
Tags must be documented at root
$
error
servers-https-only
Server URLs must use HTTPS.
$.servers[*].url
warn
servers-expected-domain
Server URLs should be on the albato.com 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
query-params-casing
Query parameters should be snake_case (the dominant convention in this API).
$.paths[*][get,post,put,patch,delete].parameters[?(@.in=='query')]
warn
schema-names-casing
Component schema names should be PascalCase (the dominant convention in this API).
$.components.schemas
warn
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