Skip to content
Get started

Autocomplete

POST/v1/intl_addver/completions

Resolves an address preview id (from GET /completions) into a full address.

Optionally verifies the resolved address through the standard US/CA verifier when verify=true is supplied and the address is in the US or Canada.

  • Uses 1 lookup per call.
  • When verify=true resolves a US or CA address, the response will be a VerifiedAddress instead of an IntlAddressCompletion.
Query ParametersExpand Collapse
includeDetails: optional boolean
properCase: optional boolean
useEnhancedChinaDataset: optional boolean
verify: optional boolean
Body ParametersJSONExpand Collapse
id: string
ReturnsExpand Collapse
data: object { building, city, company, 12 more } or object { city, country, line1, 13 more }

A fully resolved international address returned by POST /completions.

One of the following:
IntlAddressCompletion object { building, city, company, 12 more }

A fully resolved international address returned by POST /completions.

building: optional string

The building name, if applicable.

city: optional string

The city or locality.

company: optional string

The company or organization name, if applicable.

country: optional string

The country name.

countryCode: optional string

The ISO 2-letter country code.

department: optional string

The department or floor, if applicable.

error: optional string

An error message if resolution failed.

formattedAddress: optional string

The full formatted address string.

line1: optional string

The first address line.

line2: optional string

The second address line.

line3: optional string

The third address line.

line4: optional string

The fourth address line.

postalOrZip: optional string

The postal or ZIP code.

provinceCode: optional string

The province or state code.

provinceOrState: optional string

The province or state name.

VerifiedAddress object { city, country, line1, 13 more }

The result of a verified international address.

city: string

The city or locality.

country: string

The country code (ISO 3166-1 alpha-2).

line1: string

The first address line.

postalOrZip: string

The postal or ZIP code.

provinceOrState: string

The province or state.

countryName: optional string

The full country name.

details: optional object { building, buildingType, cityName, 30 more }

Additional details about the verified address, such as premise, thoroughfare, and locality.

building: optional string

The building name or number.

buildingType: optional string

The type of building (e.g., apartment, office).

cityName: optional string

The full city name.

citySecondary: optional string

Secondary city information.

cityType: optional string

The type of city (e.g., city, town, village).

deliveryAddress: optional string

The full delivery address.

dependentLocality: optional string

The dependent locality (UK addresses).

doubleDependentLocality: optional string

The double dependent locality (UK addresses).

organization: optional string

The organization or company name.

postalOrZipPrimary: optional string

The primary part of the postal or ZIP code.

postalOrZipSecondary: optional string

The secondary part of the postal or ZIP code.

postBox: optional string

The post box number.

premise: optional string

The premise name or number.

premiseNumber: optional string

The premise number.

premiseSecondary: optional string

Secondary premise information.

premiseType: optional string

The type of premise (e.g., house, flat).

provinceOrStateName: optional string

The full name of the province or state.

provinceOrStateType: optional string

The type of province or state (e.g., province, state, region).

street: optional string

The street name.

streetPostDirection: optional string

The directional suffix for the street (e.g., N, S, E, W).

streetPreDirection: optional string

The directional prefix for the street (e.g., N, S, E, W).

streetType: optional string

The type of street (e.g., St, Ave, Blvd).

subAdministrativeArea: optional string

The sub-administrative area.

subBuilding: optional string

The sub-building name or number (e.g., unit, suite).

SubBuildingFloor: optional string

The floor of the sub-building.

subBuildingNumber: optional string

The sub-building number.

subBuildingType: optional string

The type of sub-building (e.g., floor, wing).

subStreet: optional string

The sub-street name.

subStreetPostDirection: optional string

The directional suffix for the sub-street.

subStreetPreDirection: optional string

The directional prefix for the sub-street.

subStreetType: optional string

The type of sub-street.

superAdministrativeArea: optional string

The super-administrative area.

telephone: optional string

The telephone number associated with the address.

errors: optional Errors { city, generic, line1, 3 more }

Errors encountered during address verification.

city: optional array of string

Errors related to the city.

generic: optional array of string

Generic errors not tied to a specific field.

line1: optional array of string

Errors related to the first address line.

line2: optional array of string

Errors related to the second address line.

postalOrZip: optional array of string

Errors related to the postal or ZIP code.

provinceOrState: optional array of string

Errors related to the province or state.

firmName: optional string

The firm or company name, if available.

formattedAddress: optional string

The formatted address string.

geoData: optional object { geoAccuracy, latitude, longitude }

Geocoding result for the verified address.

geoAccuracy: optional string

The geocode accuracy.

latitude: optional string

The latitude of the address.

longitude: optional string

The longitude of the address.

line2: optional string

The second address line.

line3: optional string

The third address line, if available.

status: optional Status

The verification status of an address.

One of the following:
"verified"
"corrected"
"failed"
summary: optional object { contextIdentificationMatchLevel, lexiconIdentificationMatchLevel, matchScore, 6 more }

A summary of the verification process and match levels.

contextIdentificationMatchLevel: optional string

Context identification match level.

lexiconIdentificationMatchLevel: optional string

Lexicon identification match level.

matchScore: optional number

The match score (0-100).

message: optional string

Additional message about the verification.

parsingStatus: optional string

The parsing status of the address.

postCodeStatus: optional string

The status of the postal code.

postProcessedVerificationMatchLevel: optional string

The match level after post-processing.

preProcessedVerificationMatchLevel: optional string

The match level before post-processing.

verificationStatus: optional string

The overall verification status.

zipPlus4: optional string

The ZIP+4 code (for US addresses).

message: string
status: "success" or "error"
One of the following:
"success"
"error"

Autocomplete

curl https://api.postgrid.com/v1/intl_addver/completions \
    -H 'Content-Type: application/json' \
    -H "X-API-Key: $POSTGRID_ADDRESS_VERIFICATION_API_KEY" \
    -d '{
          "id": "id"
        }'
{
  "data": {
    "building": "building",
    "city": "city",
    "company": "company",
    "country": "country",
    "countryCode": "countryCode",
    "department": "department",
    "error": "error",
    "formattedAddress": "formattedAddress",
    "line1": "line1",
    "line2": "line2",
    "line3": "line3",
    "line4": "line4",
    "postalOrZip": "postalOrZip",
    "provinceCode": "provinceCode",
    "provinceOrState": "provinceOrState"
  },
  "message": "message",
  "status": "success"
}
Returns Examples
{
  "data": {
    "building": "building",
    "city": "city",
    "company": "company",
    "country": "country",
    "countryCode": "countryCode",
    "department": "department",
    "error": "error",
    "formattedAddress": "formattedAddress",
    "line1": "line1",
    "line2": "line2",
    "line3": "line3",
    "line4": "line4",
    "postalOrZip": "postalOrZip",
    "provinceCode": "provinceCode",
    "provinceOrState": "provinceOrState"
  },
  "message": "message",
  "status": "success"
}