{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/drivings-com/json-schema/drivings-com-study-plan-preview-schema.json",
  "title": "StudyPlanPreview",
  "x-generated": "2026-11-06",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/drivings-com-openapi.json#/components/schemas/StudyPlanPreview",
  "type": "object",
  "required": [
    "schemaVersion",
    "kind",
    "persisted",
    "region",
    "course",
    "schedule",
    "weeks",
    "nextStep",
    "disclaimer"
  ],
  "properties": {
    "schemaVersion": {
      "type": "string"
    },
    "kind": {
      "const": "study_plan_preview"
    },
    "persisted": {
      "const": false
    },
    "region": {
      "$ref": "#/$defs/Region"
    },
    "course": {
      "$ref": "#/$defs/Course"
    },
    "schedule": {
      "type": "object"
    },
    "weeks": {
      "type": "array",
      "minItems": 1,
      "maxItems": 16,
      "items": {
        "type": "object"
      }
    },
    "nextStep": {
      "$ref": "#/$defs/BrowserHandoff"
    },
    "disclaimer": {
      "type": "string"
    }
  },
  "$defs": {
    "BrowserHandoff": {
      "type": "object",
      "required": [
        "url",
        "kind",
        "requiresHumanConfirmation"
      ],
      "properties": {
        "url": {
          "type": "string",
          "format": "uri"
        },
        "kind": {
          "type": "string"
        },
        "requiresHumanConfirmation": {
          "const": true
        },
        "note": {
          "type": "string"
        },
        "warning": {
          "type": "string"
        }
      },
      "additionalProperties": true
    },
    "Course": {
      "type": "string",
      "enum": [
        "car",
        "motorcycle",
        "lgv",
        "pcv",
        "adi",
        "cdl"
      ]
    },
    "Region": {
      "type": "string",
      "enum": [
        "uk",
        "us"
      ]
    }
  }
}