{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/scribiz/json-schema/scribiz-checkout-confirmed-schema.json",
  "title": "CheckoutConfirmed",
  "x-generated": "2026-11-08",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/scribiz-openapi.json#/components/schemas/CheckoutConfirmed",
  "properties": {
    "captionCredits": {
      "description": "Caption wallet balance for a caption purchase; null for other purchases.",
      "type": [
        "integer",
        "null"
      ]
    },
    "kind": {
      "enum": [
        "pro",
        "mac-lifetime",
        "topup"
      ]
    },
    "lifetimeMac": {
      "type": "boolean"
    },
    "minutesTopup": {
      "type": "number"
    },
    "paid": {
      "description": "True when Stripe says the checkout was paid. A `pending` state with `paid: false` is not a payment (the checkout is still open, or Stripe could not be asked): do not tell the buyer one went through.",
      "type": "boolean"
    },
    "plan": {
      "enum": [
        "free",
        "pro",
        "lifetime"
      ]
    },
    "planUntil": {
      "type": [
        "number",
        "null"
      ]
    },
    "state": {
      "enum": [
        "active",
        "pending",
        "expired",
        "failed"
      ]
    }
  },
  "required": [
    "state",
    "kind",
    "plan",
    "planUntil",
    "lifetimeMac",
    "minutesTopup",
    "paid"
  ],
  "type": "object"
}