agrio · API Governance Rules
agrio API Rules
Spectral linting rules defining API design standards and conventions for agrio.
21 Rules
error 9
warn 11
info 1
Rule Categories
get
info
no
operation
paths
response
schema
security
servers
Rules
error
info-title-required
OpenAPI info must have a title.
$.info
warn
info-title-prefix
API title should start with "Agrio".
$.info.title
warn
info-description-required
OpenAPI info must have a description.
$.info
error
info-version-required
OpenAPI info must have a version.
$.info
error
servers-defined
At least one server must be defined.
$
error
servers-https-required
Server URLs must use HTTPS.
$.servers[*].url
warn
paths-kebab-case
Path segments should use kebab-case.
$.paths[*]~
info
paths-versioned
Paths should include a version prefix (e.g., /v1/).
$.paths[*]~
error
operation-summary-required
Every operation must have a summary.
$.paths[*][get,post,put,patch,delete]
warn
operation-summary-prefix
Operation summaries should start with "Agrio".
$.paths[*][get,post,put,patch,delete].summary
warn
operation-description-required
Every operation must have a description.
$.paths[*][get,post,put,patch,delete]
error
operation-id-required
Every operation must have an operationId.
$.paths[*][get,post,put,patch,delete]
warn
operation-tags-required
Every operation must have at least one tag.
$.paths[*][get,post,put,patch,delete]
error
response-success-required
Every operation must define at least one 2xx response.
$.paths[*][get,post,put,patch,delete].responses
warn
response-401-defined
Protected operations should define a 401 response.
$.paths[*][get,post,put,patch,delete].responses
warn
response-description-required
Every response must have a description.
$.paths[*][get,post,put,patch,delete].responses[*]
warn
schema-description-required
Top-level component schemas should have a description.
$.components.schemas[*]
error
security-schemes-defined
Security schemes must be defined.
$.components
warn
security-bearer-used
APIs should use Bearer token authentication.
$.components.securitySchemes[*]
error
get-no-request-body
GET operations must not have a request body.
$.paths[*].get
warn
no-empty-descriptions
Descriptions must not be empty strings.
$..description