Baker Hughes · API Governance Rules
Baker Hughes API Rules
Spectral linting rules defining API design standards and conventions for Baker Hughes.
15 Rules
error 3
warn 10
info 2
Rule Categories
baker
Rules
warn
baker-hughes-info-contact-required
Baker Hughes APIs must include contact information.
$.info
warn
baker-hughes-info-version-semver
API version must follow semantic versioning.
$.info.version
warn
baker-hughes-path-kebab-case
Path segments must use kebab-case.
$.paths[*]~
info
baker-hughes-path-asset-id-param
Asset resource paths should use assetId as the path parameter.
$.paths[*]~
error
baker-hughes-operation-id-required
All operations must have an operationId.
$.paths[*][get,post,put,patch,delete,options,head]
warn
baker-hughes-operation-summary-required
All operations must have a summary.
$.paths[*][get,post,put,patch,delete]
warn
baker-hughes-operation-tags-required
All operations must have at least one tag.
$.paths[*][get,post,put,patch,delete]
error
baker-hughes-security-required
All Baker Hughes APIs must define security schemes.
$
warn
baker-hughes-oauth2-required
Baker Hughes APIs should use OAuth2 for authentication.
$.components.securitySchemes[*]
error
baker-hughes-response-200-required
GET operations must define a 200 response.
$.paths[*].get.responses
warn
baker-hughes-response-error-schemas
Error responses must reference a schema.
$.paths[*][*].responses[4XX,5XX].content[*]
warn
baker-hughes-schema-description-required
All named schemas must have a description.
$.components.schemas[*]
info
baker-hughes-schema-properties-descriptions
Schema properties should have descriptions.
$.components.schemas[*].properties[*]
warn
baker-hughes-parameter-description-required
All parameters must have descriptions.
$.paths[*][*].parameters[*]
warn
baker-hughes-tags-description-required
Global tags must have descriptions.
$.tags[*]