Vendure · API Governance Rules
Vendure API Rules
Spectral linting rules defining API design standards and conventions for Vendure.
9 Rules
error 2
warn 6
info 1
Rule Categories
vendure
Rules
warn
vendure-info-license-gpl
License must reference GPL-3.0 (Vendure Core license).
$.info.license
info
vendure-info-contact-docs
Contact URL should point to docs.vendure.io.
$.info.contact
error
vendure-graphql-endpoint-uses-post
GraphQL endpoints must only expose POST.
$.paths[?(@property == '/' || @property == '/shop-api' || @property == '/admin-api')]
warn
vendure-operation-summary-title-case
Operation summaries must use Title Case.
$.paths[*][*].summary
error
vendure-operation-has-operation-id
Every operation must have an operationId.
$.paths[*][*]
warn
vendure-channel-token-header-name
When a parameter selects a channel token, the header must be named `vendure-token`.
$..parameters[?(@.in == 'header' && @.description && @.description.match(/channel/i))]
warn
vendure-asset-server-route-prefix
Asset Server paths must live under `/assets` or `/assets/preview`.
$.paths
warn
vendure-error-response-shape
4xx responses should include a description.
$.paths[*][*].responses[?(@property.match(/^4\d\d$/))]
warn
vendure-tags-defined
Each operation should have at least one tag.
$.paths[*][*]