Rackspace Technology · API Governance Rules
Rackspace Technology API Rules
Spectral linting rules defining API design standards and conventions for Rackspace Technology.
34 Rules
error 16
warn 16
Rule Categories
rackspace
Rules
error
rackspace-info-title
API title should begin with "Rackspace ".
$.info
error
rackspace-info-description-required
API description must be present and substantive (>= 80 chars).
$.info
error
rackspace-info-version-required
API version is required.
$.info
warn
rackspace-info-contact-required
Contact information should be provided.
$.info
warn
rackspace-info-license-required
License should be provided (Apache 2.0 is standard for Rackspace OSS).
$.info
error
rackspace-openapi-version
Use OpenAPI 3.0.x.
$
error
rackspace-servers-defined
At least one server must be defined.
$
error
rackspace-servers-https
All server URLs must use HTTPS.
$.servers[*]
warn
rackspace-servers-rackspacecloud
Production servers should be hosted under the rackspacecloud.com or rackspace.com domains.
$.servers[*]
error
rackspace-paths-no-trailing-slash
Paths must not end with a trailing slash.
$.paths
warn
rackspace-paths-kebab-or-lowercase
Path segments should be lowercase, kebab-case, or camelCase identifiers (no UPPER_SNAKE_CASE except curly-brace path params).
$.paths
error
rackspace-operation-id-required
Every operation must have an operationId.
$.paths[*][get,post,put,patch,delete,options,head]
error
rackspace-operation-id-camelcase
operationId must use camelCase (verb prefix preferred — get/list/show/create/update/delete/add).
$.paths[*][get,post,put,patch,delete,options,head]
error
rackspace-operation-summary-required
Every operation must have a summary.
$.paths[*][get,post,put,patch,delete,options,head]
warn
rackspace-operation-summary-title-case
Operation summaries should use Title Case (each major word capitalized).
$.paths[*][get,post,put,patch,delete,options,head]
warn
rackspace-operation-description-required
Every operation must have a description.
$.paths[*][get,post,put,patch,delete,options,head]
error
rackspace-operation-tags-required
Every operation must have at least one tag.
$.paths[*][get,post,put,patch,delete,options,head]
warn
rackspace-tags-defined
Tags must be declared at the root level.
$
warn
rackspace-tags-pascal-case
Tag names should be PascalCase or Title Case (e.g. CustomerAccounts, Reverse DNS).
$.tags[*]
warn
rackspace-parameter-description-required
All parameters must have a description.
$..parameters[?(@.in)]
error
rackspace-parameter-schema-required
All parameters must have a schema.
$..parameters[?(@.in)]
warn
rackspace-parameter-camelcase
Parameter names should be camelCase (Rackspace convention).
$..parameters[?(@.in == 'query' || @.in == 'header')]
hint
rackspace-pagination-limit-offset
Pagination should use limit + offset (Cloud DNS, Identity) or limit + marker (Offer API).
$.paths[*][get].parameters[?(@.in == 'query')]
error
rackspace-response-description-required
Every response object must have a description.
$.paths[*][*].responses[*]
error
rackspace-response-success-required
Every operation must declare a 2xx success response.
$.paths[*][get,post,put,patch,delete]
warn
rackspace-response-error-401
Tenant-scoped operations should declare a 401 Unauthorized response.
$.paths[?(@property.match(/\\{account\\}|\\{tenantId\\}/))][get,post,put,patch,delete].responses
warn
rackspace-response-async-job-202
Mutating Cloud DNS operations should return 202 Accepted (async job pattern).
$.paths[?(@property.match(/dns|domains/))][post,put,delete].responses
warn
rackspace-schema-property-camelcase
JSON properties should be camelCase (Rackspace Java/Jackson convention).
$.components.schemas[*].properties
warn
rackspace-schema-types-defined
Schema properties must declare a type or $ref.
$.components.schemas[*].properties[*]
error
rackspace-security-global
Global security must be defined.
$
warn
rackspace-security-x-auth-token
Rackspace APIs use the X-Auth-Token header (Cloud Identity-issued bearer token).
$.components.securitySchemes[*]
error
rackspace-get-no-request-body
GET operations must not have a requestBody.
$.paths[*].get
warn
rackspace-delete-no-request-body
DELETE operations should not have a requestBody (use query parameters).
$.paths[*].delete
hint
rackspace-microcks-extension
Operations should include x-microcks-operation for mock dispatching.
$.paths[*][get,post,put,patch,delete]