Trellix · API Governance Rules
Trellix API Rules
Spectral linting rules defining API design standards and conventions for Trellix.
17 Rules
error 3
warn 12
info 2
Rule Categories
no
operation
path
query
schema
servers
trellix
Rules
warn
trellix-operation-id-camel-case
Operation IDs must use camelCase
$.paths[*][*].operationId
warn
trellix-summary-title-case
Operation summaries must use Title Case
$.paths[*][*].summary
error
trellix-security-defined
All operations must define security requirements
$.paths[*][get,post,put,patch,delete]
error
trellix-response-200-get
All GET operations must define a 200 response
$.paths[*].get
warn
trellix-response-401-defined
Authenticated operations should define a 401 response
$.paths[*][get,post,put,patch,delete]
warn
trellix-tag-defined
All operations must have at least one tag
$.paths[*][get,post,put,patch,delete]
info
trellix-oauth2-bearer
Trellix APIs use OAuth 2.0 Bearer token authentication
$.components.securitySchemes
warn
trellix-path-kebab-case
API paths should use kebab-case
$.paths[*]~
warn
trellix-post-request-body
POST and PUT operations should define a request body
$.paths[*][post,put]
error
servers-https-only
Server URLs must use HTTPS.
$.servers[*].url
warn
servers-expected-domain
Server URLs should be on the trellix.com domain.
$.servers[*].url
warn
path-params-casing
Path parameters should be camelCase (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
info
schema-properties-casing
Schema properties should be snake_case (the dominant convention in this API).
$.components.schemas[*].properties
warn
operation-documents-401
Operations should document a 401 response (documented on 100% of this API's operations).
$.paths[*][get,post,put,patch,delete].responses
warn
no-empty-descriptions
Descriptions must not be empty strings.
$..description