Apache OpenNLP · API Governance Rules
Apache OpenNLP API Rules
Spectral linting rules defining API design standards and conventions for Apache OpenNLP.
16 Rules
error 5
warn 9
info 2
Rule Categories
error
info
no
operation
operationid
paths
request
response
schema
servers
Rules
error
info-title-required
API must have a title
$.info
warn
info-description-required
API must have a description
$.info
error
operation-summary-required
Operations must have summaries
$.paths[*][*]
error
operation-operationId-required
Operations must have operationIds
$.paths[*][*]
warn
operation-tags-required
Operations must have tags
$.paths[*][*]
info
operation-summary-apache-prefix
Summaries should start with Apache OpenNLP
$.paths[*][get,post,put,delete,patch].summary
warn
paths-kebab-case
Path segments should use kebab-case
$.paths[*]~
warn
request-body-content-type
Request bodies should use application/json
$.paths[*][post,put,patch].requestBody.content
error
response-success-required
Operations must have a 200 success response
$.paths[*][*].responses
warn
schema-type-defined
Schema properties should have types defined
$.components.schemas[*].properties[*]
error
servers-https-only
Server URLs must use HTTPS.
$.servers[*].url
warn
operationid-casing
Operation IDs should be camelCase (the dominant convention in this API).
$.paths[*][get,post,put,patch,delete].operationId
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
error-schema-defined
A shared error schema (ErrorResponse) should be defined for error payloads.
$.components.schemas
warn
no-empty-descriptions
Descriptions must not be empty strings.
$..description