Pure Storage · API Governance Rules
Pure Storage API Rules
Spectral linting rules defining API design standards and conventions for Pure Storage.
26 Rules
error 8
warn 14
info 4
Rule Categories
info
no
openapi
operation
parameter
paths
request
response
schema
security
servers
tag
tags
Rules
warn
info-title-pure-storage-prefix
API title should reflect the Pure Storage product family (e.g. "FlashArray REST API", "FlashBlade REST API", "Pure1 Public REST API").
$.info.title
error
info-description-required
API info.description must be present and non-trivial.
$.info
warn
info-version-semver-or-major-minor
API version should be either semver or major.minor (e.g. 2.52, 1.5).
$.info.version
error
openapi-version-3
Pure Storage specs are OpenAPI 3.0.x.
$.openapi
error
servers-defined
At least one server must be defined.
$
warn
paths-snake-case-segments
Path segments use snake_case (matches Pure Storage convention; e.g. /api/2.52/active-directory, /arrays/cloud-provider-tags).
$.paths.*~
warn
paths-version-prefix
Resource paths should be version-prefixed (e.g. /api/2.52/, /1.5/, /oauth2/1.0/).
$.paths.*~
error
paths-no-trailing-slash
Path entries must not have a trailing slash.
$.paths.*~
error
operation-summary-required
Every operation must have a summary.
$.paths.*[get,post,put,patch,delete,head,options]
warn
operation-summary-pure-storage-prefix
Operation summaries should begin with "Pure Storage" to clearly identify the provider.
$.paths.*[get,post,put,patch,delete,head,options].summary
error
operation-operationId-required
Every operation must have an operationId.
$.paths.*[get,post,put,patch,delete,head,options]
error
operation-tags-required
Every operation must include at least one tag.
$.paths.*[get,post,put,patch,delete,head,options]
warn
tags-defined-globally
Tags should be declared at the document root with descriptions (Pure Storage specs declare 50+ resource tags globally).
$
warn
tag-title-case
Tag names should use Title Case (e.g. "Active Directory", "Alert Watchers", "API Clients").
$.tags[*].name
warn
parameter-snake-case
Query and path parameter names should use snake_case (Pure Storage uses snake_case for filters, names, ids, etc.).
$.paths.*[get,post,put,patch,delete,head,options].parameters[?(@.in=='query' || @.in=='path')].name
warn
parameter-description-required
All parameters must have a description.
$.paths.*[get,post,put,patch,delete,head,options].parameters[*]
info
parameter-x-auth-token-header
When session-based auth is used, FA/FB exposes 'x-auth-token' as the auth header.
$.paths.*[get,post,put,patch,delete,head,options].parameters[?(@.in=='header' && @.name=='x-auth-token')]
error
response-success-required
Every operation must define at least one 2xx response.
$.paths.*[get,post,put,patch,delete,head,options].responses
info
response-400-recommended
Mutating operations should document a 400 Bad Request response.
$.paths.*[post,put,patch,delete].responses
warn
response-application-json
Responses should serve application/json.
$.paths.*[get,post,put,patch,delete].responses.*.content
warn
schema-property-snake-case
Schema property names should be snake_case (Pure Storage uses snake_case across FA/FB/Pure1 schemas).
$.components.schemas.*.properties.*~
info
schema-id-property-string
Object identifier 'id' should be a string (Pure Storage uses opaque string ids).
$.components.schemas.*.properties.id
info
schema-time-property-pattern
Time-valued properties should be named '*_time' or '*_at' (e.g. created, updated).
$.components.schemas.*.properties[?(@.format=='date-time')]~
warn
security-defined
Authentication mechanism should be documented (FA/FB use OAuth 2.0 token-exchange JWTs and a session 'x-auth-token' header; Pure1 uses OAuth 2.0 token exchange).
$
warn
request-body-application-json
Request bodies should accept application/json.
$.paths.*[post,put,patch].requestBody.content
warn
no-empty-description
Descriptions, when present, must not be empty strings.
$..description