Jito Labs · API Governance Rules

Jito Labs API Rules

Spectral linting rules defining API design standards and conventions for Jito Labs.

4 Rules error 1 warn 3
View Rules File View on GitHub

Rule Categories

jito

Rules

warn
jito-info-contact
Jito specs must declare a contact pointing to jito.network.
$.info.contact.url
warn
jito-operation-summary-title-case
Operation summaries must use Title Case.
$.paths.*.*.summary
error
jito-servers-require-block-engine
At least one server must point at mainnet.block-engine.jito.wtf.
$.servers
warn
jito-bundle-max-five
Any schema describing bundle transactions must cap at 5 items.
$..properties.transactions[?(@.type == 'array')]

Spectral Ruleset

Raw ↑
extends:
  - spectral:oas
rules:
  jito-info-contact:
    description: Jito specs must declare a contact pointing to jito.network.
    given: "$.info.contact.url"
    severity: warn
    then:
      function: pattern
      functionOptions:
        match: "jito"
  jito-operation-summary-title-case:
    description: Operation summaries must use Title Case.
    given: "$.paths.*.*.summary"
    severity: warn
    then:
      function: pattern
      functionOptions:
        match: "^[A-Z][A-Za-z0-9 ]+$"
  jito-servers-require-block-engine:
    description: At least one server must point at mainnet.block-engine.jito.wtf.
    given: "$.servers"
    severity: error
    then:
      function: schema
      functionOptions:
        schema:
          type: array
          contains:
            type: object
            properties:
              url:
                pattern: "block-engine.jito.wtf"
            required: ["url"]
  jito-bundle-max-five:
    description: Any schema describing bundle transactions must cap at 5 items.
    given: "$..properties.transactions[?(@.type == 'array')]"
    severity: warn
    then:
      field: maxItems
      function: truthy