Bill of Lading

Structured extraction preset for ocean, air, rail, and multimodal bills of lading. Captures shipper/consignee details, cargo manifest, transport routing, and freight charges with full FOB/CIF/INCOTERM support.

The fields this preset extracts.

bol_numberstring

Unique bill of lading number, exactly as printed on the document.

booking_numberstring

Booking reference number for the carrier.

bill_typestring

Type of bill of lading (ocean/air/rail/road/multimodal/master/house/straight/order/sea_waybill).

issue_datestring

Date bill of lading was issued (ISO-8601).

shipperobject
namestring

Shipper company name, exactly as printed.

addressstring

Shipper full address including street, city, state, postal code, country.

contact_phonestring

Shipper contact telephone number.

tax_idstring

Shipper tax identification number (VAT/EIN/equivalent).

consigneeobject
namestring

Consignee company name, exactly as printed.

addressstring

Consignee full address including street, city, state, postal code, country.

contact_phonestring

Consignee contact telephone number.

notify_partyobject
carrierobject
port_of_loadingstring

Port/airport/terminal of loading, exactly as printed.

port_of_dischargestring

Port/airport/terminal of discharge, exactly as printed.

place_of_receiptstring

Place where goods are received by carrier.

place_of_deliverystring

Final destination place of delivery.

transport_modestring

Primary transport mode (sea/air/rail/road/multimodal).

incotermsstring

Incoterms 2020 code (EXW, FCA, CPT, CIP, DAP, DPU, DDP, FAS, FOB, CFR, CIF, other).

freight_paymentstring

Freight payment method (prepaid/collect/third_party).

cargoarray<object>

Array of cargo line items.

total_packagesinteger

Total package count (must be an integer).

total_gross_weight_kgnumber

Total gross weight in kilograms.

total_volume_cbmnumber

Total volume in cubic meters.

currencystring

ISO 4217 currency code (e.g., USD, EUR, GBP).

freight_chargesarray

Array of freight and ancillary charges.

total_freightnumber

Total freight and charges amount.

signaturesobject
curl
curl -X POST 'https://app.staging.xberg.io/v1/extract' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -F 'file=@your-document.pdf' \
  --form-string 'options={"preset":"bill_of_lading"}'
Call mode
Text and vision
Citations
Enabled
Version
v1

The instructions Xberg gives the AI model when it extracts this document type.

Extract bill of lading details from the provided document. Record ports, locations, and addresses exactly as printed. Convert all package counts, weights, and dimensions to integers where specified. For cargo line items, capture marks and numbers verbatim, package counts as integers, and weights/volumes as numbers. Ensure shipper and consignee names are transcribed precisely. Include carrier details (vessel name, voyage, flight, or container numbers) if present. Capture freight charges and payment terms. Do not infer or supply missing data—only extract what is explicitly shown. If the document does not match this preset, return {}. Extract only values supported by the document. Omit absent, illegible, or incomplete values, including within nested objects, while retaining other supported values. Do not infer, guess, supply defaults, or calculate missing values. Omit dates whose complete year, month, and day are not explicit. Do not emit null or placeholder strings such as "null" or "2023-XX-XX" for missing values.

Open-source primitives, composed into one backend. Curated cohort of design partners. Apply to work with us.

We value your privacy

Xberg uses cookies to improve your experience, personalize content, and analyze traffic. You can manage your preferences at any time.