Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Excerpt
hiddentrue
namesimple

GET /v1/scheduled-vessels

This end point returns vessels that are scheduled to arrive at vessel schedule data from our partner ports. It can also be used to query vessels currently in port and vessels that have recently departedbe filtered by Port, Vessel Type, Arrival status and arrival time. This data is updated approximately every 15 minutes.

...

Code Block
GET https://api.portconnect.io/v1/scheduled-vessels

Query Parameters

By default the API returns all vessel schedule data from all our partner ports. Filters are used for narrowing down the data that is returned. Each filter can only be used with a single value and the filter cannot be repeated in the call - i.e. if you wish to filter for INPORT and DEPARTED vessels then you will need to make two separate calls.

Name

Description

portCode

UN code for the port. NZAKL, NZTRG, NZTIU or NZLYT.

vesselType

Either

cruise

CRUISE or

commercial

COMMERCIAL

vesselStatus

One of

expected

EXPECTED,

inport

INPORT or

departed

DEPARTED

arrivalDateFrom

Filters vessels arriving from and including this date. YYYY-MM-DDTHH:MM:SS format

arrivalDateTo

Filters vessles arriving to and including this date. YYYY-MM-DDTHH:MM:SS format

Example Request:

This request will return all vessel schedule data from all our partner ports.

Code Block
https://api.portconnect.io/v1/scheduled-vessels

This request will return all vessel schedule data for Tauranga.

Code Block
https://api.portconnect.io/v1/scheduled-vessels?portCode=NZTRG

This request will return all commercial vessels (excludes cruise ships) for Auckland that are expected to arrive between 2nd May 12:00am and 31st May 12:00 am:Tauranga that are in port.

Code Block
https://api.portconnect.io/v1/scheduled-vessels?portCode=NZAKLNZTRG&vesselType=COMMERCIAL&vesselStatus=EXPECTED&arrivalDateFrom=2022-05-02&arrivalDateTo=2022-05-31INPORT

This request will return all commercial vessels (excludes cruise ships) for Auckland that are expected to arrive between 12nd May 12:00pm 00am and 2:00pm on the 2nd May.  Times are NZ Daylight saving31st May 12:00 am:

Code Block
https://api.portconnect.io/v1/scheduled-vessels?portCode=NZAKL&vesselType=COMMERCIAL&vesselStatus=EXPECTED&arrivalDateFrom=2022-05-02T13:00:0002&arrivalDateTo=2022-05-02T14:00:0031

Example Response:

The response data is the same as that returned via the vessel schedule screen on the PortConnect website, and should be self-explanatory.

Code Block
languagejson
[
  {
    "vesselVisitReference": "ABCD1234",
    "vesselName": "Vessel1",
    "imoNumber": 1234567,
    "inboundVoyage": "Voyage1",
    "alternativeInboundVoyage": null,
    "outboundVoyage": null,
    "alternativeOutboundVoyage": null,
    "vesselStatus": "Expected",
    "vesselType": "Cruise",
    "portCode": "NZAKL",
    "wharfName": null,
    "previousPortName": null,
    "nextPortName": "NZAUK",
    "vesselOperator": "ShippingLine1",
    "serviceCode": null,
    "arrivalDatetime": "2023-04-15T08:00:00+12:00",
    "departureDatetime": null,
    "receivalCommenceInland": null,
    "receivalCommenceSeaport": null,
    "receivalCutoffInland": null,
    "rcvCommReeferinland": null,
    "rcvCommHazinland": null,
    "rcvCutoffHazinland": null,
    "rcvCommReeferSeaport": null,
    "rcvCommHazSeaport": null,
    "rcvCutoffHazSeaport": null,
    "receivalCutoffSeaport": null,
    "lastUpdatedDateTime": "2023-04-19T20:00:00+12:00",
    "visitPhase": "WORKING"
  }
]

...