API Request Body
Header section
Level | Name | Required | Type | Description | Applicable Ports |
---|---|---|---|---|---|
0 | header | PreadviceHeader | No | Pre-advice header information | |
1 | ShipperName | Mandatory | string | Shipper name | ALL |
1 | ConsigneeName | Optional | string | Consignee name | NZTRG / NZTIU |
1 | BookingReference | Mandatory | string | Booking reference | ALL |
1 | MessageAction | Mandatory | string (Create/Cancel) | Message action type | ALL |
1 | PointOfOriginCode | Mandatory | string | Point of origin code | ALL |
1 | LoadPortFacility | Mandatory | string | Load port facility | ALL |
1 | Vessel | Mandatory | GenericPreadviceVessel | Vessel information | ALL |
2 | shipName | Conditional | string | Vessel Name | ALL |
2 | voyageNumber | Conditional | string | Voyage Number | ALL |
2 | partnerPortShippingReference | Conditional | string | Port Vessel reference | ALL |
1 | NotificationEmails | Mandatory | string[] | List of notification email addresses | ALL |
1 | UserName | Mandatory | string | User name | ALL |
1 | UserReference | Mandatory | string | User reference | ALL |
1 | LineOperatorCode | Mandatory | string | Line operator code | ALL |
1 | LoadPortCode | Mandatory | string | Load port code | ALL |
1 | PortOfDischarge | Mandatory | string | Port of discharge | ALL |
1 | ForeignPortOfDischarge | Optional | string | Foreign port of discharge | ALL |
1 | OverseasDestinationFinal | Optional | string | Overseas destination final | ALL |
Container section
Level | Name | Required | Repeats | Type | Description | Applicable Ports |
---|---|---|---|---|---|---|
0 | containers | PreadviceContainer[] | Yes | List of container information | ||
1 | ContainerNumber | Mandatory | No | string | Container number | ALL |
1 | AttachedContainerNumbers | Optional | No | List<string> | List of attached container numbers | |
1 | IsoTypeCode | Mandatory | No | string | ISO type code for the container | ALL |
1 | FlexiTank | Optional | No | bool? | Indicates if the container is a flexi tank | NZTRG / NZTIU |
1 | IsFull | Mandatory | No | bool? | Indicates if the container is full | ALL |
1 | CommodityCode | Mandatory | No | string | Commodity code | |
1 | IsNonOperatingReefer | Optional | No | bool? | Indicates if the container is a non-operating reefer | |
1 | Refrigeration | Optional | No | GenericPreadviceRefrigeration | Refrigeration details for the container. Only required if container ISO Type is a Reefer ISO type | |
2 | isFantainer | Optional | No | bool? | ||
2 | co2Percent | Optional | No | float | ||
2 | o2Percent | Optional | No | float | ||
2 | humidityPercent | Optional | No | float | ||
2 | requiredTemperature | Conditional | No | float | ||
2 | refrigerationType | Optional | No | string | ||
2 | humidityPercent | Optional | No | |||
2 | RefrigerationType | Optional | No | string | “Chilled” | |
2 | offPowerTemperature | Optional | No | NZAKL | ||
2 | offPowerTimestamp | Optional | No | NZAKL | ||
2 | onPowerTargetTime | Optional | No | NZAKL | ||
1 | Vent | Optional | No | GenericPreadviceVent | Vent details for the container | |
2 | ventSettingType | Optional | No | |||
2 | ventSetting | Optional | No | |||
1 | CargoWeightKg | Mandatory | No | float | Cargo weight in kilograms | |
1 | TotalWeightKg | Mandatory | No | float | Total weight of the container in kilograms | |
1 | Hazardous | Optional | No | GenericPreadviceHazardous[] | List of hazardous details | |
2 | hazardousClass | Conditional | Yes | |||
2 | unNumber | Conditional | Yes | |||
2 | packagingGroup | Conditional | Yes | |||
2 | limitedQuantities | Conditional | Yes | |||
2 | marinePollutant | Conditional | Yes | |||
2 | hazardousWeight | Conditional | Yes | |||
2 | quantity | Conditional | Yes | |||
2 | emsCode | Conditional | Yes | |||
2 | hazardContact | Conditional | Yes | |||
3 | name | Conditional | Yes | |||
3 | phone | Conditional | Yes | |||
2 | medicalFirstAidGuideSet | Conditional | Yes | TRG/TIU | ||
2 | flashPointSet | Conditional | Yes | TRG/TIU | ||
1 | OverGauge | Optional | No | GenericPreadviceOverDimension[] | List of over-dimension details | |
2 | area | Conditional | Yes | String | TOP, LEFT, RIGHT, FRONT, BACK | |
2 | measureCm | Conditional | Yes | |||
1 | ContainerSeals | Mandatory | No | GenericPreadviceContainerSeal[] | List of container seals | |
2 | sealType | Mandatory | Yes | string | ||
2 | sealCode | Mandatory | Yes | string | ||
1 | ArrivalCarrierType | Mandatory | No | GenericPreadviceArrivalCarrierTypes? | Arrival carrier type | |
1 | Carrier | Mandatory | No | string | Carrier details | |
1 | HazardousCertificateBase64 | Optional | No | string | Base64 encoded hazardous certficate |
Test URL:
POST https://apitest.portconnect.io/v1/export-preadvices
Example Messages
All fields example:
{ "header": { "shipperName": "FNT", "loadPortCode": "NZAKL", "bookingReference": "SHIPPINGLINEBOOKINGREF", "pointOfOriginCode": "AKC", "vessel": { "shipName": "CMA CGM SEMARANG", "voyageNumber": "2416", "partnerPortShippingReference": "CMC9741" }, "loadPortFacility": "Auckland", "lineOperatorCode": "ARMC", "portOfDischarge": "AUMEL", "foreignPortOfDischarge": "AUMEL", "userReference": "UNIQUEREFERENCE", "notificationEmails": ["info@portconnect.co.nz"] }, "containers": [{ "containerNumber": "HAZD1234510" "attachedContainerNumbers": [], "isoTypeCode": "4500", "isFull": true, "commodityCode": "74", "isNonOperatingReefer": false, "cargoWeightKg": 16000.0, "totalWeightKg": 18000.0, "hazardous": [{ "medicalFirstAidGuideSet": true, "flashPointSet": true, "hazardousClass": "2.1", "unNumber": "1950", "packagingGroup": "1", "limitedQuantities": true, "marinePollutant": true, "hazardousWeight": 200.0, "quantity": "10", "emsCode": "F-BS-C", "hazardContact": { "name": "John Smith", "phone": "021 588 998" } }, { "medicalFirstAidGuideSet": true, "flashPointSet": true, "hazardousClass": "2.2", "unNumber": "1950", "packagingGroup": "0", "limitedQuantities": false, "marinePollutant": false, "hazardousWeight": 1000.0, "quantity": "75", "emsCode": "F-YS-Y", "hazardContact": { "name": "John Smith", "phone": "021 588 998" } }], "containerSeals": [{ "sealType": "Shipper", "sealCode": "4455" }], "arrivalCarrierType": "Rail", "carrier": "CONLIN" }, { "containerNumber": "OOGC1234651" "attachedContainerNumbers": [], "isoTypeCode": "22P1", "isFull": true, "commodityCode": "47", "isNonOperatingReefer": false, "cargoWeightKg": 16000.0, "totalWeightKg": 18000.0, "overGauge": [{ "area": "Top", "measureCm": 10.0 }, { "area": "Left", "measureCm": 20.0 }, { "area": "Right", "measureCm": 30.0 }, { "area": "Front", "measureCm": 40.0 }, { "area": "Back", "measureCm": 50.0 }], "containerSeals": [{ "sealType": "Shipper", "sealCode": "TBC" }], "arrivalCarrierType": "Truck", "carrier": "AACAR " }, { "containerNumber": "REEF1234510" "attachedContainerNumbers": [], "isoTypeCode": "2230", "isFull": true, "commodityCode": "2199", "refrigeration": { "isFantainer": false, "co2Percent": 50.0, "o2Percent": 40.0, "maximumOffPowerHours": 24.0, "offPowerTemperature": -21.0, "offPowerTimestamp": "2024-09-11T10:00:00+12:00", "onPowerTargetTime": "2024-09-11T10:00:00+12:00", "requiredTemperature": -21.0, "humidityPercent": 20.0, "refrigerationType": "Chilled" }, "vent": { "ventSettingType": "PercentageOpen", "ventSetting": 30.0 }, "cargoWeightKg": 16000.0, "totalWeightKg": 18000.0, "containerSeals": [{ "sealType": "Shipper", "sealCode": "1223" }, { "sealType": "Shipper", "sealCode": "5665" }], "arrivalCarrierType": "Truck", "carrier": "WALTER" }] }
Reefer / Hazard example
{ "header": { "shipperName": "FNT", "loadPortCode": "NZAKL", "bookingReference": "SHIPPINGLINEBOOKINGREF", "pointOfOriginCode": "AKC", "vessel": { "shipName": "CMA CGM SEMARANG", "voyageNumber": "2416", "partnerPortShippingReference": "CMC9741" }, "loadPortFacility": "Auckland", "lineOperatorCode": "ARMC", "portOfDischarge": "AUMEL", "foreignPortOfDischarge": "AUMEL", "userReference": "UNIQUEREFERENCE", "notificationEmails": ["chris.boxall@portconnect.co.nz"] }, "containers": [{ "containerNumber": "REEF1234510", "attachedContainerNumbers": [], "isoTypeCode": "2230", "isFull": true, "commodityCode": "2199", "refrigeration": { "isFantainer": false, "co2Percent": 50.0, "o2Percent": 40.0, "maximumOffPowerHours": 24.0, "offPowerTemperature": -21.0, "offPowerTimestamp": "2024-09-11T10:00:00+12:00", "onPowerTargetTime": "2024-09-11T10:00:00+12:00", "requiredTemperature": -21.0, "humidityPercent": 20.0, "refrigerationType": "Chilled" }, "vent": { "ventSettingType": "PercentageOpen", "ventSetting": 30.0 }, "cargoWeightKg": 16000.0, "totalWeightKg": 18000.0, "hazardous": [{ "medicalFirstAidGuideSet": true, "flashPointSet": true, "hazardousClass": "2.1", "unNumber": "1950", "packagingGroup": "1", "limitedQuantities": true, "marinePollutant": false, "hazardousWeight": 200.0, "quantity": "20", "emsCode": "F-AS-B", "hazardContact": { "name": "John Smith", "phone": "021 345 678" } }], "containerSeals": [{ "sealType": "Shipper", "sealCode": "1223" }, { "sealType": "Shipper", "sealCode": "5665" }], "arrivalCarrierType": "Truck", "carrier": "WALTER" }] }
Example Request Body short:
{ "header": { "shipperName": "ALNEMAH HALAL MEAT LIMITED", "bookingReference": "1AKL026740", "lineOperatorCode": "HSUD", "loadPortCode": "NZTRG", "portOfDischarge": "USLGB", "foreignPortOfDischarge": "USLGB" "pointOfOriginCode": "Bay of Plenty", "loadPortFacility": "TCT", "vessel": { "shipName": "DEBUSSY", "voyageNumber": "138N", "partnerPortShippingReference": "USY138N", }, "notificationEmails": [ "Cameron.Pitches@portconnect.co.nz" ], "userReference": "CAMTEST001" }, "containers": [ { "containerNumber": "CDPU3736837", "isoTypeCode": "2200", "flexiTank": false, "isFull": true, "commodityCode": "0201" }, "cargoWeightKg": 28000.0, "totalWeightKg": 30000.0, "containerSeals": [ { "sealType": "Shipper", "sealCode": "555" } ], "arrivalCarrierType": "Truck" } ] }
Example Response:
Export pre-advice success
{ "success": true, "errors": [], "containers": [ { "containerNumber": "CDPU3736837", "errors": [], "success": true } ] }
However, should the requiredTemperature value be set to -50 in the example above, then the following is returned:
Export pre-advice partial failure
{ "success": true, "errors": [], "containers": [ { "containerNumber": "CDPU3736837", "errors": [ "Temperature too high/low for the selected commodity (Range: -5.0 to 2.0). Change commodity or contact Terminal" ], "success": false } ] }
Pre-Advice validation rules
Must provide a valid booking
Load Port must match the booking
Load Port must be valid
Line Operator code must be valid
Line Operator code must match the booking
Vessel Visit must match the booking
Discharge Port must match the booking
Reefer ISO type containers must have a Temperature (unless specified as a Non-Operating Reefer)
Freight Kind (Full vs Empty) must match the booking
Reefer temperatures must match the booking
Conditioning details must match the booking. Conditioning details include: Humidity %, Vent value, Vent Type, O2% and CO2%
Hazard UN Codes must match the booking
Container ISO Type Groups much match the booking.
Total Pre-Advised Containers must not exceed the booking quanta (count)
Seal Type must be valid