VTEX · API Governance Rules

VTEX API Rules

Spectral linting rules defining API design standards and conventions for VTEX.

10 Rules warn 5 info 5
View Rules File View on GitHub

Rule Categories

vtex

Rules

warn
vtex-operation-summary-title-case
Operation summaries must use Title Case.
$.paths[*][*].summary
info
vtex-operation-id-kebab-case
operationId should use kebab-case or camelCase consistently.
$.paths[*][*].operationId
warn
vtex-has-tags
Every operation must have at least one tag for grouping.
$.paths[*][*]
info
vtex-server-variable-account-name
VTEX APIs should use {accountName} server variable for multi-tenancy.
$.servers[*].variables
warn
vtex-response-200-defined
Every GET operation should define a 200 response.
$.paths[*].get.responses
warn
vtex-request-body-post
POST operations should define a request body.
$.paths[*].post
warn
vtex-security-defined
VTEX APIs should define security schemes for authentication.
$.components.securitySchemes
info
vtex-info-contact
API info should include contact information.
$.info
info
vtex-path-kebab-case
Path segments should use kebab-case or camelCase, not underscores.
$.paths
info
vtex-no-empty-descriptions
Operations should have non-empty descriptions.
$.paths[*][*].description

Spectral Ruleset

Raw ↑
extends: spectral:oas
rules:
  # VTEX-specific naming conventions
  vtex-operation-summary-title-case:
    description: Operation summaries must use Title Case.
    message: "Summary '{{value}}' should use Title Case."
    severity: warn
    given: "$.paths[*][*].summary"
    then:
      function: pattern
      functionOptions:
        match: "^[A-Z]"

  vtex-operation-id-kebab-case:
    description: operationId should use kebab-case or camelCase consistently.
    severity: info
    given: "$.paths[*][*].operationId"
    then:
      function: truthy

  vtex-has-tags:
    description: Every operation must have at least one tag for grouping.
    message: "Operation '{{path}}' must have at least one tag."
    severity: warn
    given: "$.paths[*][*]"
    then:
      field: tags
      function: truthy

  vtex-server-variable-account-name:
    description: VTEX APIs should use {accountName} server variable for multi-tenancy.
    severity: info
    given: "$.servers[*].variables"
    then:
      field: accountName
      function: truthy

  vtex-response-200-defined:
    description: Every GET operation should define a 200 response.
    severity: warn
    given: "$.paths[*].get.responses"
    then:
      field: "200"
      function: truthy

  vtex-request-body-post:
    description: POST operations should define a request body.
    severity: warn
    given: "$.paths[*].post"
    then:
      field: requestBody
      function: truthy

  vtex-security-defined:
    description: VTEX APIs should define security schemes for authentication.
    severity: warn
    given: "$.components.securitySchemes"
    then:
      function: truthy

  vtex-info-contact:
    description: API info should include contact information.
    severity: info
    given: "$.info"
    then:
      field: contact
      function: truthy

  vtex-path-kebab-case:
    description: Path segments should use kebab-case or camelCase, not underscores.
    severity: info
    given: "$.paths"
    then:
      function: pattern
      functionOptions:
        notMatch: "^.*_[a-z].*$"

  vtex-no-empty-descriptions:
    description: Operations should have non-empty descriptions.
    severity: info
    given: "$.paths[*][*].description"
    then:
      function: truthy

Work with this as data

Every ruleset here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for spectral rules

4 MCP tools reach this
  • find_rulesBrowse and filter every ruleset in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools

Call it yourself

curl for this page
This ruleset
curl "https://apis.io/api/v1/rules/vtex-rules"
All spectral rules
curl "https://apis.io/api/v1/rules?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no email required.

A second provider on the same verified email joins the account you already have.