5 min read

Bill of Lading

Extract shipping details from bills of lading including vessel information, ports, containers, and cargo descriptions.

Overview

The Bill of Lading document type is designed to extract structured data from maritime shipping documents. Bills of lading serve as contracts of carriage, receipts for cargo, and documents of title. This extraction type captures all critical shipping information including parties, vessel details, port information, and container specifications.

This is ideal for:

  • Freight forwarding operations
  • Customs and compliance documentation
  • Supply chain visibility systems
  • Cargo tracking and management
  • Logistics automation workflows

Extracted Fields

| Field | Type | Description | |-------|------|-------------| | bolNumber | string | Bill of lading reference number | | shipper | object | Shipper/exporter party details | | consignee | object | Consignee/receiver party details | | vessel | string | Name of the carrying vessel | | portOfLoading | string | Origin port where cargo was loaded | | portOfDischarge | string | Destination port for cargo delivery | | containers | array | Container numbers and specifications | | cargoDescription | string | Description of goods being shipped | | weight | object | Gross and net weight with units |

Example Request

POST/v1/documents/process
curl -X POST 'https://api.docurift.com/v1/documents/process' \
  -H 'X-API-Key: your_api_key' \
  -F 'file=@bill-of-lading.pdf' \
  -F 'documentType=bill_of_lading'

Example Response

{
  "success": true,
  "data": {
    "id": "doc_bol_3f5a7c9e1b2d4f6a",
    "documentType": "bill_of_lading",
    "result": {
      "bolNumber": "MAEU123456789",
      "shipper": {
        "name": "Shenzhen Electronics Manufacturing Co., Ltd.",
        "address": "Building 12, Tech Park Industrial Zone",
        "city": "Shenzhen",
        "state": "Guangdong",
        "postalCode": "518000",
        "country": "China",
        "contact": "Mr. Zhang Wei",
        "phone": "+86 755 8888 9999",
        "email": "export@szelectronics.cn"
      },
      "consignee": {
        "name": "Pacific Distribution Inc.",
        "address": "2500 Harbor Boulevard, Terminal 4",
        "city": "Long Beach",
        "state": "CA",
        "postalCode": "90802",
        "country": "USA",
        "contact": "Sarah Johnson",
        "phone": "+1 (562) 555-0134",
        "email": "imports@pacificdist.com"
      },
      "vessel": "MSC AURORA",
      "voyageNumber": "FA847W",
      "portOfLoading": "CNSHK - Shekou, China",
      "portOfDischarge": "USLGB - Long Beach, USA",
      "placeOfReceipt": "Shenzhen Factory",
      "placeOfDelivery": "Long Beach Terminal",
      "containers": [
        {
          "containerNumber": "MSCU1234567",
          "sealNumber": "ML8847291",
          "type": "40HC",
          "quantity": 1,
          "packageCount": 450,
          "packageType": "Cartons",
          "grossWeight": 18500,
          "weightUnit": "KG",
          "volume": 67.5,
          "volumeUnit": "CBM"
        },
        {
          "containerNumber": "MSCU7654321",
          "sealNumber": "ML8847292",
          "type": "40HC",
          "quantity": 1,
          "packageCount": 380,
          "packageType": "Cartons",
          "grossWeight": 16200,
          "weightUnit": "KG",
          "volume": 62.3,
          "volumeUnit": "CBM"
        }
      ],
      "cargoDescription": "Consumer Electronics - LED Monitors, Model XP-2700 Series. HS Code: 8528.52. Freight Prepaid. Said to Contain.",
      "weight": {
        "gross": 34700,
        "net": 32100,
        "unit": "KG"
      },
      "freightTerms": "CIF Long Beach",
      "shippedOnBoardDate": "2024-11-10",
      "estimatedArrival": "2024-12-05"
    },
    "confidence": 0.94,
    "processingTimeMs": 2340
  }
}

Field Definitions

bolNumber

The unique bill of lading reference number issued by the carrier. This is the primary identifier for tracking the shipment throughout its journey.

shipper

An object containing the exporter's details:

| Property | Type | Description | |----------|------|-------------| | name | string | Company or business name | | address | string | Street address | | city | string | City name | | state | string | State or province | | postalCode | string | Postal code | | country | string | Country name | | contact | string | Contact person name | | phone | string | Contact phone number | | email | string | Contact email address |

consignee

An object containing the receiver's details with the same structure as the shipper object.

vessel

The name of the ocean vessel carrying the cargo.

portOfLoading

The port where the cargo was loaded onto the vessel, typically including the UN/LOCODE and port name.

portOfDischarge

The destination port where the cargo will be unloaded, typically including the UN/LOCODE and port name.

containers

An array of container details. Each container object includes:

| Property | Type | Description | |----------|------|-------------| | containerNumber | string | Unique container identification number | | sealNumber | string | Security seal number | | type | string | Container type (20GP, 40GP, 40HC, etc.) | | quantity | number | Number of containers of this type | | packageCount | number | Number of packages in container | | packageType | string | Type of packaging (Cartons, Pallets, etc.) | | grossWeight | number | Total weight including packaging | | weightUnit | string | Weight unit (KG, LBS) | | volume | number | Container volume | | volumeUnit | string | Volume unit (CBM, CFT) |

cargoDescription

A text description of the goods being shipped, often including HS codes, product details, and shipping terms (Said to Contain, Shipper's Load and Count, etc.).

weight

An object containing weight information:

| Property | Type | Description | |----------|------|-------------| | gross | number | Total weight including all packaging | | net | number | Weight of goods only (if available) | | unit | string | Weight unit (KG, LBS) |

Best Practices

  1. Complete Documents: Ensure the entire bill of lading is captured, including front and back pages which may contain different information.

  2. Container Numbers: Verify extracted container numbers match the ISO 6346 format (4 letters + 7 digits) for validation.

  3. Port Codes: When possible, validate extracted port information against UN/LOCODE databases for accuracy.

  4. Seal Numbers: Seal numbers are critical for customs compliance - verify these match physical seals during cargo receipt.

  5. Weight Discrepancies: Cross-reference extracted weights with actual cargo weights to identify potential issues.

  6. Multiple Pages: Bills of lading often span multiple pages. Upload all pages as a single PDF for complete extraction.

  7. Language Variations: Bills of lading may contain text in multiple languages. The primary fields are typically in English, but shipper/consignee details may be in local languages.

  8. Carrier Formats: Different shipping lines have varying B/L formats. DocuRift handles major carrier formats including Maersk, MSC, CMA CGM, COSCO, and others.

  9. Terms and Clauses: While the main shipping details are extracted, review the original document for any special clauses or terms that may affect cargo handling.