{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/vepathos-com/json-schema/vepathos-com-delivery-update-schema.json",
  "title": "DeliveryUpdate",
  "x-generated": "2026-11-28",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/vepathos-com-openapi.json#/components/schemas/DeliveryUpdate",
  "properties": {
    "destination": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Destination",
      "description": "Stop location. Coordinates in ISO 6709 decimal degrees, latitude then longitude with signs, e.g. `+40.7128-74.0060`."
    },
    "method": {
      "anyOf": [
        {
          "$ref": "#/$defs/DeliveryMethod"
        },
        {
          "type": "null"
        }
      ]
    },
    "schedules": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Schedules",
      "description": "Time windows. RFC 5545 VEVENT: `DTSTART` plus `DTEND` or `DURATION`, optionally `RRULE`. Join lines with `\\n`."
    },
    "width": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Width",
      "description": "Package width, in `length_unit`. Integer."
    },
    "height": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Height",
      "description": "Package height, in `length_unit`. Integer."
    },
    "depth": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Depth",
      "description": "Package depth, in `length_unit`. Integer."
    },
    "length_unit": {
      "anyOf": [
        {
          "$ref": "#/$defs/LengthUnit"
        },
        {
          "type": "null"
        }
      ]
    },
    "volume": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Volume",
      "description": "Package volume, in `volume_unit`. Integer."
    },
    "volume_unit": {
      "anyOf": [
        {
          "$ref": "#/$defs/VolumeUnit"
        },
        {
          "type": "null"
        }
      ]
    },
    "weight": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Weight",
      "description": "Package weight, in `weight_unit`. Integer; use `GRAMS` for fractional kilograms."
    },
    "weight_unit": {
      "anyOf": [
        {
          "$ref": "#/$defs/WeightUnit"
        },
        {
          "type": "null"
        }
      ]
    },
    "packaging": {
      "anyOf": [
        {
          "$ref": "#/$defs/PackagingType"
        },
        {
          "type": "null"
        }
      ]
    },
    "handling": {
      "anyOf": [
        {
          "items": {
            "$ref": "#/$defs/SpecialHandling"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Handling"
    },
    "value_cents": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Value Cents",
      "description": "Declared value in minor units (`5000` is 50.00)."
    },
    "value_currency": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Value Currency",
      "description": "ISO 4217 currency code."
    },
    "extra": {
      "anyOf": [
        {},
        {
          "type": "null"
        }
      ],
      "title": "Extra",
      "description": "Your own metadata, returned as sent. The planner reads `lat`, `lng`, `packages` and `zone` if present."
    },
    "milestone_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Milestone Id",
      "description": "Milestone the package leaves from."
    }
  },
  "type": "object",
  "$defs": {
    "DeliveryMethod": {
      "type": "string",
      "enum": [
        "DELIVERY",
        "PICKUP",
        "SIGNATURE"
      ],
      "title": "DeliveryMethod"
    },
    "LengthUnit": {
      "type": "string",
      "enum": [
        "CENTIMETER",
        "METER",
        "KILOMETER",
        "INCH",
        "FEET",
        "MILE"
      ],
      "title": "LengthUnit"
    },
    "PackagingType": {
      "type": "string",
      "enum": [
        "BOX",
        "ENVELOPE",
        "BAG",
        "CARTON",
        "PALLET",
        "SHRINK_WRAP"
      ],
      "title": "PackagingType"
    },
    "SpecialHandling": {
      "type": "string",
      "enum": [
        "FRAGILE",
        "PERISHABLE",
        "HAZARDOUS",
        "REFRIGERATED"
      ],
      "title": "SpecialHandling"
    },
    "VolumeUnit": {
      "type": "string",
      "enum": [
        "CUBIC_CENTIMETER",
        "CUBIC_METER",
        "LITER",
        "CUBIC_INCH",
        "CUBIC_FEET",
        "GALLON"
      ],
      "title": "VolumeUnit"
    },
    "WeightUnit": {
      "type": "string",
      "enum": [
        "GRAMS",
        "KILOGRAMS",
        "OUNCES",
        "POUNDS"
      ],
      "title": "WeightUnit"
    }
  }
}