When shipping to PO Box addresses, special handling is required as these addresses can only be serviced by specific carriers. This guide explains how to properly handle PO Box addresses in your integration.
When dealing with PO Box addresses:
Australia Post (ID: 513)
, as this is the only carrier that services PO Box addresses{warning} Failing to properly handle PO Box addresses may result in failed deliveries or invalid rate requests.
To detect PO Box addresses, check for these common patterns in the address string:
When any of these patterns are found in an address (case insensitive), the address should be treated as a PO Box and routed to Australia Post.
Example logic flow:
To preset the carrier on the createConsignment request, you would append it to the payload as follows:
{
...
"carrierId": 513,
...
}