Page tree
Skip to end of metadata
Go to start of metadata



This operation performs basic checks on user supplied inputs; Address1, Address2, Municipality, Province or Postal Code and returns verified Address, Municipality, Province and Postal Code in Canadian address recommended format which is upper cased. There is also a method to return proper cased addresses by appending "-Proper" to the language parameter (e.g Language=EN-Proper). This operation also returns time zone and a check on if the supplied location is a P.O. Box, General Delivery or Rural Route. This operation requires either a Postal Code or both Municipality and Province.  Providing all inputs is recommended, because it helps the validation proceed if some of the elements are malformed. 

URL Endpoints


XML:

https://trial.serviceobjects.com/AVCA2/api.svc/ValidateCanadianAddressV2?PostalCode={POSTALCODE}&Province={PROVINCE}&Municipality={MUNICIPALITY}&Address2={ADDRESS2}&Address={ADDRESS}&Language={LANGUAGE}&LicenseKey={LICENSEKEY}


JSON:

https://trial.serviceobjects.com/AVCA2/api.svc/ValidateCanadianAddressV2?PostalCode={POSTALCODE}&Province={PROVINCE}&Municipality={MUNICIPALITY}&Address2={ADDRESS2}&Address={ADDRESS}&Language={LANGUAGE}&LicenseKey={LICENSEKEY}&Format=JSON



ValidateCanadianAddressV2 Inputs 


Name

Type

Description

Address

String

Address line of the address to validate. 
For example, "123 Main Street".

Address 2String

The Address2 of the address to validate. This will only be used in particular situations where the Address1 does not help in validating the address.

Municipality

String

The Municipality of the address to validate.

Province

String

The Province of the address to validate.

PostalCode

String

The Postal Code of the address to validate. A Postal Code isn't required, but if one is not provided, the Municipality and Province are required.

LanguageString

The Language to return the addresses as. Acceptable values are (English, EN, French, FR, EN-Proper, FR-Proper). Leaving this field blank will use the default behavior of returning addresses as English standardized if they are provided in English, and French standardized if provided in French. Adding the additional value "Proper" will apply proper casing to the output address.

LicenseKey

String

Your license key to use the service. 
Sign up for a free trial key at 
https://www.serviceobjects.com/products/address-geocoding/canada-address-validation


ValidateCanadianAddressV2 Outputs



CanadianAddressResponseV2

Name

Type

Values

Description

CanadianAddressInfoV2ObjectVariesThe returned values of a valid Canadian Address.
ErrorObjectVariesThe returned error result from a failed address verification or user input error.
DebugString[]VariesUsed internally for testing.

 

 CanadianAddressInfoV2 

Name

Type

Values

Description

Address

String

Varies

The corrected Address line 1.

Address 2StringVariesThe corrected Address line 2

Municipality

String

Varies

The corrected Municipality.

Province

String

Varies

The corrected Province.

PostalCode

String

Varies

The corrected PostalCode.

TimeZone

String

Varies

The corresponding time zone from the validated address.

AddressNumberFragment

String

Varies

The parsed address number returned from the validated address.
"123" in "123 S. Main Street" 

StreetNameFragment

String

Varies

The parsed street name fragment returned from the validated address. 
"Main" in "123 S. Main Street" 

StreetTypeFragment

String

Varies

The parsed street type returned from the validated address 
"Street" in "123 S. Main Street" 

DirectionalCodeFragment

String

Varies

The parsed returned directional code fragment from the validated address.
"S" in "123 S. Main Street" 

UnitTypeFragment

String

Varies

The parsed unit type fragment from the validated address. i.e. "Apt" or "Suite"

UnitNumberFragment

String

Varies

The parsed unit number fragment from the validated address. "1" of "Apt 1"

IsPOBox

String

Varies

The returned Boolean value of a validated address as being a PO Box address.

BoxNumberFragmentStringVariesThe returned Box Number from a PO Box address. "1234" of "PO Box 1234"
StationInfoStringVariesThe returned Station Name of the Delivery Station.
DeliveryModeStringVariesThe returned Delivery Mode of the address.
DeliveryInstallationStringVariesThe returned Delivery Installation Type where the final mail sort happens.
CorrectionsStringVariesSee Correction Code descriptions below.
CorrectionsDescriptionsStringVariesDescription of corrections made to input address.


References


  • No labels