{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/agentaos-ai/json-schema/agentaos-ai-checkout-schema.json",
  "title": "Checkout",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/agentaos-ai-checkouts-api-openapi.yml#/components/schemas/Checkout",
  "type": "object",
  "additionalProperties": true,
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "Internal checkout UUID."
    },
    "payment_link_id": {
      "type": [
        "string",
        "null"
      ],
      "format": "uuid"
    },
    "org_id": {
      "type": "string",
      "format": "uuid"
    },
    "session_id": {
      "type": "string",
      "description": "Public ID, used in the checkout URL and as the path parameter for every other call on this resource."
    },
    "idempotency_key": {
      "type": [
        "string",
        "null"
      ]
    },
    "amount_override": {
      "type": [
        "number",
        "null"
      ],
      "description": "Set only if you passed amount or amountOverride at create."
    },
    "currency": {
      "type": "string"
    },
    "metadata": {
      "type": "object"
    },
    "webhook_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "success_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "cancel_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "tax_rate_id": {
      "type": [
        "string",
        "null"
      ],
      "format": "uuid"
    },
    "supported_networks": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "status": {
      "type": "string",
      "enum": [
        "open",
        "completed",
        "expired",
        "cancelled"
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "seller_mode": {
      "type": "string",
      "enum": [
        "mor",
        "crypto"
      ]
    },
    "environment": {
      "type": "string",
      "enum": [
        "test",
        "live"
      ]
    },
    "checkoutUrl": {
      "type": "string",
      "description": "Send your buyer here. Computed, camelCase."
    },
    "invoiceId": {
      "type": [
        "string",
        "null"
      ],
      "format": "uuid",
      "description": "Set once an invoice has been issued for this session; null until then."
    },
    "invoiceNumber": {
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "id",
    "payment_link_id",
    "org_id",
    "session_id",
    "idempotency_key",
    "amount_override",
    "currency",
    "metadata",
    "webhook_url",
    "success_url",
    "cancel_url",
    "tax_rate_id",
    "supported_networks",
    "expires_at",
    "status",
    "created_at",
    "updated_at",
    "seller_mode",
    "environment",
    "checkoutUrl"
  ]
}