HomeGuidesRecipesAPI ReferenceChangelog
Log In
API Reference

ZIP Code provides a set of information useful for display purposes. For example, if you are interested in tariffs for ZIP code 48322, you can retrieve additional information such as the city and county name as well as the latitude and longitude coordinates.

Data Definitions

ZIP Code

The Zip Code has the following data structure.

NameTypeDescription
zipcodeString5-character string of the zip code
latitudeIntegerLatitude of this location.
longitudeIntegerLongitude of this location.
cityStringDisplay name of the city containing this ZIP code.
countyStringDisplay name of the county containing this ZIP code.
areaCodeStringString containing the area code(s) containing this ZIP code. Area codes are separated a forward slash e.g. 415/510.
cityTypeStringNot currently used.
cityAliasAbbreviationStringIf not null, this has the abbreviation this city may be commonly used for this city.
elevationIntegerHighest point of elevation (in feet) within this zip code.
dayLightSavingBooleanTrue or false on whether this ZIP code observes daylight savings.
cityMixedCaseStringAlternate display name of the city containing this ZIP code.
stateAnsiIntegerState ANSI code representing the state containing this ZIP code.
countyAnsiIntegerANSI code represents the state containing this ZIP code.
stateStringTwo-character abbreviation of the state containing this ZIP code.
timeZoneIntegerNumber indicating the time zone. e.g. 8 is Pacific Time Zone.

Note the State ANSI codes for the USA can be found at https://www.census.gov/geo/reference/ansi_statetables.html.

Here's an example in JSON of a ZIP code

{  
	"zipcode":"48322",  
	"latitude":42,  
	"longitude":-83,  
	"city":"WEST BLOOMFIELD",  
	"county":"OAKLAND",  
	"areaCode":"248/734",  
	"cityType":"B",  
	"cityAliasAbbreviation":"W BLOOMFIELD",  
	"elevation":943,  
	"dayLightSaving":true,  
	"classificationCode":null,  
	"cityMixedCase":"West Bloomfield",  
	"cityAliasMixedCase":"West Bloomfield",  
	"stateAnsi":26,  
	"countyAnsi":125,  
	"state":"MI",  
	"timeZone":5  
}

Get a ZIP Code Details

This allows you to get the details for a ZIP code in the standard response format.

Resource URI

GET /rest/public/zipcodes/{zipCode}

Request Parameters

Along with the standard pagination parameterssearching and sorting parameters, and the required security parameters, the following parameters are available as part of the request:


NameTypeDescription
zipCodeStringPhrase for searching the names of ZIP Codes (Optional)

History

  • Formatting update - 3/10/2015
  • Initial Release - 6/9/2011 - Zip Code