Document FinOps Budget Non Negative

document-finops-budget-non-negative

info experience: data-modeling spec: document

budget should be a non-negative number.

budget should be a non-negative number.

Rule definition

The full Spotlight rule — drop it into a ruleset (.spotlight.yaml / .spectral.yaml) and run it with any Spotlight tool.

document-finops-budget-non-negative:
  title: Document FinOps Budget Non Negative
  reference: https://spotlight-rules.com/spec/rules/finops/document-finops-budget-non-negative/
  description: budget should be a non-negative number.
  message: budget should be a non-negative number.
  given: $.budget
  severity: info
  then:
    function: schema
    functionOptions:
      schema:
        type:
          - number
          - integer
        minimum: 0
  tags:
    - format:finops
    - spec:document
    - experience:data-modeling
  prompt: "You are editing a FinOps document to satisfy the Spotlight API
    governance rule 'document-finops-budget-non-negative' (Document FinOps
    Budget Non Negative). Requirement: budget should be a non-negative number.
    To fix: Adjust the targeted value so it conforms to the schema this rule
    requires. This rule is evaluated at the JSONPath `$.budget` — inspect every
    location it matches and correct only what violates the rule. Make the
    smallest change that satisfies the rule, leave all unrelated content, key
    order, comments, and formatting unchanged, and keep the document valid
    FinOps. Return only the complete corrected document, with no commentary."
AI fix prompt — send this to Claude, Gemini, or ChatGPT with your artifact to auto-fix this rule
You are editing a FinOps document to satisfy the Spotlight API governance rule 'document-finops-budget-non-negative' (Document FinOps Budget Non Negative). Requirement: budget should be a non-negative number. To fix: Adjust the targeted value so it conforms to the schema this rule requires. This rule is evaluated at the JSONPath `$.budget` — inspect every location it matches and correct only what violates the rule. Make the smallest change that satisfies the rule, leave all unrelated content, key order, comments, and formatting unchanged, and keep the document valid FinOps. Return only the complete corrected document, with no commentary.
ArtifactFinOps
Applies at (given)$.budget
Severityinfo — educational by default; raise to warn/error to enforce
Referencehttps://spotlight-rules.com/spec/rules/finops/document-finops-budget-non-negative/