{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "PureEV EV Catalog Vehicle",
  "description": "Vehicle object exposed by GET /vehicles and GET /vehicles/{id} on the PureEV Catalog API.",
  "type": "object",
  "required": [
    "id",
    "brand",
    "modelName",
    "market",
    "modelYear",
    "batteryCapacityKWh",
    "batteryCapacityType",
    "averageConsumptionWhPerKm",
    "rangeWLTPKm",
    "maxDCChargeKW",
    "category",
    "status",
    "sourceUrls",
    "confidence",
    "lastChecked"
  ],
  "properties": {
    "id": { "type": "string" },
    "brand": { "type": "string" },
    "modelName": { "type": "string" },
    "market": { "type": "string", "enum": ["EU", "FR", "UK", "US", "Global"] },
    "modelYear": { "type": "integer", "minimum": 2020, "maximum": 2030 },
    "batteryCapacityKWh": { "type": "number", "minimum": 20, "maximum": 130 },
    "batteryCapacityType": {
      "type": "string",
      "enum": ["official_usable", "official_gross", "usable_estimate", "gross_estimate"]
    },
    "averageConsumptionWhPerKm": { "type": "number", "minimum": 90, "maximum": 300 },
    "rangeWLTPKm": { "type": "integer", "minimum": 100, "maximum": 900 },
    "maxDCChargeKW": { "type": "integer", "minimum": 20, "maximum": 400 },
    "category": { "type": "string" },
    "status": { "type": "string", "enum": ["active", "discontinued", "announced"] },
    "sourceUrls": {
      "type": "array",
      "minItems": 1,
      "items": { "type": "string", "format": "uri" }
    },
    "confidence": { "type": "string", "enum": ["high", "medium", "low"] },
    "lastChecked": { "type": "string", "format": "date" },
    "acChargeKW": { "type": ["number", "null"], "minimum": 3, "maximum": 22 },
    "batteryChemistry": {
      "type": ["string", "null"],
      "enum": ["LFP", "NMC", "NCA", "unknown", null]
    },
    "heatPump": { "type": ["boolean", "null"] },
    "v2l": { "type": ["boolean", "null"] },
    "driveType": {
      "type": ["string", "null"],
      "enum": ["FWD", "RWD", "AWD", null]
    },
    "bodyStyle": {
      "type": ["string", "null"],
      "enum": [
        "City car",
        "Hatchback",
        "Sedan",
        "SUV",
        "Crossover",
        "Estate",
        "MPV",
        "Van",
        null
      ]
    },
    "seats": { "type": ["integer", "null"], "minimum": 2, "maximum": 9 },
    "lengthMm": { "type": ["integer", "null"], "minimum": 3000, "maximum": 6000 },
    "bootVolumeLiters": { "type": ["integer", "null"], "minimum": 100, "maximum": 3000 },
    "towingKg": { "type": ["integer", "null"], "minimum": 0, "maximum": 3500 }
  },
  "additionalProperties": false
}
