Limit

{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "kind": {
          "type": "string",
          "enum": [
            "plan_credits"
          ]
        },
        "unit": {
          "type": "string",
          "enum": [
            "credits"
          ]
        },
        "amount": {
          "type": "number",
          "description": "The plan credits a month. Carried by quota_exceeded when on-demand usage is off."
        },
        "used": {
          "type": "number",
          "description": "How much of amount is used this month, in credits."
        },
        "resets_at": {
          "type": "string",
          "description": "YYYY-MM-DD, the first day of next month (UTC), when used returns to 0."
        }
      },
      "required": [
        "kind",
        "unit",
        "amount",
        "used",
        "resets_at"
      ]
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "type": "string",
          "enum": [
            "on_demand_budget"
          ]
        },
        "unit": {
          "type": "string",
          "enum": [
            "credits"
          ]
        },
        "amount": {
          "type": "number",
          "description": "The on-demand budget a month, in credits ($0.002 a credit). Carried by quota_exceeded and spend_limit_exceeded when on-demand usage is on."
        },
        "used": {
          "type": "number",
          "description": "How much of amount is used this month, in credits."
        },
        "resets_at": {
          "type": "string",
          "description": "YYYY-MM-DD, the first day of next month (UTC), when used returns to 0."
        }
      },
      "required": [
        "kind",
        "unit",
        "amount",
        "used",
        "resets_at"
      ]
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "type": "string",
          "enum": [
            "member_on_demand"
          ]
        },
        "unit": {
          "type": "string",
          "enum": [
            "cents"
          ]
        },
        "amount": {
          "type": "number",
          "description": "The monthly on-demand limit an admin set for the person the key or token acts for, in US cents. Carried by member_limit."
        },
        "used": {
          "type": "number",
          "description": "How much of amount is used this month, in cents."
        },
        "resets_at": {
          "type": "string",
          "description": "YYYY-MM-DD, the first day of next month (UTC), when used returns to 0."
        }
      },
      "required": [
        "kind",
        "unit",
        "amount",
        "used",
        "resets_at"
      ]
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "type": "string",
          "enum": [
            "premium_hours"
          ]
        },
        "unit": {
          "type": "string",
          "enum": [
            "hours"
          ]
        },
        "amount": {
          "type": "number",
          "description": "The Premium transcript hours Ultra plan credits cover a month. Carried by fair_use_cap."
        },
        "used": {
          "type": "number",
          "description": "How much of amount is used this month, in hours."
        },
        "resets_at": {
          "type": "string",
          "description": "YYYY-MM-DD, the first day of next month (UTC), when used returns to 0."
        }
      },
      "required": [
        "kind",
        "unit",
        "amount",
        "used",
        "resets_at"
      ]
    },
    {
      "allOf": [
        {
          "$ref": "#/components/schemas/Freshness"
        },
        {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "freshness"
              ]
            }
          },
          "required": [
            "kind"
          ]
        }
      ],
      "description": "Where results stop on a plan that reads media after a delay."
    }
  ],
  "description": "On quota_exceeded, spend_limit_exceeded, member_limit, fair_use_cap and freshness_requires_paid: the limit the refusal met. Absent when the server holds no figure for it."
}