{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "Workspace that owns this record."
    },
    "period": {
      "type": "string",
      "description": "period recorded for this result."
    },
    "plan": {
      "type": "string",
      "description": "plan recorded for this result."
    },
    "subscription_status": {
      "type": "string",
      "description": "subscription status recorded for this result."
    },
    "check_reservations": {
      "type": "object",
      "properties": {
        "reserved": {
          "type": "number",
          "description": "reserved recorded for this result."
        },
        "consumed": {
          "type": "number",
          "description": "consumed recorded for this result."
        },
        "released": {
          "type": "number",
          "description": "released recorded for this result."
        },
        "note": {
          "type": "string",
          "description": "note recorded for this result."
        }
      },
      "required": [
        "reserved",
        "consumed",
        "released",
        "note"
      ],
      "additionalProperties": {},
      "description": "check reservations recorded for this result."
    },
    "monthly_check_limit": {
      "anyOf": [
        {
          "type": "number",
          "description": "monthly check limit recorded for this result."
        },
        {
          "type": "null"
        }
      ],
      "description": "monthly check limit recorded for this result."
    },
    "check_budget": {
      "type": "object",
      "properties": {
        "period": {
          "type": "string",
          "description": "period recorded for this result."
        },
        "limit": {
          "anyOf": [
            {
              "type": "number",
              "description": "limit recorded for this result."
            },
            {
              "type": "null"
            }
          ],
          "description": "limit recorded for this result."
        },
        "reserved": {
          "type": "number",
          "description": "reserved recorded for this result."
        },
        "consumed": {
          "type": "number",
          "description": "consumed recorded for this result."
        },
        "remaining": {
          "anyOf": [
            {
              "type": "number",
              "description": "Check units still available after consumed and reserved units; null if the limit is unknown."
            },
            {
              "type": "null"
            }
          ],
          "description": "Check units still available after consumed and reserved units; null if the limit is unknown."
        },
        "exhausted": {
          "anyOf": [
            {
              "type": "boolean",
              "description": "exhausted recorded for this result."
            },
            {
              "type": "null"
            }
          ],
          "description": "exhausted recorded for this result."
        },
        "resets_at": {
          "type": "string",
          "description": "resets at recorded for this result."
        },
        "enforced_by": {
          "type": "string",
          "description": "enforced by recorded for this result."
        },
        "plan_allowance_enforced": {
          "type": "boolean",
          "description": "plan allowance enforced recorded for this result."
        }
      },
      "required": [
        "period",
        "limit",
        "reserved",
        "consumed",
        "remaining",
        "exhausted",
        "resets_at",
        "enforced_by",
        "plan_allowance_enforced"
      ],
      "additionalProperties": {},
      "description": "check budget recorded for this result."
    },
    "active_watch_limit": {
      "anyOf": [
        {
          "type": "number",
          "description": "active watch limit recorded for this result."
        },
        {
          "type": "null"
        }
      ],
      "description": "active watch limit recorded for this result."
    },
    "units": {
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "object",
        "properties": {
          "used": {
            "type": "number",
            "description": "used recorded for this result."
          },
          "included_allowance": {
            "type": "number",
            "description": "included allowance recorded for this result."
          },
          "included_used": {
            "type": "number",
            "description": "included used recorded for this result."
          },
          "chargeable": {
            "type": "number",
            "description": "chargeable recorded for this result."
          },
          "rate_microusd_per_1000": {
            "type": "number",
            "description": "rate microusd per 1000 recorded for this result."
          },
          "chargeable_microusd": {
            "type": "number",
            "description": "chargeable microusd recorded for this result."
          }
        },
        "required": [
          "used",
          "included_allowance",
          "included_used",
          "chargeable",
          "rate_microusd_per_1000",
          "chargeable_microusd"
        ],
        "additionalProperties": {},
        "description": "units recorded for this result."
      },
      "description": "units recorded for this result."
    },
    "chargeable_microusd": {
      "type": "number",
      "description": "chargeable microusd recorded for this result."
    },
    "pricing_mode": {
      "type": "string",
      "const": "estimate_only",
      "description": "pricing mode recorded for this result."
    },
    "at_allowance": {
      "type": "object",
      "properties": {
        "at_allowance": {
          "type": "string",
          "description": "at allowance recorded for this result."
        },
        "enforced_limit": {
          "type": "string",
          "description": "enforced limit recorded for this result."
        },
        "note": {
          "type": "string",
          "description": "note recorded for this result."
        }
      },
      "required": [
        "at_allowance",
        "enforced_limit",
        "note"
      ],
      "additionalProperties": {},
      "description": "at allowance recorded for this result."
    },
    "checkout": {
      "type": "object",
      "properties": {
        "available": {
          "type": "boolean",
          "description": "available recorded for this result."
        },
        "reason": {
          "anyOf": [
            {
              "type": "string",
              "description": "Recorded explanation; null when no explanation applies."
            },
            {
              "type": "null"
            }
          ],
          "description": "Recorded explanation; null when no explanation applies."
        }
      },
      "required": [
        "available",
        "reason"
      ],
      "additionalProperties": {},
      "description": "checkout recorded for this result."
    },
    "collected": {
      "type": "boolean",
      "const": false,
      "description": "collected recorded for this result."
    }
  },
  "required": [
    "workspace_id",
    "period",
    "plan",
    "subscription_status",
    "check_reservations",
    "monthly_check_limit",
    "check_budget",
    "active_watch_limit",
    "units",
    "chargeable_microusd",
    "pricing_mode",
    "at_allowance",
    "checkout",
    "collected"
  ],
  "additionalProperties": {}
}
