DS-18 Supply Chain

African Port and Trade Clearance Dataset

2M+ import/export declaration records with end-to-end customs timelines from major ports in Nigeria, Ghana, Kenya, and South Africa — including HS code classifications, dwell-time breakdowns, inspection outcomes, and duty assessments for trade compliance AI and port-operations optimisation.

This is a synthetic dataset generated from high-quality expert-labelled seed data. All records are algorithmically derived — statistical distributions, inter-field correlations, and annotation characteristics faithfully replicate real-world patterns from the source data, while ensuring no real individual, organisation, or transaction can be identified or reconstructed.

The African Port and Trade Clearance Dataset aggregates 2M+ import and export declaration records processed at major seaports and land border crossing points across Nigeria (Apapa, Tin Can Island), Ghana (Tema), Kenya (Mombasa), and South Africa (Durban, Cape Town). Each record captures the full customs clearance lifecycle: declaration lodgement, document verification, physical inspection decision, examination outcome, duty assessment, and release — with timestamps at each stage enabling end-to-end dwell time modelling.

Declarations are classified by HS code chapter (2-digit) and a 6-digit HS code where available, commodity description, trade flow (import/export), declared value, and country of origin or destination. Risk channel assignment (green, amber, red lane) and inspection outcomes (compliant, documentary discrepancy, undervaluation, prohibited goods) are included for the subset of declarations that were risk-selected for examination, enabling supervised customs compliance and fraud-detection model development.

The dataset is anonymised at the declarant level — importer/exporter names are replaced with sector and size-band codes — while preserving the statistical relationships between trader characteristics, commodity types, and compliance outcomes that are essential for risk-scoring model training. A companion port-level metadata file covers berth capacity, handling equipment, and seasonal throughput indices for port-operations forecasting tasks.

Key Use Cases

Customs risk scoring and lane assignment (green / amber / red)
Undervaluation and customs fraud detection models
End-to-end dwell time prediction and bottleneck identification
HS code classification from commodity description text
Trade compliance gap analysis and audit prioritisation
Port throughput forecasting and berth scheduling optimisation
Cross-border trade facilitation and single-window process improvement
Sanctions and prohibited-goods screening model development

Dataset Highlights

Trade Declarations
2M+
import and export records
Ports Covered
6
Apapa, Tema, Mombasa, Durban, Cape Town, Tin Can
HS Code Chapters
97
full commodity classification range
Risk Channels
3
green, amber, red lane assignments

Geographic Coverage

Primary Coverage
Other Regions

Dataset Schema

Each record represents one customs declaration. Fields cover declaration identity, commodity details, trade parties, valuation, customs process timeline, and inspection outcome.

Field NameTypeDescriptionNullableExample
declaration_id STRING Unique anonymised declaration identifier No DCL-NGA-AP-20230712-0084123
country_code STRING ISO 3166-1 alpha-2 country of the customs authority No NG
port_code STRING Port or border crossing code No NGAPP
trade_flow ENUM Trade direction: IMPORT, EXPORT No IMPORT
declaration_date DATE Date of declaration lodgement (YYYY-MM-DD) No 2023-07-12
hs_chapter INTEGER 2-digit HS chapter code No 84
hs_code_6digit STRING 6-digit HS code (null if not available) Yes 847150
commodity_description STRING Declared commodity description (free text) No Automatic data processing machines (laptops)
origin_country STRING ISO country code of goods origin (imports) or destination (exports) No CN
declared_value_usd FLOAT Declared customs value in USD No 48200
gross_weight_kg FLOAT Gross weight of shipment in kilograms Yes 1240
risk_channel ENUM Risk lane assigned: GREEN, AMBER, RED No GREEN
inspected BOOLEAN True if shipment was physically inspected No false
inspection_outcome ENUM Result if inspected: COMPLIANT, DOCUMENTARY_DISCREPANCY, UNDERVALUATION, PROHIBITED_GOODS (null if not inspected) Yes null
dwell_time_days FLOAT Total port dwell time from arrival to release in days Yes 4.2
importer_sector STRING Anonymised sector code of importer / exporter Yes ELECTRONICS_RETAIL
importer_size_band ENUM Trader size: MICRO, SMALL, MEDIUM, LARGE Yes MEDIUM

Sample Records

Four representative declaration records spanning ports, trade flows, risk channels, and inspection outcomes.

trade_clearance_sample.json
[ { "declaration_id": "DCL-NGA-AP-20230712-0084123", "country_code": "NG", "port_code": "NGAPP", "trade_flow": "IMPORT", "declaration_date": "2023-07-12", "hs_chapter": 84, "hs_code_6digit": "847150", "commodity_description": "Automatic data processing machines (laptops)", "origin_country": "CN", "declared_value_usd": 48200, "gross_weight_kg": 1240, "risk_channel": "GREEN", "inspected": false, "inspection_outcome": null, "dwell_time_days": 4.2, "importer_sector": "ELECTRONICS_RETAIL", "importer_size_band": "MEDIUM" }, { "declaration_id": "DCL-GHA-TM-20231015-0031874", "country_code": "GH", "port_code": "GHTMA", "trade_flow": "IMPORT", "declaration_date": "2023-10-15", "hs_chapter": 10, "hs_code_6digit": "100190", "commodity_description": "Wheat and meslin — bulk grain", "origin_country": "UA", "declared_value_usd": 312000, "gross_weight_kg": 950000, "risk_channel": "AMBER", "inspected": true, "inspection_outcome": "COMPLIANT", "dwell_time_days": 8.7, "importer_sector": "FOOD_DISTRIBUTION", "importer_size_band": "LARGE" }, { "declaration_id": "DCL-KEN-MB-20230829-0058341", "country_code": "KE", "port_code": "KEMBA", "trade_flow": "IMPORT", "declaration_date": "2023-08-29", "hs_chapter": 87, "hs_code_6digit": "870332", "commodity_description": "Motor vehicles for transport of persons (1500–3000cc)", "origin_country": "JP", "declared_value_usd": 22500, "gross_weight_kg": 1800, "risk_channel": "RED", "inspected": true, "inspection_outcome": "UNDERVALUATION", "dwell_time_days": 21.3, "importer_sector": "AUTOMOTIVE", "importer_size_band": "SMALL" }, { "declaration_id": "DCL-ZAF-DR-20231201-0094012", "country_code": "ZA", "port_code": "ZADUR", "trade_flow": "EXPORT", "declaration_date": "2023-12-01", "hs_chapter": 26, "hs_code_6digit": "260111", "commodity_description": "Iron ores and concentrates, non-agglomerated", "origin_country": "ZA", "declared_value_usd": 1840000, "gross_weight_kg": 45000000, "risk_channel": "GREEN", "inspected": false, "inspection_outcome": null, "dwell_time_days": 2.1, "importer_sector": "MINING_EXPORT", "importer_size_band": "LARGE" } ]
Request Dataset Access

All datasets are available under a commercial licence agreement. Our team typically responds within 2 business days.

Request Access
NDA may be required

Build with Data that reflects Africa

Request access to our full catalog of licensed human-validated African datasets or request custom data tailored to your project.