Skip to main content
How Intelligent Address Formatting Works
Back
Throughout This Page
You can jump to the specified sections by clicking on these titles.

Overview

The Shipping API empowers users with the capability to validate both domestic and international addresses before generating labels. This functionality mitigates the risk of failed deliveries stemming from inaccurate address information. As part of our commitment to enhancing delivery services, we are pleased to provide this feature to all our users at no cost.

This documentation elucidates the utilization of this valuable feature and expounds upon the techniques employed by the Intelligent Address Formatter.

Intelligent Address Formatting

Only accurate or complete customer data can lead to a critical issue, often concerning incorrect address information. To address this challenge, we introduce the "format_address_default" parameter in the shipment object of the create-label request. Enabling this parameter activates the Intelligent Address Formatting feature for the associated request.

By activating this feature, the system smartly handles scenarios where requested alterations conflict with a specific courier's capabilities. In such cases, incompatible adjustments are gracefully bypassed, thereby preventing label request rejections.

Beneath, we outline a comprehensive array of methods employed by the Intelligent Address Formatter to rectify these concerns. An illustrative sample of the addressing section within a label request is visualized in the image below.

Methods of Intelligent Address Formatting:

  • ISO and Country Harmony: The Shipping API seamlessly intervenes when a particular courier necessitates the human-readable country name and its corresponding ISO code. It automatically populates the country name based on the provided ISO code. For instance, "GB" is transformed into "United Kingdom."
  • Standardization via State Codes: For shipments headed to the US, Canada (CA), or Australia (AU), human-readable county values are converted into ISO format. For instance, "Florida" becomes "FL," and "New South Wales" becomes "NSW."
  • Phone Country Validation: The Intelligent Address Formatter eliminates symbols from phone numbers (except for "+"). Additionally, an extra check confirms whether the provided number falls within the 11-14 character range for shipments bound for GB. If compliant, the number remains unchanged; if not, it defaults to "01111111111."
  • Default Phone Number Fill: In cases where a phone number isn't specified in the request, a default value of "01111111111" is automatically inserted.
  • Rectification of Phone Number Plus Symbol: If your phone number includes a "+" symbol, it is replaced with "00."
  • Default Email Address Insertion: When no email address is provided, a default value of "[email protected]" is used.
  • Name Auto-Population: When a "company_name" is provided but not a "name," the "company_name" value is duplicated into the "name" field.
  • UK Post Code Correction: The system validates and corrects postcode formatting for shipments destined for GB, ensuring accurate presentation to the courier. Adjustments could involve proper spacing between the prefixes and suffixes.
  • Address Line Length Management: Should Address Line 1 exceed the courier's character limit, it is automatically split into Address Line 2. Similarly, if Address Line 2 exceeds limits, it's divided into Address Line 3.