Geo location - ZIP & Postal Codes (US & Canada only)

Display a list of the ZIP & Postal codes of US and Canada where your visitors come from.

API Usage

This API produces a json array.

Parameters

One or more of the following parameters are required:

date Calculate the top ZIP & postal codes from the specified date entered as yyyy-MM-dd. Default is the current date.
unixTime Calculate the top ZIP & postal codes from the specified unix timestamp. Default is the current unix timestamp.
period Specify the period:

  • d for days, eg: period=14d will show 14rows with daily trends, period=d defaults to 1 day
  • w for weeks, eg: period=12w will show 12 rows with weekly trends, period=w defaults to 1 week
  • m for months, eg: period=4m will show 4 rows with monthly trends, period=m defaults to 1 month

timeZone Calculate the top ZIP & postal codes for the specified timezone. The default is the site's defined timezone.

Optional parameters:

login Your opentracker login email. Default is [demo@opentracker.net].
password Your password.
ticketId A ticketId can be used to provide credentials with an expiring token. A ticketId can be used instead of a login/ password combination. Further information can be found here.
segment This is the property field based on which you want to segment the data. By default there are no segments. You can find more information here.
filter You can choose to see no segments [none] (default), see all segments showAllSorts, or by specifying the name of the segment.
site The site to display data for. Default is [www.opentracker.net].
locale The locale parameter is an identifier for a particular combination of language and region (e.g. en_US) and determines the format of the data returned. A list of locales can be found here.
ignoreLocale Display columns without language translation [false]|true.
dataType The dataType parameter determines the format of the data returned. Values can be [ json ] | html | jsondatatable | jsonjqgrid

Examples

Display a top postal codes for the website www.opentracker.net for the user "demo@opentracker.net" with password "demo123":
HTTP GET/ POST:/api/location/top_postal_codes.jsp?period=1d&login=demo@opentracker.net&password=demo123&site=www.opentracker.net
Display a top postal codes list for the website www.opentracker.net from 2023-11-28 and three weeks back display in html:
HTTP GET/ POST:/api/location/top_postal_codes.jsp?date=2023-11-28&login=demo@opentracker.net&password=demo123&site=www.opentracker.net&period=3w&dataType=html
Display a top postal codes list for the website www.opentracker.net for the day of 2023-11-28:
HTTP GET/ POST:/api/location/top_postal_codes.jsp?period=1d&date=2023-11-28

Response

This last example returns a json array with 'n' entries starting from the specified period and date formatted as:

{ "resultsList": [
{
"No.":"1",
"ZIP/ postal codes":"Mumbai, 16 400070, IN",
"users":"55",
"graph":"||||||||||||||||||||",
"percentage":"5.3%"}
,
{
"No.":"2",
"ZIP/ postal codes":"Patna, 34 800001, IN",
"users":"37",
"graph":"|||||||||||||",
"percentage":"3.6%"}
,
{
"No.":"3",
"ZIP/ postal codes":"Bengaluru, 19 560076, IN",
"users":"33",
"graph":"||||||||||||",
"percentage":"3.2%"}
,
{
"No.":"4",
"ZIP/ postal codes":"Sydney, 02 2000, AU",
"users":"33",
"graph":"||||||||||||",
"percentage":"3.2%"}
,
{
"No.":"5",
"ZIP/ postal codes":"Chennai, 25 600001, IN",
"users":"29",
"graph":"|||||||||||",
"percentage":"2.8%"}
,
{
"No.":"6",
"ZIP/ postal codes":"Dhaka, 81 1000, BD",
"users":"27",
"graph":"||||||||||",
"percentage":"2.6%"}
,
{
"No.":"7",
"ZIP/ postal codes":"Bengaluru, 19 560001, IN",
"users":"25",
"graph":"|||||||||",
"percentage":"2.4%"}
,
{
"No.":"8",
"ZIP/ postal codes":"Kuala Lumpur, 14 50506, MY",
"users":"23",
"graph":"||||||||",
"percentage":"2.2%"}
,
{
"No.":"9",
"ZIP/ postal codes":"Delhi, 07 110001, IN",
"users":"23",
"graph":"||||||||",
"percentage":"2.2%"}
,
{
"No.":"10",
"ZIP/ postal codes":"Kolkata, 28 700059, IN",
"users":"22",
"graph":"||||||||",
"percentage":"2.1%"}
,
{
"No.":"11",
"ZIP/ postal codes":"Chennai, 25 600042, IN",
"users":"20",
"graph":"|||||||",
"percentage":"1.9%"}
,
{
"No.":"12",
"ZIP/ postal codes":"Sofia, Unknown 1000, BG",
"users":"18",
"graph":"|||||||",
"percentage":"1.7%"}
,
{
"No.":"13",
"ZIP/ postal codes":"Lahore, 04 54000, PK",
"users":"17",
"graph":"||||||",
"percentage":"1.6%"}
,
{
"No.":"14",
"ZIP/ postal codes":"Bengaluru, 19 560002, IN",
"users":"15",
"graph":"|||||",
"percentage":"1.5%"}
,
{
"No.":"15",
"ZIP/ postal codes":"San Jose, CA 95126, US",
"users":"15",
"graph":"|||||",
"percentage":"1.5%"}
,
{
"No.":"16",
"ZIP/ postal codes":"Frankfurt Am Main, 05 60313, DE",
"users":"14",
"graph":"|||||",
"percentage":"1.4%"}
,
{
"No.":"17",
"ZIP/ postal codes":"Dhaka, 81 1212, BD",
"users":"13",
"graph":"|||||",
"percentage":"1.3%"}
,
{
"No.":"18",
"ZIP/ postal codes":"Brisbane, 04 4000, AU",
"users":"13",
"graph":"|||||",
"percentage":"1.3%"}
,
{
"No.":"19",
"ZIP/ postal codes":"Delhi, 07 110003, IN",
"users":"13",
"graph":"|||||",
"percentage":"1.3%"}
,
{
"No.":"20",
"ZIP/ postal codes":"Navi Mumbai, 16 400702, IN",
"users":"12",
"graph":"||||",
"percentage":"1.2%"}
,
{
"No.":"21",
"ZIP/ postal codes":"Pune, 16 411001, IN",
"users":"12",
"graph":"||||",
"percentage":"1.2%"}
,
{
"No.":"22",
"ZIP/ postal codes":"Pune, 16 411038, IN",
"users":"11",
"graph":"||||",
"percentage":"1.1%"}
,
{
"No.":"23",
"ZIP/ postal codes":"London, Unknown EC4R, GB",
"users":"11",
"graph":"||||",
"percentage":"1.1%"}
,
{
"No.":"24",
"ZIP/ postal codes":"Bengaluru, 19 560025, IN",
"users":"11",
"graph":"||||",
"percentage":"1.1%"}
,
{
"No.":"25",
"ZIP/ postal codes":"Chittagong, 84 4000, BD",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"26",
"ZIP/ postal codes":"Amsterdam, 07 1012, NL",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"27",
"ZIP/ postal codes":"Lucknow, 36 226016, IN",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"28",
"ZIP/ postal codes":"Kochi, 13 682507, IN",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"29",
"ZIP/ postal codes":"Gurugram, 10 122001, IN",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"30",
"ZIP/ postal codes":"Miami, FL 33197, US",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"31",
"ZIP/ postal codes":"Ahmedabad, 09 380001, IN",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"32",
"ZIP/ postal codes":"Davao City, Unknown 8000, PH",
"users":"10",
"graph":"||||",
"percentage":"1.0%"}
,
{
"No.":"33",
"ZIP/ postal codes":"Puchong Batu Dua Belas, 12 47100, MY",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"34",
"ZIP/ postal codes":"Indore, 35 452001, IN",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"35",
"ZIP/ postal codes":"Hyderabad, 40 500001, IN",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"36",
"ZIP/ postal codes":"Dallas, TX 75270, US",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"37",
"ZIP/ postal codes":"Manila, Unknown 1018, PH",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"38",
"ZIP/ postal codes":"Bengaluru, 19 560067, IN",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"39",
"ZIP/ postal codes":"Noida, 36 110091, IN",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"40",
"ZIP/ postal codes":"Los Angeles, CA 90060, US",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"41",
"ZIP/ postal codes":"Dehradun, 39 248001, IN",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"42",
"ZIP/ postal codes":"Paris, A8 75001, FR",
"users":"9",
"graph":"|||",
"percentage":"0.9%"}
,
{
"No.":"43",
"ZIP/ postal codes":"Noida, 36 110001, IN",
"users":"8",
"graph":"|||",
"percentage":"0.8%"}
,
{
"No.":"44",
"ZIP/ postal codes":"Johannesburg, 06 2041, ZA",
"users":"8",
"graph":"|||",
"percentage":"0.8%"}
,
{
"No.":"45",
"ZIP/ postal codes":"Lucknow, 36 226003, IN",
"users":"8",
"graph":"|||",
"percentage":"0.8%"}
,
{
"No.":"46",
"ZIP/ postal codes":"Toronto, ON M4J, CA",
"users":"8",
"graph":"|||",
"percentage":"0.8%"}
,
{
"No.":"47",
"ZIP/ postal codes":"Patna, 34 800020, IN",
"users":"8",
"graph":"|||",
"percentage":"0.8%"}
,
{
"No.":"48",
"ZIP/ postal codes":"Mäntsälä, Unknown 04600, FI",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"49",
"ZIP/ postal codes":"Mumbai, 16 400069, IN",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"50",
"ZIP/ postal codes":"Houston, TX 77052, US",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"51",
"ZIP/ postal codes":"Mumbai, 16 110001, IN",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"52",
"ZIP/ postal codes":"Linkoping, 16 58002, SE",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"53",
"ZIP/ postal codes":"Dhaka, 81 1207, BD",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"54",
"ZIP/ postal codes":"Islamabad, 08 44000, PK",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"55",
"ZIP/ postal codes":"Toronto, ON M5A, CA",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"56",
"ZIP/ postal codes":"Caloocan City, Unknown 1411, PH",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"57",
"ZIP/ postal codes":"Jaipur, 24 302001, IN",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"58",
"ZIP/ postal codes":"Auckland, E7 1010, NZ",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"59",
"ZIP/ postal codes":"Chandigarh, 05 160047, IN",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"60",
"ZIP/ postal codes":"Mumbai, 16 400072, IN",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"61",
"ZIP/ postal codes":"Delhi, 07 110008, IN",
"users":"7",
"graph":"|||",
"percentage":"0.7%"}
,
{
"No.":"62",
"ZIP/ postal codes":"Glasgow, V2 G3, GB",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"63",
"ZIP/ postal codes":"Amsterdam, 07 1181, NL",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"64",
"ZIP/ postal codes":"Bucharest, 10 050051, RO",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"65",
"ZIP/ postal codes":"Chittagong, 84 4216, BD",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"66",
"ZIP/ postal codes":"Kuala Lumpur, 14 50504, MY",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"67",
"ZIP/ postal codes":"Adelaide, 05 5000, AU",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"68",
"ZIP/ postal codes":"Lisbon, 14 1500-001, PT",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"69",
"ZIP/ postal codes":"San Diego, CA 92101, US",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"70",
"ZIP/ postal codes":"Atlanta, GA 30301, US",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"71",
"ZIP/ postal codes":"New York, J5 NE27, GB",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"72",
"ZIP/ postal codes":"Melbourne, 07 3000, AU",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"73",
"ZIP/ postal codes":"Munich, 02 80331, DE",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"74",
"ZIP/ postal codes":"Jaipur, 24 302021, IN",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"75",
"ZIP/ postal codes":"Jaipur, 24 302012, IN",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"76",
"ZIP/ postal codes":"Makati City, Unknown 1214, PH",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"77",
"ZIP/ postal codes":"Delhi, 07 110005, IN",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"78",
"ZIP/ postal codes":"Naaldwijk, 11 2671, NL",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"79",
"ZIP/ postal codes":"Zagreb, Unknown 10000, HR",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"80",
"ZIP/ postal codes":"Hyderabad, 40 500072, IN",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"81",
"ZIP/ postal codes":"Seattle, WA 98160, US",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"82",
"ZIP/ postal codes":"Houston, TX 77002, US",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"83",
"ZIP/ postal codes":"Mexico City, Unknown 03020, MX",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"84",
"ZIP/ postal codes":"Detroit, MI 48272, US",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"85",
"ZIP/ postal codes":"Pune, 16 411033, IN",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"86",
"ZIP/ postal codes":"Meerut, 36 250001, IN",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"87",
"ZIP/ postal codes":"Mumbai, 16 400078, IN",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"88",
"ZIP/ postal codes":"Dhaka, 81 1217, BD",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"89",
"ZIP/ postal codes":"New York, NY 10118, US",
"users":"6",
"graph":"||",
"percentage":"0.6%"}
,
{
"No.":"90",
"ZIP/ postal codes":"Delhi, 07 110054, IN",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"91",
"ZIP/ postal codes":"Lucknow, 36 226002, IN",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"92",
"ZIP/ postal codes":"Johannesburg, 06 2188, ZA",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"93",
"ZIP/ postal codes":"Varna, 61 9000, BG",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"94",
"ZIP/ postal codes":"Karachi, 05 74800, PK",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"95",
"ZIP/ postal codes":"Karachi, 05 74600, PK",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"96",
"ZIP/ postal codes":"Mumbai, 16 110005, IN",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"97",
"ZIP/ postal codes":"Cincinnati, OH 45219, US",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"98",
"ZIP/ postal codes":"Phoenix, AZ 85036, US",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"99",
"ZIP/ postal codes":"Hyderabad, 40 500084, IN",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"100",
"ZIP/ postal codes":"San Jose, CA 95141, US",
"users":"5",
"graph":"||",
"percentage":"0.5%"}
,
{
"No.":"",
"ZIP/ postal codes":"",
"users":"1,033",
"graph":"",
"percentage":"100%"}
]
}

Errors

If errors are encountered, the first encountered error will be returned of form "Error: exception: message

Error: java.lang.RuntimeException: Login/ site combination is not valid

We would love to hear your feedback. Please use the facebook comment box below