{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://torneo.ai/schemas/cost_ledger.v1",
  "title": "cost_ledger.v1",
  "description": "P-11: 0 USD marginal over at least 30 days, allocated cost published. Shape of the fields check_finalite reads; extra evidence fields are allowed. Dated, not synthetic and bound by sha256 to files of the repository (receipts/gates/<schema>/*.json).",
  "type": "object",
  "required": [
    "schema",
    "synthetic",
    "observed_on",
    "marginal_usd",
    "days",
    "allocated_cost_published"
  ],
  "properties": {
    "schema": {
      "const": "cost_ledger.v1"
    },
    "synthetic": {
      "type": "boolean",
      "description": "Only false counts (gate_common.read_receipts)."
    },
    "observed_on": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}"
    },
    "marginal_usd": {
      "type": "number",
      "minimum": 0
    },
    "days": {
      "type": "number",
      "minimum": 0
    },
    "allocated_cost_published": {
      "type": "boolean"
    }
  }
}
