Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Panel
titleContents
Table of Contents
maxLevel2

What is B2B Pre-Advice?

Business to Business (B2B) Pre-Advice is a way pre-advise export containers by sending pre-advice details in an XML format to PortConnect. The export information can be extracted from your system in the XML format and sent to PortConnect. PortConnect will automatically process the file and email back a confirmation of success or failure.

...

Level

XML Element

Required segments

Repeats

Data Type

Description

Applicable Port

0

PreadviseContainerRequest

Y

N

--

This is the message header and includes an attribute. This must match exactly what is in the below examples.

ALL

1

header

Y

N

--


ALL

2

MessageType

Y

N

String

Enter “ExportPreAdvice”

ALL

2

TradingPartnerCode

Y

N

String

Portconnect will inform you on what this code is

ALL

2

PartnerPortCode

Y

N

String

This is either NZAKL, NZTRG or NZTIU

ALL

2

BusinessNotificationEmailList

Y

N

String

Semi colon separated list of emails to send Pre-Advice Acknowledgment emails to

ALL

2

UserName

Y

N

String

PortConnect login name

ALL

2

UserPassword

N

N

String

Enter “unknown” (function still in development)

ALL

1

PreAdvice

Y

N

--


ALL

2

Shipper

Y

N

--


ALL

3

name

Y

N

String (40)

The name of the Exporter or the party with the contract with the shipping line. This is a Code. Please provide PortConnect with a list of shippers and PortConnect will provide the relevant code.

ALL

3

shipperReference

Y

N

String

This is your own internal reference and can be anything

ALL

2

Equipment

Y

Y

String

Add a space then add the following attribute to the the opening element ‘equipmentType=’. Then include the following text: “CONTAINER” – Include the speech marks. The Equipment segment and all relevant sub-segments repeat when adding multiple containers.

ALL

3

equipmentID

Y

N

String (11)

Container Number

ALL

3

attachedEquipmentIDs

N

N

--

Segment to list bundled flatrack containers.

NZTRG, NZTIU

4

equipmentID

Y

Y

String (11)

Container Number

NZTRG, NZTIU

3

isoTypeCode

Y

N

String

e.g. 2210, 4500 etc using the UN standard ISO codes

ALL

3

flexiTank

N

N

Boolean

Either true or false - must be lower case.

NZTRG, NZTIU

3

isFull

Y

N

Boolean

Either true or false - must be lower case

ALL

3

isNonOperatingReefer

N

N

Boolean

Either true or false - must be lower case. If True then Refrigeration segment does not need to be included.

ALL

3

commodityCode

Y

N

String

e.g. 10, 1701, 081050 etc using the Harmonised System codes here, Commodity Code List. Enter the commodity which makes up the greatest percentage of the container

ALL

3

LoadPortFacility

Y

N

String

This is the facility the container will be delivered to.
NZTRG locations are: “MET” - Metroport Auckland, “TCT” – Tauranga Container Terminal and ‘RUA’ - Ruakura.
NZAKL location is: “Auckland”
NZTIU locations are: “ROL” – Metroport Rolleston and “PPT” Timaru Container Terminal

ALL

3

MessageAction

Y

N

String

For new Pre-Advice or updates to previously submitted containers enter “Create”. To Cancel a previously submitted incorrect container number enter "Cancel".

ALL

3

refrigeration

Y

N

String

If the container is a reefer, add a space then add the following attribute to the the opening element ‘refrigerationType=’. Then include one of the following options: “FROZEN”, “CHILLED”, “INSULATED”, “HOT” – Include the speech marks

ALL

4

isFantainer

Y

N

Boolean

Either true or false - must be lower case.

ALL

4

offPowerTemperature

N

N

Float

NO LONGER SUPPORTED

NZAKL

4

maximumOffPowerHours

N

N

Float

Number in hours. This must be whole numbers - no decimal points. This should be calculated from the offPowerTimestamp datetime.

NZAKL

4

offPowerTimestamp

N

N

Datetime

e.g. 2014-05-31T13:20:00.000

NZAKL

4

onPowerTargetTime

N

N

Datetime

NO LONGER SUPPORTED

NZAKL

4

timeAllowedOffPowerHours

N

N

Float

Number in hours. This must be whole numbers - no decimal points. Applies to after Gate-In time.

When including this segment you must also supply <timeAllowedOffPowerMinutes>

If the time allowed off power is a whole number supply:

<timeAllowedOffPowerHours>Xhours<timeAllowedOffPowerHours>

<timeAllowedOffPowerMinutes>0<timeAllowedOffPowerMinutes>

NZTRG, NZTIU

4

timeAllowedOffPowerMinutes

N

N

Float

Number in Minutes. This must be whole numbers - no decimal points. Applies to after Gate-In time.

When including this segment you must also supply <timeAllowedOffPowerHours>

If the time allowed off power is a whole number supply:

<timeAllowedOffPowerHours>Xhours<timeAllowedOffPowerHours>

<timeAllowedOffPowerMinutes>0<timeAllowedOffPowerMinutes>

If the time allowed off power is a whole less than 1 hour supply:

<timeAllowedOffPowerHours>0<timeAllowedOffPowerHours>

<timeAllowedOffPowerMinutes>Xminutes<timeAllowedOffPowerMinutes>

NZTRG, NZTIU

4

activeRefrigerationRequired

N

N

Boolean

Either true or false - must be lower case.

NZTRG, NZTIU

4

requiredTemperature

*

N

Float

*If the container is a reefer then this field is required. Put a minus symbol in front of the number if it is a negative number.

ALL

4

humidityPercent

N

N

Float

Humidity percentage

ALL

4

co2Percent

N

N

Float

CO2 percentage

ALL

4

o2Percent

N

N

Float

O2 percentage

ALL

3

vent

N

N

--


ALL

4

VentSettingType

N

N

String

Value list: PercentageOpen, FlowM3PerHour

ALL

4

VentSetting

N

N

Float


ALL

3

IMEX

Y

N

--


ALL

4

LineOperatorCode

Y

N

String

MAEU, ACLU, HSUD etc. See the following list for all Shipping Lines.

ALL

4

shipName

Y

N

String

Name of the vessel - This element is mandatory but the content can be blank if you have entered the partnerPortshippingReference details

ALL

4

voyageNumber

Y

N

String

Voyage number - This element is mandatory but the content can be blank if you have entered the partnerPortshippingReference details

ALL

4

partnerPortshippingReference

Y

N

String (20)

Vessel reference – This element is mandatory but the content can be blank if you have entered the shipName and voyageNumber details. If you are not entering a value then the element needs to be in one of the following formats:

<ns0:partnerPortshippingReference></ns0:partnerPortshippingReference>

<ns0:partnerPortshippingReference/>

If the element has a space in between then this can cause the Pre-Advice to fail.

Note - in additon to the above, PortConnect will attempt to populate the Vessel Reference directly from the booking in preference of any details supplied by the pre-adviser. This is intended to reduce booking discrepancies.

ALL

4

loadPortCode

Y

N

String

NZAKL, NZTRG or NZTIU

ALL

4

portOfDischarge

Y

N

String

As per the vessel voyage rotation - UN Location code.

If you don't know what this value is you can leave the element empty and PortConnect can populate this value for you if the shipping line has sent a valid booking. If the value cannot be populated from the booking then you will receive a validation error and you will be required to populate the value yourself before the Pre-Advice can be submitted to the port.

ALL

4

foreignPortOfDischarge

N

N

String

Final destination port - UN Location code

ALL

4

overseasDestinationFinal

N

N

String

Final destination - UN Location code

ALL

4

cutOffTimestamp

N

N

Datetime

Final export gate in time for vessel

ALL

4

bookingReference

Y

N

String (20)

Shipping Line booking reference - Must be capitals. Only 1 booking per Pre-Advice message. Mixing bookings may result it validation errors.

ALL

4

customsClearanceNumber

N

N

String (16)

If known

ALL

4

exportEntryNumber

N

N

String (16)

If known

ALL

3

CargoWeight

Y

N

Float

Weight of the cargo. Must be in KGs.

ALL

3

TotalWeight

Y

N

Float

This segment is where you must enter the Verified Gross Mass of the container. Must be in KGs.

ALL

3

hazardous

N

Y

--


ALL

4

hazardousClass

N

N

String (25)

e.g. 1.1f, 1.1g etc.

ALL

4

UNNumber

N

N

String (20)

e.g. 0005, 0121 etc

ALL

4

quantity

N

N

String

Number and Type of packages e.g. 2 Pallets or 1 box

ALL

4

packagingGroup

N

N

Float

Values: 0, 1, 2 or 3. If no packaging group then select 0.

ALL

4

limitedQuantities

N

N

Boolean

Either true or false - must be lower case.

ALL

4

marinePollutant

N

N

Boolean

Either true or false - must be lower case.

ALL

4

hazardousWeight

N

N

Float

Weight of the hazardous cargo. Must be in KGs.

ALL

4

emsCode

N

N

String (20)

Fire Rating and Spill Rating. F-A to F-Z and S-A to S-Z. No space between values.

ALL

4

flashPoint

N

N

Float

Range: -999-999

NZTRG, NZTIU

4

medicalFirstAidGuide

N

N

String (50)

NZTRG, NZTIU

4

contactPhone

N

N

String (50)

ALL

4

contactName

N

N

String (255)

ALL

3

hazardousCertificate

N

N

ALL

4

hazardousCertficateBase64

N

N

String

The base64 content must sit within a CDATA segment ie. <![CDATA[Base64ContentHere]]>

ALL

3

overGauge

N

Y

--


ALL

4

OverDimensionArea

N

N

String

Value list: Back, Front, Top, Bottom, Left, Right. Note - this segment is case sensitive and the values must be entered exactly as recorded here with Proper Case.

ALL

4

OverDimensionUOM

N

N

String

Value: CENTIMETER

ALL

4

OverDimensionMeasure

N

N

Double

This is the cm measurement of the over dimension

ALL

3

containerSeals

Y

Y

--


ALL

4

SealType

Y

N

String

Value list: NZFSA, LineOperator, Shipper, Other.

If you enter a value that is not on our approved list then the Pre-Advice will fail.

NZFSA stands for NZ Food Safety Authority and this is the seal type you must enter when using MPI seals.

If you are using a shipping line seal then you can enter the seal type as LineOperator.

ALL

4

SealCode

Y

N

String

The seal number. This field most only include alphanumeric characters - It must not include any special characters.

ALL

3

arrivalCarrierType

Y

N

String

Value list: Truck, Rail. This is the mode of arrival at the receival facility which can be an inland port or directly to the Seaport

ALL

3

arrivalCarrier

N

N

String

See the following list for all Arrival Carrier Codes. This segment is currently only sent to Port of Tauranga.

ALL

3

pointOfOriginCode

Y

N

String

Location where the container was packed or the goods originated from - UN Location code. If your location is not in the list then use the nearest UN location

ALL

2

comments

N

N

String (255)

Additional comments (not currently read by the ports)

ALL

...

Code Block
languagexml
<ns0:PreadviseContainerRequest xmlns:ns0="http://PortConnect.ExportPreAdvice.BizTalk.GenericXML/201404">
	<ns0:header>
		<ns0:MessageType>ExportPreAdvice</ns0:MessageType>
		<ns0:TradingPartnerCode>TradingPartnerCode_0</ns0:TradingPartnerCode>
		<ns0:PartnerPortCode>DestinationPortCode_0</ns0:PartnerPortCode>
		<ns0:BusinessNotificationEmailList>EmailList_0</ns0:BusinessNotificationEmailList>
		<ns0:UserName>yourusername</ns0:UserName>
		<ns0:UserPassword>yourpassword</ns0:UserPassword>
	</ns0:header>
	<ns0:PreAdvice>
		<ns0:Shipper>
			<ns0:name>name</ns0:name>
			<ns0:shipperReference>shipperReference_0</ns0:shipperReference>
		</ns0:Shipper>
		<ns0:Equipment equipmentType="CONTAINER">
			<ns0:equipmentID>equipmentIDequ</ns0:equipmentID>
			<ns0:attachedEquipmentIDs>
				<ns0:equipmentID>aaaaaaaaaa</ns0:equipmentID>
				<ns0:equipmentID>bbbbbbbbbb</ns0:equipmentID>
			</ns0:attachedEquipmentIDs>
			<ns0:isoTypeCode>isoTypeCode_0</ns0:isoTypeCode>
			<ns0:flexiTank>true</ns0:flexiTank>
			<ns0:isFull>true</ns0:isFull>
			<ns0:isNonOperatingReefer>false</ns0:isNonOperatingReefer>
			<ns0:commodityCode>commodityCode_0</ns0:commodityCode>
			<ns0:LoadPortFacility>LoadPortFacility_0</ns0:LoadPortFacility>
			<ns0:MessageAction>Create</ns0:MessageAction>
			<ns0:refrigeration refrigerationType="FROZEN">
				<ns0:isFantainer>true</ns0:isFantainer>
				<ns0:maximumOffPowerHours>10</ns0:maximumOffPowerHours>
				<ns0:offPowerTemperature>10</ns0:offPowerTemperature>
				<ns0:offPowerTimestamp>2014-05-31T13:20:00.000</ns0:offPowerTimestamp>
				<ns0:onPowerTargetTime>2014-05-31T13:20:00.000</ns0:onPowerTargetTime>
				<ns0:timeAllowedOffPowerHours>2</ns0:timeAllowedOffPowerHours>
				<ns0:timeAllowedOffPowerMinutes>3</ns0:timeAllowedOffPowerMinutes>
				<ns0:activeRefrigerationRequired>true</ns0:activeRefrigerationRequired>
				<ns0:requiredTemperature>10</ns0:requiredTemperature>
				<ns0:humidityPercent>10</ns0:humidityPercent>
				<ns0:co2Percent>10</ns0:co2Percent>
				<ns0:o2Percent>10</ns0:o2Percent>
			</ns0:refrigeration>
			<ns0:vent>
				<ns0:VentSettingType>PercentageOpen</ns0:VentSettingType>
				<ns0:VentSetting>10</ns0:VentSetting>
			</ns0:vent>
			<ns0:IMEX>
				<ns0:LineOperatorCode>LineOperatorCode_0</ns0:LineOperatorCode>
				<ns0:shipName>shipName_0</ns0:shipName>
				<ns0:voyageNumber>voyageNumber_0</ns0:voyageNumber>
				<ns0:partnerPortshippingReference>partnerPor</ns0:partnerPortshippingReference>
				<ns0:loadPortCode>loadPortCode_0</ns0:loadPortCode>
				<ns0:portOfDischarge>portOfDischarge_0</ns0:portOfDischarge>
				<ns0:foreignPortOfDischarge>foreignPortOfDischarge_0</ns0:foreignPortOfDischarge>
				<ns0:overseasDestinationFinal>overseasDe</ns0:overseasDestinationFinal>
				<ns0:cutOffTimestamp>1999-05-31T13:20:00.000</ns0:cutOffTimestamp>
				<ns0:bookingReference>BOOKINGREF1</ns0:bookingReference>
				<ns0:customsClearanceNumber>customsClearance</ns0:customsClearanceNumber>
				<ns0:exportEntryNumber>exportEntryNumbe</ns0:exportEntryNumber>
			</ns0:IMEX>
			<ns0:CargoWeight>2000</ns0:CargoWeight>
			<ns0:TotalWeight>4000</ns0:TotalWeight>
			<ns0:hazardous>
				<ns0:hazardousClass>4.1</ns0:hazardousClass>
				<ns0:UNNumber>2001</ns0:UNNumber>
				<ns0:quantity>1</ns0:quantity>
				<ns0:packagingGroup>1</ns0:packagingGroup>
				<ns0:limitedQuantities>false</ns0:limitedQuantities>
				<ns0:marinePollutant>false</ns0:marinePollutant>
				<ns0:hazardousWeight>400</ns0:hazardousWeight>
				<ns0:emsCode>F-AS-A</ns0:emsCode>
				<ns0:medicalFirstAidGuide>2</ns0:medicalFirstAidGuide>
				<ns0:flashPoint>-1</ns0:flashPoint>
				<ns0:contactPhone>0212345678</ns0:contactPhone>
				<ns0:contactName>John Smith</ns0:contactName>
			</ns0:hazardous>
			<ns0:hazardous>
				<ns0:hazardousClass>4.1</ns0:hazardousClass>
				<ns0:UNNumber>2001</ns0:UNNumber>
				<ns0:quantity>1</ns0:quantity>
				<ns0:packagingGroup>1</ns0:packagingGroup>
				<ns0:limitedQuantities>false</ns0:limitedQuantities>
				<ns0:marinePollutant>false</ns0:marinePollutant>
				<ns0:hazardousWeight>400</ns0:hazardousWeight>
				<ns0:emsCode>F-AS-A</ns0:emsCode>
				<ns0:medicalFirstAidGuide>2</ns0:medicalFirstAidGuide>
				<ns0:flashPoint>-999</ns0:flashPoint>
				<ns0:contactPhone>0212345678</ns0:contactPhone>
				<ns0:contactName>John Smith</ns0:contactName>
			</ns0:hazardous>
			<ns0:hazardousCertificate>
				<ns0:hazardousCertificateBase64><![CDATA[Base64ContentHere]]><ns0:hazardousCertificateBase64>
			</ns0:hazardousCertificate>
			<ns0:overGauge>
				<ns0:OverDimensionArea>Back</ns0:OverDimensionArea>
				<ns0:OverDimensionUOM>CENTIMETER</ns0:OverDimensionUOM>
				<ns0:OverDimensionMeasure>10</ns0:OverDimensionMeasure>
			</ns0:overGauge>
			<ns0:overGauge>
				<ns0:OverDimensionArea>Left</ns0:OverDimensionArea>
				<ns0:OverDimensionUOM>CENTIMETER</ns0:OverDimensionUOM>
				<ns0:OverDimensionMeasure>25</ns0:OverDimensionMeasure>
			</ns0:overGauge>
			<ns0:containerSeals>
				<ns0:SealType>NZFSA</ns0:SealType>
				<ns0:SealCode>SealCode1</ns0:SealCode>
			</ns0:containerSeals>
			<ns0:containerSeals>
				<ns0:SealType>Shipper</ns0:SealType>
				<ns0:SealCode>SealCode2</ns0:SealCode>
			</ns0:containerSeals>
			<ns0:arrivalCarrierType>Truck</ns0:arrivalCarrierType>
			<ns0:arrivalCarrier>Carrier_Name</ns0:arrivalCarrier>
			<ns0:pointOfOriginCode>pointOfOriginCode_0</ns0:pointOfOriginCode>
		</ns0:Equipment>
		<ns0:comments>comments</ns0:comments>
	</ns0:PreAdvice>
</ns0:PreadviseContainerRequest>

...

Code Block
languagexml
<ns0:PreadviseContainerRequest xmlns:ns0="http://PortConnect.ExportPreAdvice.BizTalk.GenericXML/201404">
	<ns0:header>
		<ns0:MessageType>ExportPreAdvice</ns0:MessageType>
		<ns0:TradingPartnerCode>TradingPartnerCode_0</ns0:TradingPartnerCode>
		<ns0:PartnerPortCode>DestinationPortCode_0</ns0:PartnerPortCode>
		<ns0:BusinessNotificationEmailList>EmailList_0</ns0:BusinessNotificationEmailList>
		<ns0:UserName>yourusername</ns0:UserName>
		<ns0:UserPassword>yourpassword</ns0:UserPassword>
	</ns0:header>
	<ns0:PreAdvice>
		<ns0:Shipper>
			<ns0:name>name</ns0:name>
			<ns0:shipperReference>shipperReference_0</ns0:shipperReference>
		</ns0:Shipper>
		<ns0:Equipment equipmentType="CONTAINER">
			<ns0:equipmentID>equipmentIDequ</ns0:equipmentID>
			<ns0:isoTypeCode>isoTypeCode_0</ns0:isoTypeCode>
			<ns0:isFull>true</ns0:isFull>
			<ns0:commodityCode>commodityCode_0</ns0:commodityCode>
			<ns0:LoadPortFacility>LoadPortFacility_0</ns0:LoadPortFacility>
			<ns0:MessageAction>Create</ns0:MessageAction>
			<ns0:refrigeration>
        <ns0:isFantainer>false</ns0:isFantainer>
			</ns0:refrigeration>
			<ns0:IMEX>
				<ns0:LineOperatorCode>LineOperatorCode_0</ns0:LineOperatorCode>
				<ns0:shipName>shipName_0</ns0:shipName>
				<ns0:voyageNumber>voyageNumber_0</ns0:voyageNumber>
				<ns0:partnerPortshippingReference>partnerPor</ns0:partnerPortshippingReference>
				<ns0:loadPortCode>loadPortCode_0</ns0:loadPortCode>
				<ns0:portOfDischarge>portOfDischarge_0</ns0:portOfDischarge>
				<ns0:foreignPortOfDischarge>foreignPortOfDischarge_0</ns0:foreignPortOfDischarge>
				<ns0:bookingReference>BOOKINGREF1</ns0:bookingReference>
			</ns0:IMEX>
			<ns0:CargoWeight>16000</ns0:CargoWeight>
			<ns0:TotalWeight>18000</ns0:TotalWeight>
			<ns0:hazardous>
				<ns0:hazardousClass>4.1</ns0:hazardousClass>
				<ns0:UNNumber>2001</ns0:UNNumber>
				<ns0:quantity>1</ns0:quantity>
				<ns0:packagingGroup>1</ns0:packagingGroup>
				<ns0:limitedQuantities>false</ns0:limitedQuantities>
				<ns0:marinePollutant>false</ns0:marinePollutant>
				<ns0:hazardousWeight>400</ns0:hazardousWeight>
				<ns0:emsCode>F-AS-A</ns0:emsCode>
				<ns0:medicalFirstAidGuide>2</ns0:medicalFirstAidGuide>
				<ns0:flashPoint>1</ns0:flashPoint>
				<ns0:contactPhone>0212345678</ns0:contactPhone>
				<ns0:contactName>John Smith</ns0:contactName>
			</ns0:hazardous>
			<ns0:hazardous>
				<ns0:hazardousClass>4.1</ns0:hazardousClass>
				<ns0:UNNumber>2001</ns0:UNNumber>
				<ns0:quantity>1</ns0:quantity>
				<ns0:packagingGroup>1</ns0:packagingGroup>
				<ns0:limitedQuantities>false</ns0:limitedQuantities>
				<ns0:marinePollutant>false</ns0:marinePollutant>
				<ns0:hazardousWeight>400</ns0:hazardousWeight>
				<ns0:emsCode>F-AS-A</ns0:emsCode>
				<ns0:medicalFirstAidGuide>2</ns0:medicalFirstAidGuide>
				<ns0:flashPoint>-999</ns0:flashPoint>
				<ns0:contactPhone>0212345678</ns0:contactPhone>
				<ns0:contactName>John Smith</ns0:contactName>
			</ns0:hazardous>
			<ns0:hazardousCertificate>
				<ns0:hazardousCertificateBase64><![CDATA[Base64ContentHere]]><ns0:hazardousCertificateBase64>
			</ns0:hazardousCertificate>
			<ns0:containerSeals>
				<ns0:SealType>Shipper</ns0:SealType>
				<ns0:SealCode>SealCode1</ns0:SealCode>
			</ns0:containerSeals>
			<ns0:arrivalCarrierType>Truck</ns0:arrivalCarrierType>
			<ns0:pointOfOriginCode>pointOfOriginCode_0</ns0:pointOfOriginCode>
		</ns0:Equipment>
	</ns0:PreAdvice>
</ns0:PreadviseContainerRequest>

...

 Latest changes to documentation

Date

Change

2024/04/23

Hazardous Certificate Base64 option added.

2024/01/04

Acknowledgment response XSD added.

2023/05/31

Cancel action message example added.

2022/10/11

XSD updated.

2022/05/26

  1. Added additional Hazardous segments to the XML Format section:

    1. flashPoint

    2. medicalFirstAidGuide

  2. Changed the Hazardous contact segment details in the XML Format section. The below fields are now at level 4 instead of level 5.

    1. contactName

    2. contactPhone

  3. Updated the Applicable Port section in the XML Format to reflect that a number of fields are now available for ALL ports.

  4. Updated the XML example messages to match the above changes.

...