Up to 20% of packages struggle to get delivered due to errors in address validation. Typos, missing suite numbers, and incorrect postal codes all make address validation difficult. Our Address Verification API provides your customers with the best purchase experience by validating addresses and ensuring deliverability.
# Import the EasyPost client.
import easypost
# Setup the client with your API key.
easypost.api_key = '259DA788-39A3-439E-BA1E-BC541B8BA520'
# Create and verify an address.
easypost.Address.create(
verify=true,
street1='417 Montgomery Street',
street2='FL 5',
city='San Francisco',
state='CA',
zip='94104',
country='US',
company='EasyPost'
)
{
id: 'adr_3eb87ded5a824fd5bde6f6c977c33a30',
object: 'Address',
created_at: '2017-05-08T19:31:54Z',
updated_at: '2017-05-08T19:31:54Z',
mode: 'test',
name: null,
company: 'EASYPOST',
street1: '417 MONTGOMERY ST STE 500',
street2: '',
city: 'SAN FRANCISCO',
state: 'CA',
zip: '94104-1100',
country: 'US',
phone: '4151234567',
email: null,
carrier_facility: null,
residential: false,
federal_tax_id: null,
state_tax_id: null,
verifications: {
delivery: {
success: true,
errors: [],
details: {
longitude: -122.40288,
latitude: 37.79298,
time_zone: 'America/Los_Angeles',
},
},
},
}
Now that over 50% of internet traffic is via mobile devices, people are making purchases from their phones more than ever, but auto-correct functionality isn't always your friend. Using an address validation API helps your customers provide their address accurately to ensure they don't miss a delivery and you don't have to issue a refund.
With the growing world of ecommerce and countless competitors in any given market, you need to ensure that your customers are having a quality experience from the start of their buyer's journey, all the way to checkout. An address validation API makes the checkout experience efficient and enjoyable for your customers.
Using an address validation API automates the address verification processes so you and your support team can stop wasting time on fixing rejected labels, tracking down lost or undelivered packages, and dealing with upset customers.
Take a look at our documentation and start building with one of our helper libraries (Python, PHP, Ruby, Node.js, Java, and more). Avoid month-long integrations and start verifying addresses in minutes with EasyPost.