Raw schema
{
"type": "object",
"properties": {
"mode": {
"description": "Transport mode: sea | air | road (default road). Selects the chargeable-weight basis.",
"type": "string",
"enum": [
"sea",
"air",
"road"
]
},
"lines": {
"description": "Canonical consignment lines (preferred). Each: { quantity, dims:{l,w,h,unit}, weight:{value,unit}, optional description / hs_code / un_number / stackable }.",
"minItems": 1,
"maxItems": 50,
"type": "array",
"items": {
"type": "object",
"properties": {
"description": {
"description": "Optional item label",
"type": "string",
"maxLength": 200
},
"quantity": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100000,
"description": "Number of identical pieces"
},
"dims": {
"type": "object",
"properties": {
"l": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Length in the given unit"
},
"w": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Width in the given unit"
},
"h": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Height in the given unit"
},
"unit": {
"type": "string",
"enum": [
"mm",
"cm",
"m",
"in"
],
"description": "Dimension unit: mm | cm | m | in"
}
},
"required": [
"l",
"w",
"h",
"unit"
],
"additionalProperties": false
},
"weight": {
"type": "object",
"properties": {
"value": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Gross weight per piece in the given unit"
},
"unit": {
"type": "string",
"enum": [
"kg",
"g",
"t",
"lb"
],
"description": "Weight unit: kg | g | t | lb"
}
},
"required": [
"value",
"unit"
],
"additionalProperties": false
},
"hs_code": {
"description": "Optional HS commodity code",
"type": "string",
"pattern": "^\\d{6,10}$"
},
"un_number": {
"description": "Optional UN number for dangerous-goods reference",
"type": "string",
"pattern": "^(UN)?\\d{4}$"
},
"stackable": {
"description": "Whether the line may be stacked two-high (halves its loading-metre footprint)",
"type": "boolean"
}
},
"required": [
"quantity",
"dims",
"weight"
],
"additionalProperties": false
}
},
"items": {
"description": "Deprecated flat alias โ dimensions in cm, weight in kg. Prefer \"lines\". Provide lines OR items.",
"minItems": 1,
"maxItems": 50,
"type": "array",
"items": {
"type": "object",
"properties": {
"description": {
"description": "Item description",
"type": "string"
},
"length": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Length in cm"
},
"width": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Width in cm"
},
"height": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Height in cm"
},
"quantity": {
"description": "Number of pieces (default 1)",
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"gross_weight": {
"type": "number",
"exclusiveMinimum": 0,
"description": "Gross weight per piece in kg"
},
"stackable": {
"description": "Can the item be stacked?",
"type": "boolean"
},
"pallet_type": {
"description": "Pallet type (informational)",
"type": "string",
"enum": [
"none",
"euro",
"uk",
"us",
"custom"
]
},
"un_number": {
"description": "Optional UN number for dangerous-goods reference",
"type": "string"
},
"hs_code": {
"description": "Optional HS commodity code",
"type": "string"
}
},
"required": [
"length",
"width",
"height",
"gross_weight"
],
"additionalProperties": false
}
},
"options": {
"description": "Optional: { air_volumetric_divisor, container_number, awb_number }.",
"type": "object",
"properties": {
"air_volumetric_divisor": {
"description": "IATA volumetric divisor in cmยณ/kg (default 6000). Only affects air.",
"type": "number",
"exclusiveMinimum": 0,
"maximum": 10000
},
"container_number": {
"description": "ISO 6346 container number โ check-digit validated, advisory only",
"type": "string",
"maxLength": 20
},
"awb_number": {
"description": "IATA 11-digit air waybill number โ check-digit validated, advisory only",
"type": "string",
"maxLength": 20
}
},
"additionalProperties": false
},
"consignment": {
"description": "Alternative to the other arguments: the consignment object (https://www.freightutils.com/schema/consignment-object.v1.json) โ lines[] (description, un_number, packing_group, variant_index, quantity {value, unit, basis}, packages {count, type, gross_kg, un_mark}, hs_code, value {amount, currency}, dims, stackable, icao_limited_quantity, inner_packaging), journey {origin, destination, date, tunnels_on_route, mode}, vehicle, crew, options. Send it alone; an input the tool needs and the object lacks comes back in missing_inputs.",
"type": "object",
"properties": {
"lines": {
"minItems": 1,
"maxItems": 50,
"type": "array",
"items": {
"type": "object",
"properties": {
"description": {
"type": "string",
"maxLength": 200
},
"un_number": {
"type": "string",
"pattern": "^(?:(?:UN\\s?)?\\d{4}|ID\\s?\\d{4})$"
},
"packing_group": {
"type": "string",
"enum": [
"I",
"II",
"III"
]
},
"variant_index": {
"type": "integer",
"minimum": 0,
"maximum": 1000
},
"quantity": {
"type": "object",
"properties": {
"value": {
"type": "number",
"minimum": 0,
"maximum": 1000000000
},
"unit": {
"type": "string",
"enum": [
"L",
"kg"
]
},
"basis": {
"type": "string",
"enum": [
"net",
"gross"
]
}
},
"required": [
"value"
],
"additionalProperties": false
},
"packages": {
"type": "object",
"properties": {
"count": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 100000
},
"type": {
"type": "string",
"maxLength": 40
},
"gross_kg": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 1000000
},
"un_mark": {
"type": "string",
"minLength": 1,
"maxLength": 80
}
},
"required": [
"count"
],
"additionalProperties": false
},
"hs_code": {
"type": "string",
"pattern": "^\\d{6,10}$"
},
"value": {
"type": "object",
"properties": {
"amount": {
"type": "number",
"minimum": 0,
"maximum": 1000000000000
},
"currency": {
"type": "string",
"pattern": "^[A-Z]{3}$"
}
},
"required": [
"amount",
"currency"
],
"additionalProperties": false
},
"dims": {
"type": "object",
"properties": {
"l": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 100000
},
"w": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 100000
},
"h": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 100000
},
"unit": {
"type": "string",
"enum": [
"mm",
"cm",
"m",
"in"
]
}
},
"required": [
"l",
"w",
"h",
"unit"
],
"additionalProperties": false
},
"stackable": {
"type": "boolean"
},
"icao_limited_quantity": {
"type": "boolean"
},
"inner_packaging": {
"type": "object",
"properties": {
"quantity": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 1000000
},
"unit": {
"type": "string",
"enum": [
"ml",
"L",
"g",
"kg"
]
},
"per_outer": {
"type": "integer",
"minimum": 1,
"maximum": 100000
},
"regime": {
"type": "string",
"enum": [
"lq",
"eq"
]
}
},
"required": [
"quantity",
"unit"
],
"additionalProperties": false
}
},
"additionalProperties": false
}
},
"journey": {
"type": "object",
"properties": {
"origin": {
"type": "string",
"pattern": "^[A-Za-z]{2}(?:\\s?[A-Za-z2-9]{3})?$"
},
"destination": {
"type": "string",
"pattern": "^[A-Za-z]{2}(?:\\s?[A-Za-z2-9]{3})?$"
},
"date": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$"
},
"tunnels_on_route": {
"maxItems": 20,
"type": "array",
"items": {
"type": "string",
"enum": [
"A",
"B",
"C",
"D",
"E"
]
}
},
"mode": {
"type": "string",
"enum": [
"road",
"air",
"sea",
"multimodal"
]
}
},
"additionalProperties": false
},
"vehicle": {
"type": "object",
"properties": {
"type": {
"type": "string",
"maxLength": 60
},
"max_mass_t": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 100
},
"axles": {
"type": "integer",
"minimum": 1,
"maximum": 12
},
"foodstuffs_carried": {
"type": "boolean"
},
"fire_extinguishers_kg": {
"maxItems": 20,
"type": "array",
"items": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 100
}
},
"orange_plates_displayed": {
"type": "boolean"
},
"placards_displayed": {
"type": "boolean"
},
"equipment_8_1_5": {
"maxItems": 11,
"type": "array",
"items": {
"type": "string",
"enum": [
"wheel_chock",
"warning_signs",
"eye_rinsing_liquid",
"warning_vest",
"portable_lighting",
"protective_gloves",
"eye_protection",
"emergency_escape_mask",
"shovel",
"drain_seal",
"collecting_container"
]
}
},
"instructions_in_writing": {
"type": "boolean"
}
},
"additionalProperties": false
},
"crew": {
"type": "object",
"properties": {
"adr_training_certificate": {
"type": "boolean"
},
"specialisations": {
"maxItems": 3,
"type": "array",
"items": {
"type": "string",
"enum": [
"class_1",
"class_7",
"tanks"
]
}
},
"photo_identification": {
"type": "boolean"
},
"awareness_training_1_3": {
"type": "boolean"
}
},
"additionalProperties": false
},
"options": {
"type": "object",
"properties": {
"air_volumetric_divisor": {
"type": "number",
"exclusiveMinimum": 0,
"maximum": 10000
},
"container_number": {
"type": "string",
"maxLength": 20
},
"awb_number": {
"type": "string",
"maxLength": 20
},
"incoterm": {
"type": "string",
"enum": [
"EXW",
"FCA",
"FAS",
"FOB",
"CFR",
"CIF",
"CPT",
"CIP",
"DAP",
"DPU",
"DDP"
]
},
"freight_cost": {
"type": "object",
"properties": {
"amount": {
"type": "number",
"minimum": 0,
"maximum": 1000000000000
},
"currency": {
"type": "string",
"pattern": "^[A-Z]{3}$"
}
},
"required": [
"amount",
"currency"
],
"additionalProperties": false
},
"insurance_cost": {
"type": "object",
"properties": {
"amount": {
"type": "number",
"minimum": 0,
"maximum": 1000000000000
},
"currency": {
"type": "string",
"pattern": "^[A-Z]{3}$"
}
},
"required": [
"amount",
"currency"
],
"additionalProperties": false
}
},
"additionalProperties": false
}
},
"required": [
"lines"
],
"additionalProperties": false
},
"edition": {
"description": "ADR edition: \"2025\" or \"2027\". Wins over as_of. Omit it and as_of picks the edition by the legal timeline: before 2027-01-01 ADR 2025; from 2027-01-01 ADR 2027 (ADR 2025 may still be applied until 2027-06-30 under 1.6.1.1 โ edition \"2025\" answers on it until then); from 2027-07-01 ADR 2027 only. An ADR 2027 answer for a date before 2027-01-01 carries an EDITION_NOT_YET_APPLICABLE warning.",
"type": "string",
"enum": [
"2025",
"2027"
]
},
"as_of": {
"description": "YYYY-MM-DD the answer is for (default today, UTC); picks the ADR edition when edition is omitted, and is echoed in the answer and its check receipt.",
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$"
}
},
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false
}